dotfiles/.config/sway/config

352 lines
9.2 KiB
Plaintext
Raw Normal View History

2018-10-08 03:21:53 +02:00
# sway config file
set $mod Mod4
# Home row direction keys, like vim
set $left j
set $down k
set $up l
set $right semicolon
set $altright ccaron
# Terminal
set $term kitty
2018-10-08 03:21:53 +02:00
# Font
2020-11-11 00:16:56 +01:00
font pango:Iosevka SS05 Medium 10
2018-10-08 03:21:53 +02:00
# Launcher
set $menu "rofi -combi-modi window,drun,run -show combi -modi combi -config ~/.local/rofi/config"
2018-10-08 03:21:53 +02:00
#set $menu j4-dmenu-desktop
2019-02-06 19:45:43 +01:00
#set $menu compgen -c | sort -u | fzf | xargs -r swaymsg -t command exec
2018-10-08 03:21:53 +02:00
output eDP-1 {
pos 0 0
resolution 1920x1080
scale 1.25
scale_filter linear
}
2019-07-24 12:01:51 +02:00
#output eDP-1 resolution 2560x1440 scale 2
#output eDP-1 resolution 1920x1080 scale 1
output "*" background ~/Slike/Wallpapers/1596344206877.jpg fill
# Zamik dobimo z SIRINA / SCALE
output HDMI-A-2 pos 1536 0 scale 1
output DP-5 pos 1536 0 scale 1
2018-10-08 03:21:53 +02:00
# start a terminal
bindsym $mod+Return exec $term
# kill focused window
bindsym $mod+Shift+q kill
# start your launcher
bindsym $mod+d exec $menu
# Drag floating windows by holding down $mod and left mouse button.
# Resize them with right mouse button + $mod.
# Despite the name, also works for non-floating windows.
# Change normal to inverse to use left mouse button for resizing and right
# mouse button for dragging.
floating_modifier $mod normal
# reload the configuration file
bindsym $mod+Shift+r reload
# exit sway (logs you out of your wayland session)
bindsym $mod+Shift+e exit
#
# Moving around:
#
# Move your focus around
bindsym $mod+$left focus left
bindsym $mod+$down focus down
bindsym $mod+$up focus up
bindsym $mod+$right focus right
bindsym $mod+$altright focus right
# or use $mod+[up|down|left|right]
bindsym $mod+Left focus left
bindsym $mod+Down focus down
bindsym $mod+Up focus up
bindsym $mod+Right focus right
# _move_ the focused window with the same, but add Shift
bindsym $mod+Shift+$left move left
bindsym $mod+Shift+$down move down
bindsym $mod+Shift+$up move up
bindsym $mod+Shift+$right move right
bindsym $mod+Shift+$altright move right
# ditto, with arrow keys
bindsym $mod+Shift+Left move left
bindsym $mod+Shift+Down move down
bindsym $mod+Shift+Up move up
bindsym $mod+Shift+Right move right
#
# Workspaces:
#
# name workspaces
set $w1 1:
set $w2 2:λ
set $w3 3:
2018-10-08 03:21:53 +02:00
set $w4 4:
2021-09-29 21:48:08 +02:00
set $w5 5:
2018-10-08 03:21:53 +02:00
set $w6 6:
set $w7 7:✭❀❤♫
2018-10-08 03:21:53 +02:00
set $w8 8:☭
set $w9 9:
set $w0 0:
2018-10-08 03:21:53 +02:00
# switch to workspace
bindsym $mod+1 workspace $w1
bindsym $mod+2 workspace $w2
bindsym $mod+3 workspace $w3
bindsym $mod+4 workspace $w4
bindsym $mod+5 workspace $w5
bindsym $mod+6 workspace $w6
bindsym $mod+7 workspace $w7
bindsym $mod+8 workspace $w8
bindsym $mod+9 workspace $w9
bindsym $mod+0 workspace $w0
# move focused container to workspace
bindsym $mod+Shift+1 move container to workspace $w1
bindsym $mod+Shift+2 move container to workspace $w2
bindsym $mod+Shift+3 move container to workspace $w3
bindsym $mod+Shift+4 move container to workspace $w4
bindsym $mod+Shift+5 move container to workspace $w5
bindsym $mod+Shift+6 move container to workspace $w6
bindsym $mod+Shift+7 move container to workspace $w7
bindsym $mod+Shift+8 move container to workspace $w8
bindsym $mod+Shift+9 move container to workspace $w9
bindsym $mod+Shift+0 move container to workspace $w0
bindsym $mod+Tab workspace next
bindsym $mod+Shift+Tab workspace prev
bindsym Mod1+Shift+$right move workspace to output right
bindsym Mod1+Shift+$altright move workspace to output right
2018-10-08 03:21:53 +02:00
bindsym Mod1+Shift+j move workspace to output left
# back and forth between workspaces
bindsym Mod1+Tab workspace back_and_forth
2018-10-08 03:21:53 +02:00
# workspace bindings
assign [class="Firefox"] $w2
assign [class="Gnote"] $w9
assign [class="Slack"] $w4
assign [class="Riot"] $w4
assign [class="Lollypop"] $w3
assign [class="Transmission"] $w3
assign [class="Nicotine+"] $w3
# Program startup
2018-11-02 01:07:23 +01:00
#exec lollypop &
2018-10-08 03:21:53 +02:00
#
# Layout stuff:
#
# You can "split" the current object of your focus with
# $mod+b or $mod+v, for horizontal and vertical splits
# respectively.
bindsym $mod+h splith
2018-10-08 03:21:53 +02:00
bindsym $mod+v splitv
# Switch the current container between different layout styles
bindsym $mod+s layout stacking
bindsym $mod+w layout tabbed
bindsym $mod+e layout toggle split
# Make the current focus fullscreen
bindsym $mod+f fullscreen
# Toggle the current focus between tiling and floating mode
bindsym $mod+Shift+space floating toggle
# Swap focus between the tiling area and the floating area
2021-12-15 14:58:03 +01:00
bindsym Mod1+space focus mode_toggle
2018-10-08 03:21:53 +02:00
# move focus to the parent container
bindsym $mod+a focus parent
#
# Scratchpad:
#
# Sway has a "scratchpad", which is a bag of holding for windows.
# You can send windows there and get them back later.
# Move the currently focused window to the scratchpad
bindsym $mod+Shift+minus move scratchpad
# Show the next scratchpad window or hide the focused scratchpad window.
# If there are multiple scratchpad windows, this command cycles through them.
bindsym $mod+minus scratchpad show
#
# Resizing containers:
#
mode "resize" {
# left will shrink the containers width
# right will grow the containers width
# up will shrink the containers height
# down will grow the containers height
bindsym $left resize shrink width 10 px or 10 ppt
bindsym $down resize grow height 10 px or 10 ppt
bindsym $up resize shrink height 10 px or 10 ppt
bindsym $right resize grow width 10 px or 10 ppt
# ditto, with arrow keys
bindsym Left resize shrink width 10 px or 10 ppt
bindsym Down resize grow height 10 px or 10 ppt
bindsym Up resize shrink height 10 px or 10 ppt
bindsym Right resize grow width 10 px or 10 ppt
# return to default mode
bindsym Return mode "default"
bindsym Escape mode "default"
}
bindsym $mod+r mode "resize"
#
# Status Bar:
#
# Read `man 5 sway-bar` for more information about this section.
bar {
position top
# status_command i3blocks
status_command i3status
2018-10-08 03:21:53 +02:00
colors {
2020-11-11 00:16:56 +01:00
focused_background #272727E5
background #272727B8
2020-10-27 21:06:46 +01:00
#statusline #ebdbb2E5
2018-10-08 03:21:53 +02:00
statusline #DCDCDC
2020-10-27 21:06:46 +01:00
focused_workspace #555555E5 #555555E5 #ffffff
2020-11-11 00:16:56 +01:00
inactive_workspace #272727E5 #272727E5 #888888
2018-10-08 03:21:53 +02:00
}
2020-11-11 00:16:56 +01:00
font pango:FontAwesome Regular 12, Iosevka SS05 Medium 12
2018-10-08 03:21:53 +02:00
strip_workspace_numbers yes
height 26
2020-10-27 21:06:46 +01:00
#tray_padding 2
separator_symbol " "
2018-10-08 03:21:53 +02:00
}
include /etc/sway/config.d/*
# Colors
client.focused #444444 #444444 #A9D000 #8c9825 #444444
client.focused_inactive #444444 #444444 #A9D000 #5c7825 #444444
client.unfocused #222222 #222222 #888888 #292d2e #222222
client.background #222222
# gaps between windows
gaps inner 6
2018-10-08 03:21:53 +02:00
smart_gaps on
2018-10-08 03:21:53 +02:00
#smart_borders on
# No titles
#for_window [class="^.*"] border pixel 2
default_border pixel 3
default_floating_border normal
hide_edge_borders smart
2018-10-08 03:21:53 +02:00
# Mouse focus
focus_follows_mouse yes
# KBD layouti
input "type:keyboard" {
xkb_layout us,si
xkb_options grp:win_space_toggle,compose:caps
}
# Touchpad fensi
input "type:touchpad" {
tap enabled
natural_scroll enabled
dwt enabled
scroll_factor 0.25
2021-04-25 00:43:50 +02:00
pointer_accel 0.5
}
# Radio študent
bindsym Mod1+shift+r exec vlc /home/g1smo/Glasba/rs.m3u
bindsym Mod1+shift+x exec playerctl play-pause
bindsym Mod1+shift+c exec playerctl play-pause
# Zvok
set $vol_down_cmd amixer -q sset Master 5%-
set $vol_up_cmd amixer -q sset Master 5%+
set $vol_toggle_cmd amixer -q sset Master toggle
2020-10-27 21:06:46 +01:00
bindsym $mod+shift+d exec "$vol_up_cmd"
bindsym XF86AudioRaiseVolume exec "$vol_up_cmd"
bindsym $mod+shift+s exec "$vol_down_cmd"
bindsym XF86AudioLowerVolume exec "$vol_down_cmd"
bindsym XF86AudioMute exec "$vol_toggle_cmd"
bindsym $mod+shift+a exec "$vol_toggle_cmd"
# GTK tema
set $gnome-schema org.gnome.desktop.interface
exec_always {
gsettings set $gnome-schema gtk-theme 'Arc-Darker'
gsettings set $gnome-schema icon-theme 'Papirus'
gsettings set $gnome-schema cursor-theme 'Adwaita'
}
# Zvetlost zaslona
bindsym XF86MonBrightnessUp exec "light -A 3"
bindsym XF86MonBrightnessDown exec "light -U 3"
# Zunanji skrin
bindsym $mod+p exec "swaymsg output HDMI-A-2 enable"
bindsym $mod+shift+p exec "swaymsg output HDMI-A-2 disable"
2020-10-27 21:06:46 +01:00
# Skrinsot
bindsym 0xff61 exec ~/bin/screenshot
2021-09-29 21:48:08 +02:00
# Scaling toggle
bindsym $mod+i exec "swaymsg output eDP-1 scale 1"
bindsym $mod+o exec "swaymsg output eDP-1 scale 1.25"
2021-12-15 14:58:03 +01:00
bindsym $mod+space exec "/home/g1smo/bin/get-layout.sh"
2020-11-11 00:16:56 +01:00
######
# AUTOSTART
###
# transparenca nekativnih oken
exec ~/sredstva/dotfiles/inactive-windows-transparency.py
# Desktop notifikacije
2021-12-15 14:58:03 +01:00
exec mako --default-timeout=10000 --icon-path /usr/share/icons/Numix
2020-11-11 00:16:56 +01:00
# Autotiling https://github.com/nwg-piotr/autotiling
exec ~/.local/bin/autotiling
# Rdece, da lahko spim, hvala
exec gammastep-indicator -m wayland -l 46.05108:14.50513
2020-10-27 21:06:46 +01:00
2020-11-11 00:16:56 +01:00
# Zagoni programov razporejeni na workspejse
workspace 1:
2021-09-29 21:48:08 +02:00
#exec firefox
exec librewolf
2020-11-11 00:16:56 +01:00
workspace 2:λ
exec emacs
workspace 3:
2020-10-27 21:06:46 +01:00
exec thunderbird
2020-11-11 00:16:56 +01:00
workspace 4:
#exec revolt
exec element-desktop
2020-11-11 00:16:56 +01:00
workspace 9:
2021-04-25 00:43:50 +02:00
exec gnome-keyring-daemon --start
2020-11-11 00:16:56 +01:00
exec keepassxc
2021-09-29 21:48:08 +02:00
# autolock in te fore
#exec swayidle -w timeout 300 'swaylock -f -c 000000' timeout 600 'swaymsg"output * dpms off"' resume 'swaymsg "output * dpms on"' before-sleep 'swaylock -f-c 000000'
# prazna baterija tezenje
exec ~/bin/swaynag-battery