public class NumberImageViewer extends javax.swing.JPanel implements IImageListener, java.awt.event.MouseMotionListener, java.awt.event.MouseListener, java.awt.event.ActionListener, java.awt.event.KeyListener, JDrawable
javax.swing.JPanel.AccessibleJPanel
javax.swing.JComponent.AccessibleJComponent
Modifier and Type | Field and Description |
---|---|
protected javax.swing.JButton |
axisButton |
protected javax.swing.JCheckBoxMenuItem |
bestFitMenuItem |
protected javax.swing.JPanel |
buttonPanel |
protected javax.swing.JScrollPane |
buttonView |
protected javax.swing.JMenu |
dblProfileMenu |
protected javax.swing.JCheckBoxMenuItem |
displayLogMenuItem |
protected double[][] |
doubleValues |
protected javax.swing.JButton |
fileButton |
protected javax.swing.JMenuItem |
fileMenuItem |
protected javax.swing.JCheckBoxMenuItem |
hBottomCheckMenuItem |
protected javax.swing.JCheckBoxMenuItem |
hCenterCheckMenuItem |
protected javax.swing.JButton |
histoButton |
protected javax.swing.JMenuItem |
histogramMenuItem |
protected javax.swing.JCheckBoxMenuItem |
hTopCheckMenuItem |
protected JImage |
imagePanel |
protected javax.swing.JScrollPane |
imageView |
protected javax.swing.JPopupMenu |
imgMenu |
protected javax.swing.JMenuItem |
infoMenuItem |
protected javax.swing.filechooser.FileFilter |
lastFileFilter |
protected java.lang.String |
lastSnapshotLocation |
protected javax.swing.JMenuItem |
lineProfile2MenuItem |
protected javax.swing.JMenuItem |
lineProfileMenuItem |
protected LineProfilerViewer |
lineProfiler |
protected javax.swing.JButton |
loadButton |
protected javax.swing.JMenuItem |
loadMenuItem |
protected boolean |
logValues |
protected javax.swing.JCheckBoxMenuItem |
negativeMenuItem |
protected java.awt.Insets |
noMargin |
protected javax.swing.JButton |
printButton |
protected javax.swing.JMenuItem |
printMenuItem |
protected javax.swing.JButton |
profile2Button |
protected javax.swing.JButton |
profileButton |
protected int |
profileMode |
protected javax.swing.JButton |
saveButton |
protected javax.swing.JMenuItem |
saveDataFileMenuItem |
protected javax.swing.JMenuItem |
saveMenuItem |
protected javax.swing.JButton |
selectButton |
protected javax.swing.JButton |
selectColorButton |
protected javax.swing.JMenuItem |
selectionColorMenuItem |
protected javax.swing.JMenuItem |
selectionMaxMenuItem |
protected javax.swing.JMenuItem |
selectionMenuItem |
protected javax.swing.JButton |
selectMaxButton |
protected javax.swing.JTextField |
selText |
protected javax.swing.JButton |
settingsButton |
protected javax.swing.JMenuItem |
settingsMenuItem |
protected javax.swing.JCheckBoxMenuItem |
showGradMenuItem |
protected javax.swing.JCheckBoxMenuItem |
snapToGridMenuItem |
protected int |
startHisto |
protected javax.swing.JCheckBoxMenuItem |
statusLineMenuItem |
protected javax.swing.JButton |
tableButton |
protected javax.swing.JMenuItem |
tableMenuItem |
protected javax.swing.JCheckBoxMenuItem |
toolbarMenuItem |
protected javax.swing.JCheckBoxMenuItem |
vCenterCheckMenuItem |
protected javax.swing.JCheckBoxMenuItem |
vLeftCheckMenuItem |
protected javax.swing.JCheckBoxMenuItem |
vRigthCheckMenuItem |
protected javax.swing.JButton |
zoomButton |
protected javax.swing.JMenuItem |
zoomMenuItem |
accessibleContext, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Constructor and Description |
---|
NumberImageViewer()
Create a new NumberImageViewer
|
Modifier and Type | Method and Description |
---|---|
void |
actionPerformed(java.awt.event.ActionEvent evt) |
int |
addCrossMarker(int x,
int y,
java.awt.Color c)
Adds a cross marker at the specified pos
|
int |
addHorizontalLineMarker(int y,
java.awt.Color c)
Adds a horizontal line marker
|
int |
addRectangleMarker(int x,
int y,
int width,
int height,
java.awt.Color c)
Adds a rectangle marker
|
void |
addRoiListener(IRoiListener l) |
int |
addVerticalLineMarker(int x,
java.awt.Color c)
Adds a vertical line marker
|
protected double[] |
buildHistogramData() |
protected double[] |
buildProfileData(java.awt.Point p1,
java.awt.Point p2) |
protected void |
changeSelectionColor() |
void |
clearMarkers()
Clears all markers
|
void |
clearModel()
Removes all listener belonging to the viewer.
|
protected double[][] |
computeLog(double[][] values) |
protected void |
constructLineProfiler() |
void |
errorChange(ErrorEvent errorEvent) |
void |
fireRoiChange() |
protected void |
freePopup() |
boolean |
getAutoZoom()
Determines wheter this image viewer has auto zoom enabled.
|
double |
getBestFitMax()
Returns current best fit max value (user value)
|
double |
getBestFitMin()
Returns current best fit min value (user value)
|
javax.swing.JComponent |
getComponent()
Returns the JComponent that implements this interface.
|
java.awt.Dimension |
getCurrentImageSize()
Returns the current image size
|
java.lang.String |
getDescription(java.lang.String name)
Get a description of this extensions.
|
java.lang.String |
getExtendedParam(java.lang.String name)
Returns the specified parameter value.
|
java.lang.String[] |
getExtensionList()
Returns list of extension name for this objects (Empty array for none).
|
Gradient |
getGradient()
Returns current colormap
|
JLAxis |
getGradientAxis()
Returna handle to the Gradient axis.
|
java.awt.Insets |
getImageMargin()
Returns image margin.
|
int |
getImageXCoord(int x)
Converts the component horizontal coordinate to the image coordinate.
|
int |
getImageYCoord(int y)
Converts the component vertical coordinate to the image coordinate.
|
java.awt.Rectangle |
getSelection()
Return current floating rectangle selection
|
int |
getSelectionMode()
Returns the floating selection mode
|
java.lang.String |
getSettings()
returns the configuration as string.
|
JLAxis |
getXAxis()
Returns a handle to the x axis.
|
JLAxis |
getYAxis()
Return a handle to the Y axis.
|
int |
getZoom()
Return the current zoom factor index.
|
boolean |
hasMarker() |
void |
imageChange(NumberImageEvent evt) |
protected void |
initButtonPanel() |
void |
initForEditing()
Call after a component of a JDSwingObject is created, this give a default look
and feel for editing.
|
protected void |
initGradient() |
protected void |
initImagePanel() |
protected void |
initPopupMenu() |
protected void |
initStatusLine() |
boolean |
isAlignToGrid()
Returns true is floating selection are aligned to grid
|
boolean |
isAutoBestFit()
Returns true when automatic best fit is enabled
|
boolean |
isBestFit()
Returns true when best fit is on
|
boolean |
isGradientVisible()
Returns true when the gradient is visible.
|
boolean |
isLogValues() |
boolean |
isNegative()
Returns true only if negative image is displayed
|
boolean |
isSelectionEnabled()
Returns true is floating selection is enabled
|
boolean |
isShowingMenu()
Returns true is the image viewer menu is displayed when clicking
on the right mouse button.
|
boolean |
isStatusLineVisible()
Returns true when the status line is visible.
|
boolean |
isToolbarVisible()
Returns true when the toolbar is visible.
|
void |
keyPressed(java.awt.event.KeyEvent e) |
void |
keyReleased(java.awt.event.KeyEvent e) |
void |
keyTyped(java.awt.event.KeyEvent e) |
void |
loadImage(java.lang.String fileName)
Load an image (gif,jpg or png) into the viewer.
|
java.lang.String |
loadSetting(java.lang.String filename)
Load NumberImageViewer settings.
|
static void |
main(java.lang.String[] args) |
void |
mouseClicked(java.awt.event.MouseEvent e) |
void |
mouseDragged(java.awt.event.MouseEvent e) |
void |
mouseEntered(java.awt.event.MouseEvent e) |
void |
mouseExited(java.awt.event.MouseEvent e) |
void |
mouseMoved(java.awt.event.MouseEvent e) |
void |
mousePressed(java.awt.event.MouseEvent e) |
void |
mouseReleased(java.awt.event.MouseEvent e) |
protected void |
mulPoint(java.awt.Point p) |
protected void |
mulRect(java.awt.Rectangle r) |
void |
printImage()
Prints out this image.
|
protected void |
refreshLineProfile() |
protected void |
refreshStatusLine() |
void |
removeRoiListener(IRoiListener l) |
void |
saveSetting(java.lang.String filename)
Save settings.
|
void |
setAlignToGrid(boolean b)
Sets the align to grid mode for floating selection
|
void |
setAutoBestFit(boolean b)
Sets the auto Best fit mode.
|
void |
setAutoZoom(boolean auto)
Enables or disables the auto zoom.
|
void |
setBestFit(boolean b)
Displays the image using the whole color range.
|
void |
setBestFitMinMax(double min,
double max)
Sets the value of best fit min and max when automatic
best fit is off.
|
void |
setCrossCursor(boolean enable)
Enable or disable the cross cursor.
|
void |
setCrossCursorColor(java.awt.Color c)
Set the cross cursor color.
|
void |
setData(double[][] v)
Sets data to display.
|
boolean |
setExtendedParam(java.lang.String name,
java.lang.String value,
boolean popupErr)
Sets the specified param.
|
void |
setGradient(Gradient g)
Sets the colormap
|
void |
setGradientVisible(boolean b)
Displays or hides the gradient (right panel).
|
void |
setImageMargin(java.awt.Insets i)
Sets the image margin.
|
void |
setLogValues(boolean logValues) |
void |
setMarkerPos(int id,
int x,
int y,
int nWidth,
int nHeight)
Sets the position of a marker
|
void |
setModel(INumberImage v)
setModel Set the model. |
void |
setNaNcolor(java.awt.Color color)
Set a specified color for NaN values.
|
void |
setNegative(boolean b)
Displays negative image when enabled
|
void |
setSelection(java.awt.Rectangle r)
Sets the floating selection.
|
void |
setSelectionEnabled(boolean b)
True is floating selection is enabled
|
void |
setSelectionMode(int m)
Sets the floating selection mode
|
void |
setShowingMenu(boolean b)
True to enable menu displayed when clicking on right mouse button.
|
void |
setStatusLineVisible(boolean b)
Displays or hides the status line (bottom panel).
|
void |
setToolbarVisible(boolean b)
Displays or hides the toolbar.
|
void |
setVerticalExtent(int ratio)
Extend verticaly the image.
|
void |
setZoom(int zoomIndex)
Sets the image zoom factor (does not affect the zoom dialog).
|
void |
stateChange(AttributeStateEvent evt) |
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate, validateTree
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
protected double[][] doubleValues
protected int profileMode
protected int startHisto
protected java.awt.Insets noMargin
protected JImage imagePanel
protected javax.swing.JScrollPane imageView
protected javax.swing.JPanel buttonPanel
protected javax.swing.JButton selectButton
protected javax.swing.JButton selectMaxButton
protected javax.swing.JButton selectColorButton
protected javax.swing.JButton fileButton
protected javax.swing.JButton zoomButton
protected javax.swing.JButton tableButton
protected javax.swing.JButton profileButton
protected javax.swing.JButton profile2Button
protected javax.swing.JButton histoButton
protected javax.swing.JButton settingsButton
protected javax.swing.JButton axisButton
protected javax.swing.JButton loadButton
protected javax.swing.JButton saveButton
protected javax.swing.JButton printButton
protected javax.swing.JScrollPane buttonView
protected javax.swing.JTextField selText
protected javax.swing.JPopupMenu imgMenu
protected javax.swing.JMenuItem infoMenuItem
protected javax.swing.JCheckBoxMenuItem bestFitMenuItem
protected javax.swing.JCheckBoxMenuItem snapToGridMenuItem
protected javax.swing.JCheckBoxMenuItem negativeMenuItem
protected javax.swing.JCheckBoxMenuItem toolbarMenuItem
protected javax.swing.JCheckBoxMenuItem statusLineMenuItem
protected javax.swing.JCheckBoxMenuItem showGradMenuItem
protected javax.swing.JMenuItem selectionMenuItem
protected javax.swing.JMenuItem selectionMaxMenuItem
protected javax.swing.JMenuItem selectionColorMenuItem
protected javax.swing.JMenuItem fileMenuItem
protected javax.swing.JMenuItem zoomMenuItem
protected javax.swing.JMenuItem tableMenuItem
protected javax.swing.JMenuItem lineProfileMenuItem
protected javax.swing.JMenuItem lineProfile2MenuItem
protected javax.swing.JMenu dblProfileMenu
protected javax.swing.JCheckBoxMenuItem vLeftCheckMenuItem
protected javax.swing.JCheckBoxMenuItem vCenterCheckMenuItem
protected javax.swing.JCheckBoxMenuItem vRigthCheckMenuItem
protected javax.swing.JCheckBoxMenuItem hTopCheckMenuItem
protected javax.swing.JCheckBoxMenuItem hCenterCheckMenuItem
protected javax.swing.JCheckBoxMenuItem hBottomCheckMenuItem
protected javax.swing.JMenuItem histogramMenuItem
protected javax.swing.JMenuItem settingsMenuItem
protected javax.swing.JMenuItem loadMenuItem
protected javax.swing.JMenuItem saveMenuItem
protected javax.swing.JMenuItem saveDataFileMenuItem
protected javax.swing.JMenuItem printMenuItem
protected javax.swing.JCheckBoxMenuItem displayLogMenuItem
protected LineProfilerViewer lineProfiler
protected java.lang.String lastSnapshotLocation
protected javax.swing.filechooser.FileFilter lastFileFilter
protected boolean logValues
protected void initImagePanel()
protected void initButtonPanel()
protected void initGradient()
protected void initStatusLine()
protected void initPopupMenu()
public void initForEditing()
JDrawable
initForEditing
in interface JDrawable
public javax.swing.JComponent getComponent()
JDrawable
getComponent
in interface JDrawable
public java.lang.String getDescription(java.lang.String name)
JDrawable
getDescription
in interface JDrawable
name
- Extension namepublic java.lang.String[] getExtensionList()
JDrawable
getExtensionList
in interface JDrawable
public boolean setExtendedParam(java.lang.String name, java.lang.String value, boolean popupErr)
JDrawable
setExtendedParam
in interface JDrawable
name
- Parameter name (Case unsensitive).value
- Parameter value.popupErr
- true when the JDrawable should display a popup if
the parameter value is incorrect, false otherwise. Note that the JDrawable
must not display an error message if the parameter does not exists even
if popupAllowed is true.public java.lang.String getExtendedParam(java.lang.String name)
JDrawable
getExtendedParam
in interface JDrawable
name
- Param name (Case unsensitive).public void addRoiListener(IRoiListener l)
public void removeRoiListener(IRoiListener l)
public void fireRoiChange()
public void setBestFit(boolean b)
b
- Best fit togglepublic boolean isBestFit()
public void setAutoBestFit(boolean b)
b
- True to enable auto best fitpublic boolean isAutoBestFit()
public void setBestFitMinMax(double min, double max)
min
- Minimum valuemax
- Maximum valuepublic double getBestFitMin()
public double getBestFitMax()
public void setGradient(Gradient g)
g
- New gradient colormappublic Gradient getGradient()
public void setNegative(boolean b)
b
- True for negtive imagepublic boolean isNegative()
public void setAlignToGrid(boolean b)
b
- True to enablepublic boolean isAlignToGrid()
public void setToolbarVisible(boolean b)
b
- True if toolbar is displayedpublic boolean isToolbarVisible()
public void setStatusLineVisible(boolean b)
b
- True if status line is displayedpublic boolean isStatusLineVisible()
public void setGradientVisible(boolean b)
b
- True if status line is displayedpublic boolean isGradientVisible()
public void setShowingMenu(boolean b)
b
- True to enable the menupublic void setZoom(int zoomIndex)
Possible zoomIndex values are: 0 : 800% 1 : 400% 2 : 200% 3 : 100% 4 : 50% 5 : 25% 6 : 12.5%
zoomIndex
- ZoomFactor index (see description).public int getZoom()
setZoom(int)
public void setAutoZoom(boolean auto)
auto
- AutoZoom flagpublic boolean getAutoZoom()
setAutoZoom(boolean)
public boolean isShowingMenu()
public java.awt.Insets getImageMargin()
public void setImageMargin(java.awt.Insets i)
i
- Image marginpublic java.awt.Dimension getCurrentImageSize()
public void setSelectionEnabled(boolean b)
b
- True to allow floating selectionpublic boolean isSelectionEnabled()
public void setCrossCursor(boolean enable)
enable
- True to enable cross cursor, false otherwise.public void setCrossCursorColor(java.awt.Color c)
c
- Cursor colorsetCrossCursor(boolean)
public void setSelection(java.awt.Rectangle r)
r
- Rectangle to selectpublic java.awt.Rectangle getSelection()
public int getSelectionMode()
public void setSelectionMode(int m)
m
- 0 for Line selection, 1 fro rectangle selectionpublic void setData(double[][] v)
v
- Handle to datapublic void loadImage(java.lang.String fileName) throws java.io.IOException
fileName
- File to be loadedjava.io.IOException
- Exception thrown in case of failurepublic int addCrossMarker(int x, int y, java.awt.Color c)
x
- X coordinatesy
- Y coordinatesc
- Marker Colorpublic int addRectangleMarker(int x, int y, int width, int height, java.awt.Color c)
x
- X topleft corner coordinatey
- Y topleft corner coordinatewidth
- Rectangle widthheight
- Rectangle hieghtc
- Marker Colorpublic int addVerticalLineMarker(int x, java.awt.Color c)
x
- Horizontal positionc
- Marker colorpublic int addHorizontalLineMarker(int y, java.awt.Color c)
y
- Vertical positionc
- Marker colorpublic void setMarkerPos(int id, int x, int y, int nWidth, int nHeight)
id
- Marker indexx
- X coordinate (ignored when HORIZONTAL_LINE Marker)y
- Y coordinate (ignored when VERTICAL_LINE Marker)nWidth
- Rectangle width (ignored when CROSS Marker or LINE Marker)nHeight
- Rectangle height (ignored when CROSS Marker or LINE Marker)public void clearMarkers()
public boolean hasMarker()
public JLAxis getXAxis()
public JLAxis getYAxis()
public JLAxis getGradientAxis()
public int getImageXCoord(int x)
x
- Component horizontal coordinatepublic int getImageYCoord(int y)
y
- Component vertical coordinatepublic void setVerticalExtent(int ratio)
ratio
- Vertical extent rationprotected void mulRect(java.awt.Rectangle r)
protected void mulPoint(java.awt.Point p)
protected void freePopup()
protected double[] buildProfileData(java.awt.Point p1, java.awt.Point p2)
protected double[] buildHistogramData()
protected void refreshLineProfile()
protected void refreshStatusLine()
public void saveSetting(java.lang.String filename)
filename
- file to be saved.public java.lang.String getSettings()
saveSetting(java.lang.String)
public java.lang.String loadSetting(java.lang.String filename)
filename
- file to be readprotected void constructLineProfiler()
public void actionPerformed(java.awt.event.ActionEvent evt)
actionPerformed
in interface java.awt.event.ActionListener
public void mouseDragged(java.awt.event.MouseEvent e)
mouseDragged
in interface java.awt.event.MouseMotionListener
public void mouseMoved(java.awt.event.MouseEvent e)
mouseMoved
in interface java.awt.event.MouseMotionListener
public void mouseEntered(java.awt.event.MouseEvent e)
mouseEntered
in interface java.awt.event.MouseListener
public void mouseExited(java.awt.event.MouseEvent e)
mouseExited
in interface java.awt.event.MouseListener
public void mouseClicked(java.awt.event.MouseEvent e)
mouseClicked
in interface java.awt.event.MouseListener
public void mouseReleased(java.awt.event.MouseEvent e)
mouseReleased
in interface java.awt.event.MouseListener
public void mousePressed(java.awt.event.MouseEvent e)
mousePressed
in interface java.awt.event.MouseListener
public void keyPressed(java.awt.event.KeyEvent e)
keyPressed
in interface java.awt.event.KeyListener
public void keyTyped(java.awt.event.KeyEvent e)
keyTyped
in interface java.awt.event.KeyListener
public void keyReleased(java.awt.event.KeyEvent e)
keyReleased
in interface java.awt.event.KeyListener
public void errorChange(ErrorEvent errorEvent)
errorChange
in interface IErrorListener
public void stateChange(AttributeStateEvent evt)
stateChange
in interface IAttributeStateListener
public void imageChange(NumberImageEvent evt)
imageChange
in interface IImageListener
public void setModel(INumberImage v)
setModel
Set the model.v
- Value to assign to model. This image must have a height equals to 2.public void clearModel()
public void setNaNcolor(java.awt.Color color)
color
- the specified color for NaN values (if null NaN color is not managed)public void printImage()
public boolean isLogValues()
public void setLogValues(boolean logValues)
logValues
- the logValues to setprotected double[][] computeLog(double[][] values)
protected void changeSelectionColor()
public static void main(java.lang.String[] args)