Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
AT&T Labs Research - Grappa / FAQ
[go: Go Back, main page]

AT&T AT&T Labs Research
AT&T Labs Research
Home
People
Projects
Research Areas
Resources
Search
Quick Searchspacer
spacer

Grappa / FAQ    Last updated: Thu Aug 30 10:46:56 EDT 2001

This page provides questions and answers which we feel may be of general interest.

Installation  (top)

  1. How do I install Grappa?
    First download the
    Grappa gzipped-tar file and unpack it any number of ways, such as the WinZip tool or the Linux command-line:
      gunzip < grappa.tgz | tar xvf -
    
    Then, look in the archives folder for the package file of your choice (usually grappa1_2.jar) and place that file somewhere in your Java CLASSPATH (any basic Java book will explain what that means) and you are ready to make use of the Grappa package in your Java programs by simply adding a
      import att.grappa.*;
    
    statement in your source files.
    (top)

  2. How do I build from the source?
    Assuming you want to build the Grappa 1.2 source and that you have either JDK1.2 or JDK1.3 installed, you may proceed as follows (Note: these are Linux style directions, modify with backslashes instead of slashes as appropriate for Windows):

    (top)

  3. Is there a demo I can look at?
    Yes, graph files and some crude demo applications are provided in the DEMO folder. The jdk1.2 folder within DEMO is probably of most interest. Assuming that the Grappa package is in your CLASSPATH and also that the current folder is in your CLASSPATH as well, then in the jdk1.2 demo folder, you can try running:
      java Demo12 ../sample.dot
    
    Note that the graph in the sample.dot file already has layout information contained in it (by means of the pos element attribute). Pressing the right mouse button provides a popup-menu. Pressing the left mouse button selects elements (either individually or by sweeping). Pressing the control-key and the left mouse button on an element lets you select additional elements without clearing the previously selected elements. Pressing the shift-key and the left mouse button on a piece of blank graph creates a new node while doing the same in an existing node and dragging to another existing node creates an edge. Pressing the labelled "Layout" button to the left of the demo panel first tries to call a local layout script (formatDemo) and then, if that fails, which it almost certainly will, it will try to contact our web server to perform the layout. This latter should work as long as you have a live connection to the internet.
    (top)

Licensing  (top)

  1. How to I license Grappa?
    Grappa is licensed under the same arrangements as are used for graphviz, which is essentially Open Source. Refer to the
    graphviz download page for additional information.
    (top)

Miscellany  (top)

  1. Is there a mailing list or message group?
    There is no specific mailing list for Grappa setup. The graphviz list can field Grappa questions (refer to the
    graphviz pages for information about that message group) or you questions can be sent directly to the author .
    (top)

  2. How do I report a bug?
    You can use the
    graphviz bug form or send reports directly to the author .
    (top)

Usage  (top)

  1. How come all my nodes and edges draw on top of each other at the same place?
    Grappa does not do layout, though it provides a convenience method (GrappaSupport.filterGraph(...)) to make using an external layout engine simpler. Moreover, since Grappa stores graph structure information and provides several methods for traversing graphs and retrieving elements, it simplifies the task of coding your own layout engine directly in Java.
    (top)

  2. Does Grappa work with JDK1.3?
    Yes, the Grappa 1.2 works with both JDK1.2 and JDK1.3. Demo12.java, however, contains a deprecated method that can be easily updated if you do not like getting the deprecation warning.
    (top)

  3. How do I trigger actions when I click on elements in the graph?
    Grappa defines a GrappaListener interface and methods in GrappaPanel for adding and removing a listener. By default, there is no listener. However, Grappa does supply an extensible GrappaAdapter class which provides one implementation of a GrappaListener as a convenience. The demo application demonstrates how it can be added to a GrappaPanel.
    (top)

  4. The javadoc documentation is OK, but what else do you have?
    Although there is an early paper (Grappa: A GRAPh PAckage in Java by Naser S. Barghouti, John M. Mocenigo and Wenke Lee at pages 336 - 343 in the Proceedings of the 5th International Symposium on
    Graph Drawing in Rome, 1997 and published by Springer-Verlag [ISBN: 3-540-63938-1]), it is rather out-of-date and only introductory in its depth. So, for all practical purposes, the javadoc documentation is it.
    (top)




home | people | projects | research areas | resources | search

Copyright and Privacy Notice