config/qtile: adjust formatting with new fill column
This commit is contained in:
parent
17fc73c63d
commit
88d9f6091d
1 changed files with 7 additions and 15 deletions
|
@ -79,15 +79,11 @@ class Apps:
|
||||||
return lazy.spawn(cls.terminal_command(program, args=args, terminal=terminal))
|
return lazy.spawn(cls.terminal_command(program, args=args, terminal=terminal))
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def shell_in_terminal(
|
def shell_in_terminal(cls, command, sargs=tuple(), targs=tuple(), *, shell=None, terminal=None):
|
||||||
cls, command, sargs=tuple(), targs=tuple(), *, shell=None, terminal=None
|
|
||||||
):
|
|
||||||
"""
|
"""
|
||||||
Opens a program in the terminal using the shell, with the given shell and terminal arguments.
|
Opens a program in the terminal using the shell, with the given shell and terminal arguments.
|
||||||
"""
|
"""
|
||||||
return cls.open_in_terminal(
|
return cls.open_in_terminal(cls.shell_command(command, sargs, shell=shell), targs, terminal=terminal)
|
||||||
cls.shell_command(command, sargs, shell=shell), targs, terminal=terminal
|
|
||||||
)
|
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def open_in_editor(cls, file_, args=tuple()):
|
def open_in_editor(cls, file_, args=tuple()):
|
||||||
|
@ -549,9 +545,7 @@ def create_powerline(
|
||||||
widget.TextBox(
|
widget.TextBox(
|
||||||
text=sep,
|
text=sep,
|
||||||
foreground=backgrounds[bg_index],
|
foreground=backgrounds[bg_index],
|
||||||
background=base
|
background=base if i == 0 else backgrounds[bg_index - (len(backgrounds) - 1)],
|
||||||
if i == 0
|
|
||||||
else backgrounds[bg_index - (len(backgrounds) - 1)],
|
|
||||||
fontsize=fontsize,
|
fontsize=fontsize,
|
||||||
padding=padding,
|
padding=padding,
|
||||||
)
|
)
|
||||||
|
@ -571,10 +565,12 @@ def init_widget_list(main=True, laptop=False):
|
||||||
"""
|
"""
|
||||||
|
|
||||||
interfaces = run_command(
|
interfaces = run_command(
|
||||||
|
# fmt:off
|
||||||
"ifconfig -s"
|
"ifconfig -s"
|
||||||
" | awk {'print $1'}"
|
" | awk {'print $1'}"
|
||||||
" | grep -Ev -e Iface -e lo -e vir.+ -e docker.+ -e tailscale.+"
|
" | grep -Ev -e Iface -e lo -e vir.+ -e docker.+ -e tailscale.+"
|
||||||
" | tac"
|
" | tac"
|
||||||
|
# fmt:on
|
||||||
).splitlines()
|
).splitlines()
|
||||||
|
|
||||||
wireless_interfaces = list(filter(lambda x: x.startswith("w"), interfaces))
|
wireless_interfaces = list(filter(lambda x: x.startswith("w"), interfaces))
|
||||||
|
@ -602,9 +598,7 @@ def init_widget_list(main=True, laptop=False):
|
||||||
|
|
||||||
main_widgets = [
|
main_widgets = [
|
||||||
[
|
[
|
||||||
widget.Wlan(
|
widget.Wlan(format=" {essid} {percent:2.0%}", interface=wireless_interfaces[0]),
|
||||||
format=" {essid} {percent:2.0%}", interface=wireless_interfaces[0]
|
|
||||||
),
|
|
||||||
],
|
],
|
||||||
network_widgets,
|
network_widgets,
|
||||||
[
|
[
|
||||||
|
@ -729,9 +723,7 @@ screens = [
|
||||||
wallpaper="@wallpaper@",
|
wallpaper="@wallpaper@",
|
||||||
wallpaper_mode="@wallpaper_mode@",
|
wallpaper_mode="@wallpaper_mode@",
|
||||||
)
|
)
|
||||||
for i in range(
|
for i in range(int(run_command("xrandr --listmonitors | grep 'Monitors:' | awk {'print $2'}")))
|
||||||
int(run_command("xrandr --listmonitors | grep 'Monitors:' | awk {'print $2'}"))
|
|
||||||
)
|
|
||||||
]
|
]
|
||||||
|
|
||||||
# Drag floating layouts.
|
# Drag floating layouts.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue