<keybind key="W-d">
<action name="Execute">
<command>dmenu_run</command>
</action>
</keybind>
When using the keybind above (in rc.xml), on the first execution of W-d
all is okay, but the second time, a "d" pressed event is sent to dmenu
resulting in a continuous "ddddddd...") which has to be stopped pressing a
key.
This behaviour started in commit 7e57b7f because release events associated
with keybinds are no longer sent to clients (before that commit, the
release event for the “d” would have been passed to dmenu, thus cancelling
the repeat).
Solves issue #176
Helped-by: @spectrum70
labwc currently doesn't handle output layout changes very well:
- Windows can end up "lost" completely offscreen
- Maximized/fullscreen windows can end up spanning multiple outputs
Currently, new_output_notify() and output_destroy_notify() contain logic
to update the cursor and force a repaint when outputs are added or
removed. This logic in fact needs to run on any output layout change,
so consolidate it into a new function, output_update_for_layout_change().
Then add a second new function, view_adjust_for_layout_change(), which
adjusts window placement to account for the new layout.
The behavior is roughly as follows:
- Normal windows that end up offscreen are centered on the closest
output (making use of the existing view_center() logic)
- Maximized windows are re-maximized on the closest output. Logic is
also added to the unmaximize step to check that the original
unmaximized position is still on-screen.
- Fullscreen windows are re-fullscreened on the same output if
possible; otherwise they are un-fullscreened.
Minimized windows don't require any special handling. Their placement
is adjusted just the same, but invisible to the user until they are
later unminimized.
There is some positioning glitch still with un-fullscreening a window
whose output has been disconnected/disabled; it can end up in an
unexpected position (but at least has the correct size and decoration).
I don't think this is due to a bug in my change per se, but perhaps the
change has exposed a bug elsewhere.
Fixes: #177
Set these two variables indepently of each other as this is cleaner and
more explicit.
In openbox <raiseOnFocus> only applies if <followMouse> is set, but there
is no need to immitate this.
Issue #144
Add `#define _POSIX_C_SOURCE 200809L` to avoid the error below:
../src/cursor.c: In function 'cursor_update_focus':
../src/cursor.c:271:2: warning: implicit declaration of function
'clock_gettime' [-Wimplicit-function-declaration]
271 | clock_gettime(CLOCK_MONOTONIC, &now);
| ^~~~~~~~~~~~~
../src/cursor.c:271:16: error: 'CLOCK_MONOTONIC' undeclared (first use in
this function)
271 | clock_gettime(CLOCK_MONOTONIC, &now);
| ^~~~~~~~~~~~~~~
../src/cursor.c:271:16: note: each undeclared identifier is reported only
once for each function it appears in
../src/cursor.c: In function 'is_double_click':
../src/cursor.c:486:16: error: 'CLOCK_MONOTONIC' undeclared (first use in
this function)
486 | clock_gettime(CLOCK_MONOTONIC, &now);
| ^~~~~~~~~~~~~~~
Before this change a window that had been minimized showed up with states Minimized and Activated.
For foreign-toplevel clients like taskbars that could mean to handle multiple windows at once
having a 'activated' state even though they were clearly minimized.
Handlers for the "destroy" signal need to unregister themselves from the
signal (using wl_list_remove()) before invoking free().
Invalid write of size 8
at 0x487DF27: wl_list_remove (in /usr/lib/libwayland-server.so.0.20.0)
by 0x4906FF0: wlr_signal_emit_safe (signal.c:32)
by 0x48EA304: reset_xdg_surface (wlr_xdg_surface.c:430)
by 0x48EA3D6: UnknownInlinedFun (wlr_xdg_surface.c:464)
by 0x48EA3D6: xdg_surface_handle_resource_destroy (wlr_xdg_surface.c:282)
by 0x4877899: ??? (in /usr/lib/libwayland-server.so.0.20.0)
by 0x487DEBF: ??? (in /usr/lib/libwayland-server.so.0.20.0)
by 0x487E3DF: ??? (in /usr/lib/libwayland-server.so.0.20.0)
by 0x487830D: wl_client_destroy (in /usr/lib/libwayland-server.so.0.20.0)
by 0x48783F6: ??? (in /usr/lib/libwayland-server.so.0.20.0)
by 0x487B1C9: wl_event_loop_dispatch (in /usr/lib/libwayland-server.so.0.20.0)
by 0x4878D36: wl_display_run (in /usr/lib/libwayland-server.so.0.20.0)
by 0x110DAC: main (main.c:81)
Address 0xc3213d8 is 424 bytes inside a block of size 704 free'd
at 0x484118B: free (vg_replace_malloc.c:755)
by 0x4906FDD: wlr_signal_emit_safe (signal.c:29)
by 0x48EA304: reset_xdg_surface (wlr_xdg_surface.c:430)
by 0x48EA3D6: UnknownInlinedFun (wlr_xdg_surface.c:464)
by 0x48EA3D6: xdg_surface_handle_resource_destroy (wlr_xdg_surface.c:282)
by 0x4877899: ??? (in /usr/lib/libwayland-server.so.0.20.0)
by 0x487DEBF: ??? (in /usr/lib/libwayland-server.so.0.20.0)
by 0x487E3DF: ??? (in /usr/lib/libwayland-server.so.0.20.0)
by 0x487830D: wl_client_destroy (in /usr/lib/libwayland-server.so.0.20.0)
by 0x48783F6: ??? (in /usr/lib/libwayland-server.so.0.20.0)
by 0x487B1C9: wl_event_loop_dispatch (in /usr/lib/libwayland-server.so.0.20.0)
by 0x4878D36: wl_display_run (in /usr/lib/libwayland-server.so.0.20.0)
by 0x110DAC: main (main.c:81)
Block was alloc'd at
at 0x48435FF: calloc (vg_replace_malloc.c:1117)
by 0x113E22: xdg_surface_new (xdg.c:401)
by 0x4906FDD: wlr_signal_emit_safe (signal.c:29)
by 0x48EABE7: handle_xdg_surface_commit (wlr_xdg_surface.c:331)
by 0x4908FE7: surface_commit_state (wlr_surface.c:457)
by 0x524DD49: ??? (in /usr/lib/libffi.so.8.1.0)
by 0x524D266: ??? (in /usr/lib/libffi.so.8.1.0)
by 0x487D322: ??? (in /usr/lib/libwayland-server.so.0.20.0)
by 0x48785CB: ??? (in /usr/lib/libwayland-server.so.0.20.0)
by 0x487B1C9: wl_event_loop_dispatch (in /usr/lib/libwayland-server.so.0.20.0)
by 0x4878D36: wl_display_run (in /usr/lib/libwayland-server.so.0.20.0)
by 0x110DAC: main (main.c:81)
Invalid write of size 8
at 0x487DF27: wl_list_remove (in /usr/lib/libwayland-server.so.0.20.0)
by 0x4906FF0: wlr_signal_emit_safe (signal.c:32)
by 0x48F5529: UnknownInlinedFun (wlr_input_device.c:34)
by 0x48F5529: wlr_input_device_destroy (wlr_input_device.c:29)
by 0x48CE4B5: backend_destroy.part.0.lto_priv.0 (backend.c:148)
by 0x48D2D55: multi_backend_destroy (backend.c:59)
by 0x48788FE: wl_display_destroy (in /usr/lib/libwayland-server.so.0.20.0)
by 0x110E71: UnknownInlinedFun (server.c:406)
by 0x110E71: main (main.c:83)
Address 0xc466568 is 24 bytes inside a block of size 56 free'd
at 0x484118B: free (vg_replace_malloc.c:755)
by 0x4906FDD: wlr_signal_emit_safe (signal.c:29)
by 0x48F5529: UnknownInlinedFun (wlr_input_device.c:34)
by 0x48F5529: wlr_input_device_destroy (wlr_input_device.c:29)
by 0x48CE4B5: backend_destroy.part.0.lto_priv.0 (backend.c:148)
by 0x48D2D55: multi_backend_destroy (backend.c:59)
by 0x48788FE: wl_display_destroy (in /usr/lib/libwayland-server.so.0.20.0)
by 0x110E71: UnknownInlinedFun (server.c:406)
by 0x110E71: main (main.c:83)
Block was alloc'd at
at 0x48435FF: calloc (vg_replace_malloc.c:1117)
by 0x11590F: new_input_notify (seat.c:137)
by 0x4906FDD: wlr_signal_emit_safe (signal.c:29)
by 0x4906FDD: wlr_signal_emit_safe (signal.c:29)
by 0x48CDCEE: UnknownInlinedFun (events.c:109)
by 0x48CDCEE: UnknownInlinedFun (events.c:242)
by 0x48CDCEE: UnknownInlinedFun (backend.c:58)
by 0x48CDCEE: handle_libinput_readable (backend.c:48)
by 0x48CE1BE: backend_start.lto_priv.0 (backend.c:114)
by 0x48D2CE5: multi_backend_start (backend.c:33)
by 0x110C45: UnknownInlinedFun (server.c:375)
by 0x110C45: main (main.c:68)
...and call it from desktop_move_to_front() in order force an enter event
on the surface below the cursor when cycling views.
Inspired by PR #164 - just restructured it a bit.
Suggested-by: @bi4k8
I couldn't help but notice some typos in README.md, and figured I might
as well fix them.
Spelling:
simplicy -> simplicity
inteded -> intended
if -> is
Compound words:
light-weight -> lightweight
wall-paper -> wallpaper
re-inventing -> reinventing
re-loaded -> reloaded
Grammar/usage:
& -> and
binds -> bindings
missing "the"
Issue arises when using the default config from docs/rc.xml.all.
Without this patch only the last action defined inside a <mousebind>
will have an effect.
Without a config or when defining the same <mousebind> multiple times
with each containing only a single <action> the issue does not exist.