diff options
| author | Fabien Costantini <fabien@onepost.net> | 2008-09-15 11:10:51 +0000 |
|---|---|---|
| committer | Fabien Costantini <fabien@onepost.net> | 2008-09-15 11:10:51 +0000 |
| commit | 8701883e54d4e7e842d4cb27c17019c03cd33f55 (patch) | |
| tree | ef86259413498fce96df97ea1decedc7e30515a6 /FL/Fl_Widget.H | |
| parent | b9ca1333769f87c029430a9d14a7a9937d400f93 (diff) | |
Doxygen documentation WP9 Done.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6251 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'FL/Fl_Widget.H')
| -rw-r--r-- | FL/Fl_Widget.H | 39 |
1 files changed, 37 insertions, 2 deletions
diff --git a/FL/Fl_Widget.H b/FL/Fl_Widget.H index fab179f7b..b23b5ba61 100644 --- a/FL/Fl_Widget.H +++ b/FL/Fl_Widget.H @@ -532,8 +532,43 @@ public: */ void argument(long v) {user_data_ = (void*)v;} - /** Return the conditions under which the callback is called. - * \return set of flags + /** + Controls when callbacks are done. The following values are useful, + the default value is FL_WHEN_RELEASE: + + <UL> + + <LI>0: The callback is not done, but + changed() is turned on.</LI> + + <LI>FL_WHEN_CHANGED: The callback is done each + time the text is changed by the user.</LI> + + <LI>FL_WHEN_RELEASE: The callback will be done + when this widget loses the focus, including when the + window is unmapped. This is a useful value for text + fields in a panel where doing the callback on every + change is wasteful. However the callback will also + happen if the mouse is moved out of the window, which + means it should not do anything visible (like pop up an + error message). You might do better setting this to + zero, and scanning all the items for changed() + when the OK button on a panel is pressed.</LI> + + <LI>FL_WHEN_ENTER_KEY: If the user types the + Enter key, the entire text is selected, and the callback + is done if the text has changed. Normally the Enter key + will navigate to the next field (or insert a newline for + a Fl_Mulitline_Input), this changes the + behavior.</LI> + + <LI>FL_WHEN_ENTER_KEY|FL_WHEN_NOT_CHANGED: The + Enter key will do the callback even if the text has not + changed. Useful for command fields.</LI> + + </UL> + Return the conditions under which the callback is called. + \return set of flags */ Fl_When when() const {return (Fl_When)when_;} |
