AdvChooser constructor

AdvChooser(
  1. {String text,
  2. String hint,
  3. String label,
  4. String error,
  5. bool enable,
  6. TextAlign alignment,
  7. String measureText,
  8. TextSpan measureTextSpan,
  9. EdgeInsets padding,
  10. EdgeInsets margin,
  11. AdvChooserController controller,
  12. List<GroupCheckItem> items,
  13. int maxLineExpand,
  14. Color hintColor,
  15. Color labelColor,
  16. Color backgroundColor,
  17. Color borderColor,
  18. Color errorColor,
  19. OnItemChanged itemChangeListener}
)

Implementation

AdvChooser(
    {String text,
    String hint,
    String label,
    String error,
    bool enable,
    TextAlign alignment,
    String measureText,
    TextSpan measureTextSpan,
    EdgeInsets padding,
    EdgeInsets margin,
    AdvChooserController controller,
    List<GroupCheckItem> items,
    int maxLineExpand,
    Color hintColor,
    Color labelColor,
    Color backgroundColor,
    Color borderColor,
    Color errorColor,
    this.itemChangeListener})
    : assert(measureText == null || measureTextSpan == null),
      assert(controller == null ||
          (text == null &&
              hint == null &&
              label == null &&
              error == null &&
              enable == null &&
              alignment == null &&
              items == null)),
      this.hintColor = hintColor ?? PitComponents.chooserHintColor,
      this.labelColor = labelColor ?? PitComponents.chooserLabelColor,
      this.backgroundColor = backgroundColor ?? PitComponents.chooserBackgroundColor,
      this.borderColor = borderColor ?? PitComponents.chooserBorderColor,
      this.errorColor = errorColor ?? PitComponents.chooserErrorColor,
      this.controller = controller ??
          new AdvChooserController(
              text: text ?? "",
              hint: hint ?? "",
              label: label ?? "",
              error: error ?? "",
              enable: enable ?? true,
              alignment: alignment ?? TextAlign.left,
              items: items ?? const []),
      this.measureTextSpan = measureTextSpan ?? new TextSpan(text: measureText, style: ts.fs16.merge(ts.tcBlack)),
      this.padding = padding ?? new EdgeInsets.all(0.0),
      this.margin = margin ?? PitComponents.editableMargin;