|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
jview.JNormalizedCanvas
stella.jview.JAltAzTelescope
public class JAltAzTelescope
A class that displays the current alt/az position of the telescope in polar coordinates. The position of the derotator, iof applicable, is shown like a counter-clockwise clockarm.
| Nested Class Summary | |
|---|---|
static class |
JAltAzTelescope.Show
Tests the class. |
| Nested classes/interfaces inherited from class jview.JNormalizedCanvas |
|---|
JNormalizedCanvas.ShowImage, JNormalizedCanvas.Test |
| Nested classes/interfaces inherited from class javax.swing.JComponent |
|---|
JComponent.AccessibleJComponent |
| Nested classes/interfaces inherited from class java.awt.Container |
|---|
Container.AccessibleAWTContainer |
| Nested classes/interfaces inherited from class java.awt.Component |
|---|
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy |
| Field Summary | |
|---|---|
private Double |
altitudecur
The last altitude of the telescope assigned to the canvas. |
private Double |
altitudedes
The desired altitude of the telescope assigned to the canvas. |
private Double |
azimuthcur
The last azimuth of the telescope assigned to the canvas. |
private Double |
azimuthdes
The desired azimuth of the telescope assigned to the canvas. |
private static int |
DEFALTITUDEGRID
Default azimuth steps. |
private static int |
DEFAZIMUTHGRID
Default azimuth steps. |
private static Color |
DEFBACKGROUND
We paint white on black. |
private static double |
DEFDEROTATORSIZE
The normalized length of the derotator locator line. |
private static Color |
DEFDESIREDCOLOR
The color the telescope is drawn in. |
private static Color |
DEFFOREGROUND
We paint white on black. |
private static int |
DEFPREFERREDHEIGHT
Default preferred size. |
private static int |
DEFPREFERREDWIDTH
Default preferred size. |
private static Color |
DEFTELESCOPECOLOR
The color the telescope is drawn in. |
private static double |
DEFTELESCOPESIZE
The normalized diameter of the telescope locator ellipse. |
private Double |
derotcur
The last derotator position assigned to the canvas. |
private Double |
derotdes
The desired derotator position assigned to the canvas. |
static String |
KEY_ALTITUDEGRID
A key to the altitude steps in degrees. |
static String |
KEY_AZIMUTHGRID
A key to the azimuth steps in degrees. |
static String |
KEY_DEROTATORSIZE
A key to the normalized size of the derotator locator. |
static String |
KEY_DESIREDCOLOR
A key to the desired location color. |
static String |
KEY_TELESCOPECOLOR
A key to the telescope location color. |
static String |
KEY_TELESCOPESIZE
A key to the normalized size of the telescope locator. |
| Fields inherited from class javax.swing.JComponent |
|---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Component |
|---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
|---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
|---|---|
JAltAzTelescope(ResourceSupplying prop)
Use a property bering for construction. |
|
| Method Summary | |
|---|---|
void |
init()
After init, we add the azimuth/altitude grid. |
protected void |
paintObjects(Graphics g,
AffineTransform af)
After painting the objects, we draw the location of the telescope, if we have it. |
private void |
paintTelescope(Graphics2D g2d,
Double azimuth,
Double altitude,
Double derot,
Color telcol,
double tsize,
double dsize,
AffineTransform af)
Draw the telescope |
void |
setComposedProperties(ResourceSupplying prop)
Defaults the grid steps and the prefereed size. |
void |
setTelescopeCurrent(double az,
double alt)
Sets a new position of the telescope. |
void |
setTelescopeCurrent(double az,
double alt,
double derotator)
Sets a new position of the telescope and the derotator value. |
void |
setTelescopeDesired(double az,
double alt)
Sets a new desired position of the telescope. |
void |
setTelescopeDesired(double az,
double alt,
double derotator)
Sets a new desired position of the telescope and the derotator value. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final String KEY_AZIMUTHGRID
public static final String KEY_ALTITUDEGRID
public static final String KEY_DESIREDCOLOR
public static final String KEY_TELESCOPECOLOR
public static final String KEY_TELESCOPESIZE
public static final String KEY_DEROTATORSIZE
private static final int DEFAZIMUTHGRID
private static final int DEFALTITUDEGRID
private static final int DEFPREFERREDWIDTH
private static final int DEFPREFERREDHEIGHT
private static final Color DEFFOREGROUND
private static final Color DEFBACKGROUND
private static final Color DEFDESIREDCOLOR
private static final Color DEFTELESCOPECOLOR
private static final double DEFTELESCOPESIZE
private static final double DEFDEROTATORSIZE
private Double azimuthcur
private Double altitudecur
private Double derotcur
private Double azimuthdes
private Double altitudedes
private Double derotdes
| Constructor Detail |
|---|
public JAltAzTelescope(ResourceSupplying prop)
| Method Detail |
|---|
public void setComposedProperties(ResourceSupplying prop)
setComposedProperties in interface ResourceAwaresetComposedProperties in class JNormalizedCanvaspublic void init()
init in interface Initializableinit in class JNormalizedCanvas
protected void paintObjects(Graphics g,
AffineTransform af)
paintObjects in class JNormalizedCanvas
private void paintTelescope(Graphics2D g2d,
Double azimuth,
Double altitude,
Double derot,
Color telcol,
double tsize,
double dsize,
AffineTransform af)
public void setTelescopeCurrent(double az,
double alt)
public void setTelescopeCurrent(double az,
double alt,
double derotator)
public void setTelescopeDesired(double az,
double alt)
public void setTelescopeDesired(double az,
double alt,
double derotator)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||