コード例 #1
0
ファイル: ramnes.py プロジェクト: 20after4/qtile-examples
def init_keys():
    keys = [Key([mod], "Left", lazy.screen.prevgroup()),
            Key([mod], "Right", lazy.screen.nextgroup()),

            Key([mod, "shift"], "Left", window_to_prev_group),
            Key([mod, "shift"], "Right", window_to_next_group),

            Key([mod], "Tab", lazy.group.next_window()),
            Key([mod, "shift"], "Tab", lazy.group.prev_window()),

            Key([mod], "space", lazy.nextlayout()),
            Key([mod, "shift"], "space", lazy.prevlayout()),

            Key([mod], "j", lazy.layout.up()),
            Key([mod], "k", lazy.layout.down()),
            Key([mod], "f", lazy.window.toggle_floating()),

            Key([mod], "r", lazy.spawncmd()),
            Key([mod], "Return", lazy.spawn(term)),
            Key([mod], "l", lazy.spawn(lock)),

            Key([mod, "shift"], "c", lazy.window.kill()),
            Key([mod, "shift"], "r", lazy.restart()),
            Key([mod, "shift"], "q", lazy.shutdown())]
    if DEBUG:
        keys += [Key(["mod1"], "Tab", lazy.layout.next()),
                 Key(["mod1", "shift"], "Tab", lazy.layout.previous())]
    return keys
コード例 #2
0
def init_keys():
    keys = [
        Key([mod], "Left", lazy.screen.prevgroup()),
        Key([mod], "Right", lazy.screen.nextgroup()),
        Key([mod, "shift"], "Left", window_to_prev_group),
        Key([mod, "shift"], "Right", window_to_next_group),
        Key([mod], "Tab", lazy.group.next_window()),
        Key([mod, "shift"], "Tab", lazy.group.prev_window()),
        Key([mod], "space", lazy.nextlayout()),
        Key([mod, "shift"], "space", lazy.prevlayout()),
        Key([mod], "j", lazy.layout.up()),
        Key([mod], "k", lazy.layout.down()),
        Key([mod], "f", lazy.window.toggle_floating()),
        Key([mod], "r", lazy.spawncmd()),
        Key([mod], "Return", lazy.spawn(term)),
        Key([mod], "l", lazy.spawn(lock)),
        Key([mod, "shift"], "c", lazy.window.kill()),
        Key([mod, "shift"], "r", lazy.restart()),
        Key([mod, "shift"], "q", lazy.shutdown()),

        # My Own Shortcuts!
        Key([alt, "shift"], "e", lazy.spawn("nautilus")),
        Key([alt, "shift"], "w", lazy.spawn("firefox")),
        Key([alt, "shift"], "f", lazy.spawn("firefox")),
        Key([alt, "shift"], "s", lazy.spawn("subl")),
        Key([alt, "shift"], "l", lazy.spawn("wakeonlan 00:15:17:30:24:08")),
        Key([alt, "shift"], "t", lazy.spawn("terminology"))
    ]
    if DEBUG:
        keys += [
            Key(["mod1"], "Tab", lazy.layout.next()),
            Key(["mod1", "shift"], "Tab", lazy.layout.previous())
        ]
    return keys
コード例 #3
0
ファイル: ramnes.py プロジェクト: meeh420/qtile-examples
def init_keys():
    keys = [
        Key([mod], "Left", lazy.screen.prevgroup()),
        Key([mod], "Right", lazy.screen.nextgroup()),
        Key([mod, "shift"], "Left", window_to_prev_group),
        Key([mod, "shift"], "Right", window_to_next_group),
        Key([mod], "Tab", lazy.group.next_window()),
        Key([mod, "shift"], "Tab", lazy.group.prev_window()),
        Key([mod], "space", lazy.nextlayout()),
        Key([mod, "shift"], "space", lazy.prevlayout()),
        Key([mod], "j", lazy.layout.up()),
        Key([mod], "k", lazy.layout.down()),
        Key([mod], "f", lazy.window.toggle_floating()),
        Key([mod], "r", lazy.spawncmd()),
        Key([mod], "Return", lazy.spawn(term)),
        Key([mod], "l", lazy.spawn(lock)),
        Key([mod, "shift"], "c", lazy.window.kill()),
        Key([mod, "shift"], "r", lazy.restart()),
        Key([mod, "shift"], "q", lazy.shutdown())
    ]
    if DEBUG:
        keys += [
            Key(["mod1"], "Tab", lazy.layout.next()),
            Key(["mod1", "shift"], "Tab", lazy.layout.previous())
        ]
    return keys
コード例 #4
0
def get_keyboard_hotkey(mod):
    return [
        Key([mod], "k",
            lazy.layout.down()),
        Key([mod], "j",
            lazy.layout.up()),
        Key([mod, "shift"], "k",
            lazy.layout.shuffle_down()),
        Key([mod, "shift"], "j",
            lazy.layout.shuffle_up()),
        Key([mod], "l",
            lazy.layout.grow()),
        Key([mod], "h",
            lazy.layout.shrink()),
        Key([mod], "n",
            lazy.layout.normalize()),
        Key([mod], "o",
            lazy.layout.maximize()),
        Key([mod], "space",
            lazy.nextlayout()),
        Key([mod], "r",
            lazy.function(lambda qtile: DMenu().run(True))),
        Key([mod, "shift"], "r",
            lazy.function(lambda qtile: DMenu().run(False))),
        Key([mod, "control"], "r",
            lazy.spawncmd()),
        Key([mod], "equal",
            lazy.function(inc_volume)),
        Key([mod], "minus",
            lazy.function(dec_volume)),
        Key([mod], "Return",
            lazy.spawn("urxvt")),
        Key([mod], "e",
            lazy.spawn("emacs")),
        Key([mod, "shift"], "q",
            lazy.window.kill()),
        Key([mod, "shift", "control"], "r",
            lazy.restart()),
        Key([mod, "shift", "control"], "q",
            lazy.shutdown()),
        Key([mod, "shift"], "d",
            lazy.hide_show_bar()),
    ]
コード例 #5
0
ファイル: ramnes.py プロジェクト: imclab/qtile-examples
def init_keys():
    return [Key([mod], "Left", lazy.screen.prevgroup()),
            Key([mod], "Right", lazy.screen.nextgroup()),

            Key([mod, "shift"], "Left", window_to_prev_group),
            Key([mod, "shift"], "Right", window_to_next_group),

            Key([mod], "Tab", lazy.layout.previous()),
            Key([mod, "shift"], "Tab", lazy.layout.next()),

            Key([mod], "space", lazy.nextlayout()),
            Key([mod, "shift"], "space", lazy.prevlayout()),

            Key([mod], "j", lazy.layout.up()),
            Key([mod], "k", lazy.layout.down()),

            Key([mod], "r", lazy.spawncmd()),
            Key([mod, "shift"], "c", lazy.window.kill()),
            Key([mod], "Return", lazy.spawn(term)),
            Key([mod], "l", lazy.spawn(lock)),
            Key([mod, "control"], "r", lazy.restart())]
