• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.10/tcl-105/tk/tk/win/

Lines Matching refs:width

63  * Cached information about the boxes bitmap, and the default border width for
192 int width = GetSystemMetrics(SM_CXEDGE);
193 if (width > 0) {
194 sprintf(tkDefButtonBorderWidth, "%d", width);
336 int width = 0, height = 0, haveImage = 0, haveText = 0, drawRing = 0;
414 * Compute width of default ring and offset for pushed buttons.
447 Tk_SizeOfImage(butPtr->image, &width, &height);
450 Tk_SizeOfBitmap(butPtr->display, butPtr->bitmap, &width, &height);
453 imageWidth = width;
474 fullWidth = (width > butPtr->textWidth ? width :
477 imageXOffset = (fullWidth - width)/2;
487 textXOffset = width + butPtr->padX;
491 fullWidth = butPtr->textWidth + butPtr->padX + width;
503 fullWidth = (width > butPtr->textWidth ? width :
508 imageXOffset = (fullWidth - width)/2;
528 width, height, pixmap, imageXOffset, imageYOffset);
532 width, height, pixmap, imageXOffset, imageYOffset);
534 Tk_RedrawImage(butPtr->image, 0, 0, width, height, pixmap,
540 0, 0, (unsigned int) width, (unsigned int) height,
571 butPtr->indicatorSpace + width, height, &x, &y);
583 Tk_RedrawImage(butPtr->selectImage, 0, 0, width, height,
587 Tk_RedrawImage(butPtr->tristateImage, 0, 0, width, height,
590 Tk_RedrawImage(butPtr->image, 0, 0, width, height, pixmap,
596 (unsigned int) width, (unsigned int) height, x, y, 1);
825 int width = 0, height = 0; /* Width and height of button */
900 * Set width and height by button type; See User Experience table, p449.
908 * First compute the minimum width of the button in characters. MWUE
913 * The width is specified in characters. A character is, by
915 * = 50 DLU. Therefore, width = -11 -> MWUE compliant buttons.
918 if (butPtr->width < 0) {
919 minWidth = -(butPtr->width); /* Min width in chars */
920 width = avgWidth * minWidth; /* Allow for characters */
921 width += (int)(0.5 + (6 * hDLU)); /* Add for padding */
925 * If shrink-wrapping was requested (width = 0) or if the text is
926 * wider than the default button width, adjust the button width up to
930 if (butPtr->width == 0
931 || (txtWidth + (int)(0.5 + (6 * hDLU)) > width)) {
932 width = txtWidth + (int)(0.5 + (6 * hDLU));
947 * added later so reduce width and height now to compensate.
950 width -= 10;
967 width = txtWidth;
991 width = txtWidth;
1019 * At this point, the width and height are correct for a Tk text button,
1039 if (imgWidth > width) {
1040 width = imgWidth;
1051 * Only increase width of button if image doesn't fit in slack
1052 * space of default button width
1055 if ((imgWidth + txtWidth + butPtr->padX) > width) {
1056 width = imgWidth + txtWidth + butPtr->padX;
1069 if (imgWidth > width) {
1070 width = imgWidth;
1081 * Fix up for minimum width.
1084 if (butPtr->width < 0) {
1089 minWidth = -(butPtr->width);
1090 if (width < minWidth) {
1091 width = minWidth;
1093 } else if (butPtr->width > 0) {
1094 width = butPtr->width;
1101 width += 2*butPtr->padX;
1104 if (butPtr->width > 0) {
1105 width = butPtr->width;
1107 width = imgWidth;
1120 * butPtr->width is in characters. We need to allow for that many
1121 * characters on the face, not in the over-all button width
1124 if (butPtr->width > 0) {
1125 width = butPtr->width * avgWidth;
1154 width += 2 * butPtr->padX;
1159 * Fix up width and height for indicator sizing and spacing.
1185 width += butPtr->indicatorSpace;
1193 width += 2 * butPtr->inset;
1196 Tk_GeometryRequest(butPtr->tkwin, width, height);