ccvisu
Class CCVisuGUI

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by java.awt.Window
              extended by java.awt.Frame
                  extended by ccvisu.CCVisuGUI
All Implemented Interfaces:
java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, javax.accessibility.Accessible

public class CCVisuGUI
extends java.awt.Frame

GUI for those who don't like command line

Version:
$Revision: 1.3 $; $Date: 2006/11/25 10:41:07 $
Author:
Damien Zufferey
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class java.awt.Frame
java.awt.Frame.AccessibleAWTFrame
 
Nested classes/interfaces inherited from class java.awt.Window
java.awt.Window.AccessibleAWTWindow
 
Nested classes/interfaces inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
private  java.awt.Checkbox anim
           
private  java.awt.Choice annot
           
private  java.awt.TextField attrExp
           
private  java.awt.Choice backColor
           
private  java.awt.Checkbox blackCircle
           
private  java.io.FilenameFilter CVSFilter
           
private  java.awt.Panel CVSOptions
           
private  java.awt.Choice dim
           
private  java.awt.Panel DISPOptions
           
private  java.awt.Button exec
          validate choices and execute
private  java.awt.TextField fontSize
           
static java.lang.String[] FORMAT
           
private  java.awt.TextField grav
           
private  java.awt.Checkbox hideSource
           
private  java.awt.TextField inFile
          textfield to enter the input file
private  java.awt.Choice inFormat
          a choice for the input format
private  java.awt.TextField initLayout
           
private  java.awt.TextField iter
           
private  java.io.FilenameFilter layFilter
           
private  java.awt.Button loadInFile
           
private  java.awt.Button loadInitLayout
           
private  java.awt.Panel MinimizerOptions
           
private  java.awt.TextField minVert
           
private  java.awt.Checkbox noWeight
           
private  java.awt.TextField outFile
          textfield to enter the output file (when needed)
private  java.awt.Choice outFormat
          a choice for the output format
private  java.awt.TextField repuExp
           
private  java.io.FilenameFilter rsfFilter
           
private  java.awt.Button saveOutFile
           
private  java.awt.TextField scale
           
private static long serialVersionUID
           
private  java.io.FilenameFilter svgFilter
           
private  java.awt.TextField timeWindow
           
private  java.awt.Choice vertRepu
           
private  java.io.FilenameFilter vrmlFilter
           
 
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
CCVisuGUI(int inForm, java.lang.String inF, int outForm, java.lang.String outF, int ddim, int iiter, java.lang.String iinitLayout, int aattrExp, int rrepuExp, boolean vvertRepu, boolean nnoWeight, float ggrav, int time, boolean hhideSource, float minVertex, int ffontSize, java.lang.String bbackColor, boolean noBlackCircle, float scalePos, boolean aanim, boolean annotAll, boolean annotNone)
          Constructor with parameters
 
Method Summary
private  void createCVSOptions(int timeWindow)
          construct the panel for the CVS options
private  void createDISPOptions(boolean hideSource, float minVertex, int fontSize, java.lang.String backColor, boolean noBlackCircle, float scalePos, boolean noAnim, boolean annotAll, boolean annotNone)
          construct the panel for the display options
private  void createFilenameFilter()
           
private  void createMinimizerOptions(int ddim, int iiter, java.lang.String iinitLayout, int attrExp, int repuExp, boolean vertRepu, boolean noWeight, float grav)
          construct the panel for the minimizer options
private  void enableCVSOptions(boolean b)
          en/disable the part concerning CVS
private  void enableDISPOptions(boolean b)
          en/disable the part concerning the display
private  void enableMinimizerOptions(boolean b)
          en/disable the part concerning the minimizer
private  void enableSVGOptions(boolean b)
          en/disable the part concerning SVG and VRML format
private  java.lang.String loadDialog()
          dialog to select a file to load
private  java.lang.String loadInitlayDialog()
          dialog to select the initial layout
static void main(java.lang.String[] args)
           
private  java.lang.String saveDialog()
          dialog to select an output file
 
Methods inherited from class java.awt.Frame
addNotify, finalize, getAccessibleContext, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, paramString, remove, removeNotify, setCursor, setExtendedState, setIconImage, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
 
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getInputContext, getListeners, getLocale, getMostRecentFocusOwner, getOwnedWindows, getOwner, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, postEvent, processEvent, processWindowEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, setAlwaysOnTop, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setLocationByPlatform, setLocationRelativeTo, show, toBack, toFront
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paint, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, setLayout, transferFocusBackward, transferFocusDownCycle, update, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, reshape, resize, resize, setBackground, setBounds, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setMinimumSize, setName, setPreferredSize, setSize, setSize, setVisible, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
 

Field Detail

serialVersionUID

private static final long serialVersionUID
See Also:
Constant Field Values

FORMAT

public static final java.lang.String[] FORMAT

inFormat

private java.awt.Choice inFormat
a choice for the input format


outFormat

private java.awt.Choice outFormat
a choice for the output format


