X-Git-Url: https://git.distorted.org.uk/~mdw/profile/blobdiff_plain/f4450ac9546d6e467919739c00c31f85f94c8590..b20bfd83146e0f60cea539eb3c6eea39f8ad549d:/xinitrc diff --git a/xinitrc b/xinitrc index 6141ab5..f1252d6 100755 --- a/xinitrc +++ b/xinitrc @@ -116,6 +116,8 @@ start-window-manager () { ###-------------------------------------------------------------------------- ### Random useful clients. +start-clients-local () { :; } + start-clients () { ## Mail notification. run bginit mail-notification @@ -123,16 +125,11 @@ start-clients () { ## System monitor. case $vnc in no) run bginit gkrellm ;; esac - ## Screensaver. - case $vnc in - no) - run init xscreensaver-command -exit - run bginit xscreensaver -no-splash - ;; - esac - ## Panel. case $vnc in no) run bginit gnome-panel ;; esac + + ## Local clients. + start-clients-local } ###-------------------------------------------------------------------------- @@ -158,7 +155,7 @@ esac ## Terminal window measurements. case "$term" in - pterm) t_wd=503 t_lineht=13 t_vextra=23 geom=-geometry;; + pterm) t_wd=504 t_lineht=13 t_vextra=23 geom=-geometry;; Eterm) t_wd=504 t_lineht=13 t_vextra=23 geom=-g;; xterm) t_wd=507 t_lineht=13 t_vextra=27 geom=-geometry;; esac @@ -203,7 +200,7 @@ start-emacs () { start-xterms () { ## Initialize some parameters. - declare -i x="ecols * e_colwd + e_hextra" + declare -i x="ecols * e_colwd + e_hextra" xb=xbound declare -i n=0 pgx=0 l h y ht declare -i hstd="35 * t_lineht + t_vextra" hmin="25 * t_lineht + t_vextra" @@ -211,9 +208,9 @@ start-xterms () { while :; do ## Start a new iteration. - if ((x + t_wd > xbound)); then + if ((x + t_wd > xb)); then if ((n >= 3)); then break; fi - x="pgx + XWIDTH" pgx="pgx + XWIDTH" xbound="xbound + XWIDTH" + x="pgx + XWIDTH" pgx="pgx + XWIDTH" xb="xb + XWIDTH" fi ## Make large xterms. @@ -237,6 +234,15 @@ start-xterms () { } ###-------------------------------------------------------------------------- +### Requesters. + +req () { + declare title=$1 hist=$2; shift 2 + cmd=$(xgetline -t "$title" -p "Command:" -Hl "$HOME/$hist") && + exec "$@" "$cmd" +} + +###-------------------------------------------------------------------------- ### Final waiting. atom=XINIT_COMMAND$atomtag @@ -253,6 +259,7 @@ xwait () { xmsg -I -t "xinitrc help" -d "xinitrc commands" - <