Browse Source

Sat Jul 13 11:45:28 AM BST 2024

Gabriel Capella 4 months ago
parent
commit
18bed4c7a2
1 changed files with 45 additions and 48 deletions
  1. 45 48
      dots/.config/sway/config

+ 45 - 48
dots/.config/sway/config

@@ -12,49 +12,35 @@ set $mod Mod1
 
 
 # Font for window titles. Will also be used by the bar unless a different font
 # Font for window titles. Will also be used by the bar unless a different font
 # is used in the bar {} block below.
 # is used in the bar {} block below.
-font pango:monospace 9
+font pango:monospace 12
 
 
 # This font is widely installed, provides lots of unicode glyphs, right-to-left
 # This font is widely installed, provides lots of unicode glyphs, right-to-left
 # text rendering and scalability on retina/hidpi displays (thanks to pango).
 # text rendering and scalability on retina/hidpi displays (thanks to pango).
-font pango:DejaVu Sans Mono 9
+font pango:DejaVu Sans Mono 12
 
 
 # The combination of xss-lock, nm-applet and pactl is a popular choice, so
 # The combination of xss-lock, nm-applet and pactl is a popular choice, so
 # they are included here as an example. Modify as you see fit.
 # they are included here as an example. Modify as you see fit.
 
 
-# xss-lock grabs a logind suspend inhibit lock and will use i3lock to lock the
-# screen before suspend. Use loginctl lock-session to lock your screen.
-exec --no-startup-id xss-lock --transfer-sleep-lock -- i3lock --nofork
-
 # NetworkManager is the most popular way to manage wireless networks on Linux,
 # NetworkManager is the most popular way to manage wireless networks on Linux,
 # and nm-applet is a desktop environment-independent system tray GUI for it.
 # and nm-applet is a desktop environment-independent system tray GUI for it.
-exec --no-startup-id nm-applet
 exec --no-startup-id clipster -d
 exec --no-startup-id clipster -d
+exec mako
 
 
 bindsym $mod+c exec clipster -sp
 bindsym $mod+c exec clipster -sp
 
 
-
-# Use pactl to adjust volume in PulseAudio.
-set $refresh_i3status killall -SIGUSR1 i3status
-bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10% && $refresh_i3status
-bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10% && $refresh_i3status
-bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle && $refresh_i3status
-bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOURCE@ toggle && $refresh_i3status
-
 # Use Mouse+$mod to drag floating windows to their wanted position
 # Use Mouse+$mod to drag floating windows to their wanted position
 floating_modifier $mod
 floating_modifier $mod
 
 
 # start a terminal
 # start a terminal
-bindsym $mod+Return exec sakura
+bindsym $mod+Return exec alacritty
 
 
 # kill focused window
 # kill focused window
 bindsym $mod+Shift+q kill
 bindsym $mod+Shift+q kill
 
 
 # start dmenu (a program launcher)
 # start dmenu (a program launcher)
-bindsym $mod+d exec  bemenu-run -l 10 -p  --counter always -c -W 0.1 -B 10 -fn 'Droid Sans Mono-12'
-# There also is the (new) i3-dmenu-desktop which only displays applications
-# shipping a .desktop file. It is a wrapper around dmenu, so you need that
-# installed.
-# bindsym $mod+d exec --no-startup-id i3-dmenu-desktop
+bindsym $mod+d exec bemenu-run -l 10 -p  --counter always -c -W 0.1 -B 10 \
+    --fixed-height --fn  'Source Code Pro 11'  \
+    --bdr "#323232" --tf "#FFFFFF" --hf "#FFFFFF"
 
 
 # change focus
 # change focus
 bindsym $mod+j focus left
 bindsym $mod+j focus left
@@ -86,6 +72,7 @@ bindsym $mod+h split h
 # split in vertical orientation
 # split in vertical orientation
 bindsym $mod+v split v
 bindsym $mod+v split v
 
 
+
 # enter fullscreen mode for the focused container
 # enter fullscreen mode for the focused container
 bindsym $mod+f fullscreen toggle
 bindsym $mod+f fullscreen toggle
 
 
@@ -103,9 +90,6 @@ bindsym $mod+space focus mode_toggle
 # focus the parent container
 # focus the parent container
 bindsym $mod+a focus parent
 bindsym $mod+a focus parent
 
 
-# focus the child container
-#bindsym $mod+d focus child
-
 # Define names for default workspaces for which we configure key bindings later on.
 # Define names for default workspaces for which we configure key bindings later on.
 # We use variables to avoid repeating the names in multiple places.
 # We use variables to avoid repeating the names in multiple places.
 set $ws1 "1"
 set $ws1 "1"
