diff options
author | kevin_walzer <kevin_walzer@noemail.net> | 2016-07-06 03:00:40 (GMT) |
---|---|---|
committer | kevin_walzer <kevin_walzer@noemail.net> | 2016-07-06 03:00:40 (GMT) |
commit | 432cc3db31d83cc48cb1e74708485e3a7ebd9745 (patch) | |
tree | 7091afb4c46f00d75d600337c1676711722c6bfa | |
parent | acc0c1903d40e137f36a1b40d4366a9c5aa9b7a6 (diff) | |
download | tk-432cc3db31d83cc48cb1e74708485e3a7ebd9745.zip tk-432cc3db31d83cc48cb1e74708485e3a7ebd9745.tar.gz tk-432cc3db31d83cc48cb1e74708485e3a7ebd9745.tar.bz2 |
Fix for excessive label padding in Tk/Mac; thanks to Brad Lanam for bug report
FossilOrigin-Name: 18b19e31b4e94cdc484e399f9faf51d4df8c8982
-rw-r--r-- | macosx/tkMacOSXButton.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/macosx/tkMacOSXButton.c b/macosx/tkMacOSXButton.c index ebbcf09..f4fbc48 100644 --- a/macosx/tkMacOSXButton.c +++ b/macosx/tkMacOSXButton.c @@ -318,7 +318,8 @@ TkpComputeButtonGeometry( Tcl_GetString(butPtr->textPtr), -1, butPtr->wrapLength, butPtr->justify, 0, &butPtr->textWidth, &butPtr->textHeight); - txtWidth = butPtr->textWidth + DEF_INSET_LEFT + DEF_INSET_RIGHT; + /*Remove extraneous padding around label widgets.*/ + txtWidth = butPtr->textWidth; txtHeight = butPtr->textHeight + DEF_INSET_BOTTOM + DEF_INSET_TOP; charWidth = Tk_TextWidth(butPtr->tkfont, "0", 1); Tk_GetFontMetrics(butPtr->tkfont, &fm); |