diff options
| author | ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> | 2024-03-13 18:02:13 +0100 |
|---|---|---|
| committer | ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> | 2024-03-13 18:02:13 +0100 |
| commit | 91d2bf4783fe46f2d46f851713f8ba2866aab68c (patch) | |
| tree | ff5c63cb564f46bebf73cd882fc1b5966456f8ec /src | |
| parent | cfcafaa2c8ed32f09abfddc6362677f65d966ace (diff) | |
Improve Fl_Wayland_Screen_Driver::base_scale(int)
Diffstat (limited to 'src')
| -rw-r--r-- | src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx b/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx index 2a0e08790..3b41bb1a5 100644 --- a/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx +++ b/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx @@ -1878,7 +1878,12 @@ int Fl_Wayland_Screen_Driver::get_key(int k) { float Fl_Wayland_Screen_Driver::base_scale(int numscreen) { - return 1.f; + const char *p; + float factor = 1; + if ((p = fl_getenv("FLTK_SCALING_FACTOR"))) { + sscanf(p, "%f", &factor); + } + return factor; } |
