Commit graph

615 commits

Author SHA1 Message Date
Joshua Ashton
8b8e37c268 theme: Implement window.label.text.justify
Crosses off 6.12.1

Signed-off-by: Joshua Ashton <joshua@froggi.es>
2021-10-17 20:50:13 +01:00
Joshua Ashton
140c245880 xdg: Respect min/max size in configure
Signed-off-by: Joshua Ashton <joshua@froggi.es>
2021-10-17 19:49:05 +01:00
Joshua Ashton
d9b021916a xwayland: Handle min width/height in configure
Signed-off-by: Joshua Ashton <joshua@froggi.es>
2021-10-17 19:49:05 +01:00
Joshua Ashton
1db6c54e59 cursor: Handle min size better
Less janky than just returning if one extent reaches max, and also uses the new min_size function for xwayland hint support.

Signed-off-by: Joshua Ashton <joshua@froggi.es>
2021-10-17 19:49:05 +01:00
Joshua Ashton
a6e1ee0a25 include: Add min/max helpers
Signed-off-by: Joshua Ashton <joshua@froggi.es>
2021-10-17 19:49:05 +01:00
Joshua Ashton
8652f97887 view: Add view_min_size helper function
Signed-off-by: Joshua Ashton <joshua@froggi.es>
2021-10-17 19:49:05 +01:00
Joshua Ashton
62123dc37e xwayland: Implement resize event
Signed-off-by: Joshua Ashton <joshua@froggi.es>
2021-10-17 18:23:15 +01:00
Joshua Ashton
2a18899689 xwayland: Implement move event
Closes: #81
Signed-off-by: Joshua Ashton <joshua@froggi.es>
2021-10-17 18:23:15 +01:00
Joshua Ashton
a67e74670b xwayland: Only perform top-left boundary check when using ssd
We don't have decorations so we shouldn't account for them.

