jebl.gui.trees.treeviewer_dev.treelayouts
Class PolarTreeLayout

java.lang.Object
  extended by jebl.gui.trees.treeviewer_dev.treelayouts.AbstractTreeLayout
      extended by jebl.gui.trees.treeviewer_dev.treelayouts.PolarTreeLayout
All Implemented Interfaces:
TreeLayout

public class PolarTreeLayout
extends AbstractTreeLayout

Author:
Andrew Rambaut

Nested Class Summary
static class PolarTreeLayout.TipLabelPosition
           
 
Nested classes/interfaces inherited from interface jebl.gui.trees.treeviewer_dev.treelayouts.TreeLayout
TreeLayout.AxisType
 
Field Summary
 
Fields inherited from class jebl.gui.trees.treeviewer_dev.treelayouts.AbstractTreeLayout
branchColouringAttribute, branchLabelPaths, branchPaths, calloutPaths, collapseAttributeName, collapsedShapes, nodeBarPaths, nodeLabelPaths, nodePoints, showingCollapsedTipLabels, tipLabelPaths, tree
 
Constructor Summary
PolarTreeLayout()
           
 
Method Summary
 double getAngularRange()
           
 Shape getHeightArea(double height1, double height2)
          Return a shape that defines a particular height interval.
 Shape getHeightLine(double height)
          Return a line that defines a particular height.
 double getHeightOfPoint(Point2D point)
           
 double getRootAngle()
           
 double getRootLength()
           
 PolarTreeLayout.TipLabelPosition getTipLabelPosition()
           
 TreeLayout.AxisType getXAxisType()
          Return whether the x axis is continuous or discrete
 TreeLayout.AxisType getYAxisType()
          Return whether the y axis is continuous or discrete
 boolean isShowingRootBranch()
          Return whether this layout displays a root branch
 boolean maintainAspectRatio()
          Return whether the two axis scales should be maintained relative to each other
 void setAngularRange(double angularRange)
           
 void setRootAngle(double rootAngle)
           
 void setRootLength(double rootLength)
           
 void setShowingRootBranch(boolean showingRootBranch)
           
 void setTipLabelPosition(PolarTreeLayout.TipLabelPosition tipLabelPosition)
           
protected  void validate()
           
 
Methods inherited from class jebl.gui.trees.treeviewer_dev.treelayouts.AbstractTreeLayout
addTreeLayoutListener, fireTreeLayoutChanged, getBranchColouringAttribute, getBranchLabelPath, getBranchLabelPathMap, getBranchPath, getBranchPathMap, getCalloutPath, getCalloutPathMap, getCollapseAttributeName, getCollapsedShape, getCollapsedShapeMap, getNodeBarPath, getNodeBarPathMap, getNodeLabelPath, getNodeLabelPathMap, getNodePoint, getTipLabelPath, getTipLabelPathMap, invalidate, isShowingCollapsedTipLabels, isShowingColouring, removeTreeLayoutListener, setBranchColouringAttribute, setCollapseAttributeName, setShowingCollapsedTipLabels, setTree
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PolarTreeLayout

public PolarTreeLayout()
Method Detail

getXAxisType

public TreeLayout.AxisType getXAxisType()
Description copied from interface: TreeLayout
Return whether the x axis is continuous or discrete

Returns:
the axis type

getYAxisType

public TreeLayout.AxisType getYAxisType()
Description copied from interface: TreeLayout
Return whether the y axis is continuous or discrete

Returns:
the axis type

maintainAspectRatio

public boolean maintainAspectRatio()
Description copied from interface: TreeLayout
Return whether the two axis scales should be maintained relative to each other

Returns:
a boolean

getHeightOfPoint

public double getHeightOfPoint(Point2D point)

getHeightLine

public Shape getHeightLine(double height)
Description copied from interface: TreeLayout
Return a line that defines a particular height. Some layouts won't be able to produce this and may throw an UnsupportedOperationException.

Returns:
the line

getHeightArea

public Shape getHeightArea(double height1,
                           double height2)
Description copied from interface: TreeLayout
Return a shape that defines a particular height interval. Some layouts won't be able to produce this and may throw an UnsupportedOperationException.

Returns:
the area

getRootAngle

public double getRootAngle()

getAngularRange

public double getAngularRange()

isShowingRootBranch

public boolean isShowingRootBranch()
Description copied from interface: TreeLayout
Return whether this layout displays a root branch

Returns:
showing root branch?

getRootLength

public double getRootLength()

getTipLabelPosition

public PolarTreeLayout.TipLabelPosition getTipLabelPosition()

setRootAngle

public void setRootAngle(double rootAngle)

setAngularRange

public void setAngularRange(double angularRange)

setShowingRootBranch

public void setShowingRootBranch(boolean showingRootBranch)

setRootLength

public void setRootLength(double rootLength)

setTipLabelPosition

public void setTipLabelPosition(PolarTreeLayout.TipLabelPosition tipLabelPosition)

validate

protected void validate()
Specified by:
validate in class AbstractTreeLayout