summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2024-03-03 08:15:42 +0100
committerManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2024-03-03 08:15:42 +0100
commit4db9391525ca0e9868b57826c14f0584a8d0b701 (patch)
treebee6e5bc23b3d9ef72f1045c63f114afc07ab421
parent257e20e929e03f31f46b310f08b0254b016c77a5 (diff)
Update doc about Ctrl/+/-/0/ zoom shortcuts
-rw-r--r--FL/Fl.H8
-rw-r--r--documentation/src/events.dox27
2 files changed, 17 insertions, 18 deletions
diff --git a/FL/Fl.H b/FL/Fl.H
index 287e00b62..702c5802c 100644
--- a/FL/Fl.H
+++ b/FL/Fl.H
@@ -1086,12 +1086,8 @@ public:
can be set to a value FLTK will multiply to the OS-given value.
The 2 variants of functions Fl::screen_scale() allow to programmatically get and set
scaling factor values. The scaling factor value can be further changed at runtime
- by typing ctrl-/+/-/0/ (cmd-/+/-/0/ under macOS). FLTK sends the
- \ref FL_ZOOM_EVENT when the factor value is changed, to which a
- callback can be associated with Fl::add_handler().
- By default, FLTK displays the new scaling factor value in a yellow, transient window.
- This can be changed with option Fl::OPTION_SHOW_SCALING.
- See also Fl::OPTION_SIMPLE_ZOOM_SHORTCUT.
+ by typing \c Ctrl/+/-/0/ (\c Cmd/+/-/0/ under macOS).
+ See \ref events_fl_shortcut for more details about these shortcuts.
@{ */
static int x(); // via screen driver
static int y(); // via screen driver
diff --git a/documentation/src/events.dox b/documentation/src/events.dox
index 5c43850d1..9a6ad6328 100644
--- a/documentation/src/events.dox
+++ b/documentation/src/events.dox
@@ -191,16 +191,19 @@ A global shortcut will work no matter what windows are displayed
or which one has the focus.
Since version 1.4, FLTK has 3 default global shortcuts (\c Ctrl/+/-/0/
-or \c Cmd/+/-/0/ under macOS) that change the value of the GUI scaling
+ [\c Cmd/+/-/0/ under macOS]) that change the value of the GUI scaling
factor. \c Ctrl+ zooms-in all app windows of the focussed display
(all displays under macOS);
\c Ctrl- zooms-out these windows; \c Ctrl 0 restores the initial value of the
-scaling factor. Although characters '+' and '0' are located in
-the shifted position of their keyboard key in some
-keyboard layouts, these shortcuts are to be used without pressing
-the shift key, for user convenience. In other words, press only
-\c Ctrl (or \c Cmd) and the key labelled '+' or '0' independently of
-whether '+' or '0' is in shifted or unshifted position on the keyboard.
+scaling factor. If any window of the display is fullscreen or maximized,
+scaling shortcuts have no effect. It's possible to deactivate FLTK's default
+scaling shortcuts with function Fl::keyboard_screen_scaling().
+
+Option Fl::OPTION_SIMPLE_ZOOM_SHORTCUT can
+facilitate the typing necessary to trigger the zoom-in operation
+with those keyboard layouts where character '+' is located in
+the shifted position of its key: when this option is On
+it's not necessary to press also the Shift key to zoom-in.
These scaling shortcuts are installed when the FLTK
library opens the display. They have a lower priority than any shortcut
@@ -208,12 +211,12 @@ defined in any menu and than any user-provided event handler
(see Fl::add_handler()) installed after FLTK opened the display.
Therefore, if a menu item of an FLTK app is given FL_COMMAND+'+'
as shortcut, that item's callback rather than FLTK's default zooming-in
-routine is triggered when \c Ctrl+ (or \c Cmd+) is pressed .
-If any window of the display is fullscreen or maximized,
-scaling shortcuts have no effect.
+routine is triggered when \c Ctrl+ (\c Cmd+ under macOS) is pressed.
-It's possible to deactivate FLTK's default scaling shortcuts with function
-Fl::keyboard_screen_scaling();
+FLTK sends the \ref FL_ZOOM_EVENT when the scaling factor value changes, to which a
+callback can be associated with Fl::add_handler().
+By default, FLTK displays the new scaling factor value in a yellow, transient window.
+This can be changed with option Fl::OPTION_SHOW_SCALING.
\section events_widget Widget Events