com.googlecode.sarasvati.visual
Class DefaultGraphLookAndFeel
java.lang.Object
com.googlecode.sarasvati.visual.DefaultGraphLookAndFeel
- All Implemented Interfaces:
- GraphLookAndFeel
public class DefaultGraphLookAndFeel
- extends Object
- implements GraphLookAndFeel
Generates widgets for nodes using the Adaptable.getAdaptor(Class) method,
passing in the Component class. It will wrap the returned component
in a ComponentWidget instance.
- Author:
- Paul Lorenz
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
INSTANCE
public static final DefaultGraphLookAndFeel INSTANCE
drawSelfArcs
protected boolean drawSelfArcs
drawArcLabels
protected boolean drawArcLabels
DefaultGraphLookAndFeel
public DefaultGraphLookAndFeel(boolean drawSelfArcs,
boolean drawArcLabels)
drawArcLabels
public boolean drawArcLabels(Arc arc)
- Description copied from interface:
GraphLookAndFeel
- Controls if arc labels should be drawn.
- Specified by:
drawArcLabels in interface GraphLookAndFeel
- Returns:
- True if arc labels should be drawn, false otherwise
drawSelfArcs
public boolean drawSelfArcs(Arc arc)
- Description copied from interface:
GraphLookAndFeel
- Controls if self arcs should be drawn.
- Specified by:
drawSelfArcs in interface GraphLookAndFeel
- Returns:
- True if self arcs should be drawn, false otherwise
newWidget
public org.netbeans.api.visual.widget.Widget newWidget(Node node,
SarasvatiGraphScene scene)
- Description copied from interface:
GraphLookAndFeel
- Returns a new Widget to represent the given node.
- Specified by:
newWidget in interface GraphLookAndFeel
- Parameters:
node - The node we need a widget forscene - The scene the widget is created in
- Returns:
- A new widget for the given node
Copyright © 2012. All Rights Reserved.