コード例 #6
0
ファイル: config.py プロジェクト: DeathPoison/dotfiles
def init_keys():
    keys = [Key([mod], "Left", lazy.screen.prevgroup()),
            Key([mod], "Right", lazy.screen.nextgroup()),

            Key([mod, "shift"], "Left", window_to_prev_group),
            Key([mod, "shift"], "Right", window_to_next_group),

            Key([mod], "Tab", lazy.group.next_window()),
            Key([mod, "shift"], "Tab", lazy.group.prev_window()),

            Key([mod], "space", lazy.nextlayout()),
            Key([mod, "shift"], "space", lazy.prevlayout()),

            Key([mod], "j", lazy.layout.up()),
            Key([mod], "k", lazy.layout.down()),
            Key([mod], "f", lazy.window.toggle_floating()),

            Key([mod], "r", lazy.spawncmd()),
            Key([mod], "Return", lazy.spawn(term)),
            Key([mod], "l", lazy.spawn(lock)),

            Key([mod, "shift"], "c", lazy.window.kill()),
            Key([mod, "shift"], "r", lazy.restart()),
            Key([mod, "shift"], "q", lazy.shutdown()),

            # My Own Shortcuts!
            Key([alt, "shift"], "e", lazy.spawn("nautilus")),
            Key([alt, "shift"], "w", lazy.spawn("firefox")),
            Key([alt, "shift"], "f", lazy.spawn("firefox")),
            Key([alt, "shift"], "s", lazy.spawn("subl")),

            Key([alt, "shift"], "l", lazy.spawn("wakeonlan 00:15:17:30:24:08")),

            Key([alt, "shift"], "t", lazy.spawn("terminology"))]
    if DEBUG:
        keys += [Key(["mod1"], "Tab", lazy.layout.next()),
                 Key(["mod1", "shift"], "Tab", lazy.layout.previous())]
    return keys
コード例 #7
0
font_params = {
    'font': font,
    'fontsize': fontsize,
    'foreground': foreground,
}

keys = [
    Key([mod], "k", lazy.layout.down()),
    Key([mod], "j", lazy.layout.up()),
    Key([mod, "shift"], "k", lazy.layout.shuffle_down()),
    Key([mod, "shift"], "j", lazy.layout.shuffle_up()),
    Key([mod], "Tab", lazy.layout.next()),
    Key([mod, "shift"], "Tab", lazy.layout.client_to_next()),
    Key([mod, "shift"], "space", lazy.layout.rotate()),
    Key([mod, "shift"], "Return", lazy.layout.toggle_split()),
    Key([mod], "space", lazy.nextlayout()),
    Key([mod], "t", lazy.window.toggle_floating()),
    Key([mod], "w", lazy.to_screen(0)),
    Key([mod, "shift"], "w", lazy.function(move_window_to_screen(0))),
    Key([mod], "e", lazy.to_screen(1)),
    Key([mod, "shift"], "e", lazy.function(move_window_to_screen(1))),
    Key([mod], "Return", lazy.spawn("urxvt")),
    Key([mod], "p",
        lazy.spawn("dmenu_run -fn '%s:pixelsize=%d'" % (font, fontsize))),
    Key([mod, "shift"], "c", lazy.window.kill()),
    Key([mod], "q", lazy.restart()),
    Key([mod, "shift"], "q", lazy.shutdown()),
]

mouse = [
    Click([mod], "Button1", lazy.window.bring_to_front()),
コード例 #8
0
from libqtile.config import Drag, Click, Key, Group
from libqtile.manager import Screen
from libqtile.command import lazy
from libqtile import layout, bar, widget

#from system import get_num_monitors

#log = logging.getLogger("qtile.config")

# Find urxvt binary and if not found use xterm


mod_key = "mod4"
keys = [
    # Toggle between different layouts as defined below
    Key([mod_key], "Tab",    lazy.nextlayout()),

    # Switch between windows in current stack pane

    Key([mod_key], "h", lazy.layout.left()),
    Key([mod_key], "l", lazy.layout.right()),
    Key([mod_key], "j", lazy.layout.down()),
    Key([mod_key], "k", lazy.layout.up()),
    Key([mod_key, "shift"], "h", lazy.layout.swap_left()),
    Key([mod_key, "shift"], "l", lazy.layout.swap_right()),
    Key([mod_key, "shift"], "j", lazy.layout.shuffle_down()),
    Key([mod_key, "shift"], "k", lazy.layout.shuffle_up()),
    Key([mod_key], "i", lazy.layout.grow()),
    Key([mod_key], "m", lazy.layout.shrink()),
    Key([mod_key], "n", lazy.layout.normalize()),
    Key([mod_key], "o", lazy.layout.maximize()),
コード例 #9
0
ファイル: default_config.py プロジェクト: vincpi/qtile
        [mod, "shift"], "space",
        lazy.layout.rotate()
    ),

    # Toggle between split and unsplit sides of stack.
    # Split = all windows displayed
    # Unsplit = 1 window displayed, like Max layout, but still with
    # multiple stack panes
    Key(
        [mod, "shift"], "Return",
        lazy.layout.toggle_split()
    ),
    Key([mod], "Return", lazy.spawn("xterm")),

    # Toggle between different layouts as defined below
    Key([mod], "Tab", lazy.nextlayout()),
    Key([mod], "w", lazy.window.kill()),

    Key([mod, "control"], "r", lazy.restart()),
    Key([mod, "control"], "q", lazy.shutdown()),
    Key([mod], "r", lazy.spawncmd()),
]

groups = [Group(i) for i in "asdfuiop"]

for i in groups:
    # mod1 + letter of group = switch to group
    keys.append(
        Key([mod], i.name, lazy.group[i.name].toscreen())
    )
