#!/bin/sh# swm (select WM)# a simple script to modify your ~/.xinitrc before `startx'WSTEMP=/tmp/wmselect.tmp.$$XINITRC=~/.xinitrcif [ ! -a $XINITRC ]; then touch $XINITRCfidialog --backtitle "swm -- dialog 0.6z" \ --title "Window manager selector" --clear \ --radiolist "Please select a window manager to start.\n\Selecting an item will modify the .xinitrc file in your\n\home directory. In case the script fails, you may need\n\to edit the .xinitrc file manually, by adding a line:\n\\"exec <your WM of choice>\" at the end.\n\n\ So, how do you fill today?" 20 61 7 \"Blackbox" "Not beige at least." off \"Fluxbox" "I feel very fluxible." on \"Fvwm" "More like classically inclined." off \"Twm" "Cholesterol free and mean." off \"Waimea" "Yes, baby, yes." off \"WindowMaker" "Next step, please." off \"Wm2" "Like an alien superhero." off 2> $WSTEMP cleantemp(){ rm -f $WSTEMP}startwm() { wm=$1case "$wm" in "Blackbox") sed '/exec/d' $XINITRC > $WSTEMP echo exec blackbox >> $WSTEMP mv $WSTEMP $XINITRC cleantemp exec startx $XINITRC;; "Fluxbox") sed '/exec/d' $XINITRC > $WSTEMP echo exec fluxbox >> $WSTEMP mv $WSTEMP $XINITRC cleantemp exec startx $XINITRC;; "Fvwm") sed '/exec/d' $XINITRC > $WSTEMP echo exec fvwm >> $WSTEMP mv $WSTEMP $XINITRC cleantemp exec startx $XINITRC;; "Twm") sed '/exec/d' $XINITRC > $WSTEMP echo exec twm >> $WSTEMP mv $WSTEMP $XINITRC cleantemp exec startx $XINITRC;; "Wm2") sed '/exec/d' $XINITRC > $WSTEMP echo exec wm2 >> $WSTEMP mv $WSTEMP $XINITRC cleantemp exec startx $XINITRC;; "Waimea") sed '/exec/d' $XINITRC > $WSTEMP echo exec waimea >> $WSTEMP mv $WSTEMP $XINITRC cleantemp exec startx $XINITRC;; "WindowMaker") sed '/exec/d' $XINITRC > $WSTEMP echo exec wmaker >> $WSTEMP mv $WSTEMP $XINITRC cleantemp exec startx $XINITRC;;esac}retval=$?choice=`cat $WSTEMP`cleantempcase $retval in 0) startwm $choice;; 1);; # Cancel has been pressed 255);; # ESC has been pressedesac
/* __START kill.xbm */#define kill_width 14#define kill_height 15static unsigned char kill_bits[] = { 0xff, 0x3f, 0xff, 0x3f, 0x0f, 0x3c, 0x07, 0x38, 0x37, 0x3b, 0x37, 0x3b, 0xcf, 0x3c, 0x1f, 0x3e, 0x1b, 0x36, 0xf1, 0x23, 0xcf, 0x3c, 0x1d, 0x3a, 0xf1, 0x23, 0xfb, 0x37, 0xff, 0x3f, };/* __END__ kill.xbm */
/* __START__ cu0.xbm */#define cu0_width 13#define cu0_height 13static unsigned char cu0_bits[] = { 0x00, 0x00, 0x0e, 0x0e, 0x1e, 0x0f, 0xbe, 0x0f, 0xfc, 0x07, 0xf8, 0x03, 0xf0, 0x01, 0xf8, 0x03, 0xfc, 0x07, 0xbe, 0x0f, 0x1e, 0x0f, 0x0e, 0x0e, 0x00, 0x00};/* __END__ cu0.xbm */
/* __START__ cu0m.xbm -- mask file */#define cu0m_width 13#define cu0m_height 13static unsigned char cu0m_bits[] = { 0x0f, 0x1e, 0x1f, 0x1f, 0xbf, 0x1f, 0xff, 0x1f, 0xfe, 0x0f, 0xfc, 0x07, 0xf8, 0x03, 0xfc, 0x07, 0xfe, 0x0f, 0xff, 0x1f, 0xbf, 0x1f, 0x1f, 0x1f, 0x0f, 0x1e};/* __END__ cu0m.xbm */
#define x86_width 10#define x86_height 8static unsigned char x86_bits[] = { 0xff, 0x03, 0xff, 0x03, 0xbb, 0x03, 0xd7, 0x03, 0xef, 0x03, 0xd7, 0x03, 0xbb, 0x03, 0xff, 0x03};/* __END__ x86.xbm. Command: xsetroot -bitmap x86.xbm */
/* s.xbm , "Slackware" */#define s_width 5#define s_height 8static unsigned char s_bits[] = { 0xff, 0xf3, 0xed, 0xfd, 0xf3, 0xef, 0xed, 0xf3};/* __END__. Comand xsetroot -bitmap s.xbm */