Package org.exbin.bined.swing
Interface CodeAreaCommandHandler
-
- All Known Implementing Classes:
DefaultCodeAreaCommandHandler
@ParametersAreNonnullByDefault public interface CodeAreaCommandHandlerInterface for code area data manipulation.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceCodeAreaCommandHandler.CodeAreaCommandHandlerFactorystatic classCodeAreaCommandHandler.ScrollbarOrientationstatic classCodeAreaCommandHandler.SelectingMode
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidbackSpacePressed()Backspace key was pressed.booleancanPaste()Returns true if paste action is possible.voidclearSelection()Clears data selection.voidcopy()Copies selection to clipboard.voidcopyAsCode()Copies selection to clipboard as code string.voidcut()Cuts selection to clipboard.voiddelete()Deletes selection.voiddeletePressed()Delete key was pressed.voidenterPressed()Enter key was pressed.booleancheckEditAllowed()Checks whether edit is allowed.voidkeyPressed(java.awt.event.KeyEvent keyEvent)Keyboard key was pressed.voidkeyTyped(java.awt.event.KeyEvent keyEvent)Keyboard key was typed.voidmoveCaret(int positionX, int positionY, CodeAreaCommandHandler.SelectingMode selecting)Moves caret with mouse event.voidpaste()Pastes content of clipboard to cursor area.voidpasteFromCode()Pastes content of clipboard to cursor area analyzing string code.voidselectAll()Expands selection to all data.voidundoSequenceBreak()Notifies command handler about end of sequence of append-able commands.voidwheelScroll(int scrollSize, CodeAreaCommandHandler.ScrollbarOrientation orientation)Performs scrolling.
-
-
-
Method Detail
-
undoSequenceBreak
void undoSequenceBreak()
Notifies command handler about end of sequence of append-able commands.
-
keyPressed
void keyPressed(java.awt.event.KeyEvent keyEvent)
Keyboard key was pressed.- Parameters:
keyEvent- key event
-
keyTyped
void keyTyped(java.awt.event.KeyEvent keyEvent)
Keyboard key was typed.- Parameters:
keyEvent- key event
-
enterPressed
void enterPressed()
Enter key was pressed.
-
backSpacePressed
void backSpacePressed()
Backspace key was pressed.
-
deletePressed
void deletePressed()
Delete key was pressed.
-
delete
void delete()
Deletes selection.
-
copy
void copy()
Copies selection to clipboard.
-
copyAsCode
void copyAsCode()
Copies selection to clipboard as code string.
-
cut
void cut()
Cuts selection to clipboard.
-
paste
void paste()
Pastes content of clipboard to cursor area.
-
selectAll
void selectAll()
Expands selection to all data.
-
clearSelection
void clearSelection()
Clears data selection.
-
pasteFromCode
void pasteFromCode()
Pastes content of clipboard to cursor area analyzing string code.
-
canPaste
boolean canPaste()
Returns true if paste action is possible.- Returns:
- true if paste is possible
-
moveCaret
void moveCaret(int positionX, int positionY, CodeAreaCommandHandler.SelectingMode selecting)Moves caret with mouse event.- Parameters:
positionX- relative position XpositionY- relative position Yselecting- selection selecting
-
wheelScroll
void wheelScroll(int scrollSize, CodeAreaCommandHandler.ScrollbarOrientation orientation)Performs scrolling.- Parameters:
scrollSize- number of scroll units (positive or negative)orientation- scrollbar orientation
-
checkEditAllowed
boolean checkEditAllowed()
Checks whether edit is allowed.- Returns:
- true if allowed
-
-