Closes: #53
Signed-off-by: Joshua Ashton <joshua@froggi.es>
2021-10-17 12:22:01 +01:00
Joshua Ashton
f12617deea action: Fix crash in move to edge
Fixes a crash in move to edge ( #77 ) when the centre of the window is out of any display regions.

Doesn't fix the expected behaviour that it would work, but much better than the whole compositor dying.

Signed-off-by: Joshua Ashton <joshua@froggi.es>
2021-10-17 12:21:49 +01:00
Joshua Ashton
8e3108c032 action: Add 'SnapToEdge'
Implements snap-style edge snapping that works between multiple monitors.

Signed-off-by: Joshua Ashton <joshua@froggi.es>
2021-10-17 12:19:35 +01:00
Joshie
6bcefc27a8 theme: fix parsing inactive label colors
There was a typo here which meant these never got parsed and always appeared as black.

Signed-off-by: Joshua Ashton <joshua@froggi.es>
2021-10-17 11:59:02 +01:00
Johan Malm
e2ae63a7cf xdg/wayland-shell: handle set_app_id and set_class events 2021-10-16 21:50:56 +01:00
Johan Malm
e140682528 view: call wlr_foreign_toplevel_handle_v1_set_app_id() on map
Fix issue #74

Add view-impl.c with view_impl_map() containing common code for xdg-shell
and xwayland-shell.
2021-10-16 21:26:57 +01:00
Johan Malm
4d44659c08 desktop: remove deprecated functions
- set_activated()
- desktop_set_focus_view_only()
2021-10-16 19:53:00 +01:00
Johan Malm
9a290feeea desktop: simplify interface for view raise/focus
Split desktop_focus_view() into the following two functions:
  - desktop_focus_and_activate_view()
  - desktop_raise_view()

Always call view_set_activated() rather than using the private
set_activated(). This keeps the code cleaner and ensures
wlr_foreign_toplevel_handle_v1_set_activated() is called.
2021-10-16 19:44:54 +01:00
Johan Malm
70144ac113 view: add view_set_activated()
Call wlr_foreign_toplevel_handle_v1_set_activated() from it in support of
issue #73
2021-10-16 19:24:26 +01:00
Johan Malm
54d22a7129 theme: inherit osd colors if not set 2021-10-15 21:44:27 +01:00
Johan Malm
597650b457 theme: add window_(in)active_label_text_color
Support both active and inactive colors for titlebar text
2021-10-15 21:35:41 +01:00
Johan Malm
606b6d946e Fix coding style, mostly whitespace 2021-10-15 20:52:36 +01:00
Johan Malm
f8e1d76333 config: survive parsing error
It is no good crashing on an rc.xml syntax error, particularly on a
SIGHUP when the user could have applications open.
2021-10-15 20:33:55 +01:00
Johan Malm
73b8f06a26 layer-shell: fix commit handler (issue #71)
On commit, do not arrange layers unless the layer shell-specific state
changed or the layer was (un)mapped.

Chase swaywm/sway@5fd5d643 and swaywm/wlroots@754f40f9
2021-10-15 19:14:07 +01:00
ARDiDo
b040838d6a Fix build errors 2021-10-15 19:11:35 +01:00
ARDiDo
4a6093f43e Update labwc-config(5) 2021-10-15 19:11:35 +01:00
ARDiDo
416499624e Complete libinput configuration 2021-10-15 19:11:35 +01:00
Johan Malm
417763e8f8 config: support audio and monitor keys by default
Add default keybinds:

    XF86_AudioLowerVolume - amixer sset Master 5%-
    XF86_AudioRaiseVolume - amixer sset Master 5%+
    XF86_AudioMute - amixer sset Master toggle
    XF86_MonBrightnessUp - brightnessctl set +10%
    XF86_MonBrightnessDown - brightnessctl set 10%-
2021-10-14 19:37:57 +01:00
Johan Malm
5325fca4b4 Update NEWS.md 2021-10-13 21:36:26 +01:00
Johan Malm
74f01af5db buf.h: update documentation 2021-10-13 21:30:44 +01:00
Johan Malm
960a1bb2ed theme: add osd colors 2021-10-13 21:29:32 +01:00
Johan Malm
2d4ca16db8 buf.c: handle variables with curly braces
In buf_expand_shell_variables(), corrently resolve ${foo}
rather than just $foo
2021-10-11 22:31:38 +01:00
Johan Malm
aa4668c792 buf.c: correctly handle unset environment variables 2021-10-11 22:28:17 +01:00
Johan Malm
71c8aa1361 session: resolve variables in environment file
When parsing <key>=<value> pairs to set enrivonment variables,
resolve variables in <value>.

For example, resolve $bar in

    foo=$bar

Fix issue #70
2021-10-11 22:15:44 +01:00
ARDiDo
d4e1791c88 Reconfigure inputs 2021-10-10 21:52:40 +01:00
ARDiDo
326b4aebd1 keyboard repeat configuration 2021-10-10 11:34:48 +01:00
ARDiDo
3dc4c02c54 partial libinput configuration 2021-10-10 11:34:48 +01:00
Johan Malm
6a00166cff Merge branch 'master' of https://github.com/johanmalm/labwc 2021-10-04 06:24:34 +01:00
ARDiDo
6b9d3f4083 fix build errors 2021-10-03 21:50:29 +01:00
ARDiDo
565f0daee9 drag across monitor 2021-10-03 21:50:29 +01:00
ARDiDo
6bf3bb97f5 implement basic drag and drop 2021-10-03 21:50:29 +01:00
Johan Malm
1e4598cdce s/desktop_view_at()/desktop_surface_and_view_at()/
Make is clearer what the function does.
2021-09-25 10:04:37 +01:00
Johan Malm
23f28e5082 desktop: desktop_view_at() set *surface correnctly
Bug introduced in 23107
2021-09-25 09:40:23 +01:00
Johan Malm
05b89691b0 desktop: fix pointer de-reference typo
Bug introduced in 23107
2021-09-25 08:37:24 +01:00
Johan Malm
b967592289 Fix coding style 2021-09-24 22:14:04 +01:00
Johan Malm
4c66004fa8 desktop.c: fix typo to compile 2021-09-24 22:13:35 +01:00
Johan Malm
231076a58f Simplify desktop_view_at() 2021-09-24 22:04:47 +01:00
Johan Malm
d2375b025d Fix coding style 2021-09-24 22:04:03 +01:00
Johan Malm
104f635b43 session.c: change "(foo*)" to "(foo *)" 2021-09-24 21:58:46 +01:00
Johan Malm
ebb632419b *.c: add SPDX-License-Identifier 2021-09-24 21:45:48 +01:00
Johan Malm
bdcb502631 ssd: refactor vertical center alignment 2021-09-24 21:28:16 +01:00
Johan Malm
4738e26d15 theme: handle border.color for backward compatibility 2021-09-24 21:26:31 +01:00