source: rtems-graphics-toolkit/fltk-1.3.0/test/fast_slow.fl @ 855379e

Last change on this file since 855379e was f5c9e9c, checked in by Alexandru-Sever Horin <alex.sever.h@…>, on 07/05/12 at 09:33:03

Aded FLTK 1.3.0

  • Property mode set to 100644
File size: 1.2 KB
Line 
1# data file for the Fltk User Interface Designer (fluid)
2version 1.00
3header_name {.h}
4code_name {.cxx}
5gridx 10
6gridy 10
7snap 3
8Function {} {open
9} {
10  Fl_Window {} {open
11    xywh {143 188 318 443} resizable visible
12  } {
13    Fl_Slider control {
14      label {move
15this}
16      callback {fast->value(o->value());
17if (!Fl::pushed()) slow->value(o->value());}
18      xywh {90 200 30 200}
19      code0 {o->when(FL_WHEN_CHANGED|FL_WHEN_RELEASE|FL_WHEN_NOT_CHANGED);}
20    }
21    Fl_Slider fast {
22      label {fast
23redraw} selected
24      xywh {140 200 30 200}
25      code0 {o->set_output();}
26    }
27    Fl_Slider slow {
28      label {slow
29redraw} selected
30      xywh {190 200 30 200}
31      code0 {o->set_output();}
32    }
33    Fl_Box {} {
34      label {The left slider has changed( FL_WHEN_CHANGED | FL_WHEN_RELEASE | FL_WHEN_NOT_CHANGED) so it produces a callback on both drag and release mouse events.
35The middle slider (representing a widget with low overhead) is changed on every mouse movement.
36The right slider (representing a widget with high overhead) is only updated when the mouse is released, by checking if Fl::pushed() is zero.}
37      xywh {10 10 300 180} box DOWN_BOX color 53 selection_color 47 labelfont 4 labelsize 12 align 148
38    }
39  }
40}
Note: See TracBrowser for help on using the repository browser.