inFile

private java.awt.TextField inFile
textfield to enter the input file


outFile

private java.awt.TextField outFile
textfield to enter the output file (when needed)


loadInFile

private java.awt.Button loadInFile

saveOutFile

private java.awt.Button saveOutFile

exec

private java.awt.Button exec
validate choices and execute


MinimizerOptions

private java.awt.Panel MinimizerOptions

DISPOptions

private java.awt.Panel DISPOptions

CVSOptions

private java.awt.Panel CVSOptions

dim

private java.awt.Choice dim

iter

private java.awt.TextField iter

initLayout

private java.awt.TextField initLayout

attrExp

private java.awt.TextField attrExp

repuExp

private java.awt.TextField repuExp

grav

private java.awt.TextField grav

noWeight

private java.awt.Checkbox noWeight

vertRepu

private java.awt.Choice vertRepu

loadInitLayout

private java.awt.Button loadInitLayout

hideSource

private java.awt.Checkbox hideSource

blackCircle

private java.awt.Checkbox blackCircle

anim

private java.awt.Checkbox anim

minVert

private java.awt.TextField minVert

fontSize

private java.awt.TextField fontSize

scale

private java.awt.TextField scale

annot

private java.awt.Choice annot

backColor

private java.awt.Choice backColor

timeWindow

private java.awt.TextField timeWindow

layFilter

private java.io.FilenameFilter layFilter

CVSFilter

private java.io.FilenameFilter CVSFilter

svgFilter

private java.io.FilenameFilter svgFilter

vrmlFilter

private java.io.FilenameFilter vrmlFilter

rsfFilter

private java.io.FilenameFilter rsfFilter
Constructor Detail

CCVisuGUI

public CCVisuGUI(int inForm,
                 java.lang.String inF,
                 int outForm,
                 java.lang.String outF,
                 int ddim,
                 int iiter,
                 java.lang.String iinitLayout,
                 int aattrExp,
                 int rrepuExp,
                 boolean vvertRepu,
                 boolean nnoWeight,
                 float ggrav,
                 int time,
                 boolean hhideSource,
                 float minVertex,
                 int ffontSize,
                 java.lang.String bbackColor,
                 boolean noBlackCircle,
                 float scalePos,
                 boolean aanim,
                 boolean annotAll,
                 boolean annotNone)
          throws java.awt.HeadlessException
Constructor with parameters

Parameters:
inForm -
inF -
outForm -
outF -
ddim - minimizer
iiter - minimizer
iinitLayout - minimizer
aattrExp - energy model
rrepuExp - energy model
vvertRepu - energy model
nnoWeight - energy model
ggrav - energy model
time - CVS
hhideSource - Layout writer
minVertex - Layout writer
ffontSize - Layout writer
bbackColor - Layout writer
noBlackCircle - Layout writer
scalePos - VRML and SVG
aanim - DISP
annotAll - Layout writer
annotNone - Layout writer
Throws:
java.awt.HeadlessException
Method Detail

createMinimizerOptions

private void createMinimizerOptions(int ddim,
                                    int iiter,
                                    java.lang.String iinitLayout,
                                    int attrExp,
                                    int repuExp,
                                    boolean vertRepu,
                                    boolean noWeight,
                                    float grav)
construct the panel for the minimizer options

Parameters:
ddim -
iiter -
iinitLayout -
attrExp -
repuExp -
vertRepu -
noWeight -
grav -

createDISPOptions

private void createDISPOptions(boolean hideSource,
                               float minVertex,
                               int fontSize,
                               java.lang.String backColor,
                               boolean noBlackCircle,
                               float scalePos,
                               boolean noAnim,
                               boolean annotAll,
                               boolean annotNone)
construct the panel for the display options

Parameters:
hideSource -
minVertex -
fontSize -
backColor -
noBlackCircle -
scalePos -
noAnim -
annotAll -
annotNone -

createCVSOptions

private void createCVSOptions(int timeWindow)
construct the panel for the CVS options

Parameters:
timeWindow -

createFilenameFilter

private void createFilenameFilter()

enableMinimizerOptions

private void enableMinimizerOptions(boolean b)
en/disable the part concerning the minimizer

Parameters:
b -

enableCVSOptions

private void enableCVSOptions(boolean b)
en/disable the part concerning CVS

Parameters:
b -

enableDISPOptions

private void enableDISPOptions(boolean b)
en/disable the part concerning the display

Parameters:
b -

enableSVGOptions

private void enableSVGOptions(boolean b)
en/disable the part concerning SVG and VRML format

Parameters:
b -

loadDialog

private java.lang.String loadDialog()
dialog to select a file to load

Returns:
return a String containing the fliename

loadInitlayDialog

private java.lang.String loadInitlayDialog()
dialog to select the initial layout

Returns:
return a String containing the fliename

saveDialog

private java.lang.String saveDialog()
dialog to select an output file

Returns:
return a String containing the filename

main

public static void main(java.lang.String[] args)