create qt configuration files if it doesn't exist #11
|
@ -20,8 +20,13 @@ while read -r line; do
|
||||||
# Get the current icon theme
|
# Get the current icon theme
|
||||||
icon_theme=$(xfconf-query -c xsettings -p /Net/IconThemeName)
|
icon_theme=$(xfconf-query -c xsettings -p /Net/IconThemeName)
|
||||||
# Apply the same theme in qt5ct and qt6ct configuration
|
# Apply the same theme in qt5ct and qt6ct configuration
|
||||||
sed -i "s/^icon_theme=.*$/icon_theme=$icon_theme/" "$HOME"/.config/qt5ct/qt5ct.conf
|
for file in "$HOME"/.config/qt5ct/qt5ct.conf "$HOME"/.config/qt6ct/qt6ct.conf; do
|
||||||
sed -i "s/^icon_theme=.*$/icon_theme=$icon_theme/" "$HOME"/.config/qt6ct/qt6ct.conf
|
if [ -f "$file" ]; then
|
||||||
|
sed -i "s/^icon_theme=.*$/icon_theme=$icon_theme/" "$file"
|
||||||
|
else
|
||||||
|
printf '[Appearance]\nicon_theme=%s\nstyle=gtk2\n' "$icon_theme" > "$file"
|
||||||
|
fi
|
||||||
|
done
|
||||||
;;
|
;;
|
||||||
# When the system font has been changed
|
# When the system font has been changed
|
||||||
'set: /Gtk/FontName')
|
'set: /Gtk/FontName')
|
||||||
|
@ -32,4 +37,4 @@ while read -r line; do
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
done < <(xfconf-query -c xsettings -m)
|
done < <(xfconf-query -c xsettings -m)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user