Interface Focusable

All Known Implementing Classes:
Panel

public interface Focusable
Legacy version of Listener interface that resembles Vaadin 7/8's Component.Focusable API as closely as possible in order to facilitate migration to newer versions of Vaadin. A sub-interface implemented by components that can obtain input focus. This includes all LegacyField components as well as some other components, such as Upload.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Sets the focus to this component.
    int
    Gets the tabulator index of the Focusable component.
    void
    setTabIndex(int tabIndex)
    Sets the tabulator index of the Focusable component.
  • Method Details

    • focus

      void focus()
      Sets the focus to this component.
    • getTabIndex

      int getTabIndex()
      Gets the tabulator index of the Focusable component.
      Returns:
      tab index set for the Focusable component
      See Also:
    • setTabIndex

      void setTabIndex(int tabIndex)
      Sets the tabulator index of the Focusable component. The tab index property is used to specify the order in which the fields are focused when the user presses the Tab key. Components with a defined tab index are focused sequentially first, and then the components with no tab index.

      After all focusable user interface components are done, the browser can begin again from the component with the smallest tab index, or it can take the focus out of the page, for example, to the location bar.

      If the tab index is not set (is set to zero), the default tab order is used. The order is somewhat browser-dependent, but generally follows the HTML structure of the page.

      A negative value means that the component is completely removed from the tabulation order and can not be reached by pressing the Tab key at all.

      Parameters:
      tabIndex - the tab order of this component. Indexes usually start from 1. Zero means that default tab order should be used. A negative value means that the field should not be included in the tabbing sequence.
      See Also: