diff options
| author | Matthias Melcher <github@matthiasm.com> | 2022-11-26 20:28:12 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-11-26 20:28:12 +0100 |
| commit | 87fe29372cf8623a003b39dea755f3d290916601 (patch) | |
| tree | 32232776fdaf8bc1d8a91536e92cfa4f414425f0 /FL | |
| parent | 191aeefc4a4161cb132065625a5e5eacb567688a (diff) | |
Local undo per Fl_Text_Buffer and Fl_Input_ (#557)
Diffstat (limited to 'FL')
| -rw-r--r-- | FL/Fl_Input_.H | 5 | ||||
| -rw-r--r-- | FL/Fl_Text_Buffer.H | 2 |
2 files changed, 7 insertions, 0 deletions
diff --git a/FL/Fl_Input_.H b/FL/Fl_Input_.H index 254730c1b..bd159049a 100644 --- a/FL/Fl_Input_.H +++ b/FL/Fl_Input_.H @@ -38,6 +38,8 @@ #define FL_MULTILINE_INPUT_WRAP (FL_MULTILINE_INPUT | FL_INPUT_WRAP) #define FL_MULTILINE_OUTPUT_WRAP (FL_MULTILINE_INPUT | FL_INPUT_READONLY | FL_INPUT_WRAP) +class Fl_Input_Undo_Action; + /** This class provides a low-overhead text input field. @@ -144,6 +146,9 @@ class FL_EXPORT Fl_Input_ : public Fl_Widget { /** \internal color of the text cursor */ Fl_Color cursor_color_; + /** \internal local undo event */ + Fl_Input_Undo_Action* undo_; + /** \internal Horizontal cursor position in pixels while moving up or down. */ static double up_down_pos; diff --git a/FL/Fl_Text_Buffer.H b/FL/Fl_Text_Buffer.H index a1d044f48..727b2a65d 100644 --- a/FL/Fl_Text_Buffer.H +++ b/FL/Fl_Text_Buffer.H @@ -60,6 +60,7 @@ #include "Fl_Export.H" +class Fl_Text_Undo_Action; /** \class Fl_Text_Selection @@ -836,6 +837,7 @@ protected: int mPreferredGapSize; /**< the default allocation for the text gap is 1024 bytes and should only be increased if frequent and large changes in buffer size are expected */ + Fl_Text_Undo_Action* mUndo; /**< local undo event */ }; #endif |
