diff options
| author | Matthias Melcher <github@matthiasm.com> | 2023-09-03 00:09:32 +0200 |
|---|---|---|
| committer | Matthias Melcher <github@matthiasm.com> | 2023-09-03 00:09:40 +0200 |
| commit | 5e8adebac2899d60fffc53d4692bc4972abcf795 (patch) | |
| tree | b79581c85dc80c4d132390de42c15faee8f3d4c9 /FL/Fl_Button.H | |
| parent | 502fa72eb472382cc47964874893085fb88116f5 (diff) | |
Adds compact buttons feature to create keypads.
See test/buttons for an example.
Diffstat (limited to 'FL/Fl_Button.H')
| -rw-r--r-- | FL/Fl_Button.H | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/FL/Fl_Button.H b/FL/Fl_Button.H index 9908b9742..31b71a416 100644 --- a/FL/Fl_Button.H +++ b/FL/Fl_Button.H @@ -79,6 +79,7 @@ class FL_EXPORT Fl_Button : public Fl_Widget { char value_; char oldval; uchar down_box_; + uchar compact_; protected: @@ -167,6 +168,14 @@ public: /// (for backwards compatibility) void down_color(unsigned c) {selection_color(c);} + + // handle flag for compact buttons, documentation in source code + void compact(uchar v); + + /// Return true if buttons are rendered as compact buttons. + /// \return 0 if compact mode is off, 1 if it is on + /// \see compact(bool) + uchar compact() { return compact_; } }; #endif |
