Interface TerminalWindowListener

All Known Implementing Classes:
Terminal

public interface TerminalWindowListener
This class listens to the terminal window display changes in terms of entering character data and pressing send keys.
  • Method Summary Link icon

    Modifier and Type
    Method
    Description
    boolean
    The insert mode can be read using this method.
    boolean
    Checks if disconnected, used e.g.
    boolean
    Checks for lock state in case status bar is not present.
    boolean
    Checks if marking is allowed, i.e.
    boolean
    onActivateMenu(boolean isPopup)
    Handles display of the pop-up window or activation of the menu bar.
    void
    Called when the mark changes.
    boolean
    onPopup(int x, int y)
    Handles display of the pop-up window.
    void
    sendCharacter(char ch)
    Sends a character to the terminal.
    void
    sendHostKey(int key)
    Sends a key to the terminal.
    void
    Sends a KeyEvent to the terminal.
    boolean
    setCursor(int x, int y)
    Sets the cursor position to X/Y.
  • Method Details Link icon

    • sendKey Link icon

      void sendKey(HostKeyEvent event)
      Sends a KeyEvent to the terminal.
      Parameters:
      event - The Host Key Event.
    • sendHostKey Link icon

      void sendHostKey(int key)
      Sends a key to the terminal.
      Parameters:
      key - The key to send.
    • sendCharacter Link icon

      void sendCharacter(char ch)
      Sends a character to the terminal.
      Parameters:
      ch - The character to send.
    • setCursor Link icon

      boolean setCursor(int x, int y)
      Sets the cursor position to X/Y.
      Parameters:
      x - The X position.
      y - The Y position.
      Returns:
      false for failure (or not supported).
    • onPopup Link icon

      boolean onPopup(int x, int y)
      Handles display of the pop-up window.
      Parameters:
      x - The mouse position in X relative the terminal container.
      y - The mouse position in Y relative the terminal container.
      Returns:
      true if handled (i.e. menu is displayed).
    • onActivateMenu Link icon

      boolean onActivateMenu(boolean isPopup)
      Handles display of the pop-up window or activation of the menu bar.
      Parameters:
      isPopup - Flag indicating it's a pop-up that should be activated, as opposed to the menu bar.
      Returns:
      true if handled (i.e. menu is displayed).
    • onMarkChange Link icon

      void onMarkChange()
      Called when the mark changes.
    • isDisconnected Link icon

      boolean isDisconnected()
      Checks if disconnected, used e.g. to paint the cursor.
      Returns:
      true if disconnected.
    • isMarkAllowed Link icon

      boolean isMarkAllowed()
      Checks if marking is allowed, i.e. connected.
      Returns:
      Mark allowed.
    • isLocked Link icon

      boolean isLocked()
      Checks for lock state in case status bar is not present.
      Returns:
      true if locked.
    • inInsertMode Link icon

      boolean inInsertMode()
      The insert mode can be read using this method.
      Returns:
      true if insert mode, false = overwrite.