コード例 #10
0
ファイル: config.py プロジェクト: freddez/yoga
    Key([mod], "Next", lazy.layout.down()),
    # Key([mod, "control"], "Prior", lazy.layout.shift_up()),
    # Key([mod, "control"], "Next", lazy.layout.shift_down()),

    Key([mod], "Tab", lazy.group.prev_window()),
    Key([mod, "shift"], "Return", lazy.layout.rotate()),
    Key([mod, "shift"], "space", lazy.layout.toggle_split()),

    Key([mod], "o", lazy.next_screen()),

    Key([mod], "e",      lazy.spawn("/usr/local/bin/emacs")),
    Key([mod], "f",      lazy.spawn("firefox")),
    Key([mod, "shift"], "f", lazy.window.toggle_fullscreen()),
    Key([mod], "g",      lazy.spawn("google-chrome")),
    Key([mod], "Return", lazy.spawn("x-terminal-emulator")),
    Key([mod], "z",  lazy.nextlayout()),
    Key([mod, "shift"], "z",  lazy.prevlayout()),
    Key([mod, "control"], "space",  lazy.nextlayout()),
    Key([mod], "c",      lazy.window.kill()),
    Key([mod], "t",      lazy.window.disable_floating()),
    # Key([mod, "shift"], "t", lazy.window.enable_floating()),

    # interact with prompts
    Key([mod], "r",              lazy.spawncmd()),
    Key([mod], "g",              lazy.switchgroup()),

    Key([mod], "Left", lazy.prevgroup()),
    Key([mod], "Right", lazy.nextgroup()),
]

if HOSTNAME.startswith('yoga'):
コード例 #11
0
    #Key([mod], 'j', lazy.layout.up()),
    #Key([mod], 'k', lazy.layout.down()),
    #Key([mod, 'shift'], 'j', lazy.layout.shuffle_up()),
    #Key([mod, 'shift'], 'k', lazy.layout.shuffle_down()),
    #Key([mod, 'shift'], 'g', lazy.layout.grow()),
    #Key([mod, 'shift'], 's', lazy.layout.shrink()),
    #Key([mod, 'shift'], 'n', lazy.layout.normalize()),
    #Key([mod, 'shift'], 'm', lazy.layout.maximize()),
    #Key([mod, 'shift'], 'space', lazy.layout.flip()),

    # Switch groups
    Key([mod], 'Left', lazy.screen.prevgroup()),
    Key([mod], 'Right', lazy.screen.nextgroup()),

    # Cycle layouts
    Key([mod], 'Up', lazy.nextlayout()),
    Key([mod], 'Down', lazy.prevlayout()),

    # Change window focus
    Key([mod], 'Tab', lazy.layout.next()),
    Key([mod, 'shift'], 'Tab', lazy.layout.previous()),

    # Switch focus to other screens
    Key([mod], 'h', lazy.to_screen(0)),  # left
    Key([mod], 'l', lazy.to_screen(1)),  # right

    # Commands: Application Launchers
    Key([mod], 'space', lazy.spawn(Commands.dmenu)),
    Key([mod], 'n', lazy.spawn(Commands.browser)),
    Key([mod], 'e', lazy.spawn(Commands.file_manager)),
    Key([mod], 'Return', lazy.spawn(Commands.terminal)),
