Top Up Prev Next Bottom Contents Index Search

2.1 Introduction


The Ptolemy interactive graphical interface (pigi) is a design editor for Ptolemy applications. It is based on tools from the Berkeley CAD framework. In pigi, Ptolemy applications are constructed graphically, by connecting icons. Hierarchy is used to manage complexity, to abstract subsystem designs, and to mix domains (models of computation).

2.1.1 Setup

Ptolemy uses several environment variables (see page 2-51). In order for Ptolemy to run properly, the following two environment variables must be set in your .cshrc file:

Example settings for a .cshrc file follow, along with how to update your path variable:

setenv PTOLEMY ~ptolemy
setenv PTARCH `$PTOLEMY/bin/ptarch`
set path = ($PTOLEMY/bin $PTOLEMY/bin.$PTARCH $path)
When Ptolemy was installed, a fictitious user named `ptolemy' may have been created whose home directory is the Ptolemy installation. If Ptolemy has been installed without creating a `ptolemy' user, then use the appropriate path name of the Ptolemy installation for the value of the PTOLEMY environment variable, such as /usr/eesww/share/ptolemy0.7, for example. Once you make the appropriate changes to your .cshrc file, you will need to reevaluate the file:

source ~/.cshrc
In the documentation, we will generally refer to the home directory of the Ptolemy installation as $PTOLEMY, but sometimes we forget and use ~ptolemy.

Pigi requires the MIT X Window System. If you are not familiar with this system, see the appendix, "Introduction to the X Window System" on page B-1. Some X window managers are configured to require that you click in a window before the "focus" moves to that window. This means that the window will not respond to input just because you have placed the mouse cursor inside it. You must first click a mouse button in the window. While it is possible to use pigi with this configuration, it is extremely unpleasant. In fact, it will be rather unpleasant to use any modern program that makes use of the window system. You will want to change the mode of the window manager so that the focus follows the mouse. The precise mechanism for doing this depends on the window manager. For the Motif window manager, mwm, the appropriate line in the .Xdefaults file is:

Mwm*keyboardFocusPolicy:					pointer
For the open-look window manager, olwm, the line is:

OpenWindows.SetInput:					followmouse
Alternatively, you can invoke olwm with the option -follow. Typically, the window manager is started in a file called .xinitrc in your home directory.

If you are running Sun's OpenWindows, you may find that the Athena widgets have not been installed; pigi will not run without them. See the installation instructions in the appendix. For more information on using pigi with OpenWindows, see "Introduction to the X Window System" on page B-1.



Top Up Prev Next Bottom Contents Index Search

Copyright © 1990-1997, University of California. All rights reserved.