terminal

Sergey Manucharyan serge at bonbon.net
Wed Jan 14 08:36:59 CET 2004


By the way: I've written a script to launch xterm
with a random background color - may be it is interesting for
those who have many terminal open simultaneously (see below).

(It was inspired by recalling old SunOS's OpenWindows with such
a feature I used to deal with 11 years ago :) )

Monday, January 12, 2004, 2:45:43, OF wrote:
OF> On Sun, 2004-01-11 at 23:29, Yan Seiner wrote:
>> [...] I think the xfce term window sucks (it doesn't do Czech fonts
>> at all, and I haven't tried Japanese.) 

OF> Lol! For good reason, there is no such "xfce terminal", it's a wrapper
OF> shell script to whatever terminal you want, primarily used for DnD
OF> purpose.

OF> Just set TERMCMD to gnome-terminal and type "xfterm", you'll see.

============================================================

#!/bin/bash
# This script launches xterm with a random background
# colour chosen among 8 predefined ones

RED='rgb:FF/A0/A0'
ORANGE='rgb:FF/C5/80'
YELLOW='rgb:FF/FF/A0'
GREEN='rgb:C0/FF/C0'
CYAN='rgb:C0/FF/FF'
BLUE='rgb:A0/D5/FF'
VIOLET='rgb:F5/C0/FF'
GREY='rgb:E0/E0/E0'

xterm -bg \
`case $(($RANDOM/4096)) in
  0) echo $RED
    ;;
  1) echo $ORANGE
    ;;
  2) echo $YELLOW
    ;;
  3) echo $GREEN
    ;;
  4) echo $CYAN
    ;;
  5) echo $BLUE
    ;;
  6) echo $VIOLET
    ;;
  7) echo $GREY
    ;;
esac`

# End of random-colour xterm script

============================================================

Best regards,
Sergey




More information about the Xfce mailing list