Package com.mxgraph.swing.view
Class mxCellStatePreview
java.lang.Object
com.mxgraph.swing.view.mxCellStatePreview
Represents the current state of a cell in a given graph view.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected List<mxCellState>protected booleanSpecifies if cell states should be cloned or changed in-place.protected intprotected Map<mxCellState,mxPoint> protected mxGraphComponentprotected float -
Constructor Summary
ConstructorsConstructorDescriptionmxCellStatePreview(mxGraphComponent graphComponent, boolean cloned) Constructs a new state preview. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddEdges(mxCellState state) intgetCount()floatprotected floatgetOpacityForCell(Object cell) booleanisCloned()booleanisEmpty()moveState(mxCellState state, double dx, double dy) moveState(mxCellState state, double dx, double dy, boolean add, boolean includeEdges) voidprotected voidpaintPreview(mxGraphics2DCanvas canvas) Draws the preview using the graphics canvas.protected voidpaintPreviewState(mxGraphics2DCanvas canvas, mxCellState state) Draws the preview using the graphics canvas.voidrestore(List<mxCellState> snapshot) voidrestoreState(mxCellState state, mxCellState from) protected mxRectanglerevalidateState(mxCellState parentState, mxCellState state, double dx, double dy) voidsetCloned(boolean value) voidsetOpacity(float value) show()Returns a dirty rectangle to be repainted in mxGraphControl.snapshot(mxCellState state) protected voidtranslateState(mxCellState parentState, mxCellState state, double dx, double dy)
-
Field Details
-
deltas
-
count
protected int count -
graphComponent
-
cloned
protected boolean clonedSpecifies if cell states should be cloned or changed in-place. -
opacity
protected float opacity -
cellStates
-
-
Constructor Details
-
mxCellStatePreview
Constructs a new state preview. The paint handler to invoke the paint method must be installed elsewhere.
-
-
Method Details
-
isCloned
public boolean isCloned() -
setCloned
public void setCloned(boolean value) -
isEmpty
public boolean isEmpty() -
getCount
public int getCount() -
getDeltas
-
setOpacity
public void setOpacity(float value) -
getOpacity
public float getOpacity() -
moveState
-
moveState
public mxPoint moveState(mxCellState state, double dx, double dy, boolean add, boolean includeEdges) -
show
Returns a dirty rectangle to be repainted in mxGraphControl. -
restore
-
restoreState
-
snapshot
-
translateState
-
revalidateState
protected mxRectangle revalidateState(mxCellState parentState, mxCellState state, double dx, double dy) -
addEdges
-
paint
-
getOpacityForCell
-
paintPreview
Draws the preview using the graphics canvas. -
paintPreviewState
Draws the preview using the graphics canvas.
-