Age | Commit message (Collapse) | Author | Files | Lines |
|
On MacOS in particular, views and windows are entirely different concepts, so
confusing them... confuses things. This was the last holdover in the API that
used the old "native window".
|
|
|
|
This makes the internal header structure match the "kinds" of definition inside
Pugl: common implementations of public API, things available internally to
platform implementations, and things the platform must define.
|
|
|
|
According to clang-tidy anyway, I'm not seeing it.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This avoids bugs in plugins, because otherwise it's possible that size hints
are not available when the host embeds the UI.
|
|
|
|
Calling X*ICFocus on NULL segfaults. This can happen if XCreateIC failed, for
example due to missing locales on minimal Docker images.
|
|
|
|
|
|
|
|
|
|
|
|
This avoids a Wunused-const-variable warning with GCC.
|
|
|
|
This implements a more powerful protocol for working with clipboards, which
supports datatype negotiation, and fixes various issues by mapping more
directly to how things work on X11.
|
|
|
|
This is a simpler example than pugl_embed_demo that demonstrates clipboard
functionality without the complexity of embedded views.
|
|
|
|
|
|
These are redundant with puglSetFrame in a sense, but allow setting the size of
a view without the position, or vice-versa. This API also maps more nicely to
Wayland, where applications can not position themselves (but can resize).
|
|
Actual window sizes and positions fit easily in a 16-bit integer. So, we use
that in "representation contexts" like events. This makes structures smaller,
and allows the values to be converted to float, double, or integer without
casting (since any int16_t or uint16_t value can fit in them without loss).
Setter APIs use native integers for convenience, to avoid casting hassles when
doing arithmetic. Ranges are checked at runtime.
|
|
This collapses many functions into one, which makes the API more easily
extensible and reduces code size.
|
|
|
|
|
|
I am not sure why the minimum was only specified before, but it seems like an
oversight.
|
|
This changes to getting cursors by name from the cursor theme, which makes the
cursor match the ones used in modern desktop environments. As far as I can
tell, there is no real standard for names, these ones seem to work for me in
GNOME, KDE, and Xfce.
I am not sure about the compatibility concerns here, but X11 without Xcursor
themes strikes me as either too esoteric or too ancient to worry about,
especially since cursor switching isn't critical functionality anyway.
|
|
This avoids issues when the default X11 cursor isn't the expected "default" of
the environment, for example with Plasma.
A real application that changes the cursor needs to do so consistently on mouse
enter and leave events anyway.
|
|
|
|
|
|
This avoids potential clashes between multiple copies of Pugl statically
compiled into several modules.
|
|
|
|
|
|
This is required on MacOS to make the examples usable. When run as bare
programs, they don't show up as normal windows or receive keyboard input.
|
|
|
|
This enables running them without the data tests (which can be annoying while
working in a messy repo), and for bonus points makes the log output look more
uniform.
|
|
I suspect that using the same configuration across both C and C++ is starting
to wear a bit thin, but this will do for now.
|
|
Since upgrading to 11.6 (on an Intel Macbook), this test no longer seems to
pass. It's unfortunate to not test that small redisplay requests only result
in small exposures, but I don't think the previous strict check reflects
reality. Exposing more than the application requested, for whatever reason, is
a natural part of window environments, so I don't know if this is something
that can be reliably unit tested.
|
|
|
|
Numerous things warn about this, and it's generally a bad idea to put these in
the code since it can result in incompatibly compiled code being linked
together. Unfortunately this makes building manually (without the build
system) more fiddly, but such is life.
|
|
|
|
|
|
|
|
|