Class DistLinePanel
java.lang.Object | +----java.awt.Component | +----java.awt.Canvas | +----Plane | +----DistLinePanel
- public class DistLinePanel
- extends Plane
- Author:
- Jonathan A. Poritz
- CX
- The abstract x-coordinate of the left side of the axis distance display.
- CY
- The abstract y-coordinate of the upper edge of the axis distance display.
- inputpanel
- A reference to the containing inputpanel.
- previ
- The location of a mousedown in this plane, to compute the extent of a drag that may occur; in pixel coordinates.
- SX
- The width, in abstract units, of the axis distance display.
- SY
- The height, in abstract units, of the axis distance display.
- X
- The width, in pixels, of the axis distance display.
- Y
- The height, in pixels, of the axis distance display.
- DistLinePanel(InputPanel)
- Constructor for DistLinePanels.
- paint(Graphics)
- Paint the DistLinePanel, by painting the parent Plane, putting a mark at the currently selected axis distance and making tickmarks.
- zoom(double)
- Scales the size of the visible window onto the line of axis distances
inputpanel
public InputPanel inputpanel
- A reference to the containing inputpanel.
- See Also:
- inputpanel
protected int previ[]
- The location of a mousedown in this plane, to compute the extent of
a drag that may occur; in pixel coordinates.
public static final double CX
- The abstract x-coordinate of the left side of the axis distance display.
public static final double CY
- The abstract y-coordinate of the upper edge of the axis distance display.
public static final double SX
- The width, in abstract units, of the axis distance display.
public static final double SY
- The height, in abstract units, of the axis distance display.
public static final int X
- The width, in pixels, of the axis distance display. Good defaults are:
- 25
- for small screens, and
- 50
- for large screens
public static final int Y
- The height, in pixels, of the axis distance display. Good defaults are:
- 200
- for small screens, and
- 300
- for large screens
DistLinePanel
public DistLinePanel(InputPanel nptpnl)
- Constructor for DistLinePanels.
- Parameters:
- nptpnl - the ambient inputpanel
paint
public void paint(Graphics g)
- Paint the DistLinePanel, by painting the parent Plane, putting a mark
at the currently selected axis distance and making tickmarks.
public void zoom(double factor)
- Scales the size of the visible window onto the line of axis distances
- Parameters:
- factor - the scaling factor, can be any positive number