App class
App static functions and constants used in the example applications.
In a real app you probably prefer putting these into different static classes that serves your application's usage. For these examples I put them all in the same class, except the colors that are in their own class.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- font → String?
-
no setter
- notoSansBold → TextStyle
-
final
- notoSansMedium → TextStyle
-
final
- notoSansRegular → TextStyle
-
final
- packageUri → Uri
-
final
- textTheme → TextTheme?
-
no setter
- visualDensity → VisualDensity
-
Defining the visual density here to so we can change it in one spot when
we want to try different options.
no setter
Static Methods
-
effectiveDialogRadius(
ThemeController controller) → double? - Return the correct platform effective dialog border radius setting.
-
effectiveRadius(
ThemeController controller) → double? - Return the correct platform effective global border radius setting.
-
responsiveInsets(
double width, [bool isCompact = false]) → double - Responsive insets based on width.
-
title(
BuildContext context) → String? - Returns the title of the MaterialApp.
Constants
- bigDesktopWidthBreakpoint → const double
- This breakpoint is only used to further increase margins and insets on very large desktops.
- colorButtonPhoneReduce → const double
- The width and height reduction of input color selection box in phone size.
- copyright → const String
- desktopWidthBreakpoint → const double
- The minimum media size needed for desktop/large tablet menu view, this is media size.
- edgeInsetsBigDesktop → const double
- Edge insets and margins for big desktop breakpoint size.
- edgeInsetsDesktop → const double
- Edge insets and margins for desktop and medium desktop breakpoint sizes.
- edgeInsetsPhone → const double
- Edge insets and margins for phone breakpoint size.
- edgeInsetsTablet → const double
- Edge insets and margins for tablet breakpoint size.
- flutterVersion → const String
- icon → const String
- license → const String
- maxBodyWidth → const double
- The max dp width used for layout content on the screen in the available body area.
- mediumDesktopWidthBreakpoint → const double
-
A medium sized desktop, in panel view we switch to vertical
topic selector page
ThemeTwoTopicsPage
, with topic selector on left and right side, one for each theme topic panel. - packageName → const String
- packageVersion → const String
- packageVersionMinor → const String
- panelButtonHeight → const double
- panelButtonPhoneHeightReduce → const double
- panelButtonPhoneWidthReduce → const double
- panelButtonWidth → const double
- The width, and height of the scrolling panel buttons in Themes Playground page view, and how much it shrinks when we go to phone size.
- phoneHeightBreakpoint → const double
- The minimum media height treated as a phone device in this app.
- phoneWidthBreakpoint → const double
- The minimum media width treated as a phone device in this app.
- pinnedSelector → const double
- The height when we want to pin the panel or color selector, instead of letting it float and snap back.
- sideBySideViewBreakpoint → const double
-
Breakpoint needed to show second panel in side-by-side view for the
ThemeTopicPage
page view. - version → const String
- versionBuild → const String
- versionMajor → const String
- versionMinor → const String
- versionPatch → const String