|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
java.awt.Window
java.awt.Frame
ij.gui.ImageWindow
ij.gui.PlotWindow
public class PlotWindow
This class implements the Analyze/Plot Profile command.
| Nested Class Summary |
|---|
| 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 | |
|---|---|
static boolean |
autoClose
Automatically close window after saving values. |
static int |
BOX
Display points using an box-shaped mark. |
static int |
CIRCLE
Display points using a circle 5 pixels in diameter. |
static int |
CROSS
Display points using an cross-shaped mark. |
static int |
fontSize
The plot text size, can be overridden by Plot.setFont, Plot.setFontSize, Plot.setXLabelFont etc. |
static boolean |
interpolate
Interpolate line profiles. |
static int |
LINE
Connect points with solid lines. |
static boolean |
listValues
Display the XY coordinates in a separate window. |
static boolean |
noGridLines
Have axes with no grid lines. |
static boolean |
noTicks
Have axes with no ticks. |
static int |
plotHeight
The height of the plot in pixels. |
static int |
plotWidth
The width of the plot (without frame) in pixels. |
static boolean |
saveXValues
Write first X column when listing or saving. |
static int |
TRIANGLE
Display points using an tiangular mark. |
static int |
X
Display points using an X-shaped mark. |
| Fields inherited from class ij.gui.ImageWindow |
|---|
closed, HGAP, ic, ij, imp, MIN_HEIGHT, MIN_WIDTH, running, running2, VGAP |
| 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 ij.gui.RoiListener |
|---|
COMPLETED, CREATED, DELETED, EXTENDED, MODIFIED, MOVED |
| Fields inherited from interface java.awt.image.ImageObserver |
|---|
ABORT, ALLBITS, ERROR, FRAMEBITS, PROPERTIES, SOMEBITS |
| Constructor Summary | |
|---|---|
PlotWindow(String title,
String xLabel,
String yLabel,
double[] xValues,
double[] yValues)
Deprecated. replaced by the Plot class. |
|
PlotWindow(String title,
String xLabel,
String yLabel,
float[] xValues,
float[] yValues)
Deprecated. replaced by the Plot class. |
|
| Method Summary | |
|---|---|
void |
actionPerformed(ActionEvent e)
Called if user has activated a button or popup menu item |
void |
addErrorBars(float[] errorBars)
Adds vertical error bars to the plot. |
void |
addLabel(double x,
double y,
String label)
Draws a label. |
void |
addPoints(double[] x,
double[] y,
int shape)
Adds a set of points to the plot using double arrays. |
void |
addPoints(float[] x,
float[] y,
int shape)
Adds a set of points to the plot or adds a curve if shape is set to LINE. |
void |
changeFont(Font font)
Changes the font. |
void |
dispose()
Releases the resources used by this PlotWindow |
void |
draw()
Displays the plot. |
void |
drawPlot(Plot plot)
Draws a new plot in this window. |
static void |
freeze()
Freezes the active plot window. |
Plot |
getPlot()
Returns the Plot associated with this PlotWindow. |
ResultsTable |
getResultsTable()
Returns the plot values as a ResultsTable. |
float[] |
getXValues()
|
float[] |
getYValues()
|
void |
imageClosed(ImagePlus imp)
|
void |
imageOpened(ImagePlus imp)
|
void |
imageUpdated(ImagePlus imp)
For live plots, this method is called if the source image content is changed |
void |
itemStateChanged(ItemEvent e)
Called if the user activates/deactivates a CheckboxMenuItem |
void |
lostOwnership(Clipboard clipboard,
Transferable contents)
|
void |
mouseMoved(int x,
int y)
Updates the X and Y values when the mouse is moved and, if appropriate, shows/hides the overlay with the triangular buttons for changing the axis range limits Overrides mouseMoved() in ImageWindow. |
void |
mouseWheelMoved(MouseWheelEvent e)
Mouse wheel: zooms when shift or ctrl is pressed, scrolls in x if space bar down, in y otherwise. |
void |
roiModified(ImagePlus img,
int id)
For live plots, update the plot if the ROI of the source image changes |
void |
run()
|
static void |
savePreferences(Properties prefs)
Called once when ImageJ quits. |
void |
setColor(Color c)
Changes the drawing color. |
void |
setLimits(double xMin,
double xMax,
double yMin,
double yMax)
Sets the x-axis and y-axis range. |
void |
setLineWidth(int lineWidth)
Changes the line width. |
| Methods inherited from class java.awt.Frame |
|---|
addNotify, getAccessibleContext, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, paramString, remove, removeNotify, setCursor, setExtendedState, setIconImage, 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 |
|---|
public static final int CIRCLE
public static final int X
public static final int BOX
public static final int TRIANGLE
public static final int CROSS
public static final int LINE
public static boolean saveXValues
public static boolean autoClose
public static boolean listValues
public static boolean interpolate
public static int plotWidth
public static int plotHeight
public static int fontSize
public static boolean noGridLines
public static boolean noTicks
| Constructor Detail |
|---|
public PlotWindow(String title,
String xLabel,
String yLabel,
float[] xValues,
float[] yValues)
public PlotWindow(String title,
String xLabel,
String yLabel,
double[] xValues,
double[] yValues)
| Method Detail |
|---|
public void setLimits(double xMin,
double xMax,
double yMin,
double yMax)
public void addPoints(float[] x,
float[] y,
int shape)
x - the x-coodinatesy - the y-coodinatesshape - Plot.CIRCLE, X, BOX, TRIANGLE, CROSS, LINE etc.
public void addPoints(double[] x,
double[] y,
int shape)
public void addErrorBars(float[] errorBars)
public void addLabel(double x,
double y,
String label)
public void setColor(Color c)
public void setLineWidth(int lineWidth)
public void changeFont(Font font)
public void draw()
public void dispose()
dispose in class Windowpublic void actionPerformed(ActionEvent e)
actionPerformed in interface ActionListenerpublic void itemStateChanged(ItemEvent e)
itemStateChanged in interface ItemListener
public void mouseMoved(int x,
int y)
mouseMoved in class ImageWindowImageWindow.mouseMoved(int, int)public void mouseWheelMoved(MouseWheelEvent e)
mouseWheelMoved in interface MouseWheelListenermouseWheelMoved in class ImageWindowpublic ResultsTable getResultsTable()
public void lostOwnership(Clipboard clipboard,
Transferable contents)
lostOwnership in interface ClipboardOwnerpublic float[] getXValues()
public float[] getYValues()
public void drawPlot(Plot plot)
public static void savePreferences(Properties prefs)
public void roiModified(ImagePlus img,
int id)
roiModified in interface RoiListenerpublic void imageOpened(ImagePlus imp)
imageOpened in interface ImageListenerpublic void imageUpdated(ImagePlus imp)
imageUpdated in interface ImageListenerpublic void imageClosed(ImagePlus imp)
imageClosed in interface ImageListenerpublic void run()
run in interface Runnablepublic Plot getPlot()
public static void freeze()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||