RadialMenu<T> class

用于从项目列表中进行选择的径向菜单。

径向菜单允许用户从多个项目中进行选择. 它显示一个打开菜单的按钮,显示按弧形排列的项目。 选择一个项目会触发在中央菜单按钮周围指定 半径 处绘制的进度条的动画。

类型T是径向菜单所代表的值的类型。给定菜单中的所有条目必须表示具有一致类型的值。 通常使用枚举. items中的每一个RadialMenuItem必须用相同的类型参数。

See also:

Inheritance

Constructors

RadialMenu({required List<RadialMenuItem<T>> items, Key? key, ValueChanged<T>? onSelect, double radius = _defaultRadius, Duration? menuAnimationDuration = _kAnimationDuration, Duration? progressAnimationDuration = _kAnimationDuration, double totalAngle = _totalAngle, double startAngle = _startAngle})
const

Properties

hashCode → int
The hash code for this object.
no setterinherited
items → List<RadialMenuItem<T>>
要从中选择的项目的列表。
final
key → Key?
Controls how one widget replaces another widget in the tree.
finalinherited
菜单打开关闭动画的持续时间。
final
onSelect → ValueChanged<T>?
当用户选择一个项目时调用。
final
progressAnimationDuration → Duration?
动作激活进度弧动画的持续时间。
final
radius → double
用于布置项目和绘制进度条的圆弧半径。
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
startAngle → double
用于布置项目和绘制进度条的圆弧开始绘制的角度。
final
totalAngle → double
用于布置项目和绘制进度条的圆弧角度。
final

Methods

createElement() → StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() → RadialMenuState
Creates the mutable state for this widget at a given location in the tree.
override
debugDescribeChildren() → List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) → String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String
Returns a one-line detailed description of the object.
inherited
toStringShort() → String
A short, textual description of this widget.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited