org.omegahat.Graphics.Plots
Class LeftAxis

java.lang.Object
  |
  +--org.omegahat.Graphics.Primitives.GraphicalObject
        |
        +--org.omegahat.Graphics.Primitives.RGO
              |
              +--org.omegahat.Graphics.Primitives.GraphicalContainer
                    |
                    +--org.omegahat.Graphics.Plots.Axis
                          |
                          +--org.omegahat.Graphics.Plots.LeftAxis
All Implemented Interfaces:
Addable, AxisInt, Copyable, GraphicalComponentInt, GraphicalContainerInt, MathOperable, ScaledComponentInt, SimpleGraphicalContainerInt, Subsettable, Tree

public class LeftAxis
extends Axis

an Axis object for the left margin, with ticks pointing to the right.


Fields inherited from class org.omegahat.Graphics.Plots.Axis
axisLabel, DEFAULT_NTICKS, nTicks, tickLabel, tickLocn, ticks
 
Fields inherited from class org.omegahat.Graphics.Primitives.GraphicalContainer
allocator, children, origin, parent, scaleX, scaleY
 
Fields inherited from class org.omegahat.Graphics.Primitives.RGO
region
 
Fields inherited from class org.omegahat.Graphics.Primitives.GraphicalObject
ACTIVE, fontSize, lastDevice, lastHeightCM, lastRegion, lastWidthCM, parents, status, VISIBLE
 
Fields inherited from interface org.omegahat.Environment.DataStructures.MathOperable
DIVIDE, MINUS, MULTIPLY, PLUS
 
Constructor Summary
LeftAxis(ScaleInt s, double[] tickLocn, java.lang.String[] tickLabel, java.lang.String label)
          a constructor when you want to do it all yourself.
LeftAxis(ScaleInt s, java.lang.String label)
          use the given scale, choosing pretty tick locations and generating tick labels from the corresponding numbers.
 
Method Summary
 void editScale(double min, double max)
          Change the scale to the given minimum and maximum.
 ScaleInt getScale()
          Get the scale object for this axis
 void makeContainer(ScaleInt sy)
          make the axis, given the tick positions and labels.
 void makeLabel(java.lang.String label)
          Make this string the label for the entire axis.
 void makeMajor()
           
 void makeTicks(ScaleInt s, double[] tickY, java.lang.String[] tickLabel)
           
 
Methods inherited from class org.omegahat.Graphics.Plots.Axis
create, createTickData, getAxisLabel, getNTicks, getTickLabels, getTickLocations, makeAxis, removeTicks, setAxisLabel, setNTicks, setTickLabels, setTickLocations
 
Methods inherited from class org.omegahat.Graphics.Primitives.GraphicalContainer
add, addGraphicalObject, addGraphicalObject, addGraphicalObject, addGraphicalObject, addGraphicalObject, addGraphicalObject, addGraphicalObject, addGraphicalObject, addGraphicalObject, addGraphicalObject, addValue, copy, copy, draw, drawChildren, get, getChild, getChildCount, getChildren, getDevice, getOrigin, getRegionAllocator, getXScale, getYScale, parent, parent, remove, removeGraphicalObject, removeGraphicalObject, setOrigin, setRegionAllocator, setXScale, setYScale, subset, subset, transform, transform
 
Methods inherited from class org.omegahat.Graphics.Primitives.RGO
center, centre, createRegionDescription, createRegionDescription, getRegion, height, height, setHJust, setRegion, setVJust, width, width, x, x, y, y
 
Methods inherited from class org.omegahat.Graphics.Primitives.GraphicalObject
cacheSize, getFontSize, getFontSize, getParameters, getParents, getStatus, isActive, isVisible, lastHeightCM, lastRegion, lastWidthCM, parents, setActive, setParameters, setParents, setVisible
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.omegahat.Graphics.Primitives.ScaledComponentInt
getXScale, getYScale, setXScale, setYScale
 
Methods inherited from interface org.omegahat.Graphics.Primitives.GraphicalComponentInt
draw, getParameters, getRegion, isActive, isVisible, parent, parent, parents, setActive, setParameters, setRegion, setVisible
 

Constructor Detail

LeftAxis

public LeftAxis(ScaleInt s,
                double[] tickLocn,
                java.lang.String[] tickLabel,
                java.lang.String label)
a constructor when you want to do it all yourself.

LeftAxis

public LeftAxis(ScaleInt s,
                java.lang.String label)
use the given scale, choosing pretty tick locations and generating tick labels from the corresponding numbers.
Method Detail

getScale

public ScaleInt getScale()
Description copied from interface: AxisInt
Get the scale object for this axis
Overrides:
getScale in class Axis

editScale

public void editScale(double min,
                      double max)
Description copied from class: Axis
Change the scale to the given minimum and maximum.

The bottom axis and left axis define this to recreate the suitable ticks, etc.

Overrides:
editScale in class Axis

makeContainer

public void makeContainer(ScaleInt sy)
make the axis, given the tick positions and labels.

Not usually called directly, but from the constructor or from a transformation.

Overrides:
makeContainer in class Axis

makeMajor

public void makeMajor()
Overrides:
makeMajor in class Axis

makeLabel

public void makeLabel(java.lang.String label)
Description copied from interface: AxisInt
Make this string the label for the entire axis.
Overrides:
makeLabel in class Axis

makeTicks

public void makeTicks(ScaleInt s,
                      double[] tickY,
                      java.lang.String[] tickLabel)
Overrides:
makeTicks in class Axis