From: SourceForge.net <no...@so...> - 2011-03-22 07:45:10
|
Bugs item #3234167, was opened at 2011-03-22 00:45 Message generated for change (Tracker Item Submitted) made by arobert3434 You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=112997&aid=3234167&group_id=12997 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: 66. Aqua Window Operations Group: development: 8.6b1.1 Status: Open Resolution: None Priority: 5 Private: No Submitted By: Adrian Robert (arobert3434) Assigned to: Daniel A. Steffen (das) Summary: Image and font problems on Tk Cocoa Buttons Initial Comment: Last-CVS Tk. Image button displays the image off-center and if border width 0 will obscure one pixel around the image. Text buttons, if the font is set, seem to be setting their size based on the point size rather than querying the font's metrics. These problems are specific to Tk Cocoa and do not occur under Tk Carbon. The following script reproduces, and the attached zip contains the image and screenshots of the results. #!/usr/bin/wish # Reproduce Tk-Cocoa button issues # Last-CVS version as of 2011-03-22 set searchButtonImg [image create photo -file "searchButton.gif"] toplevel .l wm title .l [expr { $tcl_platform(pointerSize) == 8 ? "Cocoa" : "Carbon" }] frame .l.i frame .l.t button .l.i.b1 -image $searchButtonImg -borderwidth 0 button .l.i.b2 -image $searchButtonImg -borderwidth 1 set cfont [font create -family 华文楷体 -size 24] set tfont [font create -family Courier -size 24] button .l.t.b1 -font $cfont -text "华文楷体" button .l.t.b2 -font $tfont -text "Courier" pack .l.i.b1 -padx 10 pack .l.i.b2 -padx 10 pack .l.t.b1 -padx 10 pack .l.t.b2 -padx 10 pack .l.i -pady 10 pack .l.t -pady 10 ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=112997&aid=3234167&group_id=12997 |