@@ -148,7 +132,7 @@ bindsym $mod+Shift+c reload
 # restart i3 inplace (preserves your layout/session, can be used to upgrade i3)
 # restart i3 inplace (preserves your layout/session, can be used to upgrade i3)
 bindsym $mod+Shift+r restart
 bindsym $mod+Shift+r restart
 # exit i3 (logs you out of your X session)
 # exit i3 (logs you out of your X session)
-bindsym $mod+Shift+e exec "swaynag -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -B 'Yes, exit i3' 'i3-msg exit'"
+bindsym $mod+Shift+e exec "swaynag -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -B 'Yes, exit i3' 'sway exit'"
 
 
 # resize window (you can also use the mouse for that)
 # resize window (you can also use the mouse for that)
 mode "resize" {
 mode "resize" {
@@ -180,26 +164,32 @@ bindsym $mod+r mode "resize"
 # Start i3bar to display a workspace bar (plus the system information i3status
 # Start i3bar to display a workspace bar (plus the system information i3status
 # finds out, if available)
 # finds out, if available)
 bar {
 bar {
-        mode hide
-        hidden_state hide
-        status_command i3status
-        modifier Mod1
+    position top
+    # modifier Mod1
+    # status_command while date +'%Y-%m-%d %I:%M:%S %p (UTC)'; do sleep 1; done
+    bar swaybar_command waybar
 }
 }
 
 
-
-# Sreen brightness controls
-bindsym XF86MonBrightnessUp exec sudo light -A 5 # increase screen brightness
-bindsym XF86MonBrightnessDown exec sudo light -U 5 # decrease screen brightness
-
-
 # Media player controls
 # Media player controls
-bindsym XF86AudioPlay exec playerctl play
-bindsym XF86AudioPause exec playerctl pause
+bindsym XF86AudioPlay exec playerctl play-pause
+bindsym XF86AudioPause exec playerctl play-pause
 bindsym XF86AudioNext exec playerctl next
 bindsym XF86AudioNext exec playerctl next
 bindsym XF86AudioPrev exec playerctl previous
 bindsym XF86AudioPrev exec playerctl previous
 
 
+# Monitor
+bindsym XF86MonBrightnessUp exec ddcutil setvcp --sn 6L1M413 10 + 5
+bindsym XF86MonBrightnessDown exec ddcutil setvcp --sn 6L1M413 10 - 5
+
+
+# Audio
+bindsym XF86AudioRaiseVolume exec pactl set-sink-volume @DEFAULT_SINK@ +5%
+bindsym XF86AudioLowerVolume exec pactl set-sink-volume @DEFAULT_SINK@ -5%
+bindsym XF86AudioMute exec pactl set-sink-mute @DEFAULT_SINK@ toggle
+
+bindsym Print exec 'slurp | GRIM_DEFAULT_DIR=~/Downloads/ grim -g -'
+
 # colors
 # colors
-set $black 	       #272822
+set $black             #272822
 set $white             #FFFFFF
 set $white             #FFFFFF
 set $pink              #F92672
 set $pink              #F92672
 set $blue              #444444
 set $blue              #444444
@@ -216,22 +206,29 @@ client.unfocused        $black  $black $white  $black  $black
 client.background       #ff0000
 client.background       #ff0000
 
 
 input * {
 input * {
-    xkb_layout "br"
-    xkb_options "ctrl:nocaps"
+    xkb_options "ctrl:nocaps,grp:toggle"
+    xkb_layout us,us
+    xkb_variant ,intl
+    scroll_factor 1
 }
 }
 
 
-input 1452:591:Keychron_K8_Keychron_K8 {
-    xkb_layout "us"
-}
-
-output * bg #000000 solid_color
+exec swayidle -w \
+         timeout 300 'swaylock -f -c 000000 -i /tmp/mercator_projection.png' \
+         timeout 600 'swaymsg "output * power off"' resume 'swaymsg "output * power on"' \
+         before-sleep 'swaylock -f -c 000000 -i /tmp/mercator_projection.pn'
 
 
-exec swayidle -w 	timeout 120 'swaylock -f -c 000000' 	timeout 120 'swaymsg "output * power off"' 			resume 'swaymsg "output * power on"'     before-sleep 'swaylock -f -c 000000'
+bindsym $mod+q exec 'swaylock -f -c 000000 -i /tmp/mercator_projection.png'
 
 
 smart_borders on
 smart_borders on
 hide_edge_borders both
 hide_edge_borders both
-for_window [class="^.*"] border pixel 1
-
+for_window [class="^.*"] border pixel 2
 
 
+include @sysconfdir@/sway/config.d/*
 
 
+output HDMI-A-1 pos 0 0
 
 
+output HDMI-A-2 {
+    transform 270
+    pos 930 2160
+    scale 1
+}