Interface ScrollSizeSupport

  • All Known Implementing Classes:
    ListBoxTag, TableTag, TextAreaTag, TreeTag

    public interface ScrollSizeSupport

    Definition of an interface to be implemented by tags that allow the specification of a preferred scroll width and height.

    This interface is to be implemented by tags responsible for the creation of UI controls with scrolling support (e.g. text areas, lists, etc.). For elements like this it is typically not obvious which default size they should be given. Some UI platforms use their own specific default sizes which may not be appropriate for a given application. Therefore, JGUIraffe tags allow the developer to explicitly define the size. From the tags, when the represented UI control is created, the width and height to be used can be queried as a NumberWithUnit element. It is then possible for a concrete component manager implementation to setup the control's size accordingly.

    Since:
    1.3
    Version:
    $Id: $
    Author:
    Oliver Heger
    • Method Detail

      • getPreferredScrollWidth

        NumberWithUnit getPreferredScrollWidth()
        Returns the preferred scroll width of the represented component as a NumberWithUnit. Typically, this value is determined during processing of this tag. An implementation should never return null. If no scroll width has been specified, a value of 0 or negative should be returned.
        Returns:
        the preferred scroll width
      • getPreferredScrollHeight

        NumberWithUnit getPreferredScrollHeight()
        Returns the preferred scroll height as a NumberWithUnit. Typically, this value is determined during processing of this tag. An implementation should never return null. If no scroll height has been specified, a value of 0 or negative should be returned.
        Returns:
        the preferred scroll height