X based Graphical User Interfaces



next up previous contents
Next: Programming the Shells Up: Solutions to Exercises Previous: UNIX Batch Systems

X based Graphical User Interfaces

  1. Motif is actually written using the X Window software. So if your friend is telling you they don't have any of X, then he is lying.
  2. The command
    xterm -geometry 80x24 &
    will open an xterm window. That window will include a shell for you to issue UNIX commands.

    The ampersand (&) is recommended so you can still use the parent window to issue commands.

    If an error message similar to

    Could not open display.
    was displayed, your DISPLAY environment variable is not set. Issue
    setenv DISPLAY localhost:0 (C shell)
    or
    DISPLAY=localhost:0; export DISPLAY
    where localhost is the name of the system you're using. That command will tell the application (xterm) which system to use to display.
  3. Add the line
    XTermgeometry: 80x24
    Then, from the command line, simply issue
    xterm &
  4. The command
    xterm -g black -gb white &
    will open a white xterm with black characters.

    To create the same effect, the lines

    XTermforeground: white
    XTermbackground: black
    could be added to the .Xdefaults file, so that every xterm command issued will contain the same attributes.
  5. The command
    xlsfonts | more
    will list fonts available to you during this session.
  6. An xclock application can be started by
    xclock -geometry 100x100+0-0 &
    or the line
    Xclockgeometry: 100x100+0-0
    could be added to the .Xdefaults file.



Super-User
Fri Feb 17 15:55:40 EST 1995