Ryan Dwyer
936226845f
Add extra check for view title being NULL
2018-05-05 22:29:37 +10:00
Ryan Dwyer
5d6d24e71a
Move code for re-arranging after font height change into a common place
2018-05-05 22:29:37 +10:00
Ryan Dwyer
da7d6642d3
Refactor parse_title_format()
2018-05-05 22:29:37 +10:00
Ryan Dwyer
228c478e8d
Implement title_format
...
This implements the title_format command, with a new placeholder %shell
which gets substituted with the view type (xwayland, xdg_shell_v6 or
wl_shell).
Example config:
for_window [title=".*"] title_format %title (class=%class instance=%instance shell=%shell)
2018-05-05 22:29:37 +10:00
Ryan Dwyer
e83e5487be
Use scissor to render title texture
...
This allows the title's texture to always be the full width of the text,
and clipped at render time according to the desired width (eg. tabs...).
As an added bonus, the texture no longer needs to be updated when
containers are arranged.
2018-05-05 20:32:31 +10:00
Alex Xu (Hello71)
3202c45054
Check for NULL in container_update_title
...
Fixes crash when opening Firefox developer tools.
2018-05-04 11:10:01 -04:00
Ryan Dwyer
ed0d606c2a
Fix title texture width
...
Use max of the container width or text width.
2018-05-03 22:51:14 +10:00
Drew DeVault
58a033d816
Convert border_colors.text to float[4]
2018-05-03 08:14:17 -04:00
Drew DeVault
8f06aa7598
Fix anti-aliasing
2018-05-03 08:12:26 -04:00
Ryan Dwyer
89d1571041
Fix potential segfault when setting container title
2018-05-03 15:23:39 +10:00
Ryan Dwyer
55b307cddf
Calculate config->font_height based on existing container titles
2018-05-03 15:12:00 +10:00
Ryan Dwyer
b667298a0a
Render titles
2018-05-03 15:12:00 +10:00
Dillen Meijboom
b45e2bd95e
Fixed #1888 GCC cannot compile due to uninitialized variables ( #1889 )
2018-05-02 10:40:45 +01:00
db
22170bde77
Fix layer surface crash on output destroy
...
Before freeing sway_output, NULL the wlr_output reference to it. Check for that
NULL in layer_shell handle_destroy. Don't damage null container in unmap.
Additionaly, terminate swaybg if its output is being disabled.
2018-05-01 19:05:32 +02:00
Ryan Dwyer
83952c5201
Restore view_update_position()
2018-05-01 07:46:57 -04:00
Ryan Dwyer
55577498c0
Allow clicking view decorations to focus view
2018-05-01 07:46:57 -04:00
Ryan Dwyer
0375f966f1
Fix surface offset when using borders
2018-05-01 07:46:57 -04:00
Ryan Dwyer
fa5de2876e
Move docblock and fix indenting of switch/case.
2018-05-01 07:46:57 -04:00
Ryan Dwyer
630ba30e3c
Implement borders
...
Implements rendering of borders. Title text is still to do.
Implements the following configuration directives:
* client.focused
* client.focused_inactive
* client.unfocused
* client.urgent
* border
* default_border
2018-05-01 07:46:57 -04:00
Ryan Dwyer
91f97fc21a
Fix segfault in view_unmap()
...
If the last remaining view on a workspace is unmapped and the workspace
is not visible, parent will be a C_OUTPUT. Call the arrange_output()
function in this case.
2018-05-01 17:18:20 +10:00
Ryan Dwyer
312fdf313f
Remove arrange_windows()
...
After the refactor, this function is no longer called.
2018-04-30 08:47:38 +10:00
Ryan Dwyer
167c2e1aa9
Refactor arrange_windows()
...
Replaces arrange_windows() with arrange_root(), arrange_output(),
arrange_workspace() and arrange_children_of().
Also makes fullscreen views save and restore their dimensions, which
allows it to preserve any custom resize and is also a requirement for
floating views once they are implemented.
2018-04-28 11:26:14 +10:00
Ryan Dwyer
ae39d7b28c
Remove sway_container.workspace_layout
...
Fixes #1716 .
2018-04-26 10:14:18 +10:00
Ryan Dwyer
dfc26c664f
Update wording about unmanaged/unmapped views
2018-04-24 20:14:22 +10:00
Ryan Dwyer
30a7488936
Add assert to view_execute_criteria()
2018-04-24 20:08:32 +10:00
Ryan Dwyer
72767e1cc3
Implement criteria commands
...
Implements the following commands:
* for_window [...] <cmdlist>
* assign [...] <workspace>
2018-04-24 20:08:32 +10:00
Ryan Dwyer
22b9169631
Fix crash in container_descendants()
...
If root is a C_VIEW, the children property is a null pointer.
2018-04-24 12:27:04 +10:00
emersion
a41057714f
Update for wlroots#885
2018-04-21 19:12:49 +01:00
Ryan Dwyer
34429a3605
Keep view fullscreened when moving to another workspace.
...
container_handle_fullscreen_reparent() must be called *after* setting
the container's new parent.
2018-04-20 21:26:14 +10:00
Ryan Dwyer
45a2fad0de
container_get_in_direction(): Don't split this function
2018-04-19 12:53:02 +10:00
Ryan Dwyer
7e38cc2e05
arrange_windows(): Calculate workspace properties when fullscreen
2018-04-19 12:50:53 +10:00
Ryan Dwyer
35ccdd67a8
More fullscreen fixes.
...
* Render fullscreen views without wlr function, which makes popups and
lockscreen work.
* Don't allow input events to surfaces behind fullscreen views.
* Use correct output dimensions (for rotated outputs).
2018-04-18 08:35:28 +10:00
Ryan Dwyer
72beae209b
Fullscreen fixes.
2018-04-18 00:10:32 +10:00
Ryan Dwyer
cc4da245a8
Fix views unmapping their own fullscreen windows.
2018-04-17 11:06:03 +10:00
Ryan Dwyer
c685ef081f
Create sway_workspace struct.
2018-04-17 09:31:34 +10:00
Ryan Dwyer
bfd5834f4c
Feedback for fullscreen.
2018-04-17 08:11:50 +10:00
Ryan Dwyer
52420cc24d
Implement fullscreen.
2018-04-16 20:36:40 +10:00
Dominique Martinet
8490d1662c
Fix gcc maybe-uninitialized warning
2018-04-13 22:47:27 +09:00
Dominique Martinet
de65d05821
container_destroy: fix segfault
...
cont->children doesn't have to be NULL when there is no children
2018-04-13 14:58:23 +09:00
Tony Crisci
9db859585e
container_create_notify on split
2018-04-07 18:01:18 -04:00
Tony Crisci
c0f9ee7bd1
seat get focus inactive view
2018-04-07 16:06:36 -04:00
emersion
61abd56ca4
Fix output containers position
2018-04-07 12:44:02 -04:00
Drew DeVault
c47b4d4edb
Merge pull request #1756 from emersion/output-damage
...
Fine-grained damage tracking
2018-04-07 11:53:10 -04:00
Drew DeVault
f5a9bd5cb7
Merge pull request #1700 from swaywm/move-cmd-full
...
Implement move [left|right|up|down]
2018-04-07 11:19:25 -04:00
emersion
93ca8919f6
Don't rejigger if parent has two children
2018-04-06 18:10:02 -04:00
emersion
37b173f326
When moving between outputs, use output center as reference
2018-04-06 17:50:12 -04:00
Drew DeVault
640232eb22
Revert "Break everything^W^WUse wlr_box for sway_container"
2018-04-06 16:13:26 -04:00
Drew DeVault
df0d57b916
Fix issue with incorrectly rejiggered workspaces
2018-04-06 15:54:03 -04:00
Drew DeVault
764489e737
Break everything^W^WUse wlr_box for sway_container
2018-04-06 15:38:37 -04:00
Drew DeVault
9109b1fd11
Fix moving to parallel container on another output
2018-04-06 15:37:55 -04:00