To support the user in defining his own graphical
types we provide classes describing typical
examples of graphical types supported by the Andrew toolkit (ATK).
Their class definition includes attributes for all
important parameters such as font, shape, text alignment.
These classes are organized in a specialization hierarchy
below the object GraphicalType and include the
objects shown in figure
.
Figure: The predefined graphical type classes for the Andrew toolkit
Most of these types are self-explanatory. ATK_Iconnode and ATK_Pixmapnode enable the use of pixmaps as graphical symbols in the Graph Browser. Both take the name of the pixmap file (in string format) as attribute. They differ in the way they present the name of the corresponding object: for an iconnode the object name is presented below the pixmap while in case of a pixmapnode the name is centered within the pixmap. Please note that for all concrete graphical types (i.e. all instances of the ATK type classes above) the attribute WithShape must be specified, they are not inherited from the tytpe class! Admissible values are the instances of the class ATK_ShapeStyle; admissible values of the attributes LineCap, TextAlign, FontDesc, LineColor are the instances of the classes ATK_LineCap, ATK_TextAlign, ATK_Fonts, X11_Color, resp.
The definition of new presentation styles comprises three steps:
An example of user-defined graphical types can be found in
.
For the graphical types ATK_Iconnode and ATK_Pixmapnode the attribute PixmapFile references the pixmap file name and location encoded in a string. The format of the pixmap file must be XPM3, which can be generated, e.g., using the xgrab tool. There exists a fixed sequence of places where the Graph Browser searches for the pixmap file: