In Sikuli X I can use something like
type("x", KEY_CTRL)
How can I do the same in Sikuli API?
Use the key codes in KeyEvent:
DesktopKeyboard keyboard = new DesktopKeyboard(); keyboard.keyDown(KeyEvent.VK_CONTROL); keyboard.type("x"); keyboard.keyUp(KeyEvent.VK_CONTROL);