execif["$(gsettings get org.gnome.desktop.a11y.applications screen-reader-enabled)" !="true"];then gsettings set org.gnome.desktop.a11y.applications screen-reader-enabled true&& notify-send "QT5 accessibility enabled. You need to restart ratpoison for the changes to take affect.";fi
exec /usr/bin/orca
# Alias Section
alias close_window exec ratpoison -c delete
alias ratpoison_keybindings execf=$(mktemp);ratpoison -c "help root" > $f&& yad --text-info --show-cursor --title "Ratpoison Keybindings" --button "Close:0" --filename "$f";rm "$f"
alias music_player_previous_track exec playerctl previous && notify-send "$(playerctl metadata -f '{{title}} by {{artist}}')"
alias music_player_play exec playerctl play && notify-send "$(playerctl metadata -f '{{title}} by {{artist}}')"
alias music_player_pause exec playerctl play-pause && notify-send "$(playerctl metadata -f '{{title}} by {{artist}} {{status}}')"
alias music_player_stop exec playerctl stop
alias music_player_next_track exec playerctl next && notify-send "$(playerctl metadata -f '{{title}} by {{artist}}')"
alias music_player_decrease_volume exec playerctl volume 0.05-
alias music_player_increase_volume exec playerctl volume 0.05+
alias music_player_show_info exec notify-send "$(playerctl metadata -f '{{title}} by {{artist}} from {{album}} via {{playerName}}')"
alias run_dialog exechistoryPath="${XDG_CONFIG_HOME:-$HOME/.config}/strychnine";if ! [ -d "$historyPath"];then mkdir -p "$historyPath";fi;write_history(){oldHistory="$(grep -v "$txt""$historyPath/history"| head -n 49)";echo -e "$txt\n$oldHistory"| sed 's/^$//g' > "$historyPath/history";};if[ -f "$historyPath/history"];thentxt=$(yad --entry --editable --title "Ratpoison" --text "Execute program or enter file" --button "Open:0" --separator "\n" --rest "$historyPath/history");elsetxt=$(yad --entry --title "Ratpoison" --text "Execute program or enter file" --button "Open:0");fi;if[ -z "$txt"];thenexit 0;fi;if[["$txt"=~ ^ftp://|http://|https://|www.* ]];then /usr/bin/brave $txt;write_history;exit 0;fi;if[["$txt"=~ ^mailto://.* ]];then xdg-email $txt;write_history;exit 0;fi;if[["$txt"=~ ^man://.* ]];theneval"${txt/:\/\// }"| yad --text-info --show-cursor --button "Close:0" --title "Ratpoison" -;write_history;exit 0;fi;ifcommand -v "$(echo"$txt"| cut -d " " -f1)"&> /dev/null ;theneval$txt&else xdg-open $txt&fi;write_history;exit0