Package tripleplay.ui

Class Constraints.TextConstraint

java.lang.Object
tripleplay.ui.Layout.Constraint
tripleplay.ui.Constraints.TextConstraint
Enclosing class:
Constraints

public abstract static class Constraints.TextConstraint extends Layout.Constraint
A special layout constraint used by TextWidgets which adjusts only the text size of the widget, leaving the remaining dimensions (icon, insets, etc.) unmodified. This is an implementation detail that can be safely ignored unless you are implementing your own custom text constraints.
  • Constructor Details

    • TextConstraint

      public TextConstraint()
  • Method Details

    • addTextSize

      public abstract void addTextSize(pythagoras.f.Dimension into, pythagoras.f.IDimension lsize)
      Adds the appropriate text dimensions to the supplied size.
      Parameters:
      into - the constrained size will be written into this instance.
      lsize - the size of the currently laid out text, may be null.