diff options
| author | Michael R Sweet <michael.r.sweet@gmail.com> | 2005-03-05 23:01:00 +0000 |
|---|---|---|
| committer | Michael R Sweet <michael.r.sweet@gmail.com> | 2005-03-05 23:01:00 +0000 |
| commit | e6399f8f3711bc8757d0bb4b59af3fe7d52290a7 (patch) | |
| tree | b5154f31d2690926f87871b5e89dab777caaf3c4 /src/Fl_Menu.cxx | |
| parent | a48c6dd545b385bd7d5f92fee662647b87d93d1c (diff) | |
Fix menu drawing...
src/fl_draw.cxx:
- fl_measure(): use "h" instead of "min(w,h)", since "w" is
usually 0.
src/Fl_Menu.cxx:
- Revert previous "fix" in Fl_Menu_Item::measure()
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4070 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_Menu.cxx')
| -rw-r--r-- | src/Fl_Menu.cxx | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/Fl_Menu.cxx b/src/Fl_Menu.cxx index 61e0dd98f..a5b993db8 100644 --- a/src/Fl_Menu.cxx +++ b/src/Fl_Menu.cxx @@ -122,8 +122,7 @@ int Fl_Menu_Item::measure(int* hp, const Fl_Menu_* m) const { l.size = labelsize_ ? labelsize_ : m ? m->textsize() : (uchar)FL_NORMAL_SIZE; l.color = FL_BLACK; // this makes no difference? fl_draw_shortcut = 1; - int w = l.size; int h = l.size; - if (hp) *hp = h; + int w = 0; int h = 0; l.measure(w, hp ? *hp : h); fl_draw_shortcut = 0; if (flags & (FL_MENU_TOGGLE|FL_MENU_RADIO)) w += 14; |
