1
1
mirror of https://github.com/rywng/dotfiles.git synced 2024-11-22 10:51:49 +08:00

Better theme switching script

This commit is contained in:
Ryan 2024-01-12 11:02:23 +08:00
parent c46f18d7cd
commit e7bc1ebc33
7 changed files with 113 additions and 14 deletions

View File

@ -1,3 +1,16 @@
gtk-icon-theme-name = "Adwaita" include "/home/ryan/.gtkrc-2.0.mine"
gtk-theme-name = "Adwaita-dark" gtk-theme-name="Adwaita"
gtk-font-name = "IBM Plex 12" gtk-icon-theme-name="Adwaita"
gtk-font-name="ibm-plex 12"
gtk-cursor-theme-name="Adwaita"
gtk-cursor-theme-size=24
gtk-toolbar-style=GTK_TOOLBAR_ICONS
gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
gtk-button-images=0
gtk-menu-images=0
gtk-enable-event-sounds=1
gtk-enable-input-feedback-sounds=0
gtk-xft-antialias=1
gtk-xft-hinting=1
gtk-xft-hintstyle="hintmedium"
gtk-xft-rgba="rgb"

View File

@ -1,3 +1,17 @@
gtk-icon-theme-name = "Adwaita"
gtk-theme-name = "Adwaita" include "/home/ryan/.gtkrc-2.0.mine"
gtk-font-name = "IBM Plex 12" gtk-theme-name="Adwaita"
gtk-icon-theme-name="Adwaita"
gtk-font-name="ibm-plex 12"
gtk-cursor-theme-name="Adwaita"
gtk-cursor-theme-size=24
gtk-toolbar-style=GTK_TOOLBAR_ICONS
gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
gtk-button-images=0
gtk-menu-images=0
gtk-enable-event-sounds=1
gtk-enable-input-feedback-sounds=0
gtk-xft-antialias=1
gtk-xft-hinting=1
gtk-xft-hintstyle="hintmedium"
gtk-xft-rgba="rgb"

17
.config/gtk-3.0/dark.ini Normal file
View File

@ -0,0 +1,17 @@
[Settings]
gtk-theme-name=Adwaita
gtk-icon-theme-name=Adwaita
gtk-font-name=ibm-plex 12
gtk-cursor-theme-name=Adwaita
gtk-cursor-theme-size=24
gtk-toolbar-style=GTK_TOOLBAR_ICONS
gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
gtk-button-images=0
gtk-menu-images=0
gtk-enable-event-sounds=1
gtk-enable-input-feedback-sounds=0
gtk-xft-antialias=1
gtk-xft-hinting=1
gtk-xft-hintstyle=hintmedium
gtk-xft-rgba=rgb
gtk-application-prefer-dark-theme=1

17
.config/gtk-3.0/light.ini Normal file
View File

@ -0,0 +1,17 @@
[Settings]
gtk-theme-name=Adwaita
gtk-icon-theme-name=Adwaita
gtk-font-name=ibm-plex 12
gtk-cursor-theme-name=Adwaita
gtk-cursor-theme-size=24
gtk-toolbar-style=GTK_TOOLBAR_ICONS
gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
gtk-button-images=0
gtk-menu-images=0
gtk-enable-event-sounds=1
gtk-enable-input-feedback-sounds=0
gtk-xft-antialias=1
gtk-xft-hinting=1
gtk-xft-hintstyle=hintmedium
gtk-xft-rgba=rgb
gtk-application-prefer-dark-theme=0

View File

