diff options
| author | Michael R Sweet <michael.r.sweet@gmail.com> | 2002-04-27 19:35:18 +0000 |
|---|---|---|
| committer | Michael R Sweet <michael.r.sweet@gmail.com> | 2002-04-27 19:35:18 +0000 |
| commit | 9f5d6a0ecbf4c8beaed7028c13f52aad443cf394 (patch) | |
| tree | 5e6297758864c859edc307ad630c307f5e9feba9 /src/Fl_Light_Button.cxx | |
| parent | a48e1cac3fa0be3594245cbb8180e0bbf323f35f (diff) | |
Fix rendering of Fl_Light_Button with the plastic scheme.
The "none" and "base" schemes map to no scheme (standard FLTK look-n-feel)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2119 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_Light_Button.cxx')
| -rw-r--r-- | src/Fl_Light_Button.cxx | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/Fl_Light_Button.cxx b/src/Fl_Light_Button.cxx index 8a9ad003f..f23f7614e 100644 --- a/src/Fl_Light_Button.cxx +++ b/src/Fl_Light_Button.cxx @@ -1,5 +1,5 @@ // -// "$Id: Fl_Light_Button.cxx,v 1.4.2.3.2.13 2002/04/11 10:46:19 easysw Exp $" +// "$Id: Fl_Light_Button.cxx,v 1.4.2.3.2.14 2002/04/27 19:35:18 easysw Exp $" // // Lighted button widget for the Fast Light Tool Kit (FLTK). // @@ -92,7 +92,13 @@ void Fl_Light_Button::draw() { int ww = W/2+1; int xx = dx; if (w()<ww+2*xx) xx = (w()-ww)/2; - draw_box(FL_THIN_DOWN_BOX, x()+xx, y()+dy+1, ww, hh, col); + if (Fl::scheme()) { + col = active_r() ? selection_color() : fl_inactive(selection_color()); + fl_color(value() ? col : fl_color_average(col, FL_BLACK, 0.5f)); + fl_pie(x()+xx, y()+dy+1, ww, hh, 0, 360); + } else { + draw_box(FL_THIN_DOWN_BOX, x()+xx, y()+dy+1, ww, hh, col); + } dx = (ww + 2 * dx - W) / 2; } draw_label(x()+W+2*dx, y(), w()-W-2*dx, h()); @@ -116,5 +122,5 @@ Fl_Light_Button::Fl_Light_Button(int x, int y, int w, int h, const char* l) } // -// End of "$Id: Fl_Light_Button.cxx,v 1.4.2.3.2.13 2002/04/11 10:46:19 easysw Exp $". +// End of "$Id: Fl_Light_Button.cxx,v 1.4.2.3.2.14 2002/04/27 19:35:18 easysw Exp $". // |
