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

Adds a way to increase or decrease the gap between windows #21

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

battleprogrammershirase

Hello there,
I made a few changes to be able to increase/decrease the gaps between windows, a feature I liked in bspwm or dwm, can't remember which.
Although I am not sure that directly changing config.gap is a good way of achieving this...
It still needs to be tested on a multi monitor setup but this should work fine as far as I understand.

Here is a small demo :

pytyle-gap2

@@ -78,6 +78,18 @@ def clients(self):

# End abstract methods; begin OrientLayout specific methods

def expand_gap(self):
config.gap = config.gap + config.gap_change
Copy link
Owner

Choose a reason for hiding this comment

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

This will cause pytyle3 to crash if you haven't updated your configuration. I'd like to avoid that.

Could you change references like config.gap_change to getattr(config, 'gap_change', 5)? Similarly in other places.

@BurntSushi
Copy link
Owner

Looks good. If you fix up my concerns, I'll happily merge. :-)

@battleprogrammershirase
Copy link
Author

This should be good now!
Thanks for your inputs 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants