Commit graph

1117 commits

Author SHA1 Message Date
Consolatis
505f92e733 src/buffer: Automatically adapt to scale attribute
Based on discussion in PR #389
2022-06-14 22:03:08 +01:00
Johan Malm
5626c20c44
Merge pull request #389 from bi4k8/window-switcher-scale
correctly scale window switcher
2022-06-11 22:37:30 +01:00
bi4k8
4221eb14e8 correctly scale window switcher 2022-06-11 13:44:58 +00:00
Consolatis
5a4c5de332 src/menu: Attach view to menu and use it when executing actions
This fixes #380
2022-06-09 22:09:40 +01:00
Consolatis
ca9226a7a6 src/ssd: Convert button node descriptors to struct ssd_button
This allows for way easier button hover detection and future
features like toggling rounded corner buttons on maximize.
2022-06-09 22:04:35 +01:00
Consolatis
f1ada7e407 src/ssd: Use LAB_SSD_PART_CORNER_x for rounded corner backgrounds
This matches the behavior of the surrounding borders and will usually
cause resizing instead of triggering the button itself. This effect
is only really visible when using a border width settings of > 1.

Fixes #379
2022-06-09 22:04:35 +01:00
Consolatis
32dac72734 src/view.c: Cache server pointer 2022-06-09 17:15:13 +02:00
Consolatis
9c37101ec0 Chase wlroots: update wlroots.wrap to latest master
To update the wlroots subproject use
meson subprojects update wlroots

Fixes #382
2022-06-09 02:15:15 +02:00
Johan Malm
bbea6d8330 view: if view->fullscreen on destroy, re-enable top-layer
The layer-shell top-layer is disabled when running an application in
fullscreen mode, so if this is the case on view_destroy() we have to
re-enabled the top-layer again.

Reported-by: @heroin-moose
Helped-by: @Consolatis

Fixes #377
2022-06-07 23:41:37 +02:00
Consolatis
138b1852c1 Chase wlroots: update wlroots.wrap to latest master
To update the wlroots subproject use
meson subprojects update wlroots
2022-06-07 07:13:37 +01:00
Consolatis
efd9155513 Chase wlroots: children are now only availabe in tree nodes
Chases wlroots 71f8a48d380701de1e3331d53d470bd76f5f643b
wlr_scene: Move children list from wlr_scene_node to wlr_scene_tree
2022-06-07 07:13:37 +01:00
Consolatis
08518513cc Chase wlroots: scene_node.state is now inlined
Chases wlroots cb2dbc327e4d695c2a60a386e116a7dc20b29107
wlr_scene: Inline wlr_scene_node_state
2022-06-07 07:13:37 +01:00
Consolatis
2ed7a10779 Chase wlroots: every scene_node parent is now a tree
Chases wlroots ccd0f85c2a36308e35b153c7f9653abac7659af3
wlr_scene: Only allow parenting on a wlr_scene_tree
2022-06-07 07:13:37 +01:00
Consolatis
b7c9d0e055 Chase wlroots: prep work: ssd to tree 2022-06-07 07:13:37 +01:00
Consolatis
65a5315e42 Chase wlroots: prep work: menu to tree 2022-06-07 07:13:37 +01:00
Consolatis
3f65a2ff77 Chase wlroots: wlr_scene is now a tree node
Chases wlroots 9eb71146ae56c509ee33c7e8a662549592aad870
wlr_scene: Refactor wlr_scene (the root element) to encase a wlr_scene_tree
2022-06-07 07:13:37 +01:00
Johan Malm
fb1af5f68e view: when centering, top/left align if view is bigger than usable area 2022-06-06 20:46:29 +02:00
Johan Malm
0f22613952 view: take into account top-margin for xwayland views
...in order to center accurately.
2022-06-06 20:46:29 +02:00
Johan Malm
d1e16c5030 view: center correctly with scale != 1
Fixes issue #376
2022-06-06 20:46:29 +02:00
Johan Malm
71f8aca66b xwayland-unmanaged: wl_list_remove() missing listeners on destroy 2022-06-05 23:34:04 +02:00
Johan Malm
cbc80c196c xwayland-unmanaged: remove excessive logging 2022-06-05 23:34:04 +02:00
Joshua Ashton
538fa1f244 xwayland-unmanaged: Fix set_geometry using container_of of wrong member
Fixes a segfault with starting Steam.
2022-06-05 21:54:26 +01:00
Johan Malm
2a14e8271b xwayland-unmanaged: fix typo 2022-06-05 09:55:25 +01:00
Johan Malm
9dcabbcfdd xwayland-unmanaged: prepare for handling more events
Sway handles some xwayland events that labwc still does not. This commit
just starts to rig up some handlers for these with log messages if they
are caught.

  - set_geometry: try to handle, but cannot find an application that uses
    it, so is untested.
  - request_activate - just log caught event
  - override_redirect - just log caught event
2022-06-05 09:45:58 +01:00
Johan Malm
fcd2425de3 docs/environment: add _JAVA_AWT_WM_NONREPARENTING=1 2022-06-05 09:12:54 +01:00
Johan Malm
96315def57 xwayland-unmanaged: put all surfaces under server->unmanaged_tree
...in order to render all unmanaged surfaces above views just like sway
does it:

e5728052b5/sway/desktop/render.c (L1148)

