MaterialBasedCupertinoThemeData class Null safety

A CupertinoThemeData that defers unspecified theme attributes to an upstream Material ThemeData.

This type of CupertinoThemeData is used by the Material Theme to harmonize the CupertinoTheme with the material theme's colors and text styles.

In the most basic case, ThemeData's cupertinoOverrideTheme is null and and descendant Cupertino widgets' styling is derived from the Material theme.

To override individual parts of the Material-derived Cupertino styling, cupertinoOverrideTheme's construction parameters can be used.

To completely decouple the Cupertino styling from Material theme derivation, another CupertinoTheme widget can be inserted as a descendant of the Material Theme. On a MaterialApp, this can be done using the builder parameter on the constructor.

See also:

Inheritance

Constructors

MaterialBasedCupertinoThemeData({required ThemeData materialTheme})
Create a MaterialBasedCupertinoThemeData based on a Material ThemeData and its cupertinoOverrideTheme.

Properties

barBackgroundColor Color
Background color of the top nav bar and bottom tab bar.
read-onlyinherited
brightness Brightness
The brightness override for Cupertino descendants.
read-onlyoverride
hashCode int
The hash code for this object.
read-onlyinherited
primaryColor Color
A color used on interactive elements of the theme.
read-onlyoverride
primaryContrastingColor Color
A color that must be easy to see when rendered on a primaryColor background.
read-onlyoverride
runtimeType Type
A representation of the runtime type of the object.
read-onlyinherited
scaffoldBackgroundColor Color
Background color of the scaffold.
read-onlyoverride
textTheme CupertinoTextThemeData
Text styles used by Cupertino widgets.
read-onlyinherited

Methods

copyWith({Brightness? brightness, Color? primaryColor, Color? primaryContrastingColor, CupertinoTextThemeData? textTheme, Color? barBackgroundColor, Color? scaffoldBackgroundColor}) MaterialBasedCupertinoThemeData
Copies the ThemeData's cupertinoOverrideTheme.
override
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noDefault() NoDefaultCupertinoThemeData
Returns an instance of the theme data whose property getters only return the construction time specifications with no derived values.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
inherited
resolveFrom(BuildContext context) CupertinoThemeData
Returns a new theme data with all its colors resolved against the given BuildContext.
override
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
toStringShort() String
A brief description of this object, usually just the runtimeType and the hashCode.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited