You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While looking closely at the Fl_Input_Choice widget, I noticed the lower right and bottom part of the focus box wasn't being drawn, e.g. with test/input_choice:
This wasn't introduced by my recent changes to Fl_Input_Choice; the older code did this too; I just tested a July 2021 snapshot and it had it too.
Not sure if this is unique to Fl_Input_Choice, or just due to how small the button is.
Since the focus box dotted line issue comes up a lot, we should probably have a unit test for it (I don't think we have one currently).
As a side note while sniffing around, I'm also noticing Fl_Choice does not show a focus box at all, but does if you change the scheme(). This can be seen by running the test/unittests -> "schemes test", and changing the "FLTK Scheme" chooser from one scheme to another. (Only the "none" scheme has no focus box). EDIT: This might be by design; "focus" is perhaps shown by the highlight color for the default scheme; the widget has a very different look in the default scheme when compared to the other scheme settings.
The text was updated successfully, but these errors were encountered:
Apparently even though the custom menu button widget's ctor sets the box() type to FL_UP_BOX, it's set back to FL_FLAT_BOX by the time draw() is called, causing draw_focus() to draw a focus box appropriate for an FL_FLAT_BOX, and not an FL_UP_BOX. Hence the issue.
Still investigating.. but seems to be related to that.
Seems to be a problem introduced by user-submitted patch in STR#2750 by user "dfatfl", accepted in a1d555b, when Fl_Input_Choice was separated from a single .H file into separate .H + .cxx files, back in 2017.
Seems the FL_FLAT_BOX is coming from this line added in the ctor by that patch: menu_->box(FL_FLAT_BOX); // cosmetic
Going to back that out, but we should probably carefully look at that patch to see what else was changed during the code split, as there are at least two of these 'cosmetic' entries that were not in the original code.
While looking closely at the Fl_Input_Choice widget, I noticed the lower right and bottom part of the focus box wasn't being drawn, e.g. with test/input_choice:
This wasn't introduced by my recent changes to Fl_Input_Choice; the older code did this too; I just tested a July 2021 snapshot and it had it too.
Not sure if this is unique to Fl_Input_Choice, or just due to how small the button is.
Since the focus box dotted line issue comes up a lot, we should probably have a unit test for it (I don't think we have one currently).
As a side note while sniffing around, I'm also noticing Fl_Choice does not show a focus box at all, but does if you change the scheme(). This can be seen by running the test/unittests -> "schemes test", and changing the "FLTK Scheme" chooser from one scheme to another. (Only the "none" scheme has no focus box). EDIT: This might be by design; "focus" is perhaps shown by the highlight color for the default scheme; the widget has a very different look in the default scheme when compared to the other scheme settings.
The text was updated successfully, but these errors were encountered: