long-morrow@YALE.ARPA ("H. Morrow Long") (07/22/87)
Someone in comp.windows.x asked about a basic manual for an
ordinary user on how to start X on his workstation (assuming it is
installed, etc.). We have written the following guide for beginning
X users, it contains details specific to our network, default
configuration of X windows and is presently hardcoded for the
IBM RT setup but I thought that it would provide a good starting
point for people who are asked for a rough users manual
(you should troff the X manual pages and append them also).
H. Morrow Long
long-morrow@cs.yale.edu
The latex source and a delatex'ed plain text version are appended:
------x_intro_rt.ltex-----------------------------------------------------
%
% $Header: x_intro_rt.ltex,v 1.1 87/07/21 16:47:52 long Exp $
%
% $Log: x_intro_rt.ltex,v $
% Revision 1.1 87/07/21 16:47:52 long
% Initial revision
%
%
\documentstyle{report}
\pagestyle{headings}
\thispagestyle{empty}
\oddsidemargin 0pt % Left margin on odd-numbered \evensidemargin 0pt % Left margin on even-numbered pages.
\textwidth 480pt
\begin{document}
\begin{center}
\huge An Introduction to X Windows\\
at Yale Computer Science\\
on the IBM PC RT Using ACIS 4.2\\
{\tiny By H. Morrow Long.} \\
{\tiny Form revised \today .} \\
{\tiny $Revision: 1.1 $.} \\
\normalsize
\end{center}
\vspace{.20in}
\section {Prerequisites}
The mouse must be plugged in before bringing up X.
\subsection {Verifying X installation}
If your machine has MIT X windows installed the images/links /usr/new/X and
/usr/new/xinit will exist.
By default X windows on the RT is set up for the IBM 6155 (aka as the IBM APA16
or Extended Monochrome Graphics Display device).
\subsection {Checking/Setting PATH environment variable}
Check your path environment variable to make sure the directories containing
the X programs will be searched. Type:
\begin{verbatim}
% printenv PATH
/usr/new:/usr/new/bin:/usr/local/bin:/usr/yale/bin:/etc:/usr/ucb:/bin:/usr/bin:.:/usr/ibmtools:/usr/hosts
\end{verbatim}
Your path should include the directories '/usr/new' and '/usr/new/bin', if it
does not you should execute the following and add it to the .login script in
your home directory:
\begin{verbatim}
% set path=( /usr/new /usr/new/bin $path)
\end{verbatim}
\section {Beginning X}
\subsection {Starting X Windows}
To start X type:
\begin{verbatim}
% xinit
\end{verbatim}
An 80x24 VT100 terminal emulation window titled 'login' should appear in the
upper left corner of the monitor screen. A cross-hair cursor should also
be visible at a position on the screen. Move the mouse so that the cross-hair
mouse cursor is placed inside the window on the screen. Inside the window type:
\subsection {Starting the X Ultrix/Unix Window Manager}
\begin{verbatim}
% uwm &
\end{verbatim}
This command will start the Unix Window Manager. You should hear a beep, at
which time the window manager (uwm) has installed itself.
The window manager is now controlling the interaction of the X windows server
and your input (mouse, keyboard) and output (monitor screen) devices. It is
also making a number of window managing commands available to you (the user).
\subsection {Changing the Initial Window into an Icon}
Now make sure the cross-hair mouse cursor is still located inside the 'login'
window on the screen and depress the "control" key and the left mouse button.
The 'login' window
should be turned into a half-inch square labled 'login'. It is important to
protect the initial window because exiting from or terminating it will cause
all of the X windows on the screen to disappear. The 'login' window can
be turned back into a normal window by moving the mouse to it and depressing
the "control" and left mouse button simultaneously.
The icon can be moved by placing the cursor over the icon and depressing the
left mouse button. Drag the icon to the desired location and release the
mouse button.
\subsection {Using one of the X menus}
At this point you may depress the "control" and "alt" keys in combination with
both RT mouse buttons (this chord on a 2 button mouse is in lieu of the
middle button on a three button mouse). Keep
both RT mouse buttons depressed (you can release the "control" and "alt" keys
safely) and move the mouse down thru the menu to
'Add Big Window' and release all keys and buttons. The entry in the menu
where the mouse button was released will be selected.
\subsection {Placing a window}
In this example we are asking for an 80x24 column DEC VT100 emulation window
to be set up with our default shell (/bin/csh) running inside it on our local
machine.
Many parameters have been set by default (for advanced users: the font chosen
is 9x15 pixels and can be overridden by creating a personal .Xdefaults file in
your home directory ).
A small block bar should appear in the top left corner of the screen with
'Terminal Emulator: ' in it. You should also notice the frame of a
small invisible box following the mouse cursor around the screen. These are
the general signs of an X application politely making its intended presence
known and signaling the X user to place the window wherever desired on the
screen.
\subsection {Xterm windows}
Xterm windows should usually be placed in the middle of the screen (move the
mouse cursor to a point above and to the left of the screen center point and
depress the left button) and then moved (using the mouse with left button held)
to a desired location. If the window is placed too near the edges of the screen
then the portion of the xterm window that is not located within the screen
boundaries will be clipped out. Two big or four tiny windows can be placed
on the screen without overlapping (in this case using the mouse with the right
mouse button held can be used to resize the window to 80x24, 132x25, etc.).
A window to a remote login session on another Yale CS host may be obtained
by depressing the "control" and "alt" keys in combination with the left
mouse button and selecting one of the 'Connect to ...' menu entries.
Selection is achieved by releasing the mouse button over the desired entry.
The terminal type should be set to 'vt100' (or 'xterm') on the remote computer,
if the window is resized to 132 columns the terminal type 'vt132' can be used.
Many options are available in menus inside xterm itself (tektronix mode,
scrollbars and transcript logging, etc.). The xterm main menu
can be obtained by clicking "shift" left button on the xterm window title bar,
the 'modes' menu is available using the "shift" both (middle) button(s) in the
same manner (but if you click on the label word in the middle of the title
bar you will iconify the window instead).
The xterm window will only take input from the keyboard when the mouse cursor
is positioned within the xterm window borders, it can continue to display
program output when the cursor is moved to another window (even when the window
is obscured or iconed).
Xterm windows will cease to exist once the shell (/bin/csh) or other program
(rlogin, telnet, etc.) running inside the xterm window is exited.
\subsection {Default Keyboard and Mouse Button Mapping to Function}
The window system manager defaults (in {\sf /usr/new/lib/X/uwmrc/system.uwmrc})
have been set up to provide common window management
functions and three quick pop-up menus (for advanced users: this file can be
overridden with a .uwmrc file in your home directory).
These key \& mouse button clicks to function bindings are:
\vspace{.20in}
\begin{tabular}{||l|l||} \hline \hline
\multicolumn{2}{c}{\sc Default Keyboard and Mouse Button Mapping to Function} \\ \hline
{\em Keyboard \& Mouse Action} & {\em X Window Behaviour} \\ \hline
LEFTMOUSEBUTTON & Raise Window to Top of Stack \\ \hline
LEFTMOUSEBUTTON \& MouseMovement & Move Window On Screen \\ \hline
RIGHTMOUSEBUTTON \& Mouse Movement & Resize Window \\ \hline
CTRL \& LEFTMOUSEBUTTON & Toggle Window Into Icon \\ \hline
CTRL \& ALT \& LEFTMOUSEBUTTON & Hosts Menu \\ \hline
CTRL \& ALT \& BOTHMOUSEBUTTONS & Window Operations Menu \\ \hline
CTRL \& ALT \& RIGHTMOUSEBUTTON & Preferences Menu \\ \hline
\hline
\end{tabular}
\newpage
\subsection {Default 3 X Menus Provided}
\begin{description}
\item [Hosts Menu] Provides windows to rlogin/telnet to major
Yale Computer Science general-purpose and research machines.
\vspace{.20in}
\begin{tabular}{||l||} \hline \hline
{\sc Hosts} \\ \hline
Connect to Athena \\ \hline
Connect to Bulldog \\ \hline
Connect to Casper \\ \hline
Connect to Celray \\ \hline
Connect to Connection Machine \\ \hline
Connect to Eli \\ \hline
Connect to HP Crown \\ \hline
Connect to Ice \\ \hline
Connect to Max \\ \hline
Connect to Multiflow \\ \hline
Connect to Montana \\ \hline
Connect to Ring \\ \hline
Connect to Rubiks \\ \hline
Connect to Sunny \\ \hline
Connect to Venus \\ \hline
Connect to Zoo \\ \hline
\end{tabular}
\vspace{.10in}
\item [Window Operations Menu] Obtain two sizes of VT100 terminal emulation
windows, operate on windows, invoke clock program, other miscellany.
\vspace{.10in}
\begin{tabular}{||l||} \hline \hline
{\sc Window Ops} \\ \hline
Add Big Window \\ \hline
Add TinyWindow \\ \hline
AutoIconify \\ \hline
CircUp \\ \hline
CircDown \\ \hline
Focus \\ \hline
Freeze \\ \hline
Lower \\ \hline
Move \\ \hline
NewIconify \\ \hline
Raise \\ \hline
Refresh \\ \hline
Repaint \\ \hline
Resize \\ \hline
Restart uwm \\ \hline
UnFreeze \\ \hline
Xclock \\ \hline
Xload \\ \hline
\end{tabular}
\newpage
\item [Preferences Menu] You can disable key clicking here.
\vspace{.10in}
\begin{tabular}{||l||} \hline \hline
{\sc Preferences} \\ \hline
Bell Loud \\ \hline
Bell Normal \\ \hline
Bell Off \\ \hline
Click Loud \\ \hline
Click Soft \\ \hline
Click Off \\ \hline
Lock On \\ \hline
Lock Off \\ \hline
Mouse Fast \\ \hline
Mouse Normal \\ \hline
Mouse Slow \\ \hline
\end{tabular}
\end{description}
\section {Intermediate X}
\subsection {Cutting and Pasting}
X windows has several internal buffers for the purpose of allowing
window applications to exchange data. To demonstrate copying text between
two X windows perform the following:
\begin{enumerate}
\item Set up two windows (local or remote of any size).
\item Start up your favorite text editor in each window (move the cursor to each
window and invoke the program by name).
\item Move the mouse cursor to the desired position to copy text in the
source window and depress the "shift" and both buttons (middle) to 'mark' the
beginning point in the text.
\item Keep pressing the keys and move the mouse cursor to the right
(and down for multiple lines) to the end of the text to be copied.
\item Lift the mouse button(s).
\item Move the mouse cursor to the destination window.
\item Move the xterm cursor (by editor commands, keystrokes) to the point in the
window where the copied text is to be inserted.
\item Enter insert mode if necessary in the destination window editor (necessary
in vi, not in emacs and win).
\item Depress the "shift" and right button. The text should be inserted at the
editor's cursor (not related to the X mouse cursor).
\end{enumerate}
Only a few lines may be transferred in this manner using remote xterm windows
because the remote Unix process is usually too slow and its buffer too small to
capture a large number of characters blasted at it in real time in character
at a time mode. Local xterms perform much better.
Clicking the "shift" key and left button on a line in a window will cause the
text in the line from the X mouse cursor to the end of line to be inserted (as
if typed) at the current xterm cursor position (for example: at the bottom of
the screen if you are running the regular shell).
Using either of these methods the saved text remains in the copy buffer for
repeated pasting until it is overwritten.
\subsection {X Applications}
The following X programs should be available on the RTs, Suns and Celerity.
Man pages for the following are available on the Celerity, RT servers (alabama,
kentucky and northcar) and the Suns for
more information (more manual pages, etc. should be available on the RT clients
after NFS is available). The following applications reside in the directories
/usr/new and /usr/new/lib/X/demos (where available).
\vspace{.10in}
\begin{tabular}{r|l}
biff & be notified if mail arrives and who it is from \\ \hline
bitmap & bitmap editor for X window system \\ \hline
bounce & neat hack to bounce X windows around screen \\ \hline
keycomp & X window system keyboard mapping file compiler \\ \hline
pikapix & recolor an X window snapshot \\ \hline
resize & reset TERMCAP with current size of a window \\ \hline
uwm & Window Manager Client Application of X \\ \hline
xclock & X Window System, analog / digital clock \\ \hline
xcolors & X window system color database display \\ \hline
xdemo & demonstration program for X window system \\ \hline
xdpr & dump an X window directly to the printer \\ \hline
xdvi & DVI Previewer for the X Window System \\ \hline
xfax & display a FAX file in an X window \\ \hline
xfd & X window system font displayer \\ \hline
xfish & X window system mildly annoying game \\ \hline
xhost & X window system access control program \\ \hline
ximpv & Imprint (Impress) Previewer for the X Window System \\ \hline
xinit & X window system initializer \\ \hline
xload & X window system load average display \\ \hline
xnwm & X window system manager process \\ \hline
xperfmon & X window system Unix performance monitoring tool \\ \hline
xpr & print X window dump \\ \hline
xrefresh & refresh all windows on the screen. \\ \hline
xset & X window system user setup program \\ \hline
xshell & X Window System, key/button command exec \\ \hline
xterm & X window system terminal emulator \\ \hline
xtrek & Multiplayer startrek game for X window system \\ \hline
xwd & X Window System, window image dumper. \\ \hline
xwininfo & X Window System, window information summarizer. \\ \hline
xwm & X Window System, window manager process \\ \hline
xwud & X Window System, window image undumper \\ \hline
\end{tabular}
\section {Advanced X}
This section under development. Envisioned subsections include:
\begin{itemize}
\item Setting Up and Utilizing Odd Shaped Xterm Windows
\item Running Remote X applications
\item Using GNUemacs under X - remotely and locally, keybindings, etc.
\item Modifying the ~/.Xdefaults file
\item Creating a ~/.uwmrc file
\item Developing X applications
\end{itemize}
\end{document}
------x_intro_rt.lpr------------------------------------------------------
An Introduction to X Windows
at Yale Computer Science
on the IBM PC RT Using ACIS 4.2
By H. Morrow Long.
Form revised Tue Jul 21 16:24:31 PDT 1987
Revision : 1.1
Prerequisites
The mouse must be plugged in before bringing up X.
Verifying X installation
If your machine has MIT X windows installed the images/links /usr/new/X
and /usr/new/xinit will exist. By default X windows on the RT is set
up for the IBM 6155 (aka as the IBM APA16 or Extended Monochrome
Graphics Display device).
Checking/Setting PATH environment variable
Check your path environment variable to make sure the directories containing
the X programs will be searched. Type:
% printenv PATH
/usr/new:/usr/new/bin:/usr/local/bin:/usr/yale/bin:/etc:/usr/ucb:/bin:/usr/bin:.:/usr/ibmtools:/usr/hosts
Your path should include the directories '/usr/new' and '/usr/new/bin',
if it does not you should execute the following and add it to the
.login script in your home directory:
Beginning X - Starting X Windows
To start X type:
% xinit
An 80x24 VT100 terminal emulation window titled 'login' should appear
in the upper left corner of the monitor screen. A cross-hair cursor
should also be visible at a position on the screen. Move the mouse so
that the cross-hair mouse cursor is placed inside the window on the
screen. Inside the window type:
Starting the X Ultrix/Unix Window Manager
% uwm &
This command will start the Unix Window Manager. You should hear a
beep, at which time the window manager (uwm) has installed itself.
The window manager is now controlling the interaction of the X windows
server and your input (mouse, keyboard) and output (monitor screen)
devices. It is also making a number of window managing commands
available to you (the user).
Changing the Initial Window into an Icon
Now make sure the cross-hair mouse cursor is still located inside the
'login' window on the screen and depress the "control" key and the left
mouse button. The 'login' window should be turned into a half-inch
square labled 'login'. It is important to protect the initial window
because exiting from or terminating it will cause all of the X windows
on the screen to disappear. The 'login' window can be turned back into
a normal window by moving the mouse to it and depressing the "control"
and left mouse button simultaneously.
The icon can be moved by placing the cursor over the icon and
depressing the left mouse button. Drag the icon to the desired
location and release the mouse button.
Using one of the X menus
At this point you may depress the "control" and "alt" keys in
combination with both RT mouse buttons (this chord on a 2 button mouse
is in lieu of the middle button on a three button mouse). Keep both RT
mouse buttons depressed (you can release the "control" and "alt" keys
safely) and move the mouse down thru the menu to 'Add Big Window' and
release all keys and buttons. The entry in the menu where the mouse
button was released will be selected.
Placing a window
In this example we are asking for an 80x24 column DEC VT100 emulation
window to be set up with our default shell (/bin/csh) running inside it
on our local machine. Many parameters have been set by default (for
advanced users: the font chosen is 9x15 pixels and can be overridden by
creating a personal .Xdefaults file in your home directory ).
A small block bar should appear in the top left corner of the screen
with 'Terminal Emulator: ' in it. You should also notice the frame of
a small invisible box following the mouse cursor around the screen.
These are the general signs of an X application politely making its
intended presence known and signaling the X user to place the window
wherever desired on the screen.
Xterm windows
Xterm windows should usually be placed in the middle of the screen
(move the mouse cursor to a point above and to the left of the screen
center point and depress the left button) and then moved (using the
mouse with left button held) to a desired location. If the window is
placed too near the edges of the screen then the portion of the xterm
window that is not located within the screen boundaries will be clipped
out. Two big or four tiny windows can be placed on the screen without
overlapping (in this case using the mouse with the right mouse button
held can be used to resize the window to 80x24, 132x25, etc.).
A window to a remote login session on another Yale CS host may be
obtained by depressing the "control" and "alt" keys in combination with
the left mouse button and selecting one of the 'Connect to ...' menu
entries. Selection is achieved by releasing the mouse button over the
desired entry. The terminal type should be set to 'vt100' (or 'xterm')
on the remote computer, if the window is resized to 132 columns the
terminal type 'vt132' can be used.
Many options are available in menus inside xterm itself (tektronix
mode, scrollbars and transcript logging, etc.). The xterm main menu
can be obtained by clicking "shift" left button on the xterm window
title bar, the 'modes' menu is available using the "shift" both
(middle) button(s) in the same manner (but if you click on the label
word in the middle of the title bar you will iconify the window
instead).
The xterm window will only take input from the keyboard when the mouse
cursor is positioned within the xterm window borders, it can continue
to display program output when the cursor is moved to another window
(even when the window is obscured or iconed).
Xterm windows will cease to exist once the shell (/bin/csh) or other
program (rlogin, telnet, etc.) running inside the xterm window is
exited.
Default Keyboard and Mouse Button Mapping to Function
The window system manager defaults (in
/usr/new/lib/X/uwmrc/system.uwmrc ) have been set up to provide common
window management functions and three quick pop-up menus (for advanced
users: this file can be overridden with a .uwmrc file in your home
directory). These key mouse button clicks to function bindings are:
Default Keyboard and Mouse Button Mapping to Function
Keyboard + Mouse Action X Window Behaviour
------------------------- -----------------
LEFTMOUSEBUTTON Raise Window to Top of Stack
LEFTMOUSEBUTTON MouseMovement Move Window On Screen
RIGHTMOUSEBUTTON Mouse Movement Resize Window
CTRL LEFTMOUSEBUTTON Toggle Window Into Icon
CTRL ALT LEFTMOUSEBUTTON Hosts Menu
CTRL ALT BOTHMOUSEBUTTONS Window Operations Menu
CTRL ALT RIGHTMOUSEBUTTON Preferences Menu
Default 3 X Menus Provided
[Hosts Menu] Provides windows to rlogin/telnet to major
Yale Computer Science general-purpose and research machines.
Hosts
------------------
Connect to Athena
Connect to Bulldog
Connect to Casper
Connect to Celray
Connect to Connection Machine
Connect to Eli
Connect to HP Crown
Connect to Ice
Connect to Max
Connect to Flo
Connect to Montana
Connect to Ring
Connect to Rubiks
Connect to Sunny
Connect to Venus
Connect to Zoo
[Window Operations Menu] Obtain two sizes of VT100 terminal emulation
windows, operate on windows, invoke clock program, other miscellany.
Window Ops
----------------
Add Big Window
Add TinyWindow
AutoIconify
CircUp
CircDown
Focus
Freeze
Lower
Move
NewIconify
Raise
Refresh
Repaint
Resize
Restart uwm
UnFreeze
Xclock
Xload
[Preferences Menu] You can disable key clicking here.
Preferences
-----------------
Bell Loud
Bell Normal
Bell Off
Click Loud
Click Soft
Click Off
Lock On
Lock Off
Mouse Fast
Mouse Normal
Mouse Slow
Intermediate X
Cutting and Pasting
X windows has several internal buffers for the purpose of allowing
window applications to exchange data. To demonstrate copying text
between two X windows perform the following:
Set up two windows (local or remote of any size).
Start up your favorite text editor in each window (move the cursor to each
window and invoke the program by name).
Move the mouse cursor to the desired position to copy text in the
source window and depress the "shift" and both buttons (middle) to 'mark' the
beginning point in the text.
Keep pressing the keys and move the mouse cursor to the right
(and down for multiple lines) to the end of the text to be copied.
Lift the mouse button(s).
Move the mouse cursor to the destination window.
Move the xterm cursor (by editor commands, keystrokes) to the point in the
window where the copied text is to be inserted.
Enter insert mode if necessary in the destination window editor (necessary
in vi, not in emacs and win).
Depress the "shift" and right button. The text should be inserted at the
editor's cursor (not related to the X mouse cursor).
Only a few lines may be transferred in this manner using remote xterm
windows because the remote Unix process is usually too slow and its
buffer too small to capture a large number of characters blasted at it
in real time in character at a time mode. Local xterms perform much
better.
Clicking the "shift" key and left button on a line in a window will
cause the text in the line from the X mouse cursor to the end of line
to be inserted (as if typed) at the current xterm cursor position (for
example: at the bottom of the screen if you are running the regular
shell).
Using either of these methods the saved text remains in the copy buffer
for repeated pasting until it is overwritten.
X Applications
The following X programs should be available on the RTs, Suns and
Celerity. Man pages for the following are available on the Celerity,
RT servers (alabama, kentucky and northcar) and the Suns for more
information (more manual pages, etc. should be available on the RT
clients after NFS is available). The following applications reside in
the directories /usr/new and /usr/new/lib/X/demos (where available).
biff be notified if mail arrives and who it is from
bitmap bitmap editor for X window system
bounce neat hack to bounce X windows around screen
keycomp X window system keyboard mapping file compiler
pikapix recolor an X window snapshot
resize reset TERMCAP with current size of a window
uwm Window Manager Client Application of X
xclock X Window System, analog / digital clock
xcolors X window system color database display
xdemo demonstration program for X window system
xdpr dump an X window directly to the printer
xdvi DVI Previewer for the X Window System
xfax display a FAX file in an X window
xfd X window system font displayer
xfish X window system mildly annoying game
xhost X window system access control program
ximpv Imprint (Impress) Previewer for the X Window System
xinit X window system initializer
xload X window system load average display
xnwm X window system manager process
xperfmon X window system Unix performance monitoring tool
xpr print X window dump
xrefresh refresh all windows on the screen.
xset X window system user setup program
xshell X Window System, key/button command exec
xterm X window system terminal emulator
xtrek Multiplayer startrek game for X window system
xwd X Window System, window image dumper.
xwininfo X Window System, window information summarizer.
xwm X Window System, window manager process
xwud X Window System, window image undumper
Advanced X
This section under development. Envisioned subsections include:
Setting Up and Utilizing Odd Shaped Xterm Windows
Running Remote X applications
Using GNUemacs under X - remotely and locally, keybindings, etc.
Modifying the ~/.Xdefaults file
Creating a ~/.uwmrc file
Developing X applications