lglview is not really supported anymore, but at first I tried really hard to make it functional and fast so please be kind :-)
lglview.jar was compiled and tested on a RedHat workstation with Sun's j2sdk1.4.1. It is recommended that you also run lglview.jar with version 1.4.1 as well.
See the examples dir for sample files.
java -jar lglview.jar
Sometimes for large graphs JAVA default memory allocation is insufficient so you must manually specify the amount of memory JAVA can use. For example:
java -jar -Xmx1000m lglview.jar
sets the memory limit to 1000Mb. From Windows this would be done by going to the start menu then 'Run'. You have to check your path variables in all cases.
Two files are necessary for a session: a '.lgl' file describing the edges; a 2D coordinate file with the vertex name followed by the 2D coordinates (whitespace delimited giving 3 columns total).You must first open the '.lgl' file from the 'File' menu, and then load the 2D coords also from the 'File' menu. You can look in the example directory for a .lgl edge file and its corresponding .coords file. You can also launch it directly from the command line:
java -jar -Xmx1000m lglview.jar edges.lgl 2d.coords
Although the .lgl file and the coords file are all that is necessary to get going, other input can be loaded into lglview to help elucidate your graph. To show some of the other features of the viewer the 'examples' directory has a '*.descrips' file, an edges color file '*.edge.colors', and a vertex color file '*.vertex.colors'. All of these can be loaded by looking in the 'File' menu of the viewer.
Open 2D Coords For opening the coordinates associated with the .lgl file. Must be in the following white space delimited format:
vertex1 x1 y1
vertex2 x2 y2
Load Vertex Information For viewing additional information associated with each vertex. After you load a file a panel will appear. That panel should have a help button associated with it. Check that out for further information. For loading 'Vertex Information' the file format is simple:
vertex1 words about vertex 1
vertex2 words about vertex 2
See the *.descrips file in the examples directory.
Open Vertex Color File For assigning a particular color to any or all vertices. It has to be a whitespace delimited format with RGB values for columns 2 thru 4 such as
vertex1 redFloat1 greenFloat1
blueFloat1
vertex2 redFloat2 greenFloat2 blueFloat2
Save Vertex Colors This allows the user
to save the set of vertex colors that were assigned during the session. This
will not save the default colors of vertices. The output format is the
same as the input format of Open Vertex Color File which will allow
you to pick up a session where you left off.
A warning is printed to STDOUT if an
undefined vertex is given. All of the floats can be values [0,1] inclusive.
Open Edge Color File For assigning a particular color to any or all edges. It has a similar format:
vertex1 vertex2 redFloat1 greenFloat1
blueFloat1
vertex1 vertex3 redFloat2 greenFloat2
blueFloat2
The edge is identified by two vertex ids. A warning is printed to STDOUT if an undefined edge is given. All of the floats can be values [0,1] inclusive.
Save Edge Colors
This is identical to Save Vertex Colors
mentioned above with the same caveats, except it applies to the edges.
Reload 2D Coords File This just reloads the coords file you opened last (exact same file name). This is used when lglayout is running and you may want to monitor the layout progress.
Change zoom step size Currently zoom clips the zoomStepSize of each edge and redraws the new rectangle remaining. This means that zoom can range from (0,1) non inclusive.
Change move step size Move step is the percent of the screen you want shifted to a given direction so its value is (0,1) non inclusive.
Remove Transient Edges This is an incredible optimization for the viewer. The issue with lag in the viewer is rooted with all the lines that have to be drawn and interpolated onto the panel. With this button not selected all lines are given to the panel and then the panel conveniently decides what is to be drawn, throwing away bad edges that are not actually on the panel. With this button selected, as it is by default, all lines are screened to see if at least one of the 2 vertices are even on the screen first. For zoomed regions, looking at the graph closely, or other situations where only hundreds or thousands of lines are drawn instead of millions this makes a HUGE difference in viewer performance. The end result is that edges that sit on top of the panel (neither of the vertices are in the screen area, but the edge line is interpolated onto the screen area) are REMOVED from the draw. This performance gain is not beneficial if all/most of the lines are on the screen anyway.
Zoom Point Select 'Zoom Point' if you want to use the mouse as a zooming utensil. Left click zooms in while Right Click zooms out. The zooming results are also a function of the values you set in edit menu (zoom step size and move step size). This is actually not a highlight region type function.
Zoom Region Select 'Zoom Region' to mouse over a region to zoom into. This means pressing the left button, holding while shaping out a rectangular area to cover and releasing. This feature is buggy. It works best if you start in the upperleft and move to bottom right.
ID Region Select 'ID Region' to mouse over a region you want to activate the id labels. To then turn them all back off again, select and then unselect the 'Show IDs' button.
In Zoom in
Out Zoom out
Up Move up through the data (picture moves down)
Down Move down through the data (picture moves up)
Left Move right through the data (picture moves right)
Right Move left through the data (picture moves left)
Fit Tries to move the whole graph into the viewing area. VERY BUGGY!!
SnapShot Generates a .png file of the lglview screen and offers a prompt to name it. It will only make an .png file.
Show IDs Show ALL ids or not. This button affects ALL vertices.
Show Vertices Show the vertices by drawing a small square at vertex locations.