When GLFW_ANY_PLATFORM is used (which is the default), X11 would be
selected on a Wayland system with XWayland and where XDG_SESSION_TYPE
was not set.
Closes#2035
This adds a function for querying the current title of a window. This
currently returns a copy of the last title set via GLFW.
Fixes#1448Closes#1909Closes#2482
The actual reported bug was fixed at some point during the refactoring
of the Wayland backend. This is only a bit of tidying. Updating the
cache before emitting events is always a nice thing to do.
Closes#2046
This adds the GLFW_SCALE_FRAMEBUFFER window hint, enabling control of
framebuffer scaling across Wayland and macOS. On macOS, this window
hint is a new name for GLFW_COCOA_RETINA_FRAMEBUFFER, and both hint
names will modify the same hint.
This is now a more symmetric counterpart to GLFW_SCALE_TO_MONITOR and,
weirdly, they each apply neatly to half of the supported platforms.
This commit is mostly documentation updates to better integrate and
contrast these two scaling mechanisms.
The calculation of framebuffer size is about to get more complicated
with the introduction of fractional-scale-v1, so only do it in one
place.
This is also a tiny preparation for eventually behaving better towards
wl_egl_window_resize.
We are about to introduce another scaling method (fractional-scale-v1),
so it will become more important to be specific about what scales are
used where and what their units are.
This removes 'content scale' from window and monitor structs. A monitor
(output) now has just a 'scale', which becomes a 'buffer scale' when
applied to a window. A window now has a list of 'output scales' to
select its buffer scale from. Content scales are calculated from the
respective monitor or window when queried, even if the calculation right
now is to just return the same value as before.