SinglePickerConfiguration class
Constructors
-
SinglePickerConfiguration({IconWidgetBuilder? iconBuilder, IconPickerIcon? preSelected, bool shouldScrollToSelectedIcon = true, Color? selectedIconBackgroundColor, bool showSearchBar = true, bool adaptiveDialog = false, bool showTooltips = false, bool barrierDismissible = true, double iconSize = 40, Color? iconColor, double mainAxisSpacing = 5.0, double crossAxisSpacing = 5.0, ShapeBorder? iconPickerShape, Color? backgroundColor, BoxConstraints? constraints, Widget title = const Text('Pick an icon'), Widget closeChild = const Text('Close', textScaler: TextScaler.linear(1.25)), Icon searchIcon = const Icon(Icons.search), String searchHintText = 'Search', Icon searchClearIcon = const Icon(Icons.close), SearchComparator? searchComparator, String noResultsText = 'No results for:', List<IconPack> iconPackModes = const <IconPack>[IconPack.material], Map<String, IconPickerIcon>? customIconPack})
-
const
Properties
-
adaptiveDialog
→ bool
-
Adapts the dialog to the screen size.
Behaves like a "ModalDialog"
Defaults to
false
finalinherited
-
backgroundColor
→ Color?
-
The color for the AlertDialog's background color
Defaults to
Theme.of(context).dialogBackgroundColor
settings
finalinherited
-
barrierDismissible
→ bool
-
Declares if the AlertDialog should dismiss when tapping on the outer barrier
Defaults to
true
finalinherited
-
closeChild
→ Widget
-
The child for the Widget
FlatButton
, which closes the dialog.
Sits underneeth everything.
Defaults to:
finalinherited
-
constraints
→ BoxConstraints?
-
The dialogs
BoxConstraints
for limiting/setting:
maxHeight
, maxWidth
, minHeight
, minWidth
Defaults to:
finalinherited
-
crossAxisSpacing
→ double
-
How much space to place between children in a run in the cross axis.
For example, if
spacing
is 10.0, the children will be spaced at least 10.0 logical pixels apart in the cross axis.
Defaults to 5.0
finalinherited
-
customIconPack
→ Map<String, IconPickerIcon>?
-
Provide here your custom IconPack in a Map<String, IconData>
to show your own collection of Icons to pick from
finalinherited
-
hashCode
→ int
-
The hash code for this object.
no setterinherited
-
iconBuilder
→ IconWidgetBuilder?
-
The IconWidgetBuilder is a function that builds a widget for the IconPicker
finalinherited
-
iconColor
→ Color?
-
The color of every Icon to be picked
Defaults to
Theme.of(context).iconTheme.color
settings
finalinherited
-
iconPackModes
→ List<IconPack>
-
The modes which Icons to show
Modes:
material
,
cupertino
,
materialOutline
,
fontAwesomeIcons
,
lineAwesomeIcons
Default: IconPack.material
finalinherited
-
iconPickerShape
→ ShapeBorder?
-
The dialogs shape for the picker
Defaults to AlertDialog shape
finalinherited
-
iconSize
→ double
-
Size for every icon as double
Default:
40.0
finalinherited
-
mainAxisSpacing
→ double
-
How much space to place between children in a run in the main axis.
For example, if
spacing
is 10.0, the children will be spaced at least 10.0 logical pixels apart in the main axis.
Defaults to 5.0
finalinherited
-
noResultsText
→ String
-
The text to show when no results where found for the search term
Default:
No results for:
finalinherited
-
preSelected
→ IconPickerIcon?
-
Pre-selected icon before opening the icon picker
If non-null the icon picker highlights and scrolls to the selected icon
finalinherited
-
runtimeType
→ Type
-
A representation of the runtime type of the object.
no setterinherited
-
searchClearIcon
→ Icon
-
The suffix icon after the search textfield
Defaults to:
finalinherited
-
searchComparator
→ SearchComparator?
-
The searchComparator can be used to define a custom search function
finalinherited
-
searchHintText
→ String
-
The Text to show when Searchbar-Term is empty
Default:
Search
finalinherited
-
searchIcon
→ Icon
-
The prefix icon before the search textfield
Defaults to:
finalinherited
-
selectedIconBackgroundColor
→ Color?
-
The background color for the preSelected
Defaults to
Theme.of(context).brightness == Brightness.dark ? Colors.grey[800] : Colors.grey[400]
finalinherited
-
shouldScrollToSelectedIcon
→ bool
-
Wether the picker should scroll to the selected icon (for bigger lists this could make sense) or not.
finalinherited
-
showSearchBar
→ bool
-
Defines if the searchbar will be
shown above the icons
finalinherited
-
showTooltips
→ bool
-
Shows the labels underneeth the proper icon
WARNING ON FLUTTER WEB: Could slow down the performance unless SKIA is deactivated
Defaults to
false
finalinherited
-
title
→ Widget
-
The title for the Picker.
Sits above the SearchBar and Icons.
Defaults to:
finalinherited
Methods
-
copyWith({IconWidgetBuilder? iconBuilder, IconPickerIcon? preSelected, bool? shouldScrollToSelectedIcon, Color? selectedIconsBackgroundColor, bool? showSearchBar, bool? adaptiveDialog, bool? showTooltips, bool? barrierDismissible, double? iconSize, Color? iconColor, double? mainAxisSpacing, double? crossAxisSpacing, ShapeBorder? iconPickerShape, Color? backgroundColor, BoxConstraints? constraints, Widget? title, Widget? closeChild, Icon? searchIcon, String? searchHintText, Icon? searchClearIcon, SearchComparator? searchComparator, String? noResultsText, List<IconPack>? iconPackModes, Map<String, IconPickerIcon>? customIconPack})
→ SinglePickerConfiguration
-
override
-
noSuchMethod(Invocation invocation)
→ dynamic
-
Invoked when a nonexistent method or property is accessed.
inherited
-
toString()
→ String
-
A string representation of this object.
inherited