aboutsummaryrefslogtreecommitdiff
path: root/sway
AgeCommit message (Collapse)Author
2018-09-24seat: only show cursor if pointer configuredIan Fan
2018-09-23Implement support for input wildcardBrian Ashworth
2018-09-23Fix GtkMenuBar always opening first itemRyan Dwyer
It seems like advertising that we support touch when we don't, while using SSD, makes GtkMenuBar misbehave. Please don't ask me why...
2018-09-23Merge pull request #2695 from RyanDwyer/remove-moveoutoftabsstacksDrew DeVault
Remove move_out_of_tabs_stacks
2018-09-23Merge pull request #2694 from RyanDwyer/fix-sticky-jumping-on-switchemersion
Prevent sticky containers from jumping on workspace switch
2018-09-23Merge pull request #2686 from RyanDwyer/tab-scrollingemersion
Implement tab cycling using mouse wheel
2018-09-23Flatten container in workspace_rejiggerRyan Dwyer
2018-09-23Fix some bugs as a result of removing move_out_of_tabs_stacksRyan Dwyer
2018-09-23Remove move_out_of_tabs_stacksRyan Dwyer
This fixes the following. Create these layouts and run move right: (Initial layout -> expected result -> actual result) * `H[S[unfocused focused] unfocused]` -> `H[S[unfocused] focused unfocused]` -> `H[H[S[unfocused] focused] unfocused]` * `H[S[unfocused focused] V[unfocused]]` -> `H[S[unfocused] V[unfocused focused]]` -> `H[H[S[unfocused] focused] V[unfocused]]` move_out_of_tabs_stacks was originally made to allow views to move out of the tabbed/stacked container in the parallel direction, but at some point this has started working using the regular logic.
2018-09-23Prevent sticky containers from jumping on workspace switchRyan Dwyer
If you have swaybar docked to the top, and you create a floating sticky container and switch workspaces on the same output, the sticky container would move down by the height of swaybar on each switch. This happens because when creating the workspace we set the dimensions to the same as the output, then the subsequent arrange corrects it. During this arrange, floating containers are translated so they stay relative to the workspace. This translation needs to not occur for the initial arrange. This patch makes workspaces have a zero width and height when first created, so we can detect whether this is the initial arrange and avoid translating the floating containers if so.
2018-09-22Merge pull request #2688 from RyanDwyer/exec-commands-without-focusDrew DeVault
Allow running commands on containers without focusing them
2018-09-23Allow running commands on containers without focusing themRyan Dwyer
This adds a `con` argument to `execute_command` which allows you to specify the container to execute the command on. In most cases it leaves it as `NULL` which makes it use the focused node. We only set it when executing `for_window` criteria such as when a view maps. This means we don't send unnecessary IPC focus events, and fixes a crash when the criteria command is `move scratchpad` (because we can't give focus to a hidden scratchpad container). Each of the shell map handlers now check to see if the view has a workspace. It won't have a workspace if criteria has moved it to the scratchpad.
2018-09-22commands: remove obselete code for sticky windows when switching workspaceIan Fan
2018-09-22swaybar, swaylock, & tree/container: Set cairo font options to render text ↵Geoff Greer
and lines with subpixel hinting (if available).
2018-09-22Merge pull request #2660 from RyanDwyer/fix-scratchpad-iterationemersion
Fix double iteration of scratchpad containers
2018-09-22Fix pango escaping and refactor escape_markup_textRyan Dwyer
Fixes #2674. The cause of the issue was in get_pango_layout. When we call pango_parse_markup, `text` is the escaped string, and the unescaped string is then computed and written to `buf`. We were then passing the unescaped string to pango_layout_set_markup, but this function needs the escaped string. `buf` is not needed and has been removed. The other part of this PR refactors escape_markup_text to remove the dest_length argument and removes the -1 return value on error. It now assumes that you've allocated dest to the correct length.
2018-09-22Merge pull request #2678 from RyanDwyer/reconfigure-on-repositionemersion
Reconfigure xwayland views when repositioned
2018-09-22Implement tab cycling using mouse wheelRyan Dwyer
Firstly, a change had to be made to the container_at functions. If you create layout `T[view H[view view]]` and hover the second tab, the container_at functions would return the focus_inactive child. They now return the split container itself. To compensate for this, dispatch_cursor_button has been adjusted to find the focus_inactive child before focusing it. The actual implementation of wheel scrolling is pretty straightforward. This uses handle_cursor_axis, so I took a similar approach to handle_cursor_button (ie. creating a dispatch_cursor_axis function).
2018-09-21Merge branch 'master' into swaybar-hotplugBrian Ashworth
2018-09-21Reconfigure xwayland views when repositionedRyan Dwyer
Fixes #2673.
2018-09-21Fix compilation against wlroots without X11 backendMarien Zwart
2018-09-21Merge branch 'master' into render-output-segfaultRyan Dwyer
2018-09-20swaybar: handle hotpluggingemersion
Don't kill and respawn swaybars on hotplug.
2018-09-20Merge pull request #2671 from emersion/output-execute-no-focusemersion
Fix segfault when executing command without focus
2018-09-19Merge pull request #2676 from ianyfan/ipcDrew DeVault
ipc: add pid information for views in layout tree
2018-09-19ipc: add pid information for views in layout treeIan Fan
2018-09-19Fix segfault when executing command without focusemersion
2018-09-19Merge branch 'master' into create-output-commandemersion
2018-09-19config: free strings fields when freeing input configIan Fan
2018-09-19Introduce create_output command (for developer use)Ryan Dwyer
Should help with testing hotplugging.
2018-09-19Fix segfault in output_renderemersion
2018-09-18Fix double iteration of scratchpad containersRyan Dwyer
root_for_each_container and root_find_container were using incorrect logic to determine if a container was hidden in the scratchpad. Containers will have a NULL parent if they are a direct child of a workspace. Containers will have a NULL workspace if they are hidden in the scratchpad. The incorrect check meant that root_for_each_container would run the callback on scratchpad containers twice. This meant that executing a command such as `[class="$something"] scratchpad show` would cause the command to run twice, resulting in the container being shown and hidden again which is effectively a no op. Fixes #2655.
2018-09-17Fix crash moving out of tab containerWilliam Wold
2018-09-16Merge pull request #2637 from RyanDwyer/fix-tabbed-workspace-shenanigansDrew DeVault
Make seat_get_active_child ignore floating children
2018-09-16Fix crash when destroying an idle-inhibiting clientMarien Zwart
When destroying an idle-inhibiting client, idle_inhibit_v1_check_active can get called from transaction_progress_queue on a view with a null container. view_is_visible does not handle a view in this state.
2018-09-16Rename seat_get_active_child to seat_get_active_tiling_childRyan Dwyer
Also renames container to con in one function to prevent ugly line wrapping.
2018-09-16Make seat_get_active_child ignore floating childrenRyan Dwyer
seat_get_active_child is used to get the active tiling child in a few places, such as outputs getting their active workspace and tabbed/stacked containers getting their visible child. When a workspace uses a tabbed or stacked layout and contains a focused floating view, calling seat_get_active_child on the workspace would incorrectly return the floating view. This changes it so it will return the tiling child. This fixes the following bug: * Create layout T[view view] then float one of the views * Attempt to click the tiling view to give it focus - it wouldn't work because seat_get_active_child would return the floating view
2018-09-16Fix crash when unmapping last child of a tabbed workspaceRyan Dwyer
* Create layout T[view view] * Move the cursor into the title bar area * Close both views Sway would crash because container_at_tabbed would attempt to divide by zero when there are no children. The children check isn't needed for the stacked function because it doesn't divide anything by the number of children. Fixes #2636.
2018-09-15ipc: handle NULL cases for node_get_outputIan Fan
2018-09-15ipc: add focus information to root nodeIan Fan
2018-09-14Merge branch 'master' into wlroots-1243Drew DeVault
2018-09-14Additional fix for xdg-outputDrew DeVault
2018-09-14Merge branch 'master' into wlroots-1243Drew DeVault
2018-09-14Postfix xdg-output headersDrew DeVault
"Doesn't need an update" my ass...
2018-09-15Remove redundant container creation in view initializationIan Fan
2018-09-14Update for swaywm/wlroots#1243emersion
2018-09-14Address ianyfan's commentsBrian Ashworth
wordexp p is now initialized to {0} to prevent a segfault on wordfree in the failure case. File paths with single quotes and double quotes are now supported. The quote can either be wrapped in the other quote or escaped with three backslashes. Additionally to make passing file paths with double quotes to swaybg easier, instead of enclosing the path given to swaybg in quotes, all spaces, single quotes, and double quotes in the resulting path are now escaped with a single backslash.
2018-09-13Escape spaces in background file pathBrian Ashworth
2018-09-13Allow spaces in background file pathsBrian Ashworth
2018-09-13Remove bad assertion in workspace_rejiggerRyan Dwyer
The assertion can be (rightfully) triggered by creating layout V[H[view view] view] and moving the top right view to the right. After removing the assertion I found the container being moved needs its size reset to prevent it from being sized wrongly after arranging.