コード例 #12
0
ファイル: config.py プロジェクト: vkochan/my_repo
# The keys variable contains a list of all of the keybindings that qtile will
# look through each time there is a key pressed.
keys = [
    # Log out; note that this doesn't use mod4: that's intentional in case mod4
    # gets hosed (which happens if you unplug and replug your usb keyboard
    # sometimes, or on system upgrades). This way you can still log back out
    # and in gracefully.
    Key(["shift", "mod1"], "q",  lazy.shutdown()),

    Key([mod], "k",              lazy.layout.down()),
    Key([mod], "j",              lazy.layout.up()),
    Key([mod], "h",              lazy.layout.previous()),
    Key([mod], "l",              lazy.layout.previous()),
    Key([mod, "shift"], "space", lazy.layout.rotate()),
    Key([mod, "shift"], "Return",lazy.layout.toggle_split()),
    Key([alt], "Tab",           lazy.nextlayout()),
    Key([mod], "x",              lazy.window.kill()),

    # interact with prompts
    Key([mod], "r",              lazy.spawncmd()),
    Key([mod], "g",              lazy.switchgroup()),

    # start specific apps
    Key([mod], "n",              lazy.spawn("firefox")),
    Key([mod], "Return",         lazy.spawn("terminator")),

    # Change the volume if your keyboard has special volume keys.
    Key(
        [], "XF86AudioRaiseVolume",
        lazy.spawn("amixer -c 0 -q set Master 2dB+")
    ),
コード例 #13
0
ファイル: config.py プロジェクト: imiric/dotfiles
groupbox_defaults.update(widget_defaults)

keys = [
    Key([mod], "w", lazy.window.kill()),
    Key([mod], "r", lazy.spawncmd()),

    # App launchers
    Key([mod], "Return", lazy.spawn("urxvtc")),
    Key([mod], "e", lazy.spawn('pcmanfm')),

    # windows style alt-tab/alt-shift-tab
    Key([alt], "Tab", lazy.layout.down()),
    Key([alt, "shift"], "Tab", lazy.layout.up()),

    # Layouts
    Key([alt], "space", lazy.nextlayout()),
    Key([alt], "Return", lazy.window.toggle_floating()),

    # Bindings for Stack layout
    Key( [alt, "shift"], "space", lazy.layout.rotate()),
    Key( [alt, "shift"], "Return", lazy.layout.toggle_split()),

    # Bindings for MonadTall layout
    Key([alt, "shift"], "k", lazy.layout.shuffle_down()),
    Key([alt, "shift"], "j", lazy.layout.shuffle_up()),
    Key([alt], "i", lazy.layout.grow()),
    Key([alt], "m", lazy.layout.shrink()),
    Key([alt], "n", lazy.layout.normalize()),
    Key([alt], "o", lazy.layout.maximize()),
    Key([alt, "shift"], "space", lazy.layout.flip()),
コード例 #14
0
ファイル: config.py プロジェクト: vkochan/configs
# The keys variable contains a list of all of the keybindings that qtile will
# look through each time there is a key pressed.
keys = [
    # Log out; note that this doesn't use mod4: that's intentional in case mod4
    # gets hosed (which happens if you unplug and replug your usb keyboard
    # sometimes, or on system upgrades). This way you can still log back out
    # and in gracefully.
    Key(["shift", "mod1"], "q", lazy.shutdown()),
    Key([mod], "k", lazy.layout.down()),
    Key([mod], "j", lazy.layout.up()),
    Key([mod], "h", lazy.layout.previous()),
    Key([mod], "l", lazy.layout.previous()),
    Key([mod, "shift"], "space", lazy.layout.rotate()),
    Key([mod, "shift"], "Return", lazy.layout.toggle_split()),
    Key([alt], "Tab", lazy.nextlayout()),
    Key([mod], "x", lazy.window.kill()),

    # interact with prompts
    Key([mod], "r", lazy.spawncmd()),
    Key([mod], "g", lazy.switchgroup()),

    # start specific apps
    Key([mod], "n", lazy.spawn("firefox")),
    Key([mod], "Return", lazy.spawn("terminator")),

    # Change the volume if your keyboard has special volume keys.
    Key([], "XF86AudioRaiseVolume",
        lazy.spawn("amixer -c 0 -q set Master 2dB+")),
    Key([], "XF86AudioLowerVolume",
        lazy.spawn("amixer -c 0 -q set Master 2dB-")),
コード例 #15
0
    Key(["control", ALT], "t", lazy.spawn(Commands.terminal)),

    # Switch between windows in current stack pane
    Key([ALT], "Tab", lazy.layout.next()),
    Key([ALT, "shift"], "Tab", lazy.layout.previous()),

    # Move windows up or down in current stack
    Key([MOD], "Tab", lazy.layout.shuffle_down()),
    Key([MOD, "shift"], "Tab", lazy.layout.shuffle_up()),

    # multiple stack panes
    Key([MOD, "shift"], "Return", lazy.layout.toggle_split()),
    Key([MOD], "Return", lazy.spawn(Commands.terminal)),

    # Toggle between different layouts as defined below
    Key([MOD], "space", lazy.nextlayout()),
    Key([ALT], "F4", lazy.window.kill()),

    # Key([MOD, "control"], "r", lazy.restart()),
    # Key([MOD, "control"], "q", lazy.shutdown()),
    # Key([MOD], "r", lazy.spawncmd()),

    # BRIGHTNESS
    Key([], "XF86MonBrightnessUp", lazy.spawn(Commands.brightness_up)),
    Key([], "XF86MonBrightnessDown",lazy.spawn(Commands.brightness_down)),

    # VOLUME
    Key([], "XF86AudioRaiseVolume", lazy.spawn(Commands.volume_up)),
    Key([], "XF86AudioLowerVolume", lazy.spawn(Commands.volume_down)),
    Key([], "XF86AudioMute", lazy.spawn(Commands.volume_toggle_mute))
]
コード例 #16
0
ファイル: config.py プロジェクト: terrence2/dotfiles
    Key(
        [], "XF86AudioLowerVolume",
        lazy.spawn("amixer -q set Master 2- unmute")
    ),
    Key(
        [], "XF86AudioRaiseVolume",
        lazy.spawn("amixer -q set Master 2+ unmute")
    ),
    Key(
        [], "XF86AudioMute",
        lazy.spawn("amixer -q set Master toggle")
    ),
    Key([MOD], "h",      lazy.to_screen(1)),
    Key([MOD], "l",      lazy.to_screen(0)),
    Key([MOD], "Return", lazy.spawn("gnome-terminal")),
    Key([MOD], "n",      lazy.nextlayout()),
    Key([MOD], "b",      lazy.prevlayout()),
    Key([MOD], "k",      lazy.window.kill()),

    Key([CTRL, ALT], "r", lazy.restart()),
]

groups = [Group(c) for c in "123456qwert7890"]
for i in groups:
    keys.append(
        Key([MOD], i.name, lazy.group[i.name].toscreen())
    )
    keys.append(
        Key([MOD, "shift"], i.name, lazy.window.togroup(i.name))
    )
コード例 #17
0
ファイル: config.py プロジェクト: ingsme/dotfiles
#!/bin/env python
# coding: utf-8

from libqtile.command import lazy
from libqtile import layout, bar, widget, hook
try:
    from libqtile.manager import Key, Group
except ImportError:
    from libqtile.manager import Key, Group
from libqtile.manager import Click, Drag, Screen

sup = "mod4"
alt = "mod1"
ctrl = "mod3"

keys = [
#    Key([sup], "Return", lazy.spawn("urxvt -ls +sb -bg black -fg white")),
    Key([sup], "Return", lazy.spawn("gnome-termial")),
    Key([sup], "Space", lazy.nextlayout()),
]

mouse = [
    Click("Button1", lazy.window.bring_to_front()),
    Drag([sup], "Button1", lazy.window.set_position_floating(),
        start=lazy.window.get_position()),
    Drag([sup], "Button3", lazy.window.set_size_floating(),
        start=lazy.window.get_size()),
]


コード例 #18
0
ファイル: config.py プロジェクト: vslinko/home
import subprocess
import os

from libqtile import layout, bar, widget, hook
from libqtile.command import lazy
from libqtile.config import Key, Group, Match, Screen


keys = [
    Key(['mod4', 'control'], 'w', lazy.shutdown()),
    Key(['mod4', 'control'], 'r', lazy.restart()),

    Key(['mod4'], 'Right', lazy.screen.nextgroup()),
    Key(['mod4'], 'Left', lazy.screen.prevgroup()),

    Key(['mod4'], 'apostrophe', lazy.nextlayout()),

    Key(['mod4'], 'Tab', lazy.layout.next()),
    Key(['mod4'], 'Down', lazy.layout.down()),
    Key(['mod4'], 'Up', lazy.layout.up()),

    Key(['mod4'], 'bracketleft', lazy.layout.normalize()),
    Key(['mod4'], 'bracketright', lazy.layout.maximize()),

    Key(['mod4'], 'equal', lazy.layout.grow()),
    Key(['mod4'], 'minus', lazy.layout.shrink()),

    Key(['mod4'], 'w', lazy.window.kill()),
    Key(['mod4'], 'r', lazy.spawncmd()),
    Key(['mod4'], 'Return', lazy.spawn('lxterminal')),
    Key(['mod4', 'shift'], 'c', lazy.spawn('google-chrome-stable')),
コード例 #19
0
from libqtile.manager import Key, Screen, Group, Click, Drag
from libqtile.command import lazy
from libqtile.layout.base import Layout
from libqtile import layout, bar, widget, hook
from libqtile.layout.xmonad import MonadTall

modkey = "mod4"

keys = [
    # application shortcuts
    Key([modkey, "shift"], "p", lazy.spawn("gmrun &")),
    Key([modkey, "shift"], "Return", lazy.spawn("gnome-terminal")),

    # high-level management
    Key([modkey], "space", lazy.nextlayout()), # cycle layouts
    Key([modkey], "t", lazy.window.disable_floating()), # embed float
    Key([modkey, "shift"], "t", lazy.window.enable_floating()), # pop tile
    Key([modkey, "shift"], "q", lazy.window.kill()), # kill window
    Key([modkey, "shift"], "r", lazy.restart()), # restart qtile
    Key([modkey, "shift"], "l", lazy.shutdown()), # kill qtile

    # layout controls
    Key([modkey], "k", lazy.layout.down()), # focus left
    Key([modkey], "j", lazy.layout.up()), # focus right
    Key([modkey, "shift"], "k", lazy.layout.shuffle_down()), # move tile left
    Key([modkey, "shift"], "j", lazy.layout.shuffle_up()), # move tile right
    Key([modkey], "i", lazy.layout.grow()), # increase tile size
    Key([modkey], "m", lazy.layout.shrink()), # decrease tile size
    Key([modkey], "n", lazy.layout.normalize()), # equalize tiles
    Key([modkey], "o", lazy.layout.maximize()), # maximize tile
    Key([modkey, "shift"], "space", lazy.layout.flip()), # flip orientation
コード例 #20
0
ファイル: config.py プロジェクト: dequis/dotfiles
    Key([mod], "x", lazy.spawn("sleep 0.1; tmux neww \"sh -c 'xprop; read'\"")),
    Key([mod, "shift"], "x", lazy.spawn("sleep 0.1; tmux neww \"sh -c 'xwininfo; read'\"")),
    Key([mod, "shift"], "s", lazy.spawn("sleep 0.1; scr -s")),
    Key([mod], "bracketleft", lazy.spawn("bfg-set-intensity -1")),
    Key([mod], "bracketright", lazy.spawn("bfg-set-intensity +1")),

    Key([mod], "r", lazy.spawncmd("Run:")),
    Key([mod, "shift"], "r", lazy.spawncmd("Runeval:", command="qtinfo $(%s)")),
    Key([mod], "g", lazy.togroup()),

    Key([mod], "Left", lazy.screen.prevgroup()),
    Key([mod], "Right", lazy.screen.nextgroup()),
    Key([mod], "space", lazy.window.toggle_floating()),
    Key([mod], "m", lazy.window.toggle_minimize()),

    Key([mod, "control"], "Tab", lazy.nextlayout()),
    Key([mod, "control"], "w", lazy.window.kill()),
    Key([mod, "control"], "r", lazy.restart()),
    Key([mod, "control"], "a", lazy.execute("/usr/bin/awesome", ("awesome",))),
]

mouse = [
    Drag([mod], "Button1", lazy.window.set_position_floating(),
        start=lazy.window.get_position()),
    Drag([mod], "Button3", lazy.window.set_size_floating(),
        start=lazy.window.get_size()),
]


## layouts
コード例 #21
0
ファイル: config.py プロジェクト: sux2mfgj/qtile.org
    # Layout modification
    Key([mod, 'control'], 'space', lazy.window.toggle_floating()),

    # Switch between windows in current stack pane
    Key([mod], 'k', lazy.layout.down()),
    Key([mod], 'j', lazy.layout.up()),

    # Move windows up or down in current stack
    Key([mod, 'control'], 'k', lazy.layout.shuffle_down()),
    Key([mod, 'control'], 'j', lazy.layout.shuffle_up()),

    # Switch window focus to other pane(s) of stack
    Key([mod], 'space', lazy.layout.next()),

    # Toggle between different layouts as defined below
    Key([mod], 'Tab',    lazy.nextlayout()),
]

# Mouse bindings and options
mouse = (
    Drag([mod], 'Button1', lazy.window.set_position_floating(),
        start=lazy.window.get_position()),
    Drag([mod], 'Button3', lazy.window.set_size_floating(),
        start=lazy.window.get_size()),
)

bring_front_click = True
cursor_warp = False
follow_mouse_focus = True

# Groups
コード例 #22
0
ファイル: qtile-config.py プロジェクト: ottoyiu/dotfiles-old
    Key([MOD], 'r', lazy.spawncmd(prompt=':')),

    ## Layout, group, and screen modifiers
    Key([MOD], 'k', lazy.layout.up()),
    Key([MOD], 'j', lazy.layout.down()),
    #Key([MOD, 'shift'], 'j', lazy.layout.shuffle_up()),
    #Key([MOD, 'shift'], 'k', lazy.layout.shuffle_down()),
    #Key([MOD, 'shift'], 'g', lazy.layout.grow()),
    #Key([MOD, 'shift'], 's', lazy.layout.shrink()),
    #Key([MOD, 'shift'], 'n', lazy.layout.normalize()),
    #Key([MOD, 'shift'], 'm', lazy.layout.maximize()),
    #Key([MOD, 'shift'], 'space', lazy.layout.flip()),

    Key([MOD], 'h', lazy.layout.previous()),
    Key([MOD], 'l', lazy.layout.next()),
    Key([ALT], 'Tab', lazy.nextlayout()),

    #Key([MOD, 'shift'], 'space', lazy.layout.rotate()),
    #Key([MOD, 'shift'], 'Return', lazy.layout.toggle_split()),

    #Key([MOD], 'h', lazy.to_screen(1)), # left
    #Key([MOD], 'l', lazy.to_screen(0)), # right

    Key([MOD, 'control'], 'l', lazy.spawn('xscreensaver-command -lock')),
]

