@Override
public boolean onTerminalEvent(TerminalEvent event) {
boolean result = true;
if ( event instanceof KeyboardEvent ) {
KeyboardEvent kbdEvent = (KeyboardEvent)event;
if ( (kbdEvent.isCtrlDown() && kbdEvent.getKeyCode() == KeyCode.V)
|| (kbdEvent.isShiftDown() && kbdEvent.getKeyCode() == KeyCode.INSERT)
) {
try {
String pasteText = Toolkit.getDefaultToolkit().getSystemClipboard().getData(DataFlavor.stringFlavor).toString();
String[] lines = pasteText.split("\n");
for(int i = 0; i != lines.length; ++i) {