From bc0d9063b6dbe497d83b0092c6ffa5abdd0b4230 Mon Sep 17 00:00:00 2001 From: ulve Date: Fri, 12 Jun 2026 22:36:23 +0200 Subject: [PATCH] remove qtile, move nurgle icon to waybar, fix brightnessctl --- config/qtile/.gitignore | 1 - config/qtile/config.py | 161 ---------------------- config/{qtile/icons => waybar}/nurgle.png | Bin config/waybar/style.css | 2 +- configuration.nix | 2 - home.nix | 2 +- 6 files changed, 2 insertions(+), 166 deletions(-) delete mode 100644 config/qtile/.gitignore delete mode 100644 config/qtile/config.py rename config/{qtile/icons => waybar}/nurgle.png (100%) diff --git a/config/qtile/.gitignore b/config/qtile/.gitignore deleted file mode 100644 index bee8a64..0000000 --- a/config/qtile/.gitignore +++ /dev/null @@ -1 +0,0 @@ -__pycache__ diff --git a/config/qtile/config.py b/config/qtile/config.py deleted file mode 100644 index d32db02..0000000 --- a/config/qtile/config.py +++ /dev/null @@ -1,161 +0,0 @@ -from libqtile import extension, hook, layout, qtile -from libqtile.config import Click, Drag, Group, Key, KeyChord, Match, Screen -from libqtile.lazy import lazy -from libqtile.utils import guess_terminal -import os -import subprocess - - -mod = "mod4" -terminal = guess_terminal() - -myTerm = "alacritty" - -keys = [ - Key([mod], "h", lazy.layout.left(), desc="Move focus to left"), - Key([mod], "l", lazy.layout.right(), desc="Move focus to right"), - Key([mod], "j", lazy.layout.down(), desc="Move focus down"), - Key([mod], "k", lazy.layout.up(), desc="Move focus up"), - Key([mod], "space", lazy.layout.next(), desc="Move window focus to other window"), - # Move windows between left/right columns or move up/down in current stack. - # Moving out of range in Columns layout will create new column. - Key([mod, "shift"], "h", lazy.layout.shuffle_left(), desc="Move window to the left"), - Key([mod, "shift"], "l", lazy.layout.shuffle_right(), desc="Move window to the right"), - Key([mod, "shift"], "j", lazy.layout.shuffle_down(), desc="Move window down"), - Key([mod, "shift"], "k", lazy.layout.shuffle_up(), desc="Move window up"), - # Grow windows. If current window is on the edge of screen and direction - # will be to screen edge - window would shrink. - Key([mod, "control"], "h", lazy.layout.grow_left(), desc="Grow window to the left"), - Key([mod, "control"], "l", lazy.layout.grow_right(), desc="Grow window to the right"), - Key([mod, "control"], "j", lazy.layout.grow_down(), desc="Grow window down"), - Key([mod, "control"], "k", lazy.layout.grow_up(), desc="Grow window up"), - Key([mod], "n", lazy.layout.normalize(), desc="Reset all window sizes"), - # 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(), - desc="Toggle between split and unsplit sides of stack", - ), - Key([mod], "Return", lazy.spawn(terminal), desc="Launch terminal"), - # Toggle between different layouts as defined below - Key([mod], "Tab", lazy.next_layout(), desc="Toggle between layouts"), - Key([mod], "q", lazy.window.kill(), desc="Kill focused window"), - Key( - [mod], - "f", - lazy.window.toggle_fullscreen(), - desc="Toggle fullscreen on the focused window", - ), - Key([mod], "t", lazy.window.toggle_floating(), desc="Toggle floating on the focused window"), - Key([mod, "control"], "r", lazy.reload_config(), desc="Reload the config"), - Key([mod, "control"], "q", lazy.shutdown(), desc="Shutdown Qtile"), - Key([mod], "d", lazy.spawn("rofi -show drun -show-icons"), desc='Run Launcher'), - Key( - [mod], - "s", - lazy.spawn('sh -c "maim -s | xclip -selection clipboard -t image/png -i"'), - desc="Screenshot" - ), -] - -# Add key bindings to switch VTs in Wayland. -# We can't check qtile.core.name in default config as it is loaded before qtile is started -# We therefore defer the check until the key binding is run by using .when(func=...) -for vt in range(1, 8): - keys.append( - Key( - ["control", "mod1"], - f"f{vt}", - lazy.core.change_vt(vt).when(func=lambda: qtile.core.name == "wayland"), - desc=f"Switch to VT{vt}", - ) - ) - - -groups = [Group(i) for i in "123456789"] - -for i in groups: - keys.extend( - [ - # mod + group number = switch to group - Key( - [mod], - i.name, - lazy.group[i.name].toscreen(), - desc=f"Switch to group {i.name}", - ), - # mod + shift + group number = move focused window to group - Key([mod, "shift"], i.name, lazy.window.togroup(i.name), - desc="move focused window to group {}".format(i.name)), - ] - ) - -colors = [ - ["#1a1b26", "#1a1b26"], # bg (primary.background) - ["#a9b1d6", "#a9b1d6"], # fg (primary.foreground) - ["#32344a", "#32344a"], # color01 (normal.black) - ["#f7768e", "#f7768e"], # color02 (normal.red) - ["#9ece6a", "#9ece6a"], # color03 (normal.green) - ["#e0af68", "#e0af68"], # color04 (normal.yellow) - ["#7aa2f7", "#7aa2f7"], # color05 (normal.blue) - ["#ad8ee6", "#ad8ee6"], # color06 (normal.magenta) - ["#0db9d7", "#0db9d7"], # color15 (bright.cyan) - ["#444b6a", "#444b6a"] # color[9] (bright.black) -] - -layout_theme = { - "border_width" : 1, - "margin" : 1, - "border_focus" : colors[6], - "border_normal" : colors[0], -} - -layouts = [ - layout.Columns(**layout_theme), - layout.Max(), - layout.MonadTall(**layout_theme), -] - -screens = [Screen()] - -# Drag floating layouts. -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()), - Click([mod], "Button2", lazy.window.bring_to_front()), -] - -dgroups_key_binder = None -dgroups_app_rules = [] # type: list -follow_mouse_focus = True -bring_front_click = False -floats_kept_above = True -cursor_warp = False -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 - ] -) -auto_fullscreen = True -focus_on_window_activation = "smart" -reconfigure_screens = True - -auto_minimize = True - -wl_input_rules = None - -wl_xcursor_theme = None -wl_xcursor_size = 24 - -wmname = "LG3D" diff --git a/config/qtile/icons/nurgle.png b/config/waybar/nurgle.png similarity index 100% rename from config/qtile/icons/nurgle.png rename to config/waybar/nurgle.png diff --git a/config/waybar/style.css b/config/waybar/style.css index 1e2d208..5d3990e 100644 --- a/config/waybar/style.css +++ b/config/waybar/style.css @@ -12,7 +12,7 @@ window#waybar { } #custom-nurgle { - background-image: url("/home/ulve/.config/qtile/icons/nurgle.png"); + background-image: url("/home/ulve/.config/waybar/nurgle.png"); background-size: 20px 20px; background-repeat: no-repeat; background-position: center; diff --git a/configuration.nix b/configuration.nix index 4947ef1..f348ab0 100644 --- a/configuration.nix +++ b/configuration.nix @@ -47,7 +47,6 @@ services.xserver = { enable = true; autoRepeatInterval = 35; - windowManager.qtile.enable = true; }; services.displayManager.ly.enable = true; @@ -60,7 +59,6 @@ console.keyMap = "sv-latin1"; - services.pulseaudio.enable = false; security.rtkit.enable = true; services.pipewire = { enable = true; diff --git a/home.nix b/home.nix index b699473..6fcce37 100644 --- a/home.nix +++ b/home.nix @@ -229,7 +229,6 @@ # ── Config files ───────────────────────────────────────────────────────────── xdg.configFile."fuzzel/fuzzel.ini".source = ./config/fuzzel/fuzzel.ini; - xdg.configFile."qtile".source = ./config/qtile; xdg.configFile."nvim" = { source = config.lib.file.mkOutOfStoreSymlink "/home/ulve/nixos-dotfiles/config/nvim"; }; @@ -275,6 +274,7 @@ fuzzel # wayland launcher swaylock # lock screen swayidle # idle management (dims/locks/sleeps) + brightnessctl # screen brightness control waybar # status bar with left/center/right sections lxqt.lxqt-policykit # polkit authentication agent