public abstract class DefaultDrawingLayer extends JLabel implements IDrawingLayer, MouseMotionListener, MouseListener, MouseWheelListener
JLabel.AccessibleJLabelJComponent.AccessibleJComponentContainer.AccessibleAWTContainerComponent.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy| Modifier and Type | Field and Description |
|---|---|
protected ArrayList<javax.media.jai.ROIShape> |
allROIShapes
An
ArrayList of all ROI shapes drawn on the canvas. |
protected ArrayList<AngleROI> |
angleROIs
An
ArrayList of all angle ROI elements. |
protected GeneralPath |
angleShape
The shape for the angle ROI.
|
protected javax.media.jai.ROIShape[] |
boundEditableRectangles
The 8 filled boundary rectangles for editing a shape, transformed.
|
protected javax.media.jai.ROIShape[] |
boundEditableRectanglesUntransformed
The 8 filled boundary rectangles for editing a shape, untransformed.
|
protected CanvasMover |
canvasMover
A custom key listener for moving the canvas with spacebar down and mouse
drag gestures.
|
protected javax.media.jai.ROIShape |
clickedROIShape
The clicked ROI shape.
|
protected ContextPopupListener |
contextPopupListener
The context pop up menu listener for the
ContextPopupMenu. |
protected ContextPopupMenu |
contextPopupMenu
The context pop up menu for
LookToolboxPanel and the
ImageInfoPanel. |
protected AngleROI |
currentAngleROI
The current angle ROI shape.
|
protected EllipseROI |
currentEllipseROI
The current ellipse ROI shape.
|
protected FreehandROI |
currentFreehandROI
The current freehand ROI shape.
|
protected LineROI |
currentLineROI
The current line ROI shape.
|
protected PointROI |
currentPointROI
The current point ROI shape.
|
protected PolygonROI |
currentPolygonROI
The current polygon ROI shape.
|
protected RectangleROI |
currentRectangleROI
The current rectangle ROI shape.
|
protected javax.media.jai.ROIShape |
currentROIShape
The currently selected ROI shape.
|
protected ROILayerCursorChanger |
cursorChanger
A custom event handler for highlighting a hovered shape in a specified
color.
|
protected Color |
defaultLayerColor
The default color for a ROI layer.
|
protected BasicStroke |
defaultROIStroke
The default stroke for drawing ROIs on the canvas.
|
protected ILookPanel |
displayPanel
The display panel where the image is displayed.
|
protected ArrayList<EllipseROI> |
ellipseROIs
An
ArrayList of all ellipse ROI elements. |
protected ArrayList<FreehandROI> |
freehandROIs
An
ArrayList of all freehand ROI elements. |
protected GeneralPath |
freehandShape
The shape (path) for the freehand ROI.
|
protected Color |
highlightColor
The color for highlighted ROI shapes.
|
protected BasicStroke |
highlightStroke
The stroke for the highlighted ROI shape.
|
protected UUID |
id |
protected boolean |
isInsidePtEast
A flag, whether a click happened inside the E boundary rectangle.
|
protected boolean |
isInsidePtNorth
A flag, whether a click happened inside the N boundary rectangle.
|
protected boolean |
isInsidePtNorthEast
A flag, whether a click happened inside the NE boundary rectangle.
|
protected boolean |
isInsidePtNorthWest
A flag, whether a click happened inside the NW boundary rectangle.
|
protected boolean |
isInsidePtSouth
A flag, whether a click happened inside the S boundary rectangle.
|
protected boolean |
isInsidePtSouthEast
A flag, whether a click happened inside the SE boundary rectangle.
|
protected boolean |
isInsidePtSouthWest
A flag, whether a click happened inside the SW boundary rectangle.
|
protected boolean |
isInsidePtWest
A flag, whether a click happened inside the W boundary rectangle.
|
protected boolean |
isInsideRoi
A flag, whether a click happened inside a ROI or not.
|
protected boolean |
isROIDragging
A flag, whether a ROI is currently dragged or not.
|
protected boolean |
isSelected
A flag, determining whether or not a layer is selected.
|
protected boolean |
isVisible
A flag, determining whether or not a layer's content is rendered.
|
protected Color |
lineROIBoundaryColor
The default color for drawing a
LineROI's boundaries on the
canvas. |
protected Color |
lineROIBoundaryRectangleColor
The default color for drawing a
LineROI's boundary rectangles on
the canvas. |
protected Stroke |
lineROIBoundaryStroke
The default stroke of a line ROI's boundary.
|
protected ArrayList<LineROI> |
lineROIs
An
ArrayList of all line ROI elements. |
private static org.apache.log4j.Logger |
logger
A custom class logger
|
protected String |
name
The name of this layer.
|
protected int |
numAnglePoints
The number of corners in the angle ROI.
|
protected int |
numPolyPoints
The number of corners in the polygon.
|
protected PropertyChangeSupport |
pcs
A property change support object to emit events.
|
protected ArrayList<PointROI> |
pointROIs
An
ArrayList of all point ROI elements. |
protected ArrayList<PolygonROI> |
polygonROIs
An
ArrayList of all polygon ROI elements. |
protected GeneralPath |
polygonShape
The shape for the polygon ROI.
|
protected ArrayList<RectangleROI> |
rectangleROIs
An
ArrayList of all rectangle ROI elements. |
protected Color |
roiBoundaryColor
The default color for drawing a ROI's boundaries on the canvas.
|
protected Color |
roiBoundaryRectangleColor
The default color for drawing a ROI's boundary rectangles on the canvas.
|
protected Stroke |
roiBoundaryStroke
The default stroke a the ROI's boundary.
|
protected javax.media.jai.ROIShape |
roiShapeForHighlighting
The ROI shape which should be highlighted on mouse over.
|
protected int |
roiShiftX0
A value for the translation of any ROI, x-coordinate.
|
protected int |
roiShiftY0
A value for the translation of any ROI, y-coordinate.
|
protected int |
roiX0
The start point of a ROI drawing, x-coordinate.
|
protected int |
roiY0
The start point of a ROI drawing, y-coordinate.
|
private static long |
serialVersionUID
The UID for serialization.
|
protected javax.media.jai.ROIShape |
tmpROIShape
The temporary ROI shape.
|
protected Color |
tmpROIShapeColor
The default color for drawing a temporary ROI shape.
|
protected int |
zOrder
The z-order of this layer.
|
listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOWaccessibleContext, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENTACTIVE_FRONT_LAYER, DEFAULT_IMAGE_LAYER, DEFAULT_LAYER_COLOR, DEFAULT_LAYER_COLOR_NAME, DEFAULT_LAYER_STROKE, DEFAULT_LAYER_STROKE_NAME, DRAGGING_LAYER, HIGHLIGHT_COLOR, HIGHLIGHT_COLOR_NAME, HIGHLIGHT_STROKE, HIGHLIGHT_STROKE_NAMEBOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WESTABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH| Constructor and Description |
|---|
DefaultDrawingLayer()
Default constructor.
|
DefaultDrawingLayer(ILookPanel displayPanel)
Create a new layer for
|
| Modifier and Type | Method and Description |
|---|---|
void |
addAllDefaultListeners()
This method registers all default listeners with this layer.
|
void |
addDefaultCanvasMover()
Add the default canvas mover.
|
protected void |
createContextMenuAndBehavior()
Create a new context popup menu with this instance as
ActionListener. |
void |
deleteAllROIs()
Delete all
ROIShapes on this layer. |
void |
deleteROI(javax.media.jai.ROIShape roi)
Deletes a given ROI shape.
|
void |
deleteROIs(List<javax.media.jai.ROIShape> rois)
Deletes all given shapes from the layer.
|
void |
deleteSelectedROI()
This method deletes the currently selected ROI and sets the last element
of the
ArrayList to the current ROI. |
private void |
dragROI(AffineTransform at,
Point p,
MouseEvent e) |
void |
drawAngleROI(AngleROI roi)
Generic method to draw a
AngleROI on the look panel. |
void |
drawAngleROIs(List<AngleROI> rois)
Generic method to draw
AngleROIs on the look panel. |
void |
drawEllipseROI(EllipseROI roi)
Generic method to draw a
EllipseROI on the look panel. |
void |
drawEllipseROIs(List<EllipseROI> rois)
Generic method to draw
EllipseROIs on the look panel. |
void |
drawFreehandROI(FreehandROI roi)
Generic method to draw a
FreehandROI on the look panel. |
void |
drawFreehandROIs(List<FreehandROI> rois)
Generic method to draw
FreehandROIs on the look panel. |
void |
drawLineROI(LineROI roi)
Generic method to draw a
LineROI on the look panel. |
void |
drawLineROIs(List<LineROI> rois)
Generic method to draw
LineROIs on the look panel. |
void |
drawPointROI(PointROI roi)
Generic method to draw a
PointROI on the look panel. |
void |
drawPointROIs(List<PointROI> rois)
Generic method to draw
PointROIs on the look panel. |
void |
drawPolygonROI(PolygonROI roi)
Generic method to draw a
PolygonROI on the look panel. |
void |
drawPolygonROIs(List<PolygonROI> rois)
Generic method to draw
PolygonROIs on the look panel. |
void |
drawRectangleROI(RectangleROI roi)
Generic method to draw a
RectangleROI on the look panel. |
void |
drawRectangleROIs(List<RectangleROI> rois)
Generic method to draw
RectangleROIs on the look panel. |
void |
drawROI(javax.media.jai.ROIShape roi)
Generic method to draw any specified class or subclass of
ROIShape on the look panel. |
void |
drawROIs(List<javax.media.jai.ROIShape> rois)
Generic method to draw some
ROIShapes on the look panel. |
void |
fireNewProperties(javax.media.jai.ROIShape roi)
Various updates are made according to the subclass of
ROIShape:
Sets the length in px of a given LineROI shape
to the ImageInfoPanel. |
ArrayList<javax.media.jai.ROIShape> |
getAllROIShapes()
Get the list of all
ROIShapes in this layer. |
ArrayList<AngleROI> |
getAngleROIs()
Get all
AngleROIs drawn in this layer. |
GeneralPath |
getAngleShape()
A helper variable used by mouse event handlers to draw
AngleROIs. |
javax.media.jai.ROIShape[] |
getBoundEditableRectangles() |
javax.media.jai.ROIShape[] |
getBoundEditableRectanglesUntransformed() |
javax.media.jai.ROIShape |
getClickedROIShape()
Get the previously clicked
ROIShape. |
AngleROI |
getCurrentAngleROI()
Get the current
AngleROI in this layer. |
EllipseROI |
getCurrentEllipseROI()
Get the current
EllipseROI in this layer. |
FreehandROI |
getCurrentFreehandROI()
Get the current
FreehandROI in this layer. |
LineROI |
getCurrentLineROI()
Get the current
LineROI in this layer. |
PointROI |
getCurrentPointROI()
Get the current
PointROI in this layer. |
PolygonROI |
getCurrentPolygonROI()
Get the current
PolygonROI in this layer. |
RectangleROI |
getCurrentRectangleROI()
Get the current
RectangleROI in this layer. |
javax.media.jai.ROIShape |
getCurrentROIShape()
Get the currently selected
ROIShape. |
ROILayerCursorChanger |
getCursorChanger() |
Color |
getDefaultLayerColor() |
BasicStroke |
getDefaultROIStroke() |
ILookPanel |
getDisplayPanel() |
int |
getElementCount()
Gets the total amount of elements in this layer.
|
ArrayList<EllipseROI> |
getEllipseROIs()
Get all
EllipseROIs in this layer. |
ArrayList<FreehandROI> |
getFreehandROIs()
Get all drawn
FreehandROIs in this layer. |
GeneralPath |
getFreehandShape()
Gets the path of the latest drawn shape.
|
Color |
getHighlightColor() |
BasicStroke |
getHighlightStroke() |
UUID |
getID()
Gets the unique ID of this drawing layer.
|
Color |
getLayerColor()
Get the color for ROIs on this layer.
|
Color |
getLineROIBoundaryColor() |
Color |
getLineROIBoundaryRectangleColor() |
ArrayList<LineROI> |
getLineROIs()
Get all
LineROIs in this layer. |
String |
getName()
Get the name of the layer.
|
int |
getNumAnglePoints()
A helper variable used by mouse event handlers to draw
AngleROIs. |
int |
getNumPolyPoints()
Gets the number of corners of the currently drawn
PolygonROI. |
ArrayList<PointROI> |
getPointROIs()
Get all
PointROIs in this layer. |
ArrayList<PolygonROI> |
getPolygonROIs()
Get all drawn
PolygonROIs in this layer. |
GeneralPath |
getPolygonShape()
Gets the shape of the latest
PolygonROI. |
ArrayList<RectangleROI> |
getRectangleROIs()
Get all
RectangleROIs in this layer. |
Color |
getRoiBoundaryRectangleColor() |
javax.media.jai.ROIShape |
getRoiShapeForHighlighting() |
int |
getRoiShiftX0()
Get the x-coordinate of the target point of a translation (shift) without
transformation of a ROI.
|
int |
getRoiShiftY0()
Get the y-coordinate of the target point of a translation (shift) without
transformation of a ROI.
|
int |
getRoiX0()
Get the x-coordinate of the target point of a translation (shift) without
transformation of a ROI.
|
int |
getRoiY0()
Get the y-coordinate of the target point of a translation (shift) without
transformation of a ROI.
|
javax.media.jai.ROIShape |
getTmpROIShape()
Gets the temporary ROI shape to be drawn additionally to all present
ones.
|
Color |
getTmpROIShapeColor() |
int |
getZOrder()
The order of the layer in z-direction.
|
boolean |
hasROIs()
Determines whether or not the layer contains any ROI shapes.
|
void |
initialize()
Initializes the layer with the context menu and listeners.
|
boolean |
isEmpty()
Determines whether or not the layer is empty.
|
boolean |
isInsidePtEast()
Determines whether or not the mouse is inside of the east boundary point.
|
boolean |
isInsidePtNorth()
Determines whether or not the mouse is inside of the north boundary
point.
|
boolean |
isInsidePtNorthEast()
Determines whether or not the mouse is inside of the north-east boundary
point.
|
boolean |
isInsidePtNorthWest()
Determines whether or not the mouse is inside of the north-west boundary
point.
|
boolean |
isInsidePtSouth()
Determines whether or not the mouse is inside of the south boundary
point.
|
boolean |
isInsidePtSouthEast()
Determines whether or not the mouse is inside of the south-east boundary
point.
|
boolean |
isInsidePtSouthWest()
Determines whether or not the mouse is inside of the south-west boundary
point.
|
boolean |
isInsidePtWest()
Determines whether or not the mouse is inside of the west boundary point.
|
boolean |
isInsideRoi()
Determines whether or not the mouse is inside of a drawn shape.
|
boolean |
isLayerVisible()
A flag whether or not the layer is visible in the canvas.
|
boolean |
isROIDragging()
Get a flag determining whether or not a ROI is currently being dragged by
mouse gesture.
|
boolean |
isSelected()
Get the selection state of this layer.
|
void |
mouseDragged(MouseEvent e) |
void |
mouseMoved(MouseEvent e) |
void |
mousePressed(MouseEvent e) |
void |
mouseReleased(MouseEvent e) |
void |
mouseWheelMoved(MouseWheelEvent e) |
void |
paintComponent(Graphics g)
This paints the entire component including all ROIs.
|
void |
removeAllDefaultListeners()
This method removes all default listeners from the layer.
|
void |
removeDefaultCanvasMover()
Remove the default canvas mover.
|
void |
removeRoiShapeForHighlighting()
Resets the ROI shape for highlighting to
null. |
void |
removeTmpROIShape() |
private void |
reOrganizeROIs(javax.media.jai.ROIShape currentROIShape)
Reorganize the ROI shapes and add set the last drawn element to the
current shape.
|
private void |
searchForInsideROIClick(Point p,
MouseEvent e)
Searches for a click inside of a ROI and activates the corresponding ROI,
if any found.
|
void |
setAllROIShapes(List<javax.media.jai.ROIShape> shapes)
Sets all ROI shapes in this layer.
|
void |
setAngleROIs(ArrayList<AngleROI> angleROIs)
Set all
AngleROIs in this layer. |
void |
setAngleShape(GeneralPath angleShape)
A helper variable used by mouse event handlers to draw
AngleROIs. |
void |
setBoundEditableRectangles(javax.media.jai.ROIShape[] rs) |
void |
setBoundEditableRectanglesUntransformed(javax.media.jai.ROIShape[] boundEditableRectanglesUntransformed) |
void |
setClickedROIShape(javax.media.jai.ROIShape clickedROIShape)
Set the currently clicked
ROIShape. |
void |
setCurrentAngleROI(AngleROI currentAngleROI)
Set the current
AngleROI in this layer. |
void |
setCurrentEllipseROI(EllipseROI currentEllipseROI)
Set the current
EllipseROI in this layer. |
void |
setCurrentFreehandROI(FreehandROI currentFreehandROI)
Set the current
FreehandROI. |
void |
setCurrentLineROI(LineROI currentLineROI)
Set the current
LineROI in this layer. |
void |
setCurrentPointROI(PointROI currentPointROI)
Set the current
PointROI in this layer. |
void |
setCurrentPolygonROI(PolygonROI currentPolygonROI)
Set the current
PolygonROI. |
void |
setCurrentRectangleROI(RectangleROI currentRectangleROI)
Set the current
RectangleROI in this layer. |
void |
setCurrentROIShape(javax.media.jai.ROIShape currentROIShape)
Set the currently selected (active)
ROIShape. |
void |
setCursorChanger(ROILayerCursorChanger cursorChanger) |
void |
setDefaultLayerColor(Color defaultLayerColor) |
void |
setDefaultROIStroke(BasicStroke defaultROIStroke) |
void |
setDisplayPanel(ILookPanel displayPanel) |
void |
setEllipseROIs(ArrayList<EllipseROI> ellipseROIs)
Set all
EllipseROIs in this layer. |
void |
setFreehandROIs(ArrayList<FreehandROI> freehandROIs)
Set all
FreehandROIs in this layer. |
void |
setFreehandShape(GeneralPath freehandShape)
Set the path of the latest shape.
|
void |
setHighlightColor(Color highlightColor) |
void |
setHighlightStroke(BasicStroke highlightStroke) |
void |
setID(UUID id)
Sets the unique ID of this drawing layer.
|
void |
setInsidePtEast(boolean isInsidePtEast)
Set a flag whether or not the mouse is in the east boundary point.
|
void |
setInsidePtNorth(boolean isInsidePtNorth)
Set a flag whether or not the mouse is in the north boundary point.
|
void |
setInsidePtNorthEast(boolean isInsidePtNorthEast)
Set a flag whether or not the mouse is in the north-east boundary point.
|
void |
setInsidePtNorthWest(boolean isInsidePtNorthWest)
Set a flag whether or not the mouse is in the north-west boundary point.
|
void |
setInsidePtSouth(boolean isInsidePtSouth)
Set a flag whether or not the mouse is in the south boundary point.
|
void |
setInsidePtSouthEast(boolean isInsidePtSouthEast)
Set a flag whether or not the mouse is in the south-east boundary point.
|
void |
setInsidePtSouthWest(boolean isInsidePtSouthWest)
Set a flag whether or not the mouse is in the south-west boundary point.
|
void |
setInsidePtWest(boolean isInsidePtWest)
Set a flag whether or not the mouse is in the west boundary point.
|
void |
setInsideRoi(boolean isInsideRoi)
Set a flag whether or not the mouse is inside of a drawn shape.
|
void |
setLayerColor(Color color)
Set the color for ROIs on this layer.
|
void |
setLayerVisible(boolean visible)
Set a flag determining whether or not the layer is visible in the canvas.
|
void |
setLineROIBoundaryColor(Color lineROIBoundaryColor) |
void |
setLineROIBoundaryRectangleColor(Color lineROIBoundaryRectangleColor) |
void |
setLineROIs(ArrayList<LineROI> lineROIs)
Set all
LineROIs in this layer. |
void |
setName(String name)
Determine the name of the layer which is shown in the selection panel.
|
void |
setNumAnglePoints(int numAnglePoints)
A helper variable used by mouse event handlers to draw
AngleROIs. |
void |
setNumPolyPoints(int numPolyPoints)
Set the number of
PolygonROI corners of the currently drawn
polygon ROI. |
void |
setPointROIs(ArrayList<PointROI> pointROIs)
Set all
PointROIs in this layer. |
void |
setPolygonROIs(ArrayList<PolygonROI> polygonROIs)
Set all
PolygonROIs in this layer. |
void |
setPolygonShape(GeneralPath polygonShape)
Sets the shape of the latest
PolygonROI. |
void |
setRectangleROIs(ArrayList<RectangleROI> rectangleROIs)
Set all
RectangleROIs in this layer. |
void |
setRoiBoundaryRectangleColor(Color roiBoundaryRectangleColor) |
void |
setROIDragging(boolean isROIDragging)
Set a flag whether or not a ROI is being dragged by mouse gesture.
|
void |
setRoiShapeForHighlighting(javax.media.jai.ROIShape roiShapeForHighlighting) |
void |
setRoiShiftX0(int roiShiftX0)
Set the x-coordinate of the target point of a translation (shift) without
transformation of a ROI.
|
void |
setRoiShiftY0(int roiShiftY0)
Set the y-coordinate of the target point of a translation (shift) without
transformation of a ROI.
|
void |
setRoiX0(int roiX0)
Set the x-coordinate of the origin of a translation (shift) without
transformation of a ROI.
|
void |
setRoiY0(int roiY0)
Set the y-coordinate of the origin of a translation (shift) without
transformation of a ROI.
|
void |
setSelected(boolean selected)
Set the selection state of this layer.
|
void |
setTmpROIShape(javax.media.jai.ROIShape tmp)
Sets a current ROI shape to be drawn additionally to all present ones.
|
void |
setTmpROIShapeColor(Color tmpROIShapeColor) |
void |
setZOrder(int zOrder)
Determine the order of the layer in z-direction.
|
String |
toString() |
void |
update()
Advise the
IDrawingLayer to repaint all shapes. |
private void |
updateROIInformation(MouseEvent e) |
checkHorizontalKey, checkVerticalKey, getAccessibleContext, getDisabledIcon, getDisplayedMnemonic, getDisplayedMnemonicIndex, getHorizontalAlignment, getHorizontalTextPosition, getIcon, getIconTextGap, getLabelFor, getText, getUI, getUIClassID, getVerticalAlignment, getVerticalTextPosition, imageUpdate, paramString, setDisabledIcon, setDisplayedMnemonic, setDisplayedMnemonic, setDisplayedMnemonicIndex, setHorizontalAlignment, setHorizontalTextPosition, setIcon, setIconTextGap, setLabelFor, setText, setUI, setVerticalAlignment, setVerticalTextPosition, updateUIaddAncestorListener, 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, 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, updateadd, 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, validateTreeaction, 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, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, 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, setSize, setSize, show, show, size, transferFocus, transferFocusBackward, transferFocusUpCycleclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitsetCursormouseClicked, mouseEntered, mouseExitedprivate static final long serialVersionUID
private static final org.apache.log4j.Logger logger
protected transient ILookPanel displayPanel
protected transient ContextPopupMenu contextPopupMenu
LookToolboxPanel and the
ImageInfoPanel.protected transient ContextPopupListener contextPopupListener
ContextPopupMenu.protected transient CanvasMover canvasMover
protected UUID id
protected int zOrder
protected String name
protected boolean isVisible
protected boolean isSelected
protected Color defaultLayerColor
protected BasicStroke defaultROIStroke
Float of 1.5.protected int roiX0
protected int roiY0
protected int roiShiftX0
protected int roiShiftY0
protected boolean isROIDragging
protected boolean isInsideRoi
protected boolean isInsidePtNorthWest
protected boolean isInsidePtNorth
protected boolean isInsidePtNorthEast
protected boolean isInsidePtEast
protected boolean isInsidePtSouthEast
protected boolean isInsidePtSouth
protected boolean isInsidePtSouthWest
protected boolean isInsidePtWest
protected javax.media.jai.ROIShape[] boundEditableRectangles
protected javax.media.jai.ROIShape[] boundEditableRectanglesUntransformed
protected javax.media.jai.ROIShape roiShapeForHighlighting
protected Color highlightColor
Color.white;protected BasicStroke highlightStroke
BasicStroke
of value 1.0F.protected Color roiBoundaryColor
Color.GREEN.protected Stroke roiBoundaryStroke
BasicStroke
of value 1.0F.protected Color lineROIBoundaryColor
LineROI's boundaries on the
canvas. Default value is Color.GREEN.protected Stroke lineROIBoundaryStroke
BasicStroke of value 1.0F.protected Color roiBoundaryRectangleColor
Color.RED.protected Color lineROIBoundaryRectangleColor
LineROI's boundary rectangles on
the canvas. These rectangles can be moved in order to resize the ROI
shape. Default value is Color.BLUE.protected Color tmpROIShapeColor
IDrawingLayer.DEFAULT_LAYER_COLOR.protected javax.media.jai.ROIShape currentROIShape
protected javax.media.jai.ROIShape clickedROIShape
protected javax.media.jai.ROIShape tmpROIShape
protected ArrayList<javax.media.jai.ROIShape> allROIShapes
ArrayList of all ROI shapes drawn on the canvas.protected LineROI currentLineROI
protected RectangleROI currentRectangleROI
protected ArrayList<RectangleROI> rectangleROIs
ArrayList of all rectangle ROI elements.protected EllipseROI currentEllipseROI
protected ArrayList<EllipseROI> ellipseROIs
ArrayList of all ellipse ROI elements.protected PointROI currentPointROI
protected GeneralPath freehandShape
protected FreehandROI currentFreehandROI
protected ArrayList<FreehandROI> freehandROIs
ArrayList of all freehand ROI elements.protected GeneralPath polygonShape
protected int numPolyPoints
protected PolygonROI currentPolygonROI
protected ArrayList<PolygonROI> polygonROIs
ArrayList of all polygon ROI elements.protected GeneralPath angleShape
protected int numAnglePoints
protected AngleROI currentAngleROI
protected ROILayerCursorChanger cursorChanger
protected PropertyChangeSupport pcs
public DefaultDrawingLayer()
public DefaultDrawingLayer(ILookPanel displayPanel)
displayPanel - public void initialize()
public void addDefaultCanvasMover()
addDefaultCanvasMover in interface IDrawingLayerpublic void removeDefaultCanvasMover()
removeDefaultCanvasMover in interface IDrawingLayerpublic void addAllDefaultListeners()
addAllDefaultListeners in interface IDrawingLayerpublic void removeAllDefaultListeners()
removeAllDefaultListeners in interface IDrawingLayerpublic ROILayerCursorChanger getCursorChanger()
getCursorChanger in interface IDrawingLayerpublic void setCursorChanger(ROILayerCursorChanger cursorChanger)
public void setZOrder(int zOrder)
IDrawingLayer>0 are permitted.setZOrder in interface IDrawingLayerzOrder - an Integer indicating the layer's order in a stack of
layerspublic int getZOrder()
IDrawingLayer>0 are
permitted.getZOrder in interface IDrawingLayerInteger indicating the layer's order in a stack of
layerspublic void setName(String name)
IDrawingLayersetName in interface IDrawingLayersetName in class Componentname - a unique name of the layerpublic String getName()
IDrawingLayergetName in interface IDrawingLayergetName in class Componentpublic boolean isLayerVisible()
IDrawingLayerisLayerVisible in interface IDrawingLayertrue, if the layer's components are drawn on the
canvas, false otherwisepublic void setLayerVisible(boolean visible)
IDrawingLayersetLayerVisible in interface IDrawingLayervisible - set to true, if the layer's components should be
drawn on the canvas, false otherwisepublic void setLayerColor(Color color)
IDrawingLayersetLayerColor in interface IDrawingLayerpublic Color getLayerColor()
IDrawingLayergetLayerColor in interface IDrawingLayerpublic void setSelected(boolean selected)
IDrawingLayersetSelected in interface IDrawingLayerpublic boolean isSelected()
IDrawingLayerisSelected in interface IDrawingLayertrue if the layer is selected, false
otherwisepublic int getElementCount()
IDrawingLayergetElementCount in interface IDrawingLayerpublic boolean isEmpty()
IDrawingLayerisEmpty in interface IDrawingLayerpublic void drawROI(javax.media.jai.ROIShape roi)
ROIShape on the look panel.drawROI in interface IDrawingLayerSupportroi - a specified ROIShape to be drawnpublic void drawROIs(List<javax.media.jai.ROIShape> rois)
ROIShapes on the look panel.
The shapes may be of different types.
drawROIs in interface IDrawingLayerSupportrois - ROIShapes to be drawnpublic void drawLineROI(LineROI roi)
LineROI on the look panel.drawLineROI in interface IDrawingLayerSupportroi - a LineROI to be drawnpublic void drawAngleROI(AngleROI roi)
AngleROI on the look panel.drawAngleROI in interface IDrawingLayerSupportroi - a AngleROI to be drawnpublic void drawEllipseROI(EllipseROI roi)
EllipseROI on the look panel.drawEllipseROI in interface IDrawingLayerSupportroi - a EllipseROI to be drawnpublic void drawFreehandROI(FreehandROI roi)
FreehandROI on the look panel.drawFreehandROI in interface IDrawingLayerSupportroi - a FreehandROI to be drawnpublic void drawPolygonROI(PolygonROI roi)
PolygonROI on the look panel.drawPolygonROI in interface IDrawingLayerSupportroi - a PolygonROI to be drawnpublic void drawRectangleROI(RectangleROI roi)
RectangleROI on the look panel.drawRectangleROI in interface IDrawingLayerSupportroi - a RectangleROI to be drawnpublic void drawPointROI(PointROI roi)
PointROI on the look panel.drawPointROI in interface IDrawingLayerSupportroi - a PointROI to be drawnpublic void drawLineROIs(List<LineROI> rois)
LineROIs on the look panel.drawLineROIs in interface IDrawingLayerSupportrois - LineROIs to be drawnpublic void drawRectangleROIs(List<RectangleROI> rois)
RectangleROIs on the look panel.drawRectangleROIs in interface IDrawingLayerSupportrois - RectangleROIs to be drawnpublic void drawEllipseROIs(List<EllipseROI> rois)
EllipseROIs on the look panel.drawEllipseROIs in interface IDrawingLayerSupportrois - RectangleROIs to be drawnpublic void drawFreehandROIs(List<FreehandROI> rois)
FreehandROIs on the look panel.drawFreehandROIs in interface IDrawingLayerSupportrois - FreehandROIs to be drawnpublic void drawAngleROIs(List<AngleROI> rois)
AngleROIs on the look panel.drawAngleROIs in interface IDrawingLayerSupportrois - AngleROIs to be drawnpublic void drawPointROIs(List<PointROI> rois)
PointROIs on the look panel.drawPointROIs in interface IDrawingLayerSupportrois - PointROIs to be drawnpublic void drawPolygonROIs(List<PolygonROI> rois)
PolygonROIs on the look panel.drawPolygonROIs in interface IDrawingLayerSupportrois - PolygonROIs to be drawnpublic void setAllROIShapes(List<javax.media.jai.ROIShape> shapes)
IDrawingLayerROIShapes.setAllROIShapes in interface IDrawingLayershapes - a list of ROI shapes.public ArrayList<javax.media.jai.ROIShape> getAllROIShapes()
IDrawingLayerROIShapes in this layer.getAllROIShapes in interface IDrawingLayerROIShapes of this layerpublic javax.media.jai.ROIShape getCurrentROIShape()
IDrawingLayerROIShape.getCurrentROIShape in interface IDrawingLayerpublic void setCurrentROIShape(javax.media.jai.ROIShape currentROIShape)
IDrawingLayerROIShape.setCurrentROIShape in interface IDrawingLayercurrentROIShape - the currentROIShape to setpublic void setTmpROIShape(javax.media.jai.ROIShape tmp)
IDrawingLayersetTmpROIShape in interface IDrawingLayerpublic javax.media.jai.ROIShape getTmpROIShape()
IDrawingLayergetTmpROIShape in interface IDrawingLayerROIShape, or null, if none is specifiedpublic void removeTmpROIShape()
removeTmpROIShape in interface IDrawingLayerpublic javax.media.jai.ROIShape getClickedROIShape()
IDrawingLayerROIShape.getClickedROIShape in interface IDrawingLayerpublic void setClickedROIShape(javax.media.jai.ROIShape clickedROIShape)
IDrawingLayerROIShape.setClickedROIShape in interface IDrawingLayerclickedROIShape - the clickedROIShape to setpublic ArrayList<LineROI> getLineROIs()
IDrawingLayerLineROIs in this layer.getLineROIs in interface IDrawingLayerpublic void setLineROIs(ArrayList<LineROI> lineROIs)
IDrawingLayerLineROIs in this layer. This will overwrite the entire
list of line rois in this layer.setLineROIs in interface IDrawingLayerlineROIs - the lineROIs to setpublic LineROI getCurrentLineROI()
IDrawingLayerLineROI in this layer.getCurrentLineROI in interface IDrawingLayerpublic void setCurrentLineROI(LineROI currentLineROI)
IDrawingLayerLineROI in this layer.setCurrentLineROI in interface IDrawingLayercurrentLineROI - the currentLineROI to setpublic RectangleROI getCurrentRectangleROI()
IDrawingLayerRectangleROI in this layer.getCurrentRectangleROI in interface IDrawingLayerpublic void setCurrentRectangleROI(RectangleROI currentRectangleROI)
IDrawingLayerRectangleROI in this layer.setCurrentRectangleROI in interface IDrawingLayercurrentRectangleROI - the currentRectangleROI to setpublic ArrayList<RectangleROI> getRectangleROIs()
IDrawingLayerRectangleROIs in this layer.getRectangleROIs in interface IDrawingLayerpublic void setRectangleROIs(ArrayList<RectangleROI> rectangleROIs)
IDrawingLayerRectangleROIs in this layer. This will overwrite the
entire list of rectangle rois in this layer.setRectangleROIs in interface IDrawingLayerrectangleROIs - the rectangleROIs to setpublic EllipseROI getCurrentEllipseROI()
IDrawingLayerEllipseROI in this layer.getCurrentEllipseROI in interface IDrawingLayerpublic void setCurrentEllipseROI(EllipseROI currentEllipseROI)
IDrawingLayerEllipseROI in this layer.setCurrentEllipseROI in interface IDrawingLayercurrentEllipseROI - the currentEllipseROI to setpublic ArrayList<EllipseROI> getEllipseROIs()
IDrawingLayerEllipseROIs in this layer.getEllipseROIs in interface IDrawingLayerpublic void setEllipseROIs(ArrayList<EllipseROI> ellipseROIs)
IDrawingLayerEllipseROIs in this layer. This will overwrite the entire
list of ellipse rois in this layer.setEllipseROIs in interface IDrawingLayerellipseROIs - the ellipseROIs to setpublic GeneralPath getFreehandShape()
IDrawingLayergetFreehandShape in interface IDrawingLayerpublic void setFreehandShape(GeneralPath freehandShape)
IDrawingLayersetFreehandShape in interface IDrawingLayerfreehandShape - the polyLine to setpublic FreehandROI getCurrentFreehandROI()
IDrawingLayerFreehandROI in this layer.getCurrentFreehandROI in interface IDrawingLayerpublic void setCurrentFreehandROI(FreehandROI currentFreehandROI)
IDrawingLayerFreehandROI.setCurrentFreehandROI in interface IDrawingLayercurrentFreehandROI - the currentFreehandROI to setpublic ArrayList<FreehandROI> getFreehandROIs()
IDrawingLayerFreehandROIs in this layer.getFreehandROIs in interface IDrawingLayerpublic void setFreehandROIs(ArrayList<FreehandROI> freehandROIs)
IDrawingLayerFreehandROIs in this layer. This will overwrite any
existing FreehandROIs.setFreehandROIs in interface IDrawingLayerfreehandROIs - the freehandROIs to setpublic int getNumPolyPoints()
IDrawingLayerPolygonROI.getNumPolyPoints in interface IDrawingLayerpublic void setNumPolyPoints(int numPolyPoints)
IDrawingLayerPolygonROI corners of the currently drawn
polygon ROI.setNumPolyPoints in interface IDrawingLayernumPolyPoints - the numPolyPoints to setpublic GeneralPath getPolygonShape()
IDrawingLayerPolygonROI.getPolygonShape in interface IDrawingLayerpublic void setPolygonShape(GeneralPath polygonShape)
IDrawingLayerPolygonROI.setPolygonShape in interface IDrawingLayerpolygonShape - the polygonShape to setpublic PolygonROI getCurrentPolygonROI()
IDrawingLayerPolygonROI in this layer.getCurrentPolygonROI in interface IDrawingLayerpublic void setCurrentPolygonROI(PolygonROI currentPolygonROI)
IDrawingLayerPolygonROI.setCurrentPolygonROI in interface IDrawingLayercurrentPolygonROI - the currentPolygonROI to setpublic ArrayList<PolygonROI> getPolygonROIs()
IDrawingLayerPolygonROIs in this layer.getPolygonROIs in interface IDrawingLayerpublic void setPolygonROIs(ArrayList<PolygonROI> polygonROIs)
IDrawingLayerPolygonROIs in this layer. This will overwrite any
existing PolygonROIs.setPolygonROIs in interface IDrawingLayerpolygonROIs - the polygonROIs to setpublic AngleROI getCurrentAngleROI()
IDrawingLayerAngleROI in this layer.getCurrentAngleROI in interface IDrawingLayerpublic void setCurrentAngleROI(AngleROI currentAngleROI)
IDrawingLayerAngleROI in this layer. The current
AngleROI will be highlighted first on editing ROIs.setCurrentAngleROI in interface IDrawingLayercurrentAngleROI - the currentAngleROI to setpublic PointROI getCurrentPointROI()
IDrawingLayerPointROI in this layer.getCurrentPointROI in interface IDrawingLayerpublic void setCurrentPointROI(PointROI currentPointROI)
IDrawingLayerPointROI in this layer.setCurrentPointROI in interface IDrawingLayercurrentPointROI - the currentPointROI to setpublic GeneralPath getAngleShape()
IDrawingLayerAngleROIs.getAngleShape in interface IDrawingLayerpublic void setAngleShape(GeneralPath angleShape)
IDrawingLayerAngleROIs.setAngleShape in interface IDrawingLayerangleShape - the angleShape to setpublic int getNumAnglePoints()
IDrawingLayerAngleROIs.getNumAnglePoints in interface IDrawingLayerpublic void setNumAnglePoints(int numAnglePoints)
IDrawingLayerAngleROIs.setNumAnglePoints in interface IDrawingLayernumAnglePoints - the numAnglePoints to setpublic ArrayList<AngleROI> getAngleROIs()
IDrawingLayerAngleROIs drawn in this layer.getAngleROIs in interface IDrawingLayerpublic void setAngleROIs(ArrayList<AngleROI> angleROIs)
IDrawingLayerAngleROIs in this layer.setAngleROIs in interface IDrawingLayerangleROIs - the angleROIs to setpublic ArrayList<PointROI> getPointROIs()
IDrawingLayerPointROIs in this layer.getPointROIs in interface IDrawingLayerpublic void setPointROIs(ArrayList<PointROI> pointROIs)
IDrawingLayerPointROIs in this layer. This will overwrite the entire
list of point rois in this layer.setPointROIs in interface IDrawingLayerpointROIs - the PointROIs to setpublic void fireNewProperties(javax.media.jai.ROIShape roi)
ROIShape:
px of a given LineROI shape
to the ImageInfoPanel.
px of a given angle ROI
shape.
px² of a given ROI shape, which is
permitted to have a closed area such as classes implementing
AreaEnabledROI to the ImageInfoPanel.
fireNewProperties in interface IDrawingLayerroi - public void update()
IDrawingLayerIDrawingLayer to repaint all shapes.update in interface IDrawingLayerpublic void deleteROI(javax.media.jai.ROIShape roi)
IDrawingLayerSupportdeleteROI in interface IDrawingLayerSupportpublic void deleteROIs(List<javax.media.jai.ROIShape> rois)
IDrawingLayerSupportdeleteROIs in interface IDrawingLayerSupportpublic void deleteAllROIs()
IDrawingLayerSupportROIShapes on this layer.deleteAllROIs in interface IDrawingLayerSupportpublic void deleteSelectedROI()
ArrayList to the current ROI.deleteSelectedROI in interface IDrawingLayerSupportpublic int getRoiX0()
IDrawingLayergetRoiX0 in interface IDrawingLayerpublic void setRoiX0(int roiX0)
IDrawingLayersetRoiX0 in interface IDrawingLayerroiX0 - the roiX0 to setpublic int getRoiY0()
IDrawingLayergetRoiY0 in interface IDrawingLayerpublic void setRoiY0(int roiY0)
IDrawingLayersetRoiY0 in interface IDrawingLayerroiY0 - the roiY0 to setpublic int getRoiShiftX0()
IDrawingLayergetRoiShiftX0 in interface IDrawingLayerpublic void setRoiShiftX0(int roiShiftX0)
IDrawingLayersetRoiShiftX0 in interface IDrawingLayerroiShiftX0 - the roiShiftX0 to setpublic int getRoiShiftY0()
IDrawingLayergetRoiShiftY0 in interface IDrawingLayerpublic void setRoiShiftY0(int roiShiftY0)
IDrawingLayersetRoiShiftY0 in interface IDrawingLayerroiShiftY0 - the roiShiftY0 to setpublic boolean isROIDragging()
IDrawingLayerisROIDragging in interface IDrawingLayerpublic void setROIDragging(boolean isROIDragging)
IDrawingLayersetROIDragging in interface IDrawingLayerisROIDragging - the isROIDragging to setpublic boolean isInsideRoi()
IDrawingLayerisInsideRoi in interface IDrawingLayerpublic void setInsideRoi(boolean isInsideRoi)
IDrawingLayersetInsideRoi in interface IDrawingLayerisInsideRoi - the isInsideRoi to setpublic boolean isInsidePtNorthWest()
IDrawingLayerisInsidePtNorthWest in interface IDrawingLayerpublic void setInsidePtNorthWest(boolean isInsidePtNorthWest)
IDrawingLayersetInsidePtNorthWest in interface IDrawingLayerisInsidePtNorthWest - the isInsidePtNorthWest to setpublic boolean isInsidePtNorth()
IDrawingLayerisInsidePtNorth in interface IDrawingLayerpublic void setInsidePtNorth(boolean isInsidePtNorth)
IDrawingLayersetInsidePtNorth in interface IDrawingLayerisInsidePtNorth - the isInsidePtNorth to setpublic boolean isInsidePtNorthEast()
IDrawingLayerisInsidePtNorthEast in interface IDrawingLayerpublic void setInsidePtNorthEast(boolean isInsidePtNorthEast)
IDrawingLayersetInsidePtNorthEast in interface IDrawingLayerisInsidePtNorthEast - the isInsidePtNorthEast to setpublic boolean isInsidePtEast()
IDrawingLayerisInsidePtEast in interface IDrawingLayerpublic void setInsidePtEast(boolean isInsidePtEast)
IDrawingLayersetInsidePtEast in interface IDrawingLayerisInsidePtEast - the isInsidePtEast to setpublic boolean isInsidePtSouthEast()
IDrawingLayerisInsidePtSouthEast in interface IDrawingLayerpublic void setInsidePtSouthEast(boolean isInsidePtSouthEast)
IDrawingLayersetInsidePtSouthEast in interface IDrawingLayerisInsidePtSouthEast - the isInsidePtSouthEast to setpublic boolean isInsidePtSouth()
IDrawingLayerisInsidePtSouth in interface IDrawingLayerpublic void setInsidePtSouth(boolean isInsidePtSouth)
IDrawingLayersetInsidePtSouth in interface IDrawingLayerisInsidePtSouth - the isInsidePtSouth to setpublic boolean isInsidePtSouthWest()
IDrawingLayerisInsidePtSouthWest in interface IDrawingLayerpublic void setInsidePtSouthWest(boolean isInsidePtSouthWest)
IDrawingLayersetInsidePtSouthWest in interface IDrawingLayerisInsidePtSouthWest - the isInsidePtSouthWest to setpublic boolean isInsidePtWest()
IDrawingLayerisInsidePtWest in interface IDrawingLayerpublic void setInsidePtWest(boolean isInsidePtWest)
IDrawingLayersetInsidePtWest in interface IDrawingLayerisInsidePtWest - the isInsidePtWest to setprotected void createContextMenuAndBehavior()
ActionListener. All commands have to be implemented in this
class.private void reOrganizeROIs(javax.media.jai.ROIShape currentROIShape)
public void setBoundEditableRectangles(javax.media.jai.ROIShape[] rs)
setBoundEditableRectangles in interface IDrawingLayerpublic javax.media.jai.ROIShape[] getBoundEditableRectangles()
public javax.media.jai.ROIShape[] getBoundEditableRectanglesUntransformed()
public void setBoundEditableRectanglesUntransformed(javax.media.jai.ROIShape[] boundEditableRectanglesUntransformed)
setBoundEditableRectanglesUntransformed in interface IDrawingLayerpublic Color getDefaultLayerColor()
getDefaultLayerColor in interface IDrawingLayerpublic void setDefaultLayerColor(Color defaultLayerColor)
setDefaultLayerColor in interface IDrawingLayerpublic BasicStroke getDefaultROIStroke()
getDefaultROIStroke in interface IDrawingLayerpublic void setDefaultROIStroke(BasicStroke defaultROIStroke)
setDefaultROIStroke in interface IDrawingLayerpublic Color getLineROIBoundaryColor()
getLineROIBoundaryColor in interface IDrawingLayerpublic void setLineROIBoundaryColor(Color lineROIBoundaryColor)
public Color getTmpROIShapeColor()
public void setTmpROIShapeColor(Color tmpROIShapeColor)
public Color getRoiBoundaryRectangleColor()
getRoiBoundaryRectangleColor in interface IDrawingLayerpublic void setRoiBoundaryRectangleColor(Color roiBoundaryRectangleColor)
public javax.media.jai.ROIShape getRoiShapeForHighlighting()
getRoiShapeForHighlighting in interface IDrawingLayerpublic Color getLineROIBoundaryRectangleColor()
getLineROIBoundaryRectangleColor in interface IDrawingLayerpublic void setLineROIBoundaryRectangleColor(Color lineROIBoundaryRectangleColor)
public void setRoiShapeForHighlighting(javax.media.jai.ROIShape roiShapeForHighlighting)
public void removeRoiShapeForHighlighting()
null.removeRoiShapeForHighlighting in interface IDrawingLayerpublic Color getHighlightColor()
getHighlightColor in interface IDrawingLayerpublic void setHighlightColor(Color highlightColor)
setHighlightColor in interface IDrawingLayerpublic BasicStroke getHighlightStroke()
getHighlightStroke in interface IDrawingLayerpublic void setHighlightStroke(BasicStroke highlightStroke)
setHighlightStroke in interface IDrawingLayerpublic void paintComponent(Graphics g)
paintComponent in class JComponentg - public void mouseWheelMoved(MouseWheelEvent e)
mouseWheelMoved in interface MouseWheelListenerpublic void mousePressed(MouseEvent e)
mousePressed in interface MouseListenerpublic void mouseReleased(MouseEvent e)
mouseReleased in interface MouseListenerpublic void mouseMoved(MouseEvent e)
mouseMoved in interface MouseMotionListenerpublic void mouseDragged(MouseEvent e)
mouseDragged in interface MouseMotionListenerprivate void dragROI(AffineTransform at, Point p, MouseEvent e)
private void searchForInsideROIClick(Point p, MouseEvent e)
p - e - private void updateROIInformation(MouseEvent e)
public void setDisplayPanel(ILookPanel displayPanel)
public ILookPanel getDisplayPanel()
public UUID getID()
IDrawingLayergetID in interface IDrawingLayerUUID objectpublic void setID(UUID id)
IDrawingLayersetID in interface IDrawingLayerpublic boolean hasROIs()
IDrawingLayerhasROIs in interface IDrawingLayertrue, if minimum one shape is present,
false otherwiseCopyright © 2009–2017 Helmut Ahammer, Philipp Kainz. All rights reserved.