All Packages  This Package  Class Hierarchy  Class Search  Index

Class kh.awt.ScaledDial
java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----javax.swing.JComponent
                           |
                           +----kh.awt.Dial
                                   |
                                   +----kh.awt.AnalogDial
                                           |
                                           +----kh.awt.ScaledDial

  Summary

public abstract class  ScaledDial
     extends kh.awt.AnalogDial
{
          // Fields 8
     public static final Color defaultLabelColor;
     public static final Color defaultScaleColor;
     public static final Color defaultScaleXORColor;
     protected int labelSkip;
     protected double maxDegrees;
     protected double minDegrees;
     protected int numDivisions;
     protected double stepsPerDivision;

          // Constructors 1
     public ScaledDial();

          // Methods 10
     protected double degreeFromValue(double);
     protected void paintComponent(Graphics);
     protected int scaleGetInnerRadius();
     protected int scaleGetLabelRadius();
     protected int scaleGetNumberRadius();
     protected int scaleGetOuterRadius();
     public void setLabelSkip(int);
     public void setNumDivisions();
     public void setNumDivisions(int);
     public void setStepsPerDivision(double);
}

This class adds a numeric scale around the dial


  Cross Reference

Extended By:
HandedDial





  Fields

· defaultLabelColor

Summary  |  Top
   public static final Color defaultLabelColor


· defaultScaleColor

Summary  |  Top
   public static final Color defaultScaleColor


· defaultScaleXORColor

Summary  |  Top
   public static final Color defaultScaleXORColor


· labelSkip

Summary  |  Top
   protected int labelSkip

We only label every labelSkip division


· maxDegrees

Summary  |  Top
   protected double maxDegrees


· minDegrees

Summary  |  Top
   protected double minDegrees


· numDivisions

Summary  |  Top
   protected int numDivisions


· stepsPerDivision

Summary  |  Top
   protected double stepsPerDivision


  Constructors

· ScaledDial

Summary  |  Top

   public ScaledDial() 

Default constructor



  Methods

· degreeFromValue

Summary  |  Top
   protected double degreeFromValue(double value) 


· paintComponent

Summary  |  Top
   protected void paintComponent(Graphics g) 
Overrides:
paintComponent in class AnalogDial


· scaleGetInnerRadius

Summary  |  Top
   protected int scaleGetInnerRadius() 


· scaleGetLabelRadius

Summary  |  Top
   protected int scaleGetLabelRadius() 

The outer radius of a tick mark when we are also showing a label



· scaleGetNumberRadius

Summary  |  Top
   protected int scaleGetNumberRadius() 


· scaleGetOuterRadius

Summary  |  Top
   protected int scaleGetOuterRadius() 

The outer radius of a tick mark when we are NOT showing a label



· setLabelSkip

Summary  |  Top
   public void setLabelSkip(int skip) 


· setNumDivisions

Summary  |  Top
   public void setNumDivisions() 

Create a default number of divisions by scaling between min and max based on steps per division. Print a max of 10 labels



· setNumDivisions

Summary  |  Top
   public void setNumDivisions(int value) 


· setStepsPerDivision

Summary  |  Top
   public void setStepsPerDivision(double value) 


All Packages  This Package  Class Hierarchy  Class Search  Index
Freshly brewed Java API Documentation automatically generated with polardoc Version 1.0.7