Fixes issue #367
2022-06-05 08:35:03 +01:00
Consolatis
39cdba36a8 src/config/keybind.c: fix keybind insertion order
This restores the intended behavior of keybinds set by `<default />`
to be overwritten by manually configured keybinds which come later in
the config.

In `src/keyboard.c`, `handle_keybinding()` is going backwards through
the list of keybindings and breaks after the first match.

`wl_list_insert(&list_node, item)` will insert the new item *after* the
list_node so if its called multiple times with the same list_node as
fist argument the result will be a reversed list. Using `list_node.prev`
instead will result in a non-reversed list.
2022-06-03 22:54:32 +01:00
Consolatis
986ab70780 Prevent missing direction arguments to segfault labwc
Reported-by: @Flrian
2022-06-03 19:07:13 +01:00
Johan Malm
0a7e380c14 CONTRIBUTING.md: fix typo s/sanitzise/sanitize/ 2022-06-03 18:52:35 +01:00
Consolatis
b3d1ed934c IRC notifications: disable push notifications
They were also called for the 'master' and 'v0.5' branches of forks and are
not that helpful anyway because they just post the compare link and not the
title of the commits.

Additionally, they were also called whenever a PR was merged which already
has its own notification including a link to the PR.
2022-06-02 11:44:35 +02:00
Johan Malm
3ca862b9ff docs/meson.build: remove environment following 5de92c8 2022-06-01 18:14:26 +01:00
Consolatis
184ed9e266 IRC notifications: use NOTICE to prevent join/part 2022-06-01 19:03:42 +02:00
Consolatis
b7907cc2da theme: implement osd.border.color and osd.border.width
http://openbox.org/wiki/Help:Themes#osd.border.color
http://openbox.org/wiki/Help:Themes#osd.border.width
2022-06-01 17:55:36 +01:00
Consolatis
c4074207e1 Experimentally add IRC notifications for new PRs and Issues 2022-06-01 03:27:24 +02:00
Johan Malm
5de92c80aa Move config related content from labwc(1) to labwc-config(5)
Remove labwc-environment(5) as its contents are covered in
labwc-config(5)
2022-05-31 22:37:26 +01:00
Johan Malm
c8dd19caa3 man pages: minor language and style changes 2022-05-31 22:01:26 +01:00
Johan Malm
999fef6678 labwc-config(5): move <resistance> to before <focus>
...to make the config file flow better
2022-05-31 21:57:00 +01:00
Johan Malm
9b29bbeb54 man pages: unify titles for better "man -k labwc" experience 2022-05-31 21:53:45 +01:00
Johan Malm
3cf0164316 CONTRIBUTING.md: add note on libinput debug-events 2022-05-31 21:44:31 +01:00
Consolatis
ccfcd04625 Revert "Fix dynamic output based scaling for menu and SSD"
As it turns out the reason for the workaround was a bug
in wlroots which got fixed in the meantime.

So to keep things simple just revert the workaround and
depend on the wlroots fix instead.

To update the wlroots subproject use
meson subprojects update wlroots

This reverts commit e87aa19066.
2022-05-30 21:27:33 +02:00
Johan Malm
62ae87bbd9 xwayland: call foreign-toplevel-destroy on unmap
Some xwayland clients leave unmapped child views around, typically when a
dialog window is closed. Although handle_destroy() is not called for
these, we have to call foreign-toplevel-destroy to avoid panels and the
like incorrecly showing them.
2022-05-30 21:08:54 +02:00
Consolatis
1e29d0606d Chase wlroots: xdg_popup.geometry
To update the wlroots subproject use
meson subprojects update wlroots

https://gitlab.freedesktop.org/wlroots/wlroots/-/merge_requests/3514
2022-05-30 17:54:26 +01:00
Jelle De Loecker
61675b521c xwayland-unmanaged: focus parent surface on unmap
Re-focus on parent surface if it is available

Fixes #352 relating to JetBrains and Intellij focus issues
2022-05-30 16:14:32 +01:00
Consolatis
e87aa19066 Fix dynamic output based scaling for menu and SSD
wlr_scene_buffers need an additional wlr_scene_buffer_set_source_box()
to be scaled correctly by wlroots based on the output scale.

With this commit the buffers are now scaled correctly but, especially
on higher scale factors, may be a bit blurry.

In the future we likely want a dynamic font label generator based
on the maximal scale of all the outputs the specific buffer is currently on.

Some inspiration for that could be
https://github.com/Nefsen402/sway/blob/scene-graph/sway/sway_text_buffer.c

Fixes #348
2022-05-29 22:10:00 +02:00
Consolatis
78dc2ea7fe src/theme.c: Clean up corner buffers on finish 2022-05-26 22:19:56 +01:00
Consolatis
ae9314c65e src/osd.c: Free buf.buf as its malloc'd in buf_init() 2022-05-26 22:19:56 +01:00
Consolatis
bda48da68d Deal with font_buffer_create() failures 2022-05-26 22:19:56 +01:00
Johan Malm
94f199e3c5 CONTRIBUTING.md: describe WLR_WL_OUTPUTS 2022-05-26 22:05:21 +01:00
Johan Malm
48e787ba10 CONTRIBUTING.md: add notes on debugging 2022-05-26 21:51:17 +01:00
Consolatis
163179dda1 Chase wlroots: wlr_scene_surface
To update the wlroots subproject use
meson subprojects update wlroots
2022-05-26 06:48:00 +01:00