class TileConfig: main = None groups = [ libqtile.manager.Group("a"), libqtile.manager.Group("b"), libqtile.manager.Group("c"), libqtile.manager.Group("d") ] layouts = [layout.Tile(), layout.Tile(masterWindows=2)] floating_layout = libqtile.layout.floating.Floating() keys = [] mouse = [] screens = [] follow_mouse_focus = False
class TileConfig(Config): auto_fullscreen = True groups = [ libqtile.config.Group("a"), libqtile.config.Group("b"), libqtile.config.Group("c"), libqtile.config.Group("d") ] layouts = [layout.Tile(), layout.Tile(masterWindows=2)] floating_layout = libqtile.layout.floating.Floating() keys = [] mouse = [] screens = [] follow_mouse_focus = False
class TileConfig(Config): auto_fullscreen = True groups = [ libqtile.config.Group("a"), libqtile.config.Group("b"), libqtile.config.Group("c"), libqtile.config.Group("d") ] layouts = [layout.Tile(), layout.Tile(master_length=2)] floating_layout = libqtile.resources.default_config.floating_layout keys = [] mouse = [] screens = [] follow_mouse_focus = False
def init_layouts(): return [ layout.Max(**layout_theme), layout.MonadTall(**layout_theme), layout.MonadWide(**layout_theme), layout.Bsp(**layout_theme), #layout.TreeTab( # font = "Noto Sans ", # fontsize = 10, # sections = ["FIRST", "SECOND"], # section_fontsize = 11, # bg_color = "141414", # active_bg = "90C435", # active_fg = "000000", # inactive_bg = "384323", # inactive_fg = "a0a0a0", # padding_y = 5, # section_top = 10, # panel_width = 320, # **layout_theme # ), #layout.Stack(stacks=2, **layout_theme), #layout.Columns(**layout_theme), layout.RatioTile(**layout_theme), #layout.VerticalTile(**layout_theme), layout.Tile(shift_windows=True, **layout_theme), #layout.Matrix(**layout_theme), #layout.Zoomy(**layout_theme), layout.Floating(**layout_theme) ]
def init_layouts(): return [ layout.MonadTall(**layout_theme), layout.MonadWide(**layout_theme), layout.Max(**layout_theme), layout.Floating(**layout_theme), layout.Matrix(**layout_theme), layout.RatioTile(**layout_theme), layout.VerticalTile(**layout_theme), #layout.Bsp(**layout_theme), layout.TreeTab(font="Ubuntu", fontsize=10, sections=["FIRST", "SECOND"], section_fontsize=11, bg_color="141414", active_bg="90C435", active_fg="000000", inactive_bg="384323", inactive_fg="a0a0a0", padding_y=5, section_top=10, panel_width=320, **layout_theme), #layout.Slice(side="left", width=192, name="gimp", role="gimp-toolbox", # fallback=layout.Slice(side="right", width=256, role="gimp-dock", # fallback=layout.Stack(num_stacks=1, **border_args))), #layout.Stack(stacks=2, **layout_theme), #layout.Columns(**layout_theme), #layout.Zoomy(**layout_theme), layout.Tile(shift_windows=True, **layout_theme) ]
def init_layouts(num_screens): margin = 0 if num_screens > 1: margin = 8 layouts.extend([ layout.Tile(ratio=0.5, margin=margin, border_width=1, border_normal="#111111", border_focus=BLUE) ])
def init_layouts(): margin = 0 if len(qtile.conn.pseudoscreens) > 1: margin = 8 kwargs = dict(margin=margin, border_width=1, border_normal=DARK_GREY, border_focus=BLUE, border_focus_stack=ORANGE) layouts = [ layout.Max(), layout.Columns(border_on_single=True, num_columns=2, grow_amount=5, **kwargs) ] if DEBUG: layouts += [ floating_layout, layout.Zoomy(), layout.Tile(), layout.Matrix(), layout.TreeTab(), layout.MonadTall(margin=10), layout.RatioTile(), layout.Stack() ] return layouts
local_bin = os.path.expanduser("~") + "/.local/bin" if local_bin not in os.environ["PATH"]: os.environ["PATH"] = "{}:{}".format(local_bin, os.environ["PATH"]) mod = "mod4" browser = "google-chrome" terminal = "roxterm" screenlocker = "i3lock -d" hostname = socket.gethostname() cursor_warp = False keys = init_keys() mouse = init_mouse() groups = init_groups() floating_layout = init_floating_layout() layouts = [layout.Max()] screens = [Screen(top=init_top_bar())] widget_defaults = init_widgets_defaults() if DEBUG: layouts += [ floating_layout, layout.Zoomy(), layout.Tile(), layout.Matrix(), layout.TreeTab(), layout.MonadTall(margin=10), layout.RatioTile(), layout.Stack() ]
"border_normal": "1D2330" } ##### THE LAYOUTS ##### layouts = [ #layout.MonadWide(**layout_theme), #layout.Bsp(**layout_theme), #layout.Stack(stacks=2, **layout_theme), #layout.Columns(**layout_theme), #layout.RatioTile(**layout_theme), #layout.VerticalTile(**layout_theme), #layout.Matrix(**layout_theme), #layout.Zoomy(**layout_theme), layout.MonadTall(**layout_theme), layout.Max(**layout_theme), layout.Tile(shift_windows=True, **layout_theme), layout.Stack(num_stacks=2), layout.TreeTab(font="Ubuntu", fontsize=10, sections=["FIRST", "SECOND"], section_fontsize=11, bg_color="141414", active_bg="90C435", active_fg="000000", inactive_bg="384323", inactive_fg="a0a0a0", padding_y=5, section_top=10, panel_width=320), layout.Floating(**layout_theme) ]
from widgets import MyBattery mod = "mod1" groups = [Group(i) for i in "1234567890"] # groups += [ # ScratchPad("scratchpad", [ # # ]) # # ] keys = get_keys(groups) layouts = [ layout.Tile(ratio=0.5, border_width=2, add_after_last=True, border_focus=['#d75f5f', '#8f3d3d']), layout.Max(), # Try more layouts by unleashing below layouts. # layout.Columns(border_focus_stack=['#d75f5f', '#8f3d3d'], border_width=4), # layout.Stack(num_stacks=2), # layout.Bsp(), # layout.Matrix(), # layout.MonadTall(), # layout.MonadWide(), # layout.RatioTile(), # layout.TreeTab(), # layout.VerticalTile(), # layout.Zoomy(), ]
class FakeScreenConfig: auto_fullscreen = True main = None groups = [ libqtile.config.Group("a"), libqtile.config.Group("b"), libqtile.config.Group("c"), libqtile.config.Group("d") ] layouts = [ layout.Max(), layout.RatioTile(), layout.Tile(), ] floating_layout = libqtile.layout.floating.Floating() keys = [] mouse = [] fake_screens = [Screen( bottom=bar.Bar( [ widget.GroupBox(this_screen_border=CHAM3, borderwidth=1, fontsize=FONTSIZE, padding=1, margin_x=1, margin_y=1), widget.AGroupBox(), widget.Prompt(), widget.Sep(), widget.WindowName( fontsize=FONTSIZE, margin_x=6), widget.Sep(), widget.CPUGraph(**GRAPH_KW), widget.MemoryGraph(**GRAPH_KW), widget.SwapGraph(foreground='20C020', **GRAPH_KW), widget.Sep(), widget.Systray(), widget.Sep(), widget.Clock(format='%H:%M:%S %d.%m.%Y', fontsize=FONTSIZE, padding=6), ], 24, background="#555555" ), x=0, y=0, width=600, height=480 ), Screen( top=bar.Bar( [ widget.GroupBox(), widget.WindowName(), widget.Clock() ], 30, ), x=600, y=0, width=300, height=580 ), Screen( top=bar.Bar( [ widget.GroupBox(), widget.WindowName(), widget.Clock() ], 30, ), x=0, y=480, width=500, height=400), Screen( bottom=bar.Bar( [ widget.GroupBox(), widget.WindowName(), widget.Clock() ], 30, ), x=500, y=580, width=400, height=400), ] screens = fake_screens
Group("term"), Group("irc"), Group("web"), Group("development"), ] for index, grp in enumerate(groups): keys.extend([ Key([sup], grp.name[0], lazy.group[grp.name].toscreen()), Key([sup, "control"], grp.name[0], lazy.window.togroup(grp.name)), ]) layouts = [ layout.Max(), layout.Stack(num_stacks=2), layout.Tile(ratio=0.25), ] widget_defaults = dict( font='Arial', fontsize=16, padding=3, ) default_style = dict(fontsize=10, foreground="FF6600", background="1D1D1D", font="ttf-droid") screens = [ Screen(bottom=bar.Bar(
single_border_width=2, single_margin=20, ), layout.RatioTile( border_width=2, fancy=True, margin=([50, 10, 30, 10]), ratio=1.618, ratio_increment=0.1, ), layout.Tile( add_after_last=False, add_on_top=True, border_width=2, expand=True, margin=([50, 10, 30, 10]), master_length=1, master_match=None, ratio=0.618, ration_increment=0.05, shift_windows=False, ), #layout.TreeTab( # **layout_defaults, # padding_left = 40, # padding_x = 40, # padding_y = 40, # ), #layout.Tile( # margin = [40,30,60,30], # ),
########### # Imports # ########### import re from libqtile import layout from libqtile.config import Match ########### # Layouts # ########### layouts = [ layout.Columns(name="Col", border_focus_stack='#d75f5f', margin=10), layout.MonadTall(name="Tall", margin=5), layout.MonadWide(name="Wide", margin=5), layout.Tile(name="Tile", margin=5), layout.TreeTab(name="Tab", margin=5), ] floating_layout = layout.Floating(float_rules=[ # Run the utility of `xprop` to see the wm class and name of an X client. *layout.Floating.default_float_rules, Match(wm_class='confirmreset'), # gitk Match(wm_class='makebranch'), # gitk Match(wm_class='maketag'), # gitk Match(wm_class='ssh-askpass'), # ssh-askpass Match(title='branchdialog'), # gitk Match(title='pinentry'), # GPG key password entry Match(wm_class=re.compile('dialog-.*')), # Custom dialogs ])
cardid=1), widget.YahooWeather(location='Fresno, CA', **Widget.weather), widget.Clock(fmt='%a %d %b %I:%M %p'), ], **bar_defaults), ), Screen(top=bar.Bar(widgets=[ widget.GroupBox(**Widget.groupbox), widget.WindowName(), widget.CurrentLayout(), ], **bar_defaults), ) ] # Layouts layouts = ( layout.Tile(ratio=0.5, **layout_defaults), layout.Max(**layout_defaults), layout.RatioTile(**layout_defaults), layout.Matrix(**layout_defaults), layout.MonadTall(**layout_defaults), layout.Stack(**layout_defaults), layout.Zoomy(**layout_defaults), ) floating_layout = layout.floating.Floating( auto_float_types=( 'notification', 'toolbar', 'splash', 'dialog', ),
# take the current window to a specific screen keys.append( Key(["control", "mod1"], i, lazy.window.togroup(i)) ) # layout instances # I've not included 'Tile' and 'RatioTile', # they didn't appeal to me much. layouts = [ layout.Max(), #layout.Stack(stacks=2, border_width=1), layout.xmonad.MonadTall(ratio=0.50), # splits screen into equal parts # ideal for four splitted windows in each corner layout.Tile(ratio=0.50, masterWindows=2), # a layout just for gimp layout.Slice('left', 192, name='gimp', role='gimp-toolbox', fallback=layout.Slice('right', 256, role='gimp-dock', fallback=layout.Stack(stacks=1, border_width=1))), #other useful layouts #layout.TreeTab(), #layout.zoomy.Zoomy(), ] # Automatically float these types. This overrides the default behavior (which # is to also float utility types), but the default behavior breaks our fancy # gimp slice layout specified later on. floating_layout = layout.Floating(auto_float_types=[ "notification", "toolbar",
Group("l", label="l "), # Misc ] for i in groups: keys.extend([ # mod1 + letter of group = switch to group Key([mod], i.name, lazy.group[i.name].toscreen()), # mod1 + shift + letter of group = # switch to & move focused window to group Key([mod, "shift"], i.name, lazy.window.togroup(i.name)), ]) layouts = [ layout.Max(border_width=0), layout.Tile(border_width=0), layout.Floating(border_width=2), ] widget_defaults = dict( font='sans', fontsize=12, padding=3, ) extension_defaults = widget_defaults.copy() class CustomVolume(widget.PulseVolume): def _update_drawer(self): """The main Volume doesn't include a way to show both emoji and text, for some insane reason."""
colors = [ '#363636', # panel background '#434758', # background for current screen tab '#ffffff', # font color for group names '#ffbcbc', # border line color for current tab '#b7efcd' ] # border line color for other tab and odd widgets layout_theme = { "border_focus": colors[3], "margin": 2, "border_width": 3, } layouts = [ layout.Tile(add_after_last=True, add_on_top=False, **layout_theme), # I want this layout.Max(), layout.MonadTall(**layout_theme), # I want this layout.MonadWide(**layout_theme), # I want this layout.RatioTile(**layout_theme), # I want this layout.Matrix(**layout_theme), # I want this # layout.Stack(num_stacks=2), # layout.Bsp(), # layout.Columns(), # layout.TreeTab(), # layout.VerticalTile(), # layout.Zoomy(), ] widget_defaults = dict( font='DejaVu',
layout_theme = { "border_width": 1, "margin": 6, "border_focus": "#e78aba", "border_normal": "#032541", } layouts = [ # layout.Max(), # layout.Stack(), # Try more layouts by unleashing below layouts. # layout.Bsp(), # layout.MonadTall(), # layout.MonadWide(), # layout.RatioTile(), layout.Tile(ratio=.50, **layout_theme), # layout.TreeTab(), # layout.VerticalTile(), # layout.Zoomy(), ] ##### COLORS ##### # Sections are listed from left to right. A section is from the begining of one arrow in the bar to the begining of the next. colors = [ ["#032541", "#032541"], # panel background ["#0c6583", "#0c6583"], # fifth section ["#5a3b5d", "#5a3b5d"], # fourth section ["#86618d", "#86618d"], # third section ["#903350", "#903350"], # second section ["#e784ba", "#e78aba"], # first section ["#ffffff", "#ffffff"]
# mod1 + shift + letter of group = switch to & move focused window to group keys.append(Key([mod, "shift"], i.name, lazy.window.togroup(i.name))) fonts = {'font': 'Envy Code R', 'fontsize': 10} fontcolors = fonts.copy() borders = { 'border_normal': '#ffffff', 'border_focus': '#FFBF00', 'border_width': 2, 'margin': 1, } layouts = [ layout.Tile(ratio=0.33, **borders), layout.Max(), layout.RatioTile(**borders), layout.MonadTall(**borders), layout.Stack(num_stacks=2, **borders), layout.TreeTab(active_bg="#A59461", active_fg="#000000", inactive_bg="#000000", sections=['Files'], **fontcolors), # layout.Float(), ] widget_defaults = dict( font='Envy CodeR', fontsize=12,
desc="Switch to group {}".format(i.name)), Key([mod, "shift"], i.name, lazy.window.togroup(i.name, switch_group=False), desc="Switch to & move focused window to group {}".format(i.name)), ]) layout_theme = { "border_focus": "05FFB8", "border_normal": "038C65", "border_width": 3, "margin": 3, } layouts = [ layout.Tile(**layout_theme, add_after_last=True, ratio=0.60), layout.Max(), layout.Bsp( **layout_theme, ratio=1, fair=False, ), #layout.MonadTall( # **layout_theme, #), # layout.Stack(num_stacks=2), # layout.Columns(), # layout.Matrix(), # layout.MonadWide(), # layout.RatioTile(), # layout.TreeTab(),
class FakeScreenConfig(Config): auto_fullscreen = True groups = [ libqtile.config.Group("a"), libqtile.config.Group("b"), libqtile.config.Group("c"), libqtile.config.Group("d") ] layouts = [ layout.Max(), layout.RatioTile(), layout.Tile(), ] floating_layout = libqtile.resources.default_config.floating_layout keys = [] mouse = [] fake_screens = [ Screen(bottom=bar.Bar([ widget.GroupBox(this_screen_border=CHAM3, borderwidth=1, fontsize=FONTSIZE, padding=1, margin_x=1, margin_y=1), widget.AGroupBox(), widget.Prompt(), widget.Sep(), widget.WindowName(fontsize=FONTSIZE, margin_x=6), widget.Sep(), widget.CPUGraph(**GRAPH_KW), widget.MemoryGraph(**GRAPH_KW), widget.SwapGraph(foreground='20C020', **GRAPH_KW), widget.Sep(), widget.Clock(format='%H:%M:%S %d.%manager.%Y', fontsize=FONTSIZE, padding=6), ], 24, background="#555555"), left=bar.Gap(16), right=bar.Gap(20), x=0, y=0, width=500, height=340), Screen(top=bar.Bar( [widget.GroupBox(), widget.WindowName(), widget.Clock()], 30, ), bottom=bar.Gap(24), left=bar.Gap(12), x=500, y=0, width=300, height=380), Screen(top=bar.Bar( [widget.GroupBox(), widget.WindowName(), widget.Clock()], 30, ), bottom=bar.Gap(16), right=bar.Gap(40), x=0, y=340, width=450, height=220), Screen(top=bar.Bar( [widget.GroupBox(), widget.WindowName(), widget.Clock()], 30, ), left=bar.Gap(20), right=bar.Gap(24), x=450, y=380, width=350, height=220), ] screens = []
DropDown( "music", apps.myMusicPlayer, x=s_left_margin, y=s_top_margin, width=s_width, height=s_height, warp_pointer=False, ), ], ), ) layouts = [ layout.MonadTall(**global_layout), layout.Columns(**global_layout), layout.Tile(**global_layout) # , layout.MonadWide(**global_layout) # , layout.Stack(num_stacks=2) # , layout.Matrix() # , layout.RatioTile() # , layout.TreeTab() # , layout.VerticalTile(**global_layout) # , layout.Zoomy() , layout.Bsp(**global_layout), layout.Max(**global_layout) ] def primary_bar(): return [
desc="Switch to group {}".format(i.name)), Key([mod, "shift"], i.name, lazy.window.togroup(i.name, switch_group=True), desc="Switch & move focused window to group {}".format(i.name)), # Or, use below if you prefer not to switch to that group. # # mod1 + shift + letter of group = move focused window to group # Key([mod, "shift"], i.name, lazy.window.togroup(i.name), # desc="move focused window to group {}".format(i.name)), ]) layouts = [ layout.Max(), layout.Tile(border_normal="#222222", border_focus="#ff4400", border_width=3, margin=5, add_after_last=True), layout.VerticalTile( border_normal="#222222", border_focus="#ff4400", border_width=3, margin=5, ), ] widget_defaults = dict( font='JetBrainsMono Nerd Font Mono', fontsize=16, padding=3, )
keys.append(Key([mod, 'shift'], i.name, lazy.window.togroup(i.name))) # see http://docs.qtile.org/en/latest/manual/ref/layouts.html layouts = [ layout.Max(), layout.Floating( border_focus=color_alert, border_normal=color_frame, ), #layout.Matrix(), #layout.MonadTall(), #layout.RatioTile(), #layout.Slice(), #layout.Stack(num_stacks=2), layout.Tile( border_focus=color_alert, border_normal=color_frame, ), #layout.TreeTab(), #layout.VerticalTile(), #layout.Zoomy(), ] widget_defaults = dict( font='Sans', fontsize=16, ) class Backlight(widget.Backlight): def poll(self): info = self._get_info()
layout.MonadTall(margin=16, border_width=2, border_focus="#ff00ff", border_normal="#f4c2c2"), layout.MonadWide(margin=16, border_width=2, border_focus="#ff00ff", border_normal="#f4c2c2"), layout.Matrix(**layout_theme), layout.Bsp(**layout_theme), layout.Floating(**layout_theme), layout.RatioTile(**layout_theme), layout.Max(**layout_theme), layout.Columns(**layout_theme), layout.Stack(**layout_theme), layout.Tile(**layout_theme), layout.TreeTab(sections=['FIRST', 'SECOND'], bg_color='#141414', active_bg='#0000ff', inactive_bg='#1e90ff', padding_y=5, section_top=10, panel_width=280), layout.VerticalTile(**layout_theme), layout.Zoomy(**layout_theme) ] # COLORS FOR THE BAR def init_colors():
'group_names_fg_inactive': 'bdae93', 'window_name_fg': 'b16286', 'highlight_line_color': '458588' } layout_theme = { 'border_width': 1, 'margin': 2, 'border_focus': '458588', 'border_normal': '076678' } layouts = [ layout.xmonad.MonadTall(**layout_theme), layout.Max(**layout_theme), layout.Tile(shift_windows=False, **layout_theme), layout.Stack(num_stacks=2), layout.Floating(**layout_theme), ] widget_defaults = dict( font = 'Ubuntu Mono Bold', fontsize = 14, padding = 2, ) extension_defaults = widget_defaults.copy() def init_widgets_list(): widget_list = [ widget.Sep(
# # mod1 + shift + letter of group = move focused window to group # Key([mod, "shift"], i.name, lazy.window.togroup(i.name), # desc="move focused window to group {}".format(i.name)), ]) layouts = [ layout.Columns(border_focus='#4C7899', border_width=4), layout.Max(), # Try more layouts by unleashing below layouts. #layout.Stack(border_focus='$4C7899', border_width=4, num_stacks=2), layout.Bsp(border_focus='#4C7899', border_width=4), layout.Matrix(border_focus='#4C7899', border_width=4), layout.MonadTall(border_focus='#4C7899', border_width=4), layout.MonadWide(border_focus='#4C7899', border_width=4), layout.RatioTile(border_focus='#4C7899', border_width=4), layout.Tile(border_focus='#4C7899', border_width=4), layout.TreeTab(border_focus='#4C7899', border_width=4), layout.VerticalTile(border_focus='#4C7899', border_width=4), layout.Zoomy(), ] widget_defaults = dict( font='sans', fontsize=12, padding=3, ) extension_defaults = widget_defaults.copy() screens = [ Screen( bottom=bar.Bar(
lazy.group[i.name].toscreen(), desc="Switch to group {}".format(i.name)), # mod1 + shift + letter of group = switch to & move focused window to group Key([mod, "shift"], i.name, lazy.window.togroup(i.name, switch_group=True), desc="Switch to & move focused window to group {}".format(i.name)), # Or, use below if you prefer not to switch to that group. # # mod1 + shift + letter of group = move focused window to group # Key([mod, "shift"], i.name, lazy.window.togroup(i.name), # desc="move focused window to group {}".format(i.name)), ]) layouts = [ layout.Tile(margin=2), layout.Columns( border_focus_stack='#d75f5f', margin=2, ), layout.Max(), # Try more layouts by unleashing below layouts. layout.Stack(num_stacks=2), layout.Bsp(margin=2), layout.Matrix(margin=2), layout.MonadTall(margin=2), layout.MonadWide(margin=2), layout.RatioTile(margin=2), layout.TreeTab(), layout.VerticalTile(margin=2), layout.Zoomy(),