ResponsiveScreen class
A class that provides information about the current screen size and type.
Constructors
- ResponsiveScreen(ResponsiveScreenSettings settings)
- Constructs a ResponsiveScreen with the given settings.
Properties
- context ↔ BuildContext
-
The context used for obtaining screen dimensions.
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- height → double
-
Returns the height of the screen.
no setter
- isDesktop → bool
-
Checks if the screen type is desktop.
no setter
- isPhone → bool
-
Checks if the screen type is phone.
no setter
- isTablet → bool
-
Checks if the screen type is tablet.
no setter
- isWatch → bool
-
Checks if the screen type is watch.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- screenType → ScreenType
-
Determines the screen type based on the current screen width.
no setter
- settings → ResponsiveScreenSettings
-
The settings used for determining screen type.
final
- width → double
-
Returns the width of the screen.
no setter
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
responsiveValue<
T> ({T? mobile, T? tablet, T? desktop, T? watch}) → T? - Returns a widget based on the current screen type, with fallback options.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited