ContextExtensions extension
Extensions for general basic Context
- on
Properties
- accentColor → Color
-
The foreground color for widgets (knobs, text, overscroll edge effect, etc). [...]
read-only
- backgroundColor → Color
-
A color that contrasts with the primaryColor.
read-only
- brightness → Brightness
-
The default brightness of the Theme.
read-only
- canvasColor → Color
-
The default color of MaterialType.canvas Material.
read-only
- captionStyle → TextStyle
-
Extension for getting textTheme
read-only
- cardColor → Color
-
The default color of MaterialType.card Material.
read-only
- form → FormState
-
Returns The state from the closest instance of this class that encloses the given context.
It is used for validating forms
read-only
- isLandscape → bool
-
Returns if Orientation is landscape
read-only
- isMobile → bool
-
Check if the window size is of Mobile Type as per Material Design Guidlines.
read-only
- isMobileTypeHandset → bool
-
Returns if it's a handset as per Material Design Guidlines.
read-only
- isMobileTypeTablet → bool
-
Returns if it's a tablet as per Material Design Guidlines.
read-only
- locale → Locale
-
Returns The current Locale of the app as specified in the Localizations widget.
read-only
- mdColumns → int
-
Screen Sizes Extensions for responsive UI
Returns Material no. of Columns as per Material Design Guidlines.
read-only
- mdDeviceSize → MobileDeviceSize
-
Returns device size as per Material Design Guidlines.
read-only
- mdDeviceType → MobileDeviceType
-
Returns device Type as per Material Design Guidlines.
read-only
- mdGutter → double
-
Returns Material no. of Gutters as per Material Design Guidlines.
read-only
- mdWindowSize → MobileWindowSize
-
Returns the current window size as per Material Design Guidlines.
read-only
- mq → MediaQueryData
-
To get a MediaQuery directly.
read-only
-
Extension for getting NavigatorState. Use navigator now.
@Deprecated('Use [navigator] instead. It will be removed soon.'), read-only
-
Extension for navigation to next page
Returns The state from the closest instance of this class that encloses the given context. [...]
read-only
- orientation → Orientation
-
Returns Orientation using MediaQuery
read-only
- overlay → OverlayState
-
Returns The state from the closest instance of this class that encloses the given context. [...]
read-only
- percentHeight → double
-
Get MediaQuery Screen height in percentage
read-only
- percentWidth → double
-
Get MediaQuery Screen Width in percentage
read-only
- primaryColor → Color
-
The background color for major parts of the app (toolbars, tab bars, etc).
read-only
- safePercentHeight → double
-
Get MediaQuery Screen Height in percentage including safe area calculation.
read-only
- safePercentWidth → double
-
Get MediaQuery Screen Width in percentage including safe area calculation.
read-only
- scaffold → ScaffoldState
-
Returns the closest instance of ScaffoldState in the widget tree,
which can be use to get information about that scaffold. [...]
read-only
- screenHeight → double
-
Get MediaQuery Screen Height
read-only
- screenPadding → EdgeInsets
-
Get MediaQuery Screen Padding
read-only
- screenSize → Size
-
Get MediaQuery Screen Size
read-only
- screenWidth → double
-
Get MediaQuery Screen Width
read-only
- selectionColor → Color
-
The default color of textSelectionColor.
read-only
- textTheme → TextTheme
-
Extension for getting textTheme
read-only
- theme → ThemeData
-
Extension for getting Theme
read-only
Methods
-
addOverlay(
WidgetBuilder builder) → OverlayEntry - Insert the given widget into the overlay. The newly inserted widget will always be at the top.
-
invokeAction(
Intent intent, {bool nullOk}) → bool - Action Extension
-
nextAndRemoveUntilPage(
Widget page) → void - Removing all the widgets till defined rule, and pushes the built widget to the screen using the material fade in animation
-
nextPage(
Widget page, {bool maintainState = true}) → void - Pushes the built widget to the screen using the material fade in animation
-
nextReplacementPage(
Widget page, {bool maintainState = true}) → void - Pushes and replacing the built widget to the screen using the material fade in animation
-
pop<
T> ([T result]) → void - Removes the top most Widget in the navigator's stack [...]
-
push<
T> (WidgetBuilder builder) → Future< T> - Pushes the built widget to the screen using the material fade in animation [...]
-
showSnackBar(
SnackBar snackbar) → void - Shows a SnackBar at the bottom of the scaffold. [...]