JClass DesktopViews 6.3.0 API
Documentation

com.klg.jclass.swing.gauge
Class GaugeConstraint

java.lang.Object
  |
  +--com.klg.jclass.swing.gauge.GaugeConstraint
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
LinearConstraint, RadialConstraint

public abstract class GaugeConstraint
extends Object
implements Serializable

A GaugeConstraint is one that provides layout information for a component that needs to be placed on a circular or linear gauge. It provides information on the radial or linear extent of the component.

See Also:
Serialized Form

Field Summary
protected  double extent
          For circular scales, the ratio of the radius away from the center at which to place this label.
protected  com.klg.jclass.swing.gauge.JCGauge gauge
          The gauge, upon whose gauge area this constraint is based.
 
Constructor Summary
GaugeConstraint(com.klg.jclass.swing.gauge.JCGauge gauge, double extent)
          Constructor for GaugeConstraint using a JCGauge as the component.
 
Method Summary
 double getExtent()
          Returns the extent at which this component will be placed.
 com.klg.jclass.swing.gauge.JCGauge getGauge()
          Returns the JCGauge on which this constraint will be used
 void setExtent(double extent)
          Sets the extent at which this component will be placed.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

extent

protected double extent
For circular scales, the ratio of the radius away from the center at which to place this label. For linear scales, the ratio of the width or height away from the top left of the scale.


gauge

protected com.klg.jclass.swing.gauge.JCGauge gauge
The gauge, upon whose gauge area this constraint is based.

Constructor Detail

GaugeConstraint

public GaugeConstraint(com.klg.jclass.swing.gauge.JCGauge gauge,
                       double extent)
Constructor for GaugeConstraint using a JCGauge as the component.

Parameters:
gauge - The associated gauge
extent - For circular scales, the ratio of the radius away from the center at which to place a label. For linear scales, the ratio of the width or height away from the top left of the scale.
Method Detail

getExtent

public double getExtent()
Returns the extent at which this component will be placed.

Returns:
The extent at which this component will be placed

setExtent

public void setExtent(double extent)
Sets the extent at which this component will be placed.

Parameters:
extent - The extent at which to place this component

getGauge

public com.klg.jclass.swing.gauge.JCGauge getGauge()
Returns the JCGauge on which this constraint will be used

Returns:
The gauge on which this constraint will be used

Copyright © 2004 Quest Software Inc..
All rights reserved.