Image class
DSL node for an Image widget (network images).
Usage
Image(
src: 'https://example.com/photo.jpg',
key: Key('hero_image'),
width: 300,
height: 200,
fit: 'cover',
borderRadius: 12,
)
Supported fit values: fill, contain, cover, fitWidth,
fitHeight, none, scaleDown
Constructors
Properties
- borderRadius → dynamic
-
Border radius: a number (uniform) or a map with
tl/tr/bl/br.final - fit → String?
-
Box fit string:
'cover','contain','fill', etc.final - hashCode → int
-
The hash code for this object.
no setterinherited
- height → double?
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- src → String
-
Network URL of the image.
final
- width → double?
-
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
Serialises this node and all its children into the SDUI JSON format.
override
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited