CNToolbarBadge class
A badge on a CNToolbarButton: a count, a short text, or a dot.
NSItemBadge on macOS 26+, UIBarButtonItem.Badge on iOS 27+ (iOS 26
draws bar button badges in navigation bars only). Older systems have no
toolbar badges, so there the badge is not shown; the Flutter toolbar of
iOS below 26 draws one.
- Annotations
Constructors
- CNToolbarBadge.count(int count)
-
A badge showing
count.const - CNToolbarBadge.indicator()
-
A small dot without content.
const
- CNToolbarBadge.text(String text)
-
A badge showing a short
text, such as "New".const
Properties
- count → int?
-
The number shown, for CNToolbarBadge.count.
final
- hashCode → int
-
The hash code for this object.
no setteroverride
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- text → String?
-
The text shown, for CNToolbarBadge.text.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override