Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make gaps implementation consistent with i3-gaps #2726

Merged
merged 3 commits into from
Sep 30, 2018

Conversation

RyanDwyer
Copy link
Member

This changes our gaps implementation to behave like i3-gaps.

Our previous implementation allowed you to set gaps on a per container basis. This is no longer possible as it isn't supported by i3-gaps and doesn't seem to have a practical use case. The gaps_outer and gaps_inner properties on containers are now removed as they just read the gaps_inner from the workspace.

gaps inner|outer <px> no longer changes the gaps for all workspaces. It only sets defaults for new workspaces.

gaps inner|outer current|workspace|all set|plus|minus <px> is now runtime only, and the workspace option is now removed. current now sets gaps for the current workspace as opposed to the current container.

workspace <ws> gaps inner|outer <px> is now implemented. This sets defaults for a workspace.

This also fixes a bug where changing the layout of a split container from linear to tabbed would cause gaps to not be applied to it until you switch to another workspace and back.

i3-gaps docs: https://github.com/Airblader/i3#gaps

Supersedes/closes #2131.

This changes our gaps implementation to behave like i3-gaps.

Our previous implementation allowed you to set gaps on a per container
basis. This isn't supported by i3-gaps and doesn't seem to have a
practical use case. The gaps_outer and gaps_inner properties on
containers are now removed as they just read the gaps_inner from the
workspace.

`gaps inner|outer <px>` no longer changes the gaps for all workspaces.
It only sets defaults for new workspaces.

`gaps inner|outer current|workspace|all set|plus|minus <px>` is now
runtime only, and the workspace option is now removed. `current` now
sets gaps for the current workspace as opposed to the current container.

`workspace <ws> gaps inner|outer <px>` is now implemented. This sets
defaults for a workspace.

This also fixes a bug where changing the layout of a split container
from linear to tabbed would cause gaps to not be applied to it until you
switch to another workspace and back.
Copy link
Member

@RedSoxFan RedSoxFan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. If gaps are negative, they should be set to 0
  2. Can you update the man page?

Aside from those two things LGTM

@ddevault ddevault merged commit f1dbdce into swaywm:master Sep 30, 2018
@ddevault
Copy link
Contributor

Thanks!

@RyanDwyer RyanDwyer deleted the overhaul-gaps branch September 30, 2018 11:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants