work on gtk stuff, more utils setup stuff, fixed some sxhk stuff, dynamic font stuff

This commit is contained in:
Daniel Flanagan 2016-01-07 01:09:52 -06:00
parent 4aeef2d74d
commit bde1b11dad
8 changed files with 80 additions and 23 deletions

View file

@ -1,4 +1,22 @@
#!/usr/bin/env bash #!/usr/bin/env bash
sudo pacman -S the_silver_searcher --noconfirm DIR=$(cd "$(dirname "${BASH_SOURCE[0]}" )/.." && pwd)
source $DIR/variables.bash
sudo pacman -S \
rofi \
slock \
the_silver_searcher \
thunar \
luakit \
--noconfirm
pacaur -S \
gtk-theme-arc \
firefox-developer \
google-chrome-dev \
--noconfirm --noedit
sudo ln -s /usr/bin/firefox-developer /usr/bin/firefox
sudo ln -s /usr/bin/google-chrome-unstable /usr/bin/chrome

View file

@ -8,5 +8,5 @@ rm -f "$DOTFILES_PATH/vim/config/colors/current.vim"
ln -s "$DOTFILES_PATH/colors/xresources" "$HOME/.Xresources.colors" ln -s "$DOTFILES_PATH/colors/xresources" "$HOME/.Xresources.colors"
ln -s "$DOTFILES_PATH/colors/vim" "$DOTFILES_PATH/vim/config/colors/current.vim" ln -s "$DOTFILES_PATH/colors/vim" "$DOTFILES_PATH/vim/config/colors/current.vim"
xrdb ~/.Xresources source "$DOTFILES_PATH/x/xloadresources"

22
scripts/get_x_fonts.sh Normal file
View file

@ -0,0 +1,22 @@
#!/usr/bin/env sh
XRES_FILE="$HOME/.Xresources"
if [ -a "$HOME/.Xresources.env" ]; then
XRES_FILE="$HOME/.Xresources.env"
fi
PRIMARY_FONT_XRESOURCES=$(grep "#define primaryfont xft:" "$XRES_FILE" | grep -v "/\*" | head -n 1)
export PRIMARY_FONT_FAMILY_WITH_SIZE=${PRIMARY_FONT_XRESOURCES:24}
export PRIMARY_FONT_FAMILY=$(echo $PRIMARY_FONT_FAMILY_WITH_SIZE | sed 's/\-.*//')
export PRIMARY_FONT_SIZE=$(echo $PRIMARY_FONT_FAMILY_WITH_SIZE | sed 's/.*\-//')
SECONDARY_FONT_XRESOURCES=$(grep "#define secondaryfont xft:" "$XRES_FILE" | grep -v "/\*" | head -n 1)
export SECONDARY_FONT_FAMILY_WITH_SIZE=${SECONDARY_FONT_XRESOURCES:26}
export SECONDARY_FONT_FAMILY=$(echo $SECONDARY_FONT_FAMILY_WITH_SIZE | sed 's/\-.*//')
export SECONDARY_FONT_SIZE=$(echo $SECONDARY_FONT_FAMILY_WITH_SIZE | sed 's/.*\-//')
ICON_FONT_XRESOURCES=$(grep "#define iconfont xft:" "$XRES_FILE" | grep -v "/\*" | head -n 1)
export ICON_FONT_FAMILY_WITH_SIZE=${ICON_FONT_XRESOURCES:21}
export ICON_FONT_FAMILY=$(echo $ICON_FONT_FAMILY_WITH_SIZE | sed 's/\-.*//')
export ICON_FONT_SIZE=$(echo $ICON_FONT_FAMILY_WITH_SIZE | sed 's/.*\-//')

View file

@ -18,7 +18,10 @@ super + b
# toggle floating/fullscreen modes for current node # toggle floating/fullscreen modes for current node
super + {s,f} super + {s,f}
bspc node -t {floating,fullscreen} bspc node -t {tiled,floating}
super + shift + {s,f}
bspc node -t {pseudo_tiled,fullscreen}
# focus the last node/desktop # focus the last node/desktop
super + {grave,Tab} super + {grave,Tab}
@ -134,7 +137,8 @@ super + Return
# spawn the app launcher # spawn the app launcher
super + space super + space
dmenu_run -fn "$PRIMARY_FONT_FAMILY_WITH_SIZE" -i -nb "#$(get_color 00)" -sb "#$(get_color 00)" -sf "#$(get_color 0A)" -nf "#$(get_color 04)" -h "$BAR_HEIGHT" rofi -show run -font "Monaco 9" -fuzzy -bw $BORDER_WIDTH -bg "#$(get_color 00)" -fg "#$(get_color 0A)" -hlfg "#$(get_color 0D)" -hlbg "#$(get_color 01)"
# dmenu_run -fn "$PRIMARY_FONT_FAMILY_WITH_SIZE" -i -nb "#$(get_color 00)" -sb "#$(get_color 00)" -sf "#$(get_color 0A)" -nf "#$(get_color 04)" -h "$BAR_HEIGHT"
# make sxhkd reload its configuration files: # make sxhkd reload its configuration files:
super + Escape super + Escape

3
x/gtk2rc Normal file
View file

@ -0,0 +1,3 @@
gtk-icon-theme-name = "Adwaita"
gtk-theme-name = "Raleigh"
gtk-font-name = "Monaco 9"

4
x/gtk3settings.ini Normal file
View file

@ -0,0 +1,4 @@
[Settings]
gtk-icon-theme-name = Adwaita
gtk-theme-name = Adwaita
gtk-font-name = Monaco 9

View file

@ -3,18 +3,24 @@
DIR=$(cd "$(dirname "${BASH_SOURCE[0]}" )/.." && pwd) DIR=$(cd "$(dirname "${BASH_SOURCE[0]}" )/.." && pwd)
source "$DIR/variables.bash" source "$DIR/variables.bash"
rm "$HOME/.xinitrc" mkdir -p "$HOME/.config/gtk-3.0"
rm "$HOME/.Xresources" rm -f "$HOME/.xinitrc"
ln -s "$HOME/.dotfiles/x/xinitrc" "$HOME/.xinitrc" rm -f "$HOME/.Xresources"
ln -s "$HOME/.dotfiles/x/xresources" "$HOME/.Xresources" rm -f "$HOME/.config/gtkrc-2.0"
rm -f "$HOME/.config/gtk-3.0/settings.ini"
ln -s "$DOTFILES_PATH/x/xinitrc" "$HOME/.xinitrc"
ln -s "$DOTFILES_PATH/x/xresources" "$HOME/.Xresources"
ln -s "$DOTFILES_PATH/x/gtk3settings.ini" "$HOME/.config/gtk-3.0/settings.ini"
ln -s "$DOTFILES_PATH/x/gtk2rc" "$HOME/.config/gtkrc-2.0"
xrdb "$HOME/.Xresources" >/dev/null 2>&1 sudo mkdir -p /root/.gtk-3.0/
sudo mkdir -p /root/.config/gtk-3.0/
sudo rm -f "/root/.gtkrc-2.0"
sudo rm -f "/root/.gtk-3.0/settings.ini"
sudo rm -f "/root/.config/gtk-3.0/settings.ini"
sudo ln -s "$DOTFILES_PATH/x/gtk2rc" "/root/.gtkrc-2.0"
sudo ln -s "$DOTFILES_PATH/x/gtk3settings.ini" "/root/.gtk-3.0/settings.ini"
sudo ln -s "$DOTFILES_PATH/x/gtk3settings.ini" "/root/.config/gtk-3.0/settings.ini"
if [ -f "$HOME/.Xresources.colors" ]; then source "$DOTFILES_PATH/x/xloadresources"
xrdb -merge "$HOME/.Xresources.colors" >/dev/null 2>&1
fi
if [ -f "$HOME/.Xresources.env" ]; then
xrdb -merge "$HOME/.Xresources.env" >/dev/null 2>&1
fi

View file

@ -8,27 +8,27 @@ sysresources=/etc/X11/xinit/.Xresources
sysmodmap=/etc/X11/xinit/.Xmodmap sysmodmap=/etc/X11/xinit/.Xmodmap
if [ -f $sysresources ]; then if [ -f $sysresources ]; then
xrdb -merge $sysresources xrdb -merge $sysresources >/dev/null 2>&1
fi fi
if [ -f $sysmodmap ]; then if [ -f $sysmodmap ]; then
xmodmap $sysmodmap xmodmap $sysmodmap >/dev/null 2>&1
fi fi
if [ -f "$userresources" ]; then if [ -f "$userresources" ]; then
xrdb -merge "$userresources" xrdb -merge "$userresources" >/dev/null 2>&1
fi fi
if [ -f "$usercolors" ]; then if [ -f "$usercolors" ]; then
xrdb -merge "$usercolors" xrdb -merge "$usercolors" >/dev/null 2>&1
fi fi
if [ -f "$userenv" ]; then if [ -f "$userenv" ]; then
xrdb -merge "$userenv" xrdb -merge "$userenv" >/dev/null 2>&1
fi fi
if [ -f "$usermodmap" ]; then if [ -f "$usermodmap" ]; then
xmodmap "$usermodmap" xmodmap "$usermodmap" >/dev/null 2>&1
fi fi
if [ -d /etc/X11/xinit/xinitrc.d ] ; then if [ -d /etc/X11/xinit/xinitrc.d ] ; then