group_setup = (
    ('main', {}),
    ('dev', {
        'layout': 'max',
        'apps': {'wm_class': ('Komodo Edit',)},
コード例 #23
0
ファイル: config.py プロジェクト: Dnida/Qtile-Config
     Key([alt], 'Right', lazy.screen.nextgroup()),
# Layout modification
     Key([alt, 'control'], 'space', lazy.window.toggle_floating()),
# Switch between windows in current stack pane
     Key([alt], "k", lazy.layout.down()),
     Key([alt], "j", lazy.layout.up()),
     Key([alt, "shift"], "k", lazy.layout.shuffle_down()),
     Key([alt, "shift"], "j", lazy.layout.shuffle_up()),
     Key([alt], "i", lazy.layout.grow()),
     Key([alt], "m", lazy.layout.shrink()),
     Key([alt], "n", lazy.layout.normalize()),  
     Key([alt], "o", lazy.layout.maximize()),
     Key([alt, "shift"], "space", lazy.layout.flip()),
     Key([alt], 'space', lazy.layout.next()),
# Toggle between different layouts as defined below
     Key([alt], 'Tab', lazy.nextlayout())
]

mouse = [
    Drag([alt], "Button1", lazy.window.set_position_floating(),
        start=lazy.window.get_position()),
    Drag([alt], "Button3", lazy.window.set_size_floating(),
        start=lazy.window.get_size()),
    Click([alt], "Button2", lazy.window.bring_to_front())
]

# Next, we specify group names, and use the group position to generate
# a key binding for it.

groups = [
     Group('home'),
コード例 #24
0
ファイル: roger-config.py プロジェクト: mikkeloscar/qtile
keys = [
    Key(
        [mod], "k",
        lazy.layout.down()
    ),
    Key(
        [mod], "j",
        lazy.layout.up()
    ),
    Key(
        [mod], "f",
        lazy.window.toggle_floating()
    ),
    Key(
        [mod], "space",
        lazy.nextlayout()
    ),
    Key([mod], "Tab",
        lazy.layout.next()
    ),
    Key([mod, "shift"], "Tab",
        lazy.layout.previous()
    ),
    Key(
        [mod, "shift"], "space",
        lazy.layout.rotate()
    ),
    Key(
        [mod, "shift"], "Return",
        lazy.layout.toggle_split()
    ),
コード例 #25
0
ファイル: cortesi-config.py プロジェクト: AdamG/qtile
    ),
    Key(
        ["mod1", "shift"], "space",
        lazy.layout.rotate()
    ),
    Key(
        ["mod1", "shift"], "Return",
        lazy.layout.toggle_split()
    ),

    Key(["mod1"], "n",      lazy.spawn("firefox")),
    Key(["mod1"], "h",      lazy.to_screen(1)),
    Key(["mod1"], "l",      lazy.to_screen(0)),
    # ~/bin/x starts a terminal program
    Key(["mod1"], "Return", lazy.spawn("~/bin/x")),
    Key(["mod1"], "Tab",    lazy.nextlayout()),
    Key(["mod1"], "w",      lazy.window.kill()),

    # The bindings below control Amarok, and my sound volume.
    Key(
        ["mod1", "shift"], "k",
        lazy.spawn("amixer -c 1 -q set Speaker 2dB+")
    ),
    Key(
        ["mod1", "shift"], "j",
        lazy.spawn("amixer -c 1 -q set Speaker 2dB-")
    ),
    Key(
        ["mod1", "shift"], "n",
        lazy.spawn("amarok -t")
    ),
コード例 #26
0
ファイル: config.py プロジェクト: meeh420/qtile-examples
    Key(["shift", "mod1"], "q", lazy.shutdown()),

    # toggle between windows just like in unity with 'alt+tab'
    Key(["mod1","shift"], "Tab", lazy.layout.down()),
    Key(["mod1"], "Tab", lazy.layout.up()),
    
    Key([mod], "h", lazy.layout.previous().when('tile'),lazy.layout.up().when('xmonad-tall')),
    Key([mod], "l", lazy.layout.previous()),

    # swap tile positions,(works only on tiles)
    Key([mod, "shift"], "space", lazy.layout.rotate()),
    
    Key([mod, "shift"], "Return",lazy.layout.toggle_split()),

    # change the layout
    Key([mod], "j", lazy.nextlayout()),

    # quit the program "qtile way"
    Key([mod], "x", lazy.window.kill()),

    # move to the adjacent screen
    Key([mod], "Left", lazy.group.prevgroup()),
    Key([mod], "Right", lazy.group.nextgroup()),
    
    # interact with prompts
    Key([mod], "r", lazy.spawncmd()),
    Key([mod], "g", lazy.switchgroup()),

    # start specific apps
    Key([mod], "e", lazy.spawn("python ~/.config/qtile/checkmail.py")),
    
コード例 #27
0
ファイル: config.py プロジェクト: dmpayton/dotfiles
    #Key([mod], 'j', lazy.layout.up()),
    #Key([mod], 'k', lazy.layout.down()),
    #Key([mod, 'shift'], 'j', lazy.layout.shuffle_up()),
    #Key([mod, 'shift'], 'k', lazy.layout.shuffle_down()),
    #Key([mod, 'shift'], 'g', lazy.layout.grow()),
    #Key([mod, 'shift'], 's', lazy.layout.shrink()),
    #Key([mod, 'shift'], 'n', lazy.layout.normalize()),
    #Key([mod, 'shift'], 'm', lazy.layout.maximize()),
    #Key([mod, 'shift'], 'space', lazy.layout.flip()),

    # Switch groups
    Key([mod], 'Left', lazy.screen.prevgroup()),
    Key([mod], 'Right', lazy.screen.nextgroup()),

    # Cycle layouts
    Key([mod], 'Up', lazy.nextlayout()),
    Key([mod], 'Down', lazy.prevlayout()),

    # Change window focus
    Key([mod], 'Tab', lazy.layout.next()),
    Key([mod, 'shift'], 'Tab', lazy.layout.previous()),

    # Switch focus to other screens
    Key([mod], 'h', lazy.to_screen(0)),  # left
    Key([mod], 'l', lazy.to_screen(1)),  # right

    # Commands: Application Launchers
    Key([mod], 'space', lazy.spawn(Commands.dmenu)),
    Key([mod], 'n', lazy.spawn(Commands.browser)),
    Key([mod], 'e', lazy.spawn(Commands.file_manager)),
    Key([mod], 'Return', lazy.spawn(Commands.terminal)),
コード例 #28
0

##########################################################################################
# KEYBINDINGS
##########################################################################################

keys = [
    Key(["mod1"], "k", lazy.layout.down()),
    Key(["mod1"], "j", lazy.layout.up()),
    Key(["mod1", "control"], "k", lazy.layout.shuffle_down()),
    Key(["mod1", "control"], "j", lazy.layout.shuffle_up()),
    Key(["mod1"], "space", lazy.layout.next()),
    Key(["mod1", "shift"], "space", lazy.layout.rotate()),
    Key(["mod1", "shift"], "Return", lazy.layout.toggle_split()),
    Key(["mod1"], "Return", lazy.spawn("urxvt -tr +sb -fg white -sh 30")),
    Key(["mod1"], "Tab", lazy.nextlayout()),
    Key(["mod1"], "w", lazy.window.kill()),
    Key(["mod1", "control"], "r", lazy.restart()),
    Key(["mod4"], "f", lazy.spawn("firefox")),
    Key(["mod4"], "d", lazy.spawn("deluge")),
]

for i in groups:
    keys.append(Key(["mod1"], i.name, lazy.group[i.name].toscreen()))
    keys.append(Key(["mod1", "shift"], i.name, lazy.window.togroup(i.name)))

keys.append(Key(["mod1"], "Left", lazy.group.prevgroup()))
keys.append(Key(["mod1"], "Right", lazy.group.nextgroup()))
keys.append(Key(["mod1", "shift"], "Left", lazy.function(toPrevGroup)))
keys.append(Key(["mod1", "shift"], "Right", lazy.function(toNextGroup)))
コード例 #29
0
    Key([sup], "p", lazy.spawn("pidgin")),
    Key([sup], "d", lazy.spawn("setxkbmap -layout es -variant dvorak")),
    Key([sup], "q", lazy.spawn("setxkbmap -layout latan")),
    Key([sup], "w", lazy.window.kill()),
    Key([], "XF86AudioRaiseVolume",
        lazy.spawn("amixer -c 0 -q set Master 2dB+")),
    Key([], "XF86AudioLowerVolume",
        lazy.spawn("amixer -c 0 -q set Master 2dB-")),
    Key([sup, "control"], "r", lazy.restart()),
    # cycle to previous group
    Key([sup], "Left", lazy.group.prevgroup()),
    # cycle to next group
    Key([sup], "Right", lazy.group.nextgroup()),

    # windows style alt-tab/alt-shift-tab
    Key([sup], "Tab", lazy.nextlayout()),
    Key([sup, "shift"], "Tab", lazy.previouslayout()),
    # PRINT SCREEN
    Key([sup], "F10", lazy.spawn("import -window root ~/screenshot.png")),
    Key([alt], "t", lazy.window.toggle_floating()),
]

groups = [
    Group("1"),
    Group("2"),
    Group("3"),
    Group("4"),
    Group("5"),
    Group("6"),
    Group("7"),
    Group("8"),
コード例 #30
0
ファイル: matt.py プロジェクト: mattharrison/qtile_config
    #     [MOD, "shift"], "space",
    #     lazy.layout.rotate()
    # ),
    Key(
        [MOD, "shift"], "Return",
        lazy.layout.toggle_split()
    ),

    Key([MOD], "n",      lazy.spawn("firefox")),
    Key([MOD], "h",      lazy.to_screen(1)),
    Key([MOD], "l",      lazy.to_screen(0)),
    # ~/bin/x starts a terminal program
    #Key([MOD], "Return", lazy.spawn("~/bin/x")),
    Key([MOD], "Return", lazy.spawn("terminator -p tango")),
    #Key([MOD], "Tab",    lazy.nextlayout()),
    Key([MOD], "space",    lazy.nextlayout()),
    Key([MOD, 'shift'], "space",    lazy.prevlayout()),
    Key([MOD], "Tab",    lazy.group.next_window()),
    Key([MOD, 'shift'], "Tab",    lazy.group.prev_window()),
    Key([MOD, 'shift'], "c",      lazy.window.kill()),
    Key([MOD], "f",      lazy.window.toggle_floating()),
    Key([MOD], "m",      lazy.window.toggle_minimize()),
    Key([MOD], "x",      lazy.window.toggle_maximize()),
    Key([MOD], "u",      lazy.window.toggle_fullscreen()),
    #Key([MOD], "[",   lazy.window.move_floating(-10,0)),
    #Key([MOD], "]",   lazy.window.move_floating(10,0)),
    Key([MOD, 'shift'], "r",      lazy.restart()),
    Key([MOD], "p",      lazy.spawncmd()),
    #Key([MOD, 'shift'], "Down", lazy.window.down_opacity()),
    Key([MOD], "z", lazy.window.down_opacity()),
    Key([MOD], "downarrow", lazy.window.down_opacity()),
コード例 #31
0
ファイル: config.py プロジェクト: airwoodix/qtile-config
class command:
    terminal = get_alternatives(['terminator', 'gnome-terminal', 'xterm'])
    autostart = os.path.join(os.path.dirname(__file__), 'bin/autostart')
    lock = os.path.join(os.path.dirname(__file__), 'bin/lock')
    suspend = os.path.join(os.path.dirname(__file__), 'bin/suspend')
    hibernate = os.path.join(os.path.dirname(__file__), 'bin/hibernate')


# Key bindings
keys = [
    # Window manager controls
    Key([MODKEY, CTRL], 'r', lazy.restart()),
    Key([MODKEY, CTRL], 'q', lazy.shutdown()),
    Key([MODKEY, SHIFT], SPACE, lazy.layout.flip()),
    Key([MODKEY], RETURN, lazy.spawn(command.terminal)),
    Key([MODKEY], SPACE, lazy.nextlayout()),
    Key([MODKEY], 'q', lazy.window.kill()),
    Key([MODKEY], 'p', lazy.spawncmd()),
    Key([MODKEY], 't', lazy.window.toggle_floating()),
    Key([MODKEY], 'f', lazy.window.toggle_fullscreen()),

    # Move Focus
    Key([MODKEY], TAB, lazy.layout.next()),
    Key([MODKEY, SHIFT], TAB, lazy.layout.previous()),
    Key([MODKEY], 'h', lazy.layout.left()),
    Key([MODKEY], 'j', lazy.layout.down()),
    Key([MODKEY], 'k', lazy.layout.up()),
    Key([MODKEY], 'l', lazy.layout.right()),
    Key([MODKEY], 'w', lazy.prev_screen()),
    Key([MODKEY], 'e', lazy.next_screen()),
    Key([WIN], '1', lazy.to_screen(0)),
コード例 #32
0
ファイル: config.py プロジェクト: T0MASD/qtile-config
    Key([mod, "shift"], "p", lazy.pause()),
    Key([mod, "shift"], "space", lazy.layout.rotate()),
    Key([mod], "Left", lazy.group.prevgroup()),
    Key([mod], "Right", lazy.group.nextgroup()),
    Key([mod], "Up", lazy.to_next_screen()),
    Key([mod], "Down", lazy.to_prev_screen()),
    Key([mod], "Tab", lazy.layout.next()),
    Key([mod], "f", lazy.window.toggle_floating()),
    Key([mod], "g", lazy.togroup()),
    Key([mod], "r", lazy.spawncmd()),
    Key([mod], "j", lazy.layout.up()),
    Key([mod], "k", lazy.layout.down()),
    Key([mod], "q", lazy.restart()),
    Key([mod], "l", lazy.spawn(
        'alock -auth pam -bg image:center,file=' + image)),
    Key([mod], "space", lazy.nextlayout()),
    Key([mod], "Return", lazy.spawn('urxvt')),
    Key([mod], "w", lazy.window.kill()),
    Key([mod], "BackSpace", lazy.spawn(
        "dmenu_run -i -b -fn 'monofur:pixelsize=16:antialias=true'"
        " -p 'Run' -nf '#ffffff' -nb '#202020'")),
    Key([mod], "XF86AudioPlay", lazy.spawn(mpc + 'toggle')),
    Key([mod], "XF86AudioPrev", lazy.spawn(mpc + 'prev')),
    Key([mod], "XF86AudioNext", lazy.spawn(mpc + 'next')),
    Key([mod], "XF86AudioStop", lazy.spawn(mpc + 'stop')),
    Key([mod], "XF86AudioLowerVolume", lazy.spawn(mpc + 'volume -2')),
    Key([mod], "XF86AudioRaiseVolume", lazy.spawn(mpc + 'volume +2')),
]

mouse = [
    Drag([mod], "Button1", lazy.window.set_position_floating(),
コード例 #33
0
ファイル: config.py プロジェクト: Forkk/olddotfiles
for upkey, downkey in stack_switch_keys:
    keys.append(Key([mod], upkey, lazy.layout.up()))
    keys.append(Key([mod], downkey, lazy.layout.down()))
    for mod2 in [ctrl, alt, shift]:
        keys.append(Key([mod, mod2], upkey, lazy.layout.shuffle_up()))
        keys.append(Key([mod, mod2], downkey, lazy.layout.shuffle_down()))


# Switch between layouts.
layout_switch_keys = [
        # Super + the two keys on both sides of the bottom row of the keyboard to switch windows.
        ("period", "slash"),
        ("z", "x"),
]
for upkey, downkey in layout_switch_keys:
    keys.append(Key([mod], upkey, lazy.nextlayout()))
    keys.append(Key([mod], downkey, lazy.prevlayout()))


# Switch between screens.
screen_switch_keys = [
        # Super + the two keys on both sides of the middle row of the keyboard to switch windows.
        ("semicolon", "apostrophe"),
        ("s", "d"),
]

for firstkey, secondkey in screen_switch_keys:
    keys.append(Key([mod], firstkey, lazy.to_screen(0)))
    keys.append(Key([mod], secondkey, lazy.to_screen(1)))

コード例 #34
0
ファイル: config.py プロジェクト: valenca/dotfiles
    # Switch window focus to other pane(s) of stack
    #Key([sup], "space",lazy.layout.next()),

    # Swap panes of split stack
    #Key([sup, "shift"], "space",lazy.layout.rotate()),

    # Toggle between split and unsplit sides of stack.
    # Split = all windows displayed
    # Unsplit = 1 window displayed, like Max layout, but still with
    # multiple stack panes
    Key([sup, "shift"], "Return",
        lazy.layout.toggle_split()
    ),

    # Toggle between different layouts as defined below
    Key([sup], "Tab", lazy.nextlayout()),
    Key([sup], "w", lazy.window.kill()),

    Key([sup, "control"], "r", lazy.restart()),
    Key([sup, "control"], "q", lazy.shutdown()),

    #Key([alt], "F2", lazy.spawncmd("")),
    Key([alt], "F4", lazy.window.kill()),

	Key([sup],"t",lazy.spawn("urxvt")),
	Key([sup],"f",lazy.spawn("chromium")),
	Key([sup],"e",lazy.spawn("emacs")),
	Key([sup],"m",lazy.spawn("urxvt -name mocp -background black -foreground white -e mocp")),

	Key([],"F2",lazy.spawn("xbacklight -dec 10")),
	Key([],"F3",lazy.spawn("xbacklight -inc 10")),
コード例 #35
0
ファイル: config.py プロジェクト: fscherf/qtile-config
class command:
    terminal = get_alternatives(['terminator', 'gnome-terminal', 'xterm'])
    autostart = os.path.join(os.path.dirname(__file__), 'bin/autostart')
    lock = os.path.join(os.path.dirname(__file__), 'bin/lock')
    suspend = os.path.join(os.path.dirname(__file__), 'bin/suspend')
    hibernate = os.path.join(os.path.dirname(__file__), 'bin/hibernate')

# Key bindings
keys = [
    # Window manager controls
    Key([MODKEY, CTRL], 'r', lazy.restart()),
    Key([MODKEY, CTRL], 'q', lazy.shutdown()),
    Key([MODKEY, SHIFT], SPACE, lazy.layout.flip()),
    Key([MODKEY], RETURN, lazy.spawn(command.terminal)),
    Key([MODKEY], SPACE, lazy.nextlayout()),
    Key([MODKEY], 'q', lazy.window.kill()),
    Key([MODKEY], 'p', lazy.spawncmd()),
    Key([MODKEY], 't', lazy.window.toggle_floating()),
    Key([MODKEY], 'f', lazy.window.toggle_fullscreen()),

    # Move Focus
    Key([MODKEY], TAB, lazy.layout.next()),
    Key([MODKEY, SHIFT], TAB, lazy.layout.previous()),
    Key([MODKEY], 'h', lazy.layout.left()),
    Key([MODKEY], 'j', lazy.layout.down()),
    Key([MODKEY], 'k', lazy.layout.up()),
    Key([MODKEY], 'l', lazy.layout.right()),
    Key([MODKEY], 'w', lazy.prev_screen()),
    Key([MODKEY], 'e', lazy.next_screen()),
    Key([WIN], '1', lazy.to_screen(0)),
コード例 #36
0
from libqtile import layout, bar, widget, hook
try:
    from libqtile.manager import Key, Group, Click, Drag, Screen
except ImportError:
    from libqtile.config import Key, Group, Click, Drag, Screen

sup = "mod4"
alt = "mod1"

keys = [
# SWAP MASTER WINDOWS AROUND
    Key([alt], "n", lazy.layout.down()),
    Key([alt], "m", lazy.layout.up()),
# LAYOUT CHANGERS
    # move to next layout in the stack
    Key([alt], "space", lazy.nextlayout()),
    # switch master windows
    Key([alt, "shift"], "space", lazy.layout.rotate()),

# MOVEMENT KEYS
    # windows style alt-tab/alt-shift-tab
    Key([alt], "Tab", lazy.layout.next()),
    Key([alt, "shift"], "Tab", lazy.layout.previous()),

    # kill current window
    Key([alt, "shift"], "c", lazy.window.kill()),

    # dec ratio of current window
    Key([alt], "q", lazy.layout.decrease_ratio()),

    # inc ratio of current window
コード例 #37
0
ファイル: config.py プロジェクト: jtimon/config
        lazy.layout.rotate()
    ),

    # Toggle between split and unsplit sides of stack.
    # Split = all windows displayed
    # Unsplit = 1 window displayed, like Max layout, but still with multiple stack panes
    Key(
        [super_key, shift_key], "Return",
        lazy.layout.toggle_split()
    ),
    Key([super_key], "h",      lazy.to_screen(1)),
    Key([super_key], "l",      lazy.to_screen(0)),
    Key([super_key], "Return", lazy.spawn("xterm")),

    # Toggle between different layouts as defined below
    Key([super_key], "Tab",    lazy.nextlayout()),
    Key([super_key, shift_key], "q", lazy.window.kill()),

    Key([super_key, control_key], "r", lazy.restart()),
]

groups = [
    Group("1"),
    Group("2"),
    Group("3"),
    Group("4"),
    Group("5"),
    # Group("6"),
    # Group("7"),
    # Group("8"),
    # Group("9"),