HtmlToolbarOptions constructor
const
HtmlToolbarOptions({
- List<
String> ? audioExtensions, - List<
Widget> customToolbarButtons = const [], - List<
int> customToolbarInsertionIndices = const [], - List<
Toolbar> defaultToolbarButtons = const [StyleButtons(), FontSettingButtons(fontSizeUnit: false), FontButtons(clearAll: false), ColorButtons(), ListButtons(listStyles: false), ParagraphButtons(textDirection: false, lineHeight: false, caseConverter: false), InsertButtons(video: false, audio: false, table: false, hr: false, otherFile: false)], - List<
String> ? otherFileExtensions, - List<
String> ? imageExtensions, - bool initiallyExpanded = false,
- FutureOr<
bool> linkInsertInterceptor()?, - FutureOr<
bool> mediaLinkInsertInterceptor()?, - FutureOr<
bool> mediaUploadInterceptor(- PlatformFile,
- InsertFileType
- FutureOr<
bool> onButtonPressed(- ButtonType,
- bool?,
- Function?
- FutureOr<
bool> onDropdownChanged(- DropdownType,
- dynamic,
- void (
- dynamic
- void onOtherFileLinkInsert()?,
- void onOtherFileUpload(
- PlatformFile
- ToolbarType toolbarType = ToolbarType.nativeScrollable,
- ToolbarPosition toolbarPosition = ToolbarPosition.aboveEditor,
- List<
String> ? videoExtensions, - int dropdownElevation = 8,
- Widget? dropdownIcon,
- Color? dropdownIconColor,
- double dropdownIconSize = 24,
- double dropdownItemHeight = kMinInteractiveDimension,
- Color? dropdownFocusColor,
- Color? dropdownBackgroundColor,
- DropdownMenuDirection? dropdownMenuDirection,
- double? dropdownMenuMaxHeight,
- BoxDecoration? dropdownBoxDecoration,
- Color? buttonColor,
- Color? buttonSelectedColor,
- Color? buttonFillColor,
- Color? buttonFocusColor,
- Color? buttonHighlightColor,
- Color? buttonHoverColor,
- Color? buttonSplashColor,
- Color? buttonBorderColor,
- Color? buttonSelectedBorderColor,
- BorderRadius? buttonBorderRadius,
- double? buttonBorderWidth,
- bool renderBorder = false,
- TextStyle? textStyle,
- Widget separatorWidget = const VerticalDivider(indent: 2, endIndent: 2, color: Colors.grey),
- bool renderSeparatorWidget = true,
- double toolbarItemHeight = 36,
- double gridViewHorizontalSpacing = 5,
- double gridViewVerticalSpacing = 5,
- bool allowImagePicking = true,
Implementation
const HtmlToolbarOptions({
this.audioExtensions,
this.customToolbarButtons = const [],
this.customToolbarInsertionIndices = const [],
this.defaultToolbarButtons = const [
StyleButtons(),
FontSettingButtons(fontSizeUnit: false),
FontButtons(clearAll: false),
ColorButtons(),
ListButtons(listStyles: false),
ParagraphButtons(textDirection: false, lineHeight: false, caseConverter: false),
InsertButtons(video: false, audio: false, table: false, hr: false, otherFile: false),
],
this.otherFileExtensions,
this.imageExtensions,
this.initiallyExpanded = false,
this.linkInsertInterceptor,
this.mediaLinkInsertInterceptor,
this.mediaUploadInterceptor,
this.onButtonPressed,
this.onDropdownChanged,
this.onOtherFileLinkInsert,
this.onOtherFileUpload,
this.toolbarType = ToolbarType.nativeScrollable,
this.toolbarPosition = ToolbarPosition.aboveEditor,
this.videoExtensions,
this.dropdownElevation = 8,
this.dropdownIcon,
this.dropdownIconColor,
this.dropdownIconSize = 24,
this.dropdownItemHeight = kMinInteractiveDimension,
this.dropdownFocusColor,
this.dropdownBackgroundColor,
this.dropdownMenuDirection,
this.dropdownMenuMaxHeight,
this.dropdownBoxDecoration,
this.buttonColor,
this.buttonSelectedColor,
this.buttonFillColor,
this.buttonFocusColor,
this.buttonHighlightColor,
this.buttonHoverColor,
this.buttonSplashColor,
this.buttonBorderColor,
this.buttonSelectedBorderColor,
this.buttonBorderRadius,
this.buttonBorderWidth,
this.renderBorder = false,
this.textStyle,
this.separatorWidget = const VerticalDivider(indent: 2, endIndent: 2, color: Colors.grey),
this.renderSeparatorWidget = true,
this.toolbarItemHeight = 36,
this.gridViewHorizontalSpacing = 5,
this.gridViewVerticalSpacing = 5,
this.allowImagePicking = true,
});