Class InputFieldRenderer

All Implemented Interfaces:
IPropertyContainer, IRenderer

public class InputFieldRenderer extends AbstractOneLineTextFieldRenderer
The AbstractOneLineTextFieldRenderer implementation for input fields.
  • Constructor Details

    • InputFieldRenderer

      public InputFieldRenderer (InputField modelElement)
      Creates a new InputFieldRenderer instance.
      Parameters:
      modelElement - the model element
  • Method Details

    • getNextRenderer

      public IRenderer getNextRenderer()
      Gets a new instance of this class to be used as a next renderer, after this renderer is used, if IRenderer.layout(LayoutContext) is called more than once.
      Returns:
      new renderer instance
    • getSize

      public int getSize()
      Gets the size of the input field.
      Returns:
      the input field size
    • isPassword

      public boolean isPassword()
      Checks if the input field is a password field.
      Returns:
      true, if the input field is a password field
    • adjustFieldLayout

      protected void adjustFieldLayout (LayoutContext layoutContext)
      Adjusts the field layout.
      Specified by:
      adjustFieldLayout in class AbstractFormFieldRenderer
      Parameters:
      layoutContext - layout context
    • createFlatRenderer

      protected IRenderer createFlatRenderer()
      Creates the flat renderer instance.
      Specified by:
      createFlatRenderer in class AbstractFormFieldRenderer
      Returns:
      the renderer instance.
    • applyAcroField

      protected void applyAcroField (DrawContext drawContext)
      Applies the AcroField widget.
      Specified by:
      applyAcroField in class AbstractFormFieldRenderer
      Parameters:
      drawContext - the draw context
    • getProperty

      public  T1 getProperty (int key)
      Gets the property from this entity. Compared to IPropertyContainer.getOwnProperty(int), this method can check parent's properties, styles, etc, depending on the origin of the instance
      Specified by:
      getProperty in interface IPropertyContainer
      Overrides:
      getProperty in class AbstractRenderer
      Type Parameters:
      T1 - the return type associated with the property
      Parameters:
      key - the property to be retrieved
      Returns:
      the value of the given property. null will be returned if the property value was not found
    • setMinMaxWidthBasedOnFixedWidth

      protected boolean setMinMaxWidthBasedOnFixedWidth (MinMaxWidth minMaxWidth)
      Overrides:
      setMinMaxWidthBasedOnFixedWidth in class AbstractRenderer