"Grafix" is a utility originally designed to help scientists in the
visualization of results of a computation, esp. for numerical integrations of
partial differential equations.
It can be used, however, for any application that wants to use X-Windows for
drawing pictures, functions or other graphic objects in a convinient
interactive manner or even for writing a graphical user interface for any task.
Grafix should be considered as a layer between an application and the X Window
system built up of a bunch of basic classes as building elements.
The simplest way of using it is to define instances of these classes.
For more complicated programs the user has to define own derivations to the
The object-oriented approach enables a quite simple way of introducing user
- Grafix is based on Unix and the X Window system.
- Grafix does not use any commercial code, like Motif, so it is totally free.
- Grafix is been ported and tested for Linux and SunOS, with X11R5/R6
- Grafix is small and fast since it is pure functionality without any
- Grafix is completely written in C++ and to compile with g++ on both platforms
Taken from Wolfgang Koehler, grafix/HOWTO.txt
Grafix is available under the GNU GENERAL PUBLIC LICENSE. Some changes have been made in the code so that the behaviour of the spscan user interface is slightly different from the original grafix interface.
The interface has the following "look and feel":
have 3 states: normal, cursor over button, button pressed. The "button pressed" look is retained, until the routine called by the button is ready. If a button does not change when the cursor is over it, the program is busy or suspended.
Buttons with a small triangle on the right side show a submenu when you click with the left or middle mouse button. If you use the left button, the menu is temporary, with the middle button you get permanent submenus. To remove the submenu, press the right button on a submenu ( --> call the routine) or on the main menu (no action).
... are blue rectangular fields with a "3D down" look.
Move the pointer into the edit box. The cursor can be moved with the "right" and "left" keys. You can add and delete characters at the position to the left of the cursor. Press ESC to delete the contents of the edit window. As soon as the Pointer leaves the edit window, the string is evaluated, and translated into the internal representation, or discarded if not acceptable. Pressing RETURN has the same effect, and it warps the pointer one line down.
Selections are not supported, i.e. nothing can be copied from, or into, edit boxes. The mouse cannot be used to move the cursor, mark text, ...
have a small square in the right, which is either in "up" or "down" position. Pressing the button switches between these two states. A toggle button is connected with a boolean variable, which is true in "down" and false in "up" position.
The upper field shows full directory (pointer on ".") or file names (pointer on a file name). It cannot be edited.
The filter field (second from top) and the filename field (below) can be edited. The filter field can be used for relative and absolute directory changes as well as to enter a search mask for the filename. The filename field also accepts relative as well as absulute filenames.
A single click to a directory cd's to this directory. A single click to a file puts the filename to the lower edit box, where it can be edited. You have to click Load or Save, double click doesnt do anything.
If you click the abort button, nothing is loaded or stored. Two remarks for use in SPSCAN: If the program is compiled without error handling, abort loading will crash on some routines. Some routines can only be left if you save a list (the box simply re-appears, if you press abort). In such cases you have to save to /dev/null, if you want to abort.
More recent grafix releases have not (yet) been merged in, although some of the changes made are parallel to the changes made in the 1.2 release.
- files: separated into header and .cc file
- file_new_box: major changes. can read and write files.
- color allocation fixed. Tries to find nearly matching color, if all cells allocated.
- pulldown menue unmapping changed: uses parentw->Unmap(). No grab on pulldown_window, instead release of automatic grab on the pulldown_button. You get permanent menues with the middle mouse button. Remove menues with the left mouse button.
- Buttons can be activated with RETURN
- several minor changes in callback hierarchie
- a number of additions, for example tables
Dr. Ralf W. Glaser
Institut für Molekularbiologie & Biophysik
Last modified: Dec 11, 1995