X Windows Configuration Setup for Using CTT

The document IMSL Computational Technology Toolkit contains an overview of CTT and information on its use that should be read prior to reading this document.

The most efficient way to do program development with CTT on Strauss is to use a workstation that functions as an X Windows server. This type of workstation includes Sun Rays, Microsoft Windows systems using XMING and UNIX workstations. In these multi-windowed environments, you can open several windows at once—a documentation window, an editor window and a compile/run window.

This document assumes that you have already modified your UNIX configuration files as described in the document Getting Started with CTT: Setting Up Your UNIX Account. Further modifications to these configuration files, described below, will facilitate your use of CTT in an X Windows environment.

Modifying your alias file

The commands cttxterm and cttstrauss will open an xterm window just for working with CTT. When you are done with that window, close it or type exit . The command cttdoc will open a CTT documentation window. The commands cttxterm and cttdoc only work on Strauss; cttstrauss works on any Unix machine with ssh X tunneling enabled.

Add the following lines to the file called ~/.alias, which you may have to create.

if $?DISPLAY then
       alias cttxterm '(setenv NEED_CTT; xterm -name commands $)'
       alias cttdoc 'acroread $CTT_DIR/help/imsl.pdf $'
       alias cttstrauss\
         ssh -X -f strauss.udel.edu 'setenv NEED_CTT\; xterm -name commands'

These three new commands will become defined when you start a new shell or open an new xterm window.

Modifying your X defaults file

The commands in the previous section all start an xterm with the name "commands." This is where you type commands to compile and run your program. Compiling and running your program may produce more lines of output than fit in a normal sized window. You may want to configure your X defaults so any window named "commands" has more lines on the screen, and more lines in the save buffer for scrolling.

Add the following lines to your ~/.Xdefaults-strauss.udel.edu file on Strauss.

commands.VT100.Foreground: DarkSlateBlue 
commands.VT100.Background: lightGray 
commands.VT100.geometry: 80x48
commands.VT100.saveLines: 4800
commands.VT100.ScrollBar: true

Now, any xterm on Strauss with the name "commands" will have these resources set. The window will be 48 lines long and 4800 lines (100 pages) will be saved in the scrollback buffer. You can use the scrollbar, or you can use the Page Up, Page Down, Home and End keys to display all the saved lines.

We recommended that you edit the source or data files in another window. That way, the normal output is not interrupted with full screen edit lines.

Connecting to Strauss from your local desktop

Here are the three steps to start an xterm on Strauss:

  1. Select an X11 windows server.
    You will need an X11 server on your local desktop. Start XMING on a Windows PC, or start the X11 application on a Mac OS X. Local X Windows desktops such as, Gnome KDE or CDE are based on X11, so you do not need to start a new X11 server.
  2. Use an SSH client to connect to Strauss.
    Type ssh -X username@strauss.udel.edu replacing username with your UDelNet ID. On a Windows PC use the University-supplied SSH client to connect to Strauss with X11 tunnelling enabled.
  3. Open a CTT xterm window.
    Type cttxterm

These last two steps can be accomplished with one command:

ssh -X -f username@strauss.udel.edu 'setenv NEED_CTT\; xterm -name commands'

Use this command to customize your desktop for quickly openning a CTT-configured xterm on Strauss.