Tk Source Code

Check-in [9e3533bf]
Login
Bounty program for improvements to Tcl and certain Tcl packages.
Tcl 2019 Conference, Houston/TX, US, Nov 4-8
Send your abstracts to [email protected]
or submit via the online form by Sep 9.

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Cleanup of bounds in button code.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | core-8-5-branch
Files: files | file ages | folders
SHA1: 9e3533bf31d3691c2b786d84922e5c11102920a3
User & Date: kevin_walzer 2015-02-16 22:06:17
Context
2015-02-18
03:32
Fine-tune display during resize events; now shows resize in progress but does not redraw contentview until done check-in: d22491b4 user: kevin_walzer tags: core-8-5-branch
2015-02-16
22:06
Merge mark check-in: f434c087 user: kevin_walzer tags: trunk
22:06
Cleanup of bounds in button code. check-in: 9e3533bf user: kevin_walzer tags: core-8-5-branch
20:19
Major fix for HITheme button metrics; thanks to Marc Culler for patch. check-in: 05455332 user: kevin_walzer tags: core-8-5-branch
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to macosx/tkMacOSXButton.c.

406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
        if (width < contBounds.size.width) {
    	  width = contBounds.size.width;
        }

        /* Pad to fill difference between content bounds and button bounds. */
    	paddingx = contBounds.origin.x;
    	paddingy = contBounds.origin.y;
        if (paddingx > 0) {
    	  //width += paddingx;
        }
        if (paddingy > 0) {
    	  //height += paddingy;
        }

        if (height < paddingx - 4) {
            /* can't have buttons much shorter than button side diameter. */
            height = paddingx - 4;
    	}

    } else {






<
<
<
<
<
<







406
407
408
409
410
411
412






413
414
415
416
417
418
419
        if (width < contBounds.size.width) {
    	  width = contBounds.size.width;
        }

        /* Pad to fill difference between content bounds and button bounds. */
    	paddingx = contBounds.origin.x;
    	paddingy = contBounds.origin.y;







        if (height < paddingx - 4) {
            /* can't have buttons much shorter than button side diameter. */
            height = paddingx - 4;
    	}

    } else {