|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
javax.swing.JFrame
uk.ac.starlink.splat.iface.FlipFrame
public class FlipFrame
Provides a toolbox for optionally flipping and translating a modifiable spectrum. Flipping allows the detailed line shape to be compared.
Nested Class Summary | |
---|---|
protected class |
FlipFrame.LocalAction
Inner class defining all local Actions. |
protected class |
FlipFrame.StateStore
|
protected class |
FlipFrame.StoredProperties
|
Nested classes/interfaces inherited from class javax.swing.JFrame |
---|
JFrame.AccessibleJFrame |
Nested classes/interfaces inherited from class java.awt.Frame |
---|
Frame.AccessibleAWTFrame |
Nested classes/interfaces inherited from class java.awt.Window |
---|
Window.AccessibleAWTWindow |
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 | |
---|---|
protected JComboBox |
availableSpectra
JComboBox that displays the list of available spectra. |
protected JPanel |
contentPane
Content pane of frame. |
protected uk.ac.starlink.util.gui.BasicFileChooser |
fileChooser
File chooser used for line visitor files |
protected JCheckBox |
flipBox
Flip state. |
protected uk.ac.starlink.ast.gui.DecimalField |
flipCentre
Flip coordinate. |
protected GlobalSpecPlotList |
globalList
The global list of spectra and plots. |
protected uk.ac.starlink.ast.gui.DecimalField |
incrementSpinner
Spinner increment. |
protected SpinnerNumberModel |
offsetModel
And the model. |
protected uk.ac.starlink.ast.gui.ScientificSpinner |
offsetSpinner
User offset control. |
protected PlotControl |
plot
The PlotControl that is displaying the current spectrum. |
protected static Preferences |
prefs
UI preferences. |
protected JCheckBox |
redshiftBox
Is offset to be interpreted as a redshift? |
protected JCheckBoxMenuItem |
singleComparisonBox
Menu item retaining state of visitor state changes |
protected JTextArea |
spefoArea
Simple text area for SPEFO values. |
protected JCheckBoxMenuItem |
spefoBox
Menu item retaining state of SPEFO changes |
protected JTextArea |
spefoNotes
|
protected double |
spefoOffset
|
protected double |
spefoRV
|
protected Map |
storedPropertiesMap
List of spectra and properties that we have modified. |
Fields inherited from class javax.swing.JFrame |
---|
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled |
Fields inherited from class java.awt.Frame |
---|
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface javax.swing.WindowConstants |
---|
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
FlipFrame(PlotControl plot)
Create an instance. |
Method Summary | |
---|---|
void |
actionPerformed(ActionEvent e)
|
protected void |
addSpectrum(EditableSpecData spectrum,
boolean replace)
Add a spectrum to the changed list. |
protected void |
applyOffset()
Apply the current offset to the selected spectrum. |
protected void |
closeWindowEvent(boolean reset)
Close the window. |
protected void |
copyFlipCurrentSpectrum()
Make a copy of the current spectrum and apply a flip, if requested. |
protected EditableSpecData |
getComparisonSpectrum()
Access the comparison spectrum, this is the one selected in the JComboBox of spectra. |
Object |
getLineState()
Return any state information about the current line. |
PlotControl |
getPlot()
Get the PlotControl that we are using. |
protected FlipFrame.StoredProperties |
getStoredProperties(EditableSpecData spectrum)
Get the StoredProperties instance for a spectrum. |
protected void |
initFileChooser()
Initialise the file chooser to have the necessary filters. |
protected void |
initFrame()
Initialise frame properties (disposal, title, menus etc.). |
protected void |
initUI()
Initialise the main part of the user interface. |
void |
itemStateChanged(ItemEvent e)
|
protected void |
makeSpefoChanges()
Make SPEFO-like changes to interface ala Petr Skoda. |
void |
plotChanged(PlotChangedEvent e)
Sent when a plot property is changed (i.e. |
void |
plotCreated(PlotChangedEvent e)
Sent when a plot is created. |
void |
plotRemoved(PlotChangedEvent e)
Sent when a plot is removed. |
protected void |
readVisitorLineList()
Read a line list of positions and initialise the LineVisitor with them. |
protected boolean |
redshiftSpecFrameSet(uk.ac.starlink.ast.FrameSet frameSet,
boolean islineid,
double redshift)
Transform the spectral coordinates of a FrameSet by a redshift factor. |
protected void |
resetSelectedSpectrum()
Reset selected spectrum to it default offset. |
void |
setPlot(PlotControl plot)
Set the PlotControlFrame that has the spectrum that we are to process. |
protected void |
setVisitorLineList()
Set the comparison spectrum as the visitor line list. |
protected void |
spefoSave()
Append the contents of the SPEFO areas to the file SPEFO.log. |
void |
stateChanged(ChangeEvent e)
|
protected void |
updateNames()
Update the spectra available for translation. |
void |
viewLine(double coord,
uk.ac.starlink.ast.Frame coordFrame,
Object state)
Move to a view of a line, possibilty restoring some related state information. |
void |
viewSpectrum(SpecData specData)
Display a spectrum. |
Methods inherited from class java.awt.Frame |
---|
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.awt.MenuContainer |
---|
getFont, postEvent |
Field Detail |
---|
protected static Preferences prefs
protected Map storedPropertiesMap
protected JComboBox availableSpectra
protected JCheckBox flipBox
protected JCheckBox redshiftBox
protected uk.ac.starlink.ast.gui.ScientificSpinner offsetSpinner
protected SpinnerNumberModel offsetModel
protected uk.ac.starlink.ast.gui.DecimalField incrementSpinner
protected uk.ac.starlink.ast.gui.DecimalField flipCentre
protected GlobalSpecPlotList globalList
protected JPanel contentPane
protected PlotControl plot
protected JCheckBoxMenuItem spefoBox
protected JTextArea spefoArea
protected JTextArea spefoNotes
protected double spefoOffset
protected double spefoRV
protected JCheckBoxMenuItem singleComparisonBox
protected uk.ac.starlink.util.gui.BasicFileChooser fileChooser
Constructor Detail |
---|
public FlipFrame(PlotControl plot)
Method Detail |
---|
public PlotControl getPlot()
public void setPlot(PlotControl plot)
plot
- the PlotControl reference.protected void initUI()
protected void initFrame()
protected void copyFlipCurrentSpectrum()
protected boolean redshiftSpecFrameSet(uk.ac.starlink.ast.FrameSet frameSet, boolean islineid, double redshift)
protected void updateNames()
protected EditableSpecData getComparisonSpectrum()
protected FlipFrame.StoredProperties getStoredProperties(EditableSpecData spectrum)
protected void applyOffset()
protected void addSpectrum(EditableSpecData spectrum, boolean replace)
protected void resetSelectedSpectrum()
protected void readVisitorLineList()
protected void initFileChooser()
protected void setVisitorLineList()
protected void makeSpefoChanges()
protected void spefoSave()
protected void closeWindowEvent(boolean reset)
public void stateChanged(ChangeEvent e)
stateChanged
in interface ChangeListener
public void plotCreated(PlotChangedEvent e)
PlotListener
plotCreated
in interface PlotListener
public void plotRemoved(PlotChangedEvent e)
PlotListener
plotRemoved
in interface PlotListener
public void plotChanged(PlotChangedEvent e)
PlotListener
plotChanged
in interface PlotListener
public void itemStateChanged(ItemEvent e)
itemStateChanged
in interface ItemListener
public void actionPerformed(ActionEvent e)
actionPerformed
in interface ActionListener
public void viewSpectrum(SpecData specData)
LineProvider
viewSpectrum
in interface LineProvider
specData
- the spectrum to displaypublic void viewLine(double coord, uk.ac.starlink.ast.Frame coordFrame, Object state)
LineProvider
viewLine
in interface LineProvider
coord
- the coordinate of the line in wcs units.coordFrame
- Frame
defining the coordinate system and
units. This should be used to transform into the
coordinate system as understood by the LineProvider.state
- previously returned state information, null for none.public Object getLineState()
LineProvider
getLineState
in interface LineProvider
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |