StyledText.
Classes that wish to provide their own drag under effect for a StyledText
can extend this class, override the StyledTextDropTargetEffect.dragOver
method and override any other applicable methods in StyledTextDropTargetEffect to
display their own drag under effect.
super method to get the default drag under effect implementation.
The feedback value is either one of the FEEDBACK constants defined in
class DND which is applicable to instances of this class,
or it must be built by bitwise OR'ing together
(that is, using the int "|" operator) two or more
of those DND effect constants.
DropTargetAdapter, DropTargetEvent, Sample code and further information
| Modifier and Type | Field and Description |
|---|---|
| pack-priv static final int | |
| pack-priv int | |
| pack-priv Listener | |
| pack-priv static final int | |
| pack-priv static final int | |
| pack-priv long | |
| pack-priv int | |
| pack-priv int |
| Access | Constructor and Description |
|---|---|
| public | StyledTextDropTargetEffect(StyledText
the styledText)StyledText over which the user positions the cursor to drop the dataCreates a new |
| Modifier and Type | Method and Description |
|---|---|
| public void | dragEnter(DropTargetEvent
the information associated with the drag start event event)Overrides org. Implements org. dragEnter provides a default drag under effect
for the feedback specified in event.feedback.
|
| public void | dragLeave(DropTargetEvent
the information associated with the drag leave event event)Overrides org. Implements org. dragLeave provides a default drag under effect
for the feedback specified in event.feedback.
|
| public void | dragOver(DropTargetEvent
the information associated with the drag over event event)Overrides org. Implements org. dragOver provides a default drag under effect
for the feedback specified in event.feedback.
|
| public void | dropAccept(DropTargetEvent
the information associated with the drop accept event event)Overrides org. Implements org. dropAccept provides a default drag under effect
for the feedback specified in event.feedback.
|
| pack-priv void |
| CARET_WIDTH | back to summary |
|---|---|
| pack-priv static final int CARET_WIDTH | |
| currentOffset | back to summary |
|---|---|
| pack-priv int currentOffset | |
| paintListener | back to summary |
|---|---|
| pack-priv Listener paintListener | |
| SCROLL_HYSTERESIS | back to summary |
|---|---|
| pack-priv static final int SCROLL_HYSTERESIS | |
| SCROLL_TOLERANCE | back to summary |
|---|---|
| pack-priv static final int SCROLL_TOLERANCE | |
| scrollBeginTime | back to summary |
|---|---|
| pack-priv long scrollBeginTime | |
| scrollX | back to summary |
|---|---|
| pack-priv int scrollX | |
| scrollY | back to summary |
|---|---|
| pack-priv int scrollY | |
| StyledTextDropTargetEffect | back to summary |
|---|---|
| public StyledTextDropTargetEffect(StyledText styledText) Creates a new
| |
| dragEnter | back to summary |
|---|---|
| public void dragEnter(DropTargetEvent event) Overrides org. Implements org. This implementation of
| |
| dragLeave | back to summary |
|---|---|
| public void dragLeave(DropTargetEvent event) Overrides org. Implements org. This implementation of
| |
| dragOver | back to summary |
|---|---|
| public void dragOver(DropTargetEvent event) Overrides org. Implements org. This implementation of
| |
| dropAccept | back to summary |
|---|---|
| public void dropAccept(DropTargetEvent event) Overrides org. Implements org. This implementation of
| |
| refreshCaret | back to summary |
|---|---|
| pack-priv void refreshCaret(StyledText text, int oldOffset, int newOffset) | |