public abstract class AbstractReshapeHandleProvider extends Object implements IReshapeHandleProvider
IReshapeHandleProvider
interface that has properties to restrict the
size and area of a reshapeable.Constructor and Description |
---|
AbstractReshapeHandleProvider() |
Modifier and Type | Method and Description |
---|---|
HandlePositions |
getAvailableHandles(IInputModeContext context)
Returns the
HandlePositions property. |
abstract IHandle |
getHandle(IInputModeContext context,
HandlePositions position)
Provides a
IHandle that uses the rectangle and reshapeable instance bound to this instance to perform the actual
reshaping. |
HandlePositions |
getHandlePositions()
Gets the bitwise combination of all handle positions this instance provides a handle for.
|
ISize |
getMaximumSize()
Gets the maximum size allowed for the reshapeable.
|
IRectangle |
getMinimumEnclosedArea()
Gets the minimum rectangular area that needs to be contained in the reshapeable.
|
ISize |
getMinimumSize()
Gets the minimum size allowed for the reshapeable.
|
void |
setHandlePositions(HandlePositions value)
Sets the bitwise combination of all handle positions this instance provides a handle for.
|
void |
setMaximumSize(ISize value)
Sets the maximum size allowed for the reshapeable.
|
void |
setMinimumEnclosedArea(IRectangle value)
Sets the minimum rectangular area that needs to be contained in the reshapeable.
|
void |
setMinimumSize(ISize value)
Sets the minimum size allowed for the reshapeable.
|
public HandlePositions getAvailableHandles(IInputModeContext context)
HandlePositions
property.getAvailableHandles
in interface IReshapeHandleProvider
context
- The context for which the handles are queried.RectangleReshapeHandleProvider.getHandle(IInputModeContext, HandlePositions)
.public abstract IHandle getHandle(IInputModeContext context, HandlePositions position)
IHandle
that uses the rectangle and reshapeable instance bound to this instance to perform the actual
reshaping.
This method may be called for each possible single position contained in the set as returned by
getAvailableHandles(IInputModeContext)
.
getHandle
in interface IReshapeHandleProvider
context
- The context for which the handles are queried.position
- The position to provide an instance for.public final HandlePositions getHandlePositions()
getAvailableHandles(IInputModeContext)
,
RectangleReshapeHandleProvider.getHandle(IInputModeContext, HandlePositions)
,
setHandlePositions(HandlePositions)
public final ISize getMaximumSize()
The default value is SizeD.INFINITE
.
RectangleHandle.getMaximumSize()
,
setMaximumSize(ISize)
public final IRectangle getMinimumEnclosedArea()
The default value is SizeD.ZERO
.
RectangleHandle.getMinimumEnclosedArea()
,
setMinimumEnclosedArea(IRectangle)
public final ISize getMinimumSize()
The default value is SizeD.ZERO
.
RectangleHandle.getMinimumSize()
,
setMinimumSize(ISize)
public final void setHandlePositions(HandlePositions value)
value
- The HandlePositions to set.getAvailableHandles(IInputModeContext)
,
RectangleReshapeHandleProvider.getHandle(IInputModeContext, HandlePositions)
,
getHandlePositions()
public final void setMaximumSize(ISize value)
The default value is SizeD.INFINITE
.
value
- The maximum size.RectangleHandle.getMaximumSize()
,
getMaximumSize()
public final void setMinimumEnclosedArea(IRectangle value)
The default value is SizeD.ZERO
.
value
- The minimum size.RectangleHandle.getMinimumEnclosedArea()
,
getMinimumEnclosedArea()
public final void setMinimumSize(ISize value)
The default value is SizeD.ZERO
.
value
- The minimum size.RectangleHandle.getMinimumSize()
,
getMinimumSize()