mirror of
https://gitlab.com/dwt1/dotfiles.git
synced 2026-04-24 12:00:24 +10:00
Adding new function for maximizing/fullscreening programs
This commit is contained in:
@@ -53,6 +53,13 @@ def minimize_all(qtile):
|
|||||||
if hasattr(win, "toggle_minimize"):
|
if hasattr(win, "toggle_minimize"):
|
||||||
win.toggle_minimize()
|
win.toggle_minimize()
|
||||||
|
|
||||||
|
@lazy.function
|
||||||
|
def maximize_by_switching_layout(qtile):
|
||||||
|
current_layout_name = qtile.current_group.layout.name
|
||||||
|
if current_layout_name == 'monadtall':
|
||||||
|
qtile.current_group.layout = 'max'
|
||||||
|
elif current_layout_name == 'max':
|
||||||
|
qtile.current_group.layout = 'monadtall'
|
||||||
# A list of available commands that can be bound to keys can be found
|
# A list of available commands that can be bound to keys can be found
|
||||||
# at https://docs.qtile.org/en/latest/manual/config/lazy.html
|
# at https://docs.qtile.org/en/latest/manual/config/lazy.html
|
||||||
keys = [
|
keys = [
|
||||||
@@ -131,7 +138,7 @@ keys = [
|
|||||||
Key([mod], "n", lazy.layout.normalize(), desc="Reset all window sizes"),
|
Key([mod], "n", lazy.layout.normalize(), desc="Reset all window sizes"),
|
||||||
Key([mod], "m", lazy.layout.maximize(), desc='Toggle between min and max sizes'),
|
Key([mod], "m", lazy.layout.maximize(), desc='Toggle between min and max sizes'),
|
||||||
Key([mod], "t", lazy.window.toggle_floating(), desc='toggle floating'),
|
Key([mod], "t", lazy.window.toggle_floating(), desc='toggle floating'),
|
||||||
Key([mod], "f", lazy.window.toggle_fullscreen(), desc='toggle fullscreen'),
|
Key([mod], "f", maximize_by_switching_layout(), lazy.window.toggle_fullscreen(), desc='toggle fullscreen'),
|
||||||
Key([mod, "shift"], "m", minimize_all(), desc="Toggle hide/show all windows on current group"),
|
Key([mod, "shift"], "m", minimize_all(), desc="Toggle hide/show all windows on current group"),
|
||||||
|
|
||||||
# Switch focus of monitors
|
# Switch focus of monitors
|
||||||
|
|||||||
Reference in New Issue
Block a user