Commit Graph

16 Commits

Author SHA1 Message Date
ManoloFLTK
5bab46940c Re-organize cross-platform support for text input methods.
FLTK 1.3 supports complex text input methods (TIMs) for the 3 platforms
(X11, Windows, macOS). This support has an interface with FLTK that is
common for X11 and Windows, via (undocumented) functions fl_set_spot(),
fl_set_status() and fl_reset_spot().
In contrast, and because it's been developed independently, the
interface between the macOS TIM and FLTK 1.3 is completely different :
static functions FL::insertion_point_location() and Fl::reset_marked_text().

The present change implements a single TIM/FLTK interface
used by all platforms based on functions fl_set_spot() and
fl_reset_spot().

The previous macOS-specific functions FL::insertion_point_location() and
Fl::reset_marked_text() are maintained only for compatibility with 1.3
and deprecated.
2022-01-07 16:34:54 +01:00
ManoloFLTK
08e59770aa Remove compiler warnings about unused parameters (issue #307) - cont'd 2021-12-09 11:40:55 +01:00
ManoloFLTK
397226b75d Add use of fl_capture_window() by test/device
Also, rename fl_capture_window_part() to fl_capture_window().
2021-11-16 15:03:36 +01:00
Albrecht Schlosser
713d1bfd7c Revert parts of and fix other 'constness' changes (#239, #181)
Some of the previous constness changes turned out to be incomplete,
others had to be reverted because some other driver methods could
not be made 'const' - particularly those calling open_display() to
get the requested information.
2021-06-18 18:46:17 +02:00
Albrecht Schlosser
f94ed7116c Make non-const Fl_Screen_Driver methods const (#181)
As requested by issue #181:
  "Fl_Screen_Driver.H non-const functions should be const"

Not all methods could be made 'const' because some screen related
methods call init() internally.
2021-06-16 14:24:05 +02:00
ManoloFLTK
889acc7d74 Fix use of an SVG image in Fl_Tiled_Image when display is rescaled. 2020-07-30 17:41:35 +02:00
Albrecht Schlosser
f09e17c3c5 Remove $Id$ tags, update URL's, and more
- remove obsolete svn '$Id$' tags from all source files
- update .fl files and generated files accordingly
- replace 'http://www.fltk.org' URL's with 'https://...'
- replace bug report URL 'str.php' with 'bugs.php'
- remove trailing whitespace
- fix other whitespace errors flagged by Git
- add and/or fix missing or wrong standard headers
- convert tabs to spaces in all source files

The only relevant code changes are in the fluid/ folder where
some .fl files and other source files were used to generate
the '$Id' headers and footers.
2020-07-06 20:28:20 +02:00
Albrecht Schlosser
f93b825b08 Update Fl::keyboard_screen_scaling()
- make the internal variable static
- make it callable after fl_open_display()
- document that it's currently only usable to switch scaling off
2020-01-31 15:48:21 +01:00
ManoloFLTK
4ba6cef0b9 Add Fl::keyboard_screen_scaling(int) to control recognition of ctrl/+/-/0/ 2020-01-31 09:42:36 +01:00
ManoloFLTK
33eb87940d Fix a case when fl_read_window() did not capture subwindows correctly.
The case was under macOS with a non-GL parent window mapped to a retina display
containing a GL subwindow and if the app did not call Fl::use_high_res_GL(1).
2019-08-21 12:01:51 +02:00
ManoloFLTK
94fffb701c Add one argument to Fl_Screen_Driver::read_win_rectangle()
The new argument gives the window to be captured, or NULL to indicate capture
from the current offscreen.
Calling this function becomes easier because less dependent on global variables.
2019-06-06 18:28:49 +02:00
ManoloFLTK
499ec5c291 Replace static void Fl_Window_Driver::default_icons() by virtual Fl_Screen_Driver::default_icons() 2019-03-25 18:47:29 +01:00
ManoloFLTK
d988930461 Process env var FLTK_SCALING_FACTOR consistently across platforms.
The procedure to set screen scaling factors becomes:
1) each screen scaling factor is set to 1
2) the OS is queried according to each platform to get screen scaling factor
values
3) The value of FLTK_SCALING_FACTOR, if present, is used to multiply
scaling factors
2019-03-06 11:10:37 +01:00
Manolo Gouy
91bb8bce1f Create default implementation of Fl_Screen_Driver::get_system_scheme() and use it for macOS and Windows.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13137 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-11-28 18:01:02 +00:00
Manolo Gouy
b6f65b1c87 X11: simplify the use of member function Fl_X11_Screen_Driver::init_workarea().
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13044 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-09-07 09:24:35 +00:00
Manolo Gouy
26cb08badb Move Fl_Screen_Driver.H from FL/ to src/
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12975 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-06-26 14:04:09 +00:00