PdfListBoxField constructor

PdfListBoxField(
  1. PdfPage page,
  2. String name,
  3. Rect bounds, {
  4. List<PdfListFieldItem>? items,
  5. bool multiSelect = false,
  6. List<int>? selectedIndexes,
  7. List<String>? selectedValues,
  8. PdfFont? font,
  9. PdfTextAlignment alignment = PdfTextAlignment.left,
  10. PdfColor? borderColor,
  11. PdfColor? foreColor,
  12. PdfColor? backColor,
  13. int? borderWidth,
  14. PdfHighlightMode highlightMode = PdfHighlightMode.invert,
  15. PdfBorderStyle borderStyle = PdfBorderStyle.solid,
  16. String? tooltip,
})

Initializes a new instance of the PdfListBoxField class with the specific page and name.

Implementation

PdfListBoxField(
  PdfPage page,
  String name,
  Rect bounds, {
  List<PdfListFieldItem>? items,
  bool multiSelect = false,
  List<int>? selectedIndexes,
  List<String>? selectedValues,
  PdfFont? font,
  PdfTextAlignment alignment = PdfTextAlignment.left,
  PdfColor? borderColor,
  PdfColor? foreColor,
  PdfColor? backColor,
  int? borderWidth,
  PdfHighlightMode highlightMode = PdfHighlightMode.invert,
  PdfBorderStyle borderStyle = PdfBorderStyle.solid,
  String? tooltip,
}) {
  _helper = PdfListBoxFieldHelper(this);
  _helper.initializeInternal(
    page,
    name,
    bounds,
    font: font,
    alignment: alignment,
    items: items,
    borderColor: borderColor,
    foreColor: foreColor,
    backColor: backColor,
    borderWidth: borderWidth,
    highlightMode: highlightMode,
    borderStyle: borderStyle,
    tooltip: tooltip,
  );
  this.multiSelect = multiSelect;
  if (selectedIndexes != null) {
    this.selectedIndexes = selectedIndexes;
  }
  if (selectedValues != null) {
    this.selectedValues = selectedValues;
  }
}