From: <no...@so...> - 2001-06-29 04:42:02
|
Bugs item #437282, was opened at 2001-06-28 21:42 You can respond by visiting: http://sourceforge.net/tracker/?func=detail&atid=112997&aid=437282&group_id=12997 Category: [*button] and [label] Group: 8.3.3 Status: Open Resolution: None Priority: 5 Submitted By: Christopher Heiny (clheiny) Assigned to: Nobody/Anonymous (nobody) Summary: Windows button -highlight* broken Initial Comment: OK, if it's not actually broken, the behavior inconsistent, and the fix is not readily apparent from the documenation, and the fix might cause portability problems (different behavior on different platforms. Run the following code snippit in wish 8.3.3 on Linux. toplevel .t button .t.b -text "Foo" -command {puts stdout "Foo!"} -highlightthickness 2 -highlightcolor red -highlightbackground red -borderwidth 0 pack .t.b And you should see a flat button with a 2bit red box around it. However, under Windows, the same code snippet results in no visible border (although the widget >is< sized correctly to accomodate the border). However, if you then type .t.b configure -default active The missing border is displayed correctly (correct == in the manner displayed under Unix, which is what is described in the documentation, and is what I expect it to be doing). The culprit code appears to be in tk/win/winButton.c, around line 399. At this point, highlightthickness is overridden and forced to zero if the "-default" option is not "active". A brief perusal of tk/unix/unixButton.c does not turn up a similar value stomp; however, I didn't do a detailed walkthru so it may have eluded me. Something that just occurred to me is that the default setting for "-default" may be different between the two platforms. I haven't checked that. I haven't checked Mac behavior, either. ---------------------------------------------------------------------- You can respond by visiting: http://sourceforge.net/tracker/?func=detail&atid=112997&aid=437282&group_id=12997 |
From: <no...@so...> - 2001-12-27 20:20:58
|
Bugs item #437282, was opened at 2001-06-28 21:42 You can respond by visiting: http://sourceforge.net/tracker/?func=detail&atid=112997&aid=437282&group_id=12997 Category: 03. [*button] and [label] Group: = 8.3.3 >Status: Closed >Resolution: Invalid Priority: 5 Submitted By: Christopher Heiny (clheiny) Assigned to: Nobody/Anonymous (nobody) Summary: Windows button -highlight* broken Initial Comment: OK, if it's not actually broken, the behavior inconsistent, and the fix is not readily apparent from the documenation, and the fix might cause portability problems (different behavior on different platforms. Run the following code snippit in wish 8.3.3 on Linux. toplevel .t button .t.b -text "Foo" -command {puts stdout "Foo!"} -highlightthickness 2 -highlightcolor red -highlightbackground red -borderwidth 0 pack .t.b And you should see a flat button with a 2bit red box around it. However, under Windows, the same code snippet results in no visible border (although the widget >is< sized correctly to accomodate the border). However, if you then type .t.b configure -default active The missing border is displayed correctly (correct == in the manner displayed under Unix, which is what is described in the documentation, and is what I expect it to be doing). The culprit code appears to be in tk/win/winButton.c, around line 399. At this point, highlightthickness is overridden and forced to zero if the "-default" option is not "active". A brief perusal of tk/unix/unixButton.c does not turn up a similar value stomp; however, I didn't do a detailed walkthru so it may have eluded me. Something that just occurred to me is that the default setting for "-default" may be different between the two platforms. I haven't checked that. I haven't checked Mac behavior, either. ---------------------------------------------------------------------- >Comment By: Jeffrey Hobbs (hobbs) Date: 2001-12-27 12:20 Message: Logged In: YES user_id=72656 These differences are intended to make Tk on Windows more like true Windows buttons. ---------------------------------------------------------------------- You can respond by visiting: http://sourceforge.net/tracker/?func=detail&atid=112997&aid=437282&group_id=12997 |