diff options
-rw-r--r-- | Kvantum/KvArcDark#/KvArcDark#.kvconfig | 4 | ||||
-rw-r--r-- | X11/Xresources | 1 | ||||
-rwxr-xr-x | lock | 60 | ||||
-rw-r--r-- | nvim/colors/hybrid.vim | 46 | ||||
-rw-r--r-- | nvim/init.vim | 7 | ||||
-rw-r--r-- | tmux/tmux.conf | 47 |
6 files changed, 91 insertions, 74 deletions
diff --git a/Kvantum/KvArcDark#/KvArcDark#.kvconfig b/Kvantum/KvArcDark#/KvArcDark#.kvconfig index 1e72285..57c8c42 100644 --- a/Kvantum/KvArcDark#/KvArcDark#.kvconfig +++ b/Kvantum/KvArcDark#/KvArcDark#.kvconfig @@ -114,7 +114,7 @@ blur_only_active_window=false centered_forms=false kinetic_scrolling=false middle_click_scroll=false -no_selection_tint=false +no_selection_tint=true noninteger_translucency=false style_vertical_toolbars=false @@ -190,7 +190,7 @@ text.focus.color=white [Focus] inherits=PanelButtonCommand -frame=true +frame=false frame.element=focus frame.top=1 frame.bottom=1 diff --git a/X11/Xresources b/X11/Xresources index 6a8423c..1acf5c8 100644 --- a/X11/Xresources +++ b/X11/Xresources @@ -2,7 +2,6 @@ Xcursor.theme: SpaceKCursors -! *.font: "Monospace 12" *.font: "Inconsolata:pixelsize=17:antialias=true:autohint=true" ! special @@ -1,6 +1,6 @@ #!/bin/bash -# This script is a workaround for xsecurelock not being able to lock the screen when a fullscreen window is active. +# This script is a workaround for xsecurelock not being able to lock the screen when a fullscreen window is in focus. # Lock the screen with xsecurelock and take care of picom lock_screen() { @@ -30,24 +30,37 @@ lock_screen() { declare -a LIST_OF_WINDOW_TITLES_THAT_PREVENT_LOCKING=( "YouTube" "Netflix" + "Disney+" + "Prime Video" + "Hulu" + "HBO Max" "Twitch" - #"Spotify" + "Spotify" + "Spotube" "MPlayer" "VLC" "mpv" + "Zoom" "Google Meet" "Microsoft Teams" - "Zoom" #"Discord" #"Slack" - #"Plex" + "Plex" + "Kodi" + "Jellyfish" + "OBS" "CCTV" ) +#for i in "${LIST_OF_WINDOW_TITLES_THAT_PREVENT_LOCKING[@]}"; do + #echo $i +#done + # Dependencies -AWK=/usr/bin/awk -GREP=/usr/bin/grep -XPROP=/usr/bin/xprop +AWK=/bin/awk +GREP=/bin/grep +XPROP=/bin/xprop +XWININFO=/bin/xwininfo # Find active window id get_active_id() { @@ -56,7 +69,7 @@ get_active_id() { # Determine a window's title text by it's ID get_window_title() { - # For mplayer or vlc, we might need to check WM_CLASS(STRING), idk. + # For some apps you may need to check WM_CLASS(STRING) instead $XPROP -id $1 | $AWK -F '=' '$1 ~ /_NET_WM_NAME\(UTF8_STRING\)/ { print $2 }' } @@ -68,32 +81,41 @@ is_fullscreen() { # Determine if the locker command should run based on which windows are fullscreened. should_lock() { + id=$(get_active_id) + if [[ $id == "" ]]; then + echo "No active window found in the workspace" + return 0 + fi + echo "$id" + title=$(get_window_title $id) + echo "Active window:$title" if is_fullscreen $id; then + echo "Fullscreen window detected:$title" + return 1 + else for i in "${LIST_OF_WINDOW_TITLES_THAT_PREVENT_LOCKING[@]}"; do if [[ $title =~ $i ]]; then - return 0 + echo "$i was found in$title" + return 1 fi done - #echo "Fullscreen window detected: $title" return 0 - else - return 1 fi } # Debugging -if should_lock; then - echo "Locking the screen..." -else - echo "Not locking the screen..." -fi +#if should_lock; then + #echo "Locking the screen..." + #/bin/dunstify -u low "Locking the screen..." +#else + #echo "Not locking the screen..." + #/bin/dunstify -u low "Not locking the screen..." +#fi # main() if should_lock; then - dunstify -u critical "Screen will close" - sleep 15 lock_screen fi diff --git a/nvim/colors/hybrid.vim b/nvim/colors/hybrid.vim index 9f02434..cc9494b 100644 --- a/nvim/colors/hybrid.vim +++ b/nvim/colors/hybrid.vim @@ -97,29 +97,29 @@ else let s:gui_comment = "#707880" endif -let s:palette.gui.background = { 'dark' : "#0a001f" , 'light' : "#e94c80" } -let s:palette.gui.foreground = { 'dark' : "#ace6f0" , 'light' : "#0a001f" } -let s:palette.gui.selection = { 'dark' : "#6740ba" , 'light' : "#ace6f0" } -let s:palette.gui.line = { 'dark' : "#828ff9" , 'light' : "#ace6f0" } -let s:palette.gui.comment = { 'dark' : "#eebea4" , 'light' : "#ace6f0" } -let s:palette.gui.red = { 'dark' : "#e94c80" , 'light' : "#5f0000" } -let s:palette.gui.orange = { 'dark' : "#ac96dc" , 'light' : "#875f00" } -let s:palette.gui.yellow = { 'dark' : "#ac96dc" , 'light' : "#5f5f00" } +let s:palette.gui.background = { 'dark' : "#0a001f" , 'light' : "#0a001f" } +let s:palette.gui.foreground = { 'dark' : "#ace6f0" , 'light' : "#ace6f0" } +let s:palette.gui.selection = { 'dark' : "#6740ba" , 'light' : "#6740ba" } +let s:palette.gui.line = { 'dark' : "#828ff9" , 'light' : "#828ff9" } +let s:palette.gui.comment = { 'dark' : "#eebea4" , 'light' : "#eebea4" } +let s:palette.gui.red = { 'dark' : "#e94c80" , 'light' : "#e94c80" } +let s:palette.gui.orange = { 'dark' : "#ac96dc" , 'light' : "#ac96dc" } +let s:palette.gui.yellow = { 'dark' : "#ac96dc" , 'light' : "#ac96dc" } let s:palette.gui.green = { 'dark' : "#828ff9" , 'light' : "#828ff9" } -let s:palette.gui.aqua = { 'dark' : "#ace6f0" , 'light' : "#828ff9" } -let s:palette.gui.blue = { 'dark' : "#e94c80" , 'light' : "#00005f" } -let s:palette.gui.purple = { 'dark' : "#ac96dc" , 'light' : "#5f005f" } -let s:palette.gui.window = { 'dark' : "#0a001f" , 'light' : "#9e9e9e" } -let s:palette.gui.darkcolumn = { 'dark' : "#0a001f" , 'light' : "#808080" } -let s:palette.gui.addbg = { 'dark' : "#e94c80" , 'light' : "#d7ffd7" } -let s:palette.gui.addfg = { 'dark' : "#e94c80" , 'light' : "#828ff9" } -let s:palette.gui.changebg = { 'dark' : "#9e9e9e" , 'light' : "#e94c80" } -let s:palette.gui.changefg = { 'dark' : "#828ff9" , 'light' : "#5f005f" } -let s:palette.gui.delbg = { 'dark' : "#e94c80" , 'light' : "#ffd7d7" } -let s:palette.gui.darkblue = { 'dark' : "#828ff9" , 'light' : "#d7ffd7" } +let s:palette.gui.aqua = { 'dark' : "#ace6f0" , 'light' : "#ace6f0" } +let s:palette.gui.blue = { 'dark' : "#e94c80" , 'light' : "#e94c80" } +let s:palette.gui.purple = { 'dark' : "#ac96dc" , 'light' : "#ac96dc" } +let s:palette.gui.window = { 'dark' : "#0a001f" , 'light' : "#0a001f" } +let s:palette.gui.darkcolumn = { 'dark' : "#0a001f" , 'light' : "#0a001f" } +let s:palette.gui.addbg = { 'dark' : "#e94c80" , 'light' : "#e94c80" } +let s:palette.gui.addfg = { 'dark' : "#e94c80" , 'light' : "#e94c80" } +let s:palette.gui.changebg = { 'dark' : "#9e9e9e" , 'light' : "#9e9e9e" } +let s:palette.gui.changefg = { 'dark' : "#828ff9" , 'light' : "#828ff9" } +let s:palette.gui.delbg = { 'dark' : "#e94c80" , 'light' : "#e94c80" } +let s:palette.gui.darkblue = { 'dark' : "#828ff9" , 'light' : "#828ff9" } let s:palette.gui.darkcyan = { 'dark' : "#828ff9" , 'light' : "#828ff9" } -let s:palette.gui.darkred = { 'dark' : "#5f0000" , 'light' : "#d7d7ff" } -let s:palette.gui.darkpurple = { 'dark' : "#e94c80" , 'light' : "#5f005f" } +let s:palette.gui.darkred = { 'dark' : "#5f0000" , 'light' : "#5f0000" } +let s:palette.gui.darkpurple = { 'dark' : "#e94c80" , 'light' : "#e94c80" } if exists("g:hybrid_custom_term_colors") && g:hybrid_custom_term_colors == 1 " light dark @@ -361,11 +361,11 @@ exe "hi! Statement" .s:fg_blue .s:bg_none .s:fmt_none " Conditional" " Repeat" " Label" -exe "hi! Operator" .s:fg_aqua .s:bg_none .s:fmt_none +exe "hi! Operator" .s:fg_red .s:bg_none .s:fmt_none " Keyword" " Exception" -exe "hi! PreProc" .s:fg_yellow .s:bg_none .s:fmt_none +exe "hi! PreProc" .s:fg_yellow .s:bg_none .s:fmt_none exe "hi! Include" .s:fg_yellow .s:bg_none .s:fmt_none " Define" " Macro" diff --git a/nvim/init.vim b/nvim/init.vim index dce8052..b9e9784 100644 --- a/nvim/init.vim +++ b/nvim/init.vim @@ -28,9 +28,6 @@ set clipboard+=unnamedplus set shiftwidth=4 set expandtab -" auto convert tabs to spaces at file open - autocmd BufReadPost * :retab - " removing white spaces autocmd BufWritePre * %s/\s\+$//e @@ -122,7 +119,7 @@ hi CursorLine cterm=NONE ctermbg=256 hi CursorColumn cterm=NONE ctermbg=257 nnoremap <Leader>b :set cursorline! <CR> - "(Disable/enable) Local cursor line +"(Disable/enable) Local cursor line at startup "augroup CursorLine "au! "au VimEnter,WinEnter,BufWinEnter * setlocal cursorline @@ -158,7 +155,7 @@ nnoremap <Leader>b :set cursorline! <CR> """NeoVide if exists("g:neovide") - set guifont="Inconsolata Nerd:h12" + set guifont="Inconsolata" "let g:neovide_transparency = 0.8 let g:neovide_cursor_vfx_mode = "pixiedust" endif diff --git a/tmux/tmux.conf b/tmux/tmux.conf index b77c33c..81ed9b8 100644 --- a/tmux/tmux.conf +++ b/tmux/tmux.conf @@ -22,17 +22,15 @@ run '~/.tmux/plugins/tpm/tpm' set -g mouse on -#set-option -sa terminal-overrides ",xterm*:Tc" +unbind C-b +set -g prefix C-Space +bind C-Space send-prefix -#unbind C-b -#set -g prefix C-Space -#bind C-Space send-prefix - -## Vim style pane selection -#bind h select-pane -L -#bind j select-pane -D -#bind k select-pane -U -#bind l select-pane -R +# Vim style pane selection +bind h select-pane -L +bind j select-pane -D +bind k select-pane -U +bind l select-pane -R ## Start windows and panes at 1, not 0 set -g base-index 1 @@ -40,27 +38,28 @@ set -g pane-base-index 1 set-window-option -g pane-base-index 1 set-option -g renumber-windows on -## Use Alt-arrow keys without prefix key to switch panes -#bind -n M-Left select-pane -L -#bind -n M-Right select-pane -R -#bind -n M-Up select-pane -U -#bind -n M-Down select-pane -D +## Use Ctrl + arrow keys without prefix key to switch panes +bind -n C-Left select-pane -L +bind -n C-Right select-pane -R +bind -n C-Up select-pane -U +bind -n C-Down select-pane -D ## Shift arrow to switch windows bind -n S-Left previous-window bind -n S-Right next-window -## Shift Alt vim keys to switch windows -#bind -n M-H previous-window -#bind -n M-L next-window +## Shift Ctrl vim keys to switch windows +bind -n C-H previous-window +bind -n C-L next-window ## set vi-mode -#set-window-option -g mode-keys vi +set-window-option -g mode-keys vi ## keybindings -#bind-key -T copy-mode-vi v send-keys -X begin-selection -#bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle -#bind-key -T copy-mode-vi y send-keys -X copy-selection-and-cancel +bind-key -T copy-mode-vi v send-keys -X begin-selection +bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle +bind-key -T copy-mode-vi y send-keys -X copy-selection-and-cancel -#bind '"' split-window -v -c "#{pane_current_path}" -#bind % split-window -h -c "#{pane_current_path}" +## open new windows in the current directory +bind '"' split-window -v -c "#{pane_current_path}" +bind % split-window -h -c "#{pane_current_path}" |