diff options
Diffstat (limited to 'src/Fl_Positioner.cxx')
| -rw-r--r-- | src/Fl_Positioner.cxx | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/Fl_Positioner.cxx b/src/Fl_Positioner.cxx index a960f707c..1cb0bd7a1 100644 --- a/src/Fl_Positioner.cxx +++ b/src/Fl_Positioner.cxx @@ -25,6 +25,7 @@ // http://www.fltk.org/str.php // + // The positioner widget from Forms, gives 2D input // Written by: Mark Overmars @@ -56,6 +57,7 @@ void Fl_Positioner::draw() { draw_label(); } +/** Returns the current position in x and y.*/ int Fl_Positioner::value(double X, double Y) { clear_changed(); if (X == xvalue_ && Y == yvalue_) return 0; @@ -64,10 +66,12 @@ int Fl_Positioner::value(double X, double Y) { return 1; } +/** Sets the X axis coordinate.*/ int Fl_Positioner::xvalue(double X) { return(value(X, yvalue_)); } +/** Sets the Y axis coordinate.*/ int Fl_Positioner::yvalue(double Y) { return(value(xvalue_, Y)); } @@ -120,6 +124,10 @@ int Fl_Positioner::handle(int e) { return handle(e, x(), y(), w(), h()); } +/** + Creates a new Fl_Positioner widget using the given position, + size, and label string. The default boxtype is FL_NO_BOX. +*/ Fl_Positioner::Fl_Positioner(int X, int Y, int W, int H, const char* l) : Fl_Widget(X, Y, W, H, l) { box(FL_DOWN_BOX); @@ -132,6 +140,7 @@ Fl_Positioner::Fl_Positioner(int X, int Y, int W, int H, const char* l) xstep_ = ystep_ = 0; } +/** Sets the X axis bounds.*/ void Fl_Positioner::xbounds(double a, double b) { if (a != xmin || b != xmax) { xmin = a; xmax = b; @@ -139,6 +148,7 @@ void Fl_Positioner::xbounds(double a, double b) { } } +/** Sets the Y axis bounds.*/ void Fl_Positioner::ybounds(double a, double b) { if (a != ymin || b != ymax) { ymin = a; ymax = b; |
