aboutsummaryrefslogtreecommitdiff
path: root/sway/layout.c
AgeCommit message (Collapse)Author
2016-07-31Refactor functions to update container bordersTony Crisci
Replace `update_view_border()` with `update_container_border()`. The latter should handle both the case where the container is a view or if the container has children.
2016-07-30revert border hiding to more recent versionD.B
2016-07-30properly hide top border inside tabbed/stackedD.B
When titlebar is hidden, top border of the topmost view inside tabbed/stacked container will not be drawn. This is changed in layout.c On the other hand, top border should be drawn sometimes, for example when titlebar is hidden on a view that is not the topmost inside tabbed/stacked container. This is changed in border.c
2016-07-28Update hidpi support to latest wlc APIDrew DeVault
2016-07-28Initial pass on HiDPI supportDrew DeVault
2016-07-28Merge pull request #793 from thejan2009/workspace_layout_first_window_fixDrew DeVault
bugfix: invisible windows on empty workspace with tabbed/stacked layout
2016-07-28bugfix: windows on empty workspaces with layout tabbed/stacked would spawn ↵D.B
with 0x0 geometry
2016-07-27Implement `focus child` commandTony Crisci
The `focus child` command focuses the child container within the selected container.
2016-07-22properly hide bottom and right bordersD.B
2016-07-21fix regression in hide_edge_bordersZandr Martin
2016-07-21rename ws to workspace for clarityD.B
2016-07-21calculate borders for hiding from workspace geometryD.B
2016-07-21Arrange backgrounds only when requiredMykyta Holubakha
2016-07-21Initial work on window eventsMykyta Holubakha
2016-07-18Move backgrounds to back after arrange_windowsDrew DeVault
Fixes #769
2016-07-16refactor swayc_tabbed_stacked_parent into _ancestor and _parent and use ↵D.B
where needed
2016-07-04implement `get_tree` commandZandr Martin
2016-06-02redo smart_gaps/hide_edge_borders fixZandr Martin
2016-05-18Fix issue #661.Jasen Borisov
Borders are now drawn correctly (same behavior as i3) for tabbed and stacked containers, when the children have 'border none' set.
2016-04-29Fix uninitialized variableMikkel Oscar Lyderik
2016-04-27border: clear buffer on fullscreen viewsMikkel Oscar Lyderik
This patch makes sure to clear the border buffer of fullscreen view so the border doesn't get drawn behind a fullscreen view, which would be visible if the view was transparent.
2016-04-25Remove commented codeMikkel Oscar Lyderik
2016-04-25Use correct geometry for nested containersMikkel Oscar Lyderik
2016-04-25Disable inner gaps when in tabbed/stacked modeMikkel Oscar Lyderik
2016-04-25Add support for nested tabbed/stacked containersMikkel Oscar Lyderik
2016-04-25Make floating border fixes work with tabbed/stacked codeMikkel Oscar Lyderik
2016-04-25Improve move command with tabbed/stacked layoutMikkel Oscar Lyderik
2016-04-25Correctly determine default layoutMikkel Oscar Lyderik
2016-04-25Fix problems with floating windowsMikkel Oscar Lyderik
Makes any tabbed/stacked layout a container to separate from floating windows which may be attached to a workspace.
2016-04-25Tabbed and stacked layoutMikkel Oscar Lyderik
2016-04-16Remove clang warnings (-Wsign-compare)Mikkel Oscar Lyderik
2016-04-03Fix window borderscrondog
This fixes floating borders when moving outside of the output. Not sure what happens with dual screen as I only have 1 monitor
2016-04-02Fix spelling mistakesEric Engestrom
2016-03-31Correctly reset border geometryMikkel Oscar Lyderik
2016-03-30Fix borders with floating windowsMikkel Oscar Lyderik
2016-03-30Implement bordersMikkel Oscar Lyderik
The borders are implemented as a surface/buffer attached to each view which is sent to and rendered by wlc in the view_pre_render callback. All the drawing logic is handled in sway/border.c and all the logic for calculating the geometry of the border/view is handled in `update_geometry` in sway/layout.c (same place as gaps are calculated).
2016-03-30Implement some more on bordersDrew DeVault
Note that this segfaults ALL THE TIME in wlc code. Paging @Cloudef for help, I'm at a loss.
2016-03-20Implement 'smart_gaps' feature from i3-gapsMikkel Oscar Lyderik
2016-03-04Fix assigning workspaces to outputsMikkel Oscar Lyderik
It's possible to assign workspaces to certain outputs using the command: workspace <name> output <output> However, this did not work in some cases where the workspace was assigned before the given output was made available to sway. This patch fixes those cases.
2016-02-28Correctly move focus from one output to a new one.Mikkel Oscar Lyderik
This patch aims to correctly handle moving focus <left|right|up|down> between outputs. For instance, if moving from one output to a new output at the left of the current one, it should focus the right-most view/container on the new output, and the opposite if moving from right to left. This should happen regardless of the previously stored focus of the new output. This also handles moving to a new output above or below the current one.
2015-12-28arrange_windows_r: Round pixels to match reality, fixes calculations.S. Christoffer Eliesen
If the width or height of a container can't be evenly distributed to its children, then the layout algorithm still thought it got it right (due to using decimals) which caused a gap of one or more pixels for some window arrangements. This is fixed by this patch by first rounding off the width and height (so that decimals are never introduced) and then adjusting the last view in a container to fill the remaining pixels (which now is counted correctly due to the decimals being removed). Also, due to the way gaps are implemented, an odd sized gap can never be aligned properly, so just adjust to closest even number.
2015-12-28arrange_windows_r: Bring parent coordinates into layout calculations.S. Christoffer Eliesen
This brings consistency into the algorithm (instead of resetting and then fetching again).
2015-12-25Focus new sibling added to containerMikkel Oscar Lyderik
This makes sure that the window being added to a container gets focus.
2015-12-25Trigger workspace init event (floating)Mikkel Oscar Lyderik
Triggers workspace init event when moving a floating window to a new workspace. This is a follow up on #391 which didn't handle floating windows.
2015-12-21Trigger ipc_event_workspace in all casesMikkel Oscar Lyderik
This makes sure that the workspace IPC event is triggered when needed. Fixes #382 while making sure that the IPC event is only triggered once.
2015-12-20layout: Fix `edge_gaps off` with top/left panels.S. Christoffer Eliesen
Since x/y won't be zero when there's a top or left panel in place, we need to take those coordinates into account too.
2015-12-20extensions: Track panels by wl_resource, position per panel.S. Christoffer Eliesen
Track each panel separately via its wl_resource. `set_panel_position` might be called before `set_panel`, so reuse panel config. Place the position in panel_config so that each panel has its own position.
2015-12-18layout: arrange_windows: Partially fix swaybar irregularties.S. Christoffer Eliesen
2015-12-18layout: arrange_windows: Fix/better debug output.S. Christoffer Eliesen
2015-12-18layout: Keep output at the correct size, workspace can be smaller.S. Christoffer Eliesen
If the output is not at the correct size then that info must be queried from wlc. The output size is used by e.g. seamless mouse to detect output edges. With this patch the output size is now correct and the workspace size is adjusted according to any panels. Without this patch seamless mouse would fail to detect outputs above/below each other if there was a panel in between because the output would offically end where the panel started, not at the actual screen edge.