@ -23,28 +23,26 @@ if [ $scheme = "light" ]; then
# kitty config # kitty config
kitty -1 sh -c "kitty @ set-colors -a -c ~/.config/kitty/themes/light.conf" & kitty -1 sh -c "kitty @ set-colors -a -c ~/.config/kitty/themes/light.conf" &
# zathura # zathura
mv ~/.config/zathura/zathurarc.light ~/.config/zathura/zathurarc cp ~/.config/zathura/zathurarc.light ~/.config/zathura/zathurarc
# qt5ct and qt6ct # qt5ct and qt6ct
cp ~/.config/qt5ct/light.conf ~/.config/qt5ct/qt5ct.conf cp ~/.config/qt5ct/light.conf ~/.config/qt5ct/qt5ct.conf
cp ~/.config/qt6ct/light.conf ~/.config/qt6ct/qt6ct.conf cp ~/.config/qt6ct/light.conf ~/.config/qt6ct/qt6ct.conf
# gtk2 # gtk2
cp ~/.config/gtk-2.0/light.conf ~/.gtkrc-2.0 cp ~/.config/gtk-2.0/light.conf ~/.gtkrc-2.0
# set wallpaper location # gtk3
# unlink ~/.config/sway/Wallpaper cp ~/.config/gtk-3.0/light.ini ~/.config/gtk-3.0/settings.ini
# ln -s ~/Pictures/wall/sway/light ~/.config/sway/Wallpaper
else else
# kitty config # kitty config
kitty -1 sh -c "kitty @ set-colors -a -c ~/.config/kitty/themes/dark.conf" & kitty -1 sh -c "kitty @ set-colors -a -c ~/.config/kitty/themes/dark.conf" &
# zathura # zathura
mv ~/.config/zathura/zathurarc.dark ~/.config/zathura/zathurarc cp ~/.config/zathura/zathurarc.dark ~/.config/zathura/zathurarc
# qt5ct and qt6ct # qt5ct and qt6ct
cp ~/.config/qt5ct/dark.conf ~/.config/qt5ct/qt5ct.conf cp ~/.config/qt5ct/dark.conf ~/.config/qt5ct/qt5ct.conf
cp ~/.config/qt6ct/dark.conf ~/.config/qt6ct/qt6ct.conf cp ~/.config/qt6ct/dark.conf ~/.config/qt6ct/qt6ct.conf
# gtk2 # gtk2
cp ~/.config/gtk-2.0/dark.conf ~/.gtkrc-2.0 cp ~/.config/gtk-2.0/dark.conf ~/.gtkrc-2.0
# set dark wallpaper # gtk3
# unlink ~/.config/sway/Wallpaper cp ~/.config/gtk-3.0/dark.ini ~/.config/gtk-3.0/settings.ini
# ln -s ~/Pictures/wall/sway/dark ~/.config/sway/Wallpaper
fi fi
swaymsg reload swaymsg reload

View File

@ -0,0 +1,40 @@
set notification-error-bg "#282828" # bg
set notification-error-fg "#fb4934" # bright:red
set notification-warning-bg "#282828" # bg
set notification-warning-fg "#fabd2f" # bright:yellow
set notification-bg "#282828" # bg
set notification-fg "#b8bb26" # bright:green
set completion-bg "#504945" # bg2
set completion-fg "#ebdbb2" # fg
set completion-group-bg "#3c3836" # bg1
set completion-group-fg "#928374" # gray
set completion-highlight-bg "#83a598" # bright:blue
set completion-highlight-fg "#504945" # bg2
# Define the color in index mode
set index-bg "#504945" # bg2
set index-fg "#ebdbb2" # fg
set index-active-bg "#83a598" # bright:blue
set index-active-fg "#504945" # bg2
set inputbar-bg "#282828" # bg
set inputbar-fg "#ebdbb2" # fg
set statusbar-bg "#504945" # bg2
set statusbar-fg "#ebdbb2" # fg
set highlight-color "#fabd2f" # bright:yellow
set highlight-active-color "#fe8019" # bright:orange
set default-bg "#282828" # bg
set default-fg "#ebdbb2" # fg
set render-loading true
set render-loading-bg "#282828" # bg
set render-loading-fg "#ebdbb2" # fg
# Recolor book content's color
set recolor-lightcolor "#282828" # bg
set recolor-darkcolor "#ebdbb2" # fg
set recolor "true"
# set recolor-keephue true # keep original color