TDAvatar class
用于头像显示
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatelessWidget
- TDAvatar
Constructors
-
TDAvatar({Key? key, TDAvatarSize size = TDAvatarSize.medium, TDAvatarType type = TDAvatarType.normal, TDAvatarShape shape = TDAvatarShape.circle, String? text, double? radius, IconData? icon, String? avatarUrl, double? avatarSize, List<
String> ? avatarDisplayList, String? displayText, dynamic onTap()?, String defaultUrl = '', Widget? avatarDisplayWidget, double avatarDisplayBorder = 2, List<String> ? avatarDisplayListAsset}) -
const
Properties
- avatarDisplayBorder → double
-
带操作\展示的头像描边宽度
final
-
avatarDisplayList
→ List<
String> ? -
带操作\展示的头像列表
final
-
avatarDisplayListAsset
→ List<
String> ? -
带操作\展示的头像列表 (本地资源)
final
- avatarDisplayWidget → Widget?
-
带操作头像自定义操作Widget
final
- avatarSize → double?
-
自定义头像大小
final
- avatarUrl → String?
-
头像地址
final
- defaultUrl → String
-
默认图片(本地)
final
- displayText → String?
-
纯展示类型末尾文字
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- icon → IconData?
-
自定义图标
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- onTap → dynamic Function()?
-
操作点击事件
final
- radius → double?
-
自定义圆角
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- shape → TDAvatarShape
-
头像形状
final
- size → TDAvatarSize
-
头像尺寸
final
- text → String?
-
自定义文字
final
- type → TDAvatarType
-
头像类型
final
Methods
-
build(
BuildContext context) → Widget -
Describes the part of the user interface represented by this widget.
override
-
buildDisplayAvatar(
BuildContext context) → Widget -
buildOperationAvatar(
BuildContext context) → Widget -
createElement(
) → StatelessElement -
Creates a StatelessElement to manage this widget's location in the tree.
inherited
-
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