Compare commits

...

4 Commits

5 changed files with 119 additions and 118 deletions

View File

@ -1,5 +1,32 @@
# vim: ft=yaml
# Configuration for Alacritty, the GPU enhanced terminal emulator.
# Font configuration
font:
# Normal (roman) font face
normal:
family: MonoFont
style: Regular
size: {{ .alacritty.font.size }}
# Offset is the extra space around each character. `offset.y` can be thought
# of as modifying the line spacing, and `offset.x` as modifying the letter
# spacing.
offset:
x: {{ .alacritty.font.offset.x }}
y: {{ .alacritty.font.offset.y }}
# Glyph offset determines the locations of the glyphs within their cells with
# the default being at the bottom. Increasing `x` moves the glyph to the
# right, increasing `y` moves the glyph upward.
# glyph_offset:
# x: 0
# y: 26
# Use built-in font for box drawing characters.
#
# If `true`, Alacritty will use a custom built-in font for box drawing
# characters (Unicode points 2500 - 259f).
#
#builtin_box_drawing: true
# Import additional configuration files
#
@ -57,36 +84,6 @@ scrolling:
# Scrolling distance multiplier.
#multiplier: 3
# Font configuration
font:
# Normal (roman) font face
normal:
family: MonoFont
style: Regular
size: {{ .alacritty.font.size }}
# Offset is the extra space around each character. `offset.y` can be thought
# of as modifying the line spacing, and `offset.x` as modifying the letter
# spacing.
offset:
x: {{ .alacritty.font.offset.x }}
y: {{ .alacritty.font.offset.y }}
# Glyph offset determines the locations of the glyphs within their cells with
# the default being at the bottom. Increasing `x` moves the glyph to the
# right, increasing `y` moves the glyph upward.
# glyph_offset:
# x: 0
# y: 26
# Use built-in font for box drawing characters.
#
# If `true`, Alacritty will use a custom built-in font for box drawing
# characters (Unicode points 2500 - 259f).
#
#builtin_box_drawing: true
# If `true`, bold text is drawn using the bright color variants.
#draw_bold_text_with_bright_colors: false

View File

@ -4,9 +4,7 @@
<alias>
<family>MonoFont</family>
<prefer>
<family>Pragmata Pro</family>
<family>Font Awesome 6 Free Regular</family>
<family>Font Awesome 6 Brands Regular</family>
<family>IosevkaTerm Nerd Font</family>
</prefer>
</alias>
</fontconfig>

View File

@ -31,6 +31,10 @@ set $down n
set $up e
set $right i
set $telegram " "
set $firefox " "
set $thunderbird " "
# Font for window titles. Will also be used by the bar unless a different font
# is used in the bar {} block below.
font pango:MonoFont {{ .i3.font_size }}
@ -99,9 +103,9 @@ bindsym $mod+7 workspace number 7
bindsym $mod+8 workspace number 8
bindsym $mod+9 workspace number 9
bindsym $mod+0 workspace number 10
bindsym $mod+p workspace
bindsym $mod+w workspace
bindsym $mod+m workspace
bindsym $mod+p workspace $telegram
bindsym $mod+w workspace $firefox
bindsym $mod+m workspace $thunderbird
# move focused container to workspace
bindsym $mod+Shift+1 move container to workspace number 1
@ -114,9 +118,9 @@ bindsym $mod+Shift+7 move container to workspace number 7
bindsym $mod+Shift+8 move container to workspace number 8
bindsym $mod+Shift+9 move container to workspace number 9
bindsym $mod+Shift+0 move container to workspace number 10
bindsym $mod+Shift+p move container to workspace
bindsym $mod+Shift+w move container to workspace
bindsym $mod+Shift+m move container to workspace
bindsym $mod+Shift+p move container to workspace $telegram
bindsym $mod+Shift+w move container to workspace $firefox
bindsym $mod+Shift+m move container to workspace $thunderbird
bindsym $mod+Shift+c reload
bindsym $mod+Shift+r restart
@ -179,15 +183,13 @@ bindsym $mod+Print exec "pyazo -d"
workspace_layout tabbed
# Auto-assign programs to certain workspaces
assign [class="(?i)firefox"]
assign [class="(?i)chromium"]
assign [class="Telegram"]
assign [class="thunderbird"]
assign [class="(?i)slack"]
assign [class="(?i)firefox"] $firefox
assign [class="(?i)chromium"] $firefox
assign [class="Telegram"] $telegram
assign [class="thunderbird"] $thunderbird
assign [class="(?i)slack"] $telegram
for_window [class="Lxappearance"] floating enable
for_window [class="Spotify"] move to workspace 
for_window [class="tidal-hifi"] move to workspace 
for_window [class="deezer"] move to workspace 
for_window [class="tidal-hifi"] move to workspace $telegram
new_window pixel 2
hide_edge_borders smart
@ -218,6 +220,7 @@ bindsym $mod+F12 mode "$mode_kb_select"
bar {
position top
padding -2px 0 -1px
tray_output none
status_command ~/.local/share/bumblebee-status/bumblebee-status -c ~/.config/bumblebee-status/top.toml
bindsym button4 nop
@ -233,6 +236,7 @@ bar {
bar {
position bottom
padding -2px 0 -1px
tray_output {{ .i3.tray_output }}
status_command ~/.local/share/bumblebee-status/bumblebee-status -c ~/.config/bumblebee-status/bottom.toml
bindsym button4 nop

View File

@ -4,7 +4,7 @@
# for running programs. It contains icons for a few programs, but more can
# easily be added by inserting them into WINDOW_ICONS below.
#
# Dependencies: xorg-xprop i3ipc fontawesome
# Dependencies: xorg-xprop i3ipc nerdfonts
#
# Installation:
# Add "exec_always ~/.config/i3/i3-autoname-workspaces.py &" to the i3 config
@ -24,7 +24,7 @@ import subprocess as proc
from sys import exit
from typing import Any, NoReturn
import fontawesome as fa # type: ignore
import nerdfonts as nf # type: ignore
import i3ipc # type: ignore
# Add icons here for common programs you use. The keys are the X window class
@ -38,68 +38,70 @@ import i3ipc # type: ignore
# xprop (https://linux.die.net/man/1/xprop). Run `xprop | grep WM_CLASS`
# then click on the application you want to inspect.
WINDOW_ICONS: dict[str, str] = {
'alacritty': fa.icons['terminal'],
'blender': fa.icons['cube'],
'blueman-manager': fa.icons['bluetooth'],
'calibre-gui': fa.icons['book'],
'chromium': fa.icons['chrome'],
'cities.x64': fa.icons['city'],
'clonehero': fa.icons['guitar'],
'code-oss': fa.icons['code'],
'vscodium': fa.icons['code'],
'cutter': fa.icons['bug'],
'darktable': fa.icons['camera'],
'discord': fa.icons['comment'],
'dwarf_fortress': fa.icons['fort-awesome'],
'easyeffects': fa.icons['music'],
'evince': fa.icons['file-pdf'],
'factorio': fa.icons['cog'],
'feh': fa.icons['image'],
'firefox': fa.icons['firefox'],
'firefoxdeveloperedition': fa.icons['firefox'],
'ghb': fa.icons['video'],
'gimp': fa.icons['file-image'],
'gimp-2.10': fa.icons['file-image'],
'gparted': fa.icons['hdd'],
'gsmartcontrol': fa.icons['hdd'],
'inkscape': fa.icons['pen-nib'],
'jetbrains-idea-ce': fa.icons['code'],
'jetbrains-studio': fa.icons['code'],
'kicad': fa.icons['microchip'],
'ksp.x86_64': fa.icons['space-shuttle'],
'ledger live': fa.icons['wallet'],
'libreoffice-calc': fa.icons['file-excel'],
'libreoffice-impress': fa.icons['file-powerpoint'],
'libreoffice-writer': fa.icons['file-alt'],
'lutris': fa.icons['gamepad'],
'mpv': fa.icons['video'],
'polymc': fa.icons['cube'],
'minecraft': fa.icons['cube'],
'mupdf': fa.icons['file-pdf'],
'nemiver': fa.icons['bug'],
'nm-connection-editor': fa.icons['wifi'],
'obs': fa.icons['video'],
'pavucontrol': fa.icons['volume-up'],
'picard': fa.icons['music'],
'qbittorrent': fa.icons['download'],
'qtcreator': fa.icons['code'],
'roxterm': fa.icons['terminal'],
'seahorse': fa.icons['lock'],
'simplescreenrecorder': fa.icons['video'],
'slack': fa.icons['slack'],
'spotify': fa.icons['spotify'],
'sqlitebrowser': fa.icons['database'],
'steam': fa.icons['steam'],
'surviving mars': fa.icons['rocket'],
'telegram-desktop': fa.icons['telegram'],
'terraria.bin.x86_64': fa.icons['tree'],
'thunderbird': fa.icons['envelope'],
'vim': fa.icons['code'],
'virtualbox manager': fa.icons['desktop'],
'vlc': fa.icons['video'],
'wireshark': fa.icons['network-wired'],
'zathura': fa.icons['file-pdf'],
'zenity': fa.icons['window-maximize'],
'alacritty': nf.icons['fa_terminal'],
'blender': nf.icons['fa_cube'],
'blueman-manager': nf.icons['fa_bluetooth'],
'calibre-gui': nf.icons['fa_book'],
'chromium': nf.icons['fa_chrome'],
'cities.x64': nf.icons['md_city'],
'clonehero': nf.icons['md_guitar_electric'],
'code-oss': nf.icons['fa_code'],
'vscodium': nf.icons['fa_code'],
'cutter': nf.icons['fa_bug'],
'darktable': nf.icons['fa_camera'],
'discord': nf.icons['fa_comment'],
'dwarf_fortress': nf.icons['fa_fort_awesome'],
'easyeffects': nf.icons['fa_music'],
'evince': nf.icons['fa_file_pdf_o'],
'factorio': nf.icons['fa_cog'],
'feh': nf.icons['fa_image'],
'firefox': nf.icons['fa_firefox'],
'firefoxdeveloperedition': nf.icons['fa_firefox'],
'ghb': nf.icons['md_video'],
'gimp': nf.icons['cod_file_media'],
'gimp-2.10': nf.icons['cod_file_media'],
'gparted': nf.icons['fa_hdd_o'],
'gsmartcontrol': nf.icons['fa_hdd_o'],
'inkscape': nf.icons['md_fountain_pen_tip'],
'jetbrains-idea-ce': nf.icons['fa_code'],
'jetbrains-studio': nf.icons['fa_code'],
'kcharselect': nf.icons['fa_font'],
'kicad': nf.icons['fa_microchip'],
'ksp.x86_64': nf.icons['fa_space_shuttle'],
'ledger live': nf.icons['md_wallet'],
'libreoffice-calc': nf.icons['fa_file_excel_o'],
'libreoffice-impress': nf.icons['fa_file_powerpoint_o'],
'libreoffice-writer': nf.icons['fa_file_word_o'],
'lutris': nf.icons['fa_gamepad'],
'mpv': nf.icons['md_video'],
'polymc': nf.icons['fa_cube'],
'minecraft': nf.icons['fa_cube'],
'mupdf': nf.icons['fa_file_pdf_o'],
'nemiver': nf.icons['fa_bug'],
'nm-connection-editor': nf.icons['fa_wifi'],
'obs': nf.icons['md_video'],
'openlens': nf.icons['md_kubernetes'],
'pavucontrol': nf.icons['fa_volume_up'],
'picard': nf.icons['fa_music'],
'qbittorrent': nf.icons['fa_download'],
'qtcreator': nf.icons['fa_code'],
'roxterm': nf.icons['fa_terminal'],
'seahorse': nf.icons['fa_lock'],
'simplescreenrecorder': nf.icons['md_video'],
'slack': nf.icons['fa_slack'],
'spotify': nf.icons['fa_spotify'],
'sqlitebrowser': nf.icons['fa_database'],
'steam': nf.icons['fa_steam'],
'surviving mars': nf.icons['fa_rocket'],
'telegram-desktop': nf.icons['fa_telegram'],
'terraria.bin.x86_64': nf.icons['fa_tree'],
'thunderbird': nf.icons['fa_envelope'],
'vim': nf.icons['fa_code'],
'virtualbox manager': nf.icons['fa_desktop'],
'vlc': nf.icons['md_video'],
'wireshark': nf.icons['md_shark_fin'],
'zathura': nf.icons['fa_file_pdf_o'],
'zenity': nf.icons['fa_window_maximize'],
}
# This icon is used for any application not in the list above
@ -133,7 +135,7 @@ def construct_workspace_name(parts) -> str:
if parts['icons']:
new_name += ' ' + parts['icons']
return new_name
return new_name + ' '
# Returns an array of the values for the given property from xprop. This
@ -164,8 +166,8 @@ def icon_for_window(window) -> str:
if cls in WINDOW_ICONS:
return WINDOW_ICONS[cls]
else:
print(f'No icon available for: {classes}')
else:
print(f'No icon available for: {classes}')
return DEFAULT_ICON
@ -173,7 +175,7 @@ def icon_for_window(window) -> str:
# renames all workspaces based on the windows present
def rename_workspaces(i3) -> None:
for workspace in i3.get_tree().workspaces():
if workspace.name in ['', '', '']:
if workspace.num == -1:
continue
name_parts = parse_workspace_name(workspace.name)

View File

@ -1,7 +1,7 @@
configuration {
modi: "drun,ssh,emoji";
fixed-num-lines: true;
font: "Pragmata Pro {{ .rofi.font.size }}";
font: "MonoFont {{ .rofi.font.size }}";
location: 0;
show-icons: false;
terminal: "terminator";