Results for “ThemeData”
Full-text search across Boring Doc explanations, official documentation pages, the Flutter API index and every indexed version change.
API reference
- ThemeDataclass
visual Theme for a MaterialApp or a widget subtree within the app. material.ThemeData ThemeData Theme Data class material
- ThemeDataTweenclass
interpolation between two ThemeDatas. material.ThemeDataTween ThemeDataTween Theme Data Tween class material
- ThemeData.fallbackconstructor
default color theme. Same as ThemeData.light. material.ThemeData.ThemeData.fallback ThemeData fallback Theme Data.fallback constructor material
- ThemeDataTween.newconstructor
Creates a ThemeData tween. material.ThemeDataTween.ThemeDataTween.new ThemeDataTween new Theme Data Tween.new constructor material
- ThemeData.newconstructor
Create a ThemeData that's used to configure a Theme. material.ThemeData.ThemeData.new ThemeData new Theme Data.new constructor material
- ThemeData.fromconstructor
Create a ThemeData based on the colors in the given colorScheme and text styles of the optional textTheme. material.ThemeData.ThemeData.from ThemeData from Theme Data.from constructor material
- ThemeData.rawconstructor
Create a ThemeData given a set of exact values. Most values must be specified. They all must also be non-null except for cupertinoOverrideTheme, and deprecated members
- ThemeData.lightconstructor
default light theme. material.ThemeData.ThemeData.light ThemeData light Theme Data.light constructor material
- ThemeData.darkconstructor
default dark theme. material.ThemeData.ThemeData.dark ThemeData dark Theme Data.dark constructor material
- ThemeExtensionclass
interface that defines custom additions to a ThemeData object. material.ThemeExtension ThemeExtension Theme Extension class material
- InteractiveInkFeatureFactoryclass
encapsulation of an InteractiveInkFeature constructor used by InkWell, InkResponse, and ThemeData. material.InteractiveInkFeatureFactory InteractiveInkFeatureFactory Interactive Ink Feature Factory class material
- MaterialBasedCupertinoThemeDataclass
CupertinoThemeData that defers unspecified theme attributes to an upstream Material ThemeData. material.MaterialBasedCupertinoThemeData MaterialBasedCupertinoThemeData Material Based Cupertino Theme Data class material
- TextButtonThemeDataclass
TextButtons when it's used with TextButtonTheme or with the overall Theme's ThemeData.textButtonTheme. material.TextButtonThemeData TextButtonThemeData Text Button Theme Data class material
- FilledButtonThemeDataclass
FilledButtons when it's used with FilledButtonTheme or with the overall Theme's ThemeData.filledButtonTheme. material.FilledButtonThemeData FilledButtonThemeData Filled Button Theme Data class material
- ElevatedButtonThemeDataclass
ElevatedButtons when it's used with ElevatedButtonTheme or with the overall Theme's ThemeData.elevatedButtonTheme. material.ElevatedButtonThemeData ElevatedButtonThemeData Elevated Button Theme Data class material
- OutlinedButtonThemeDataclass
OutlinedButtons when it's used with OutlinedButtonTheme or with the overall Theme's ThemeData.outlinedButtonTheme. material.OutlinedButtonThemeData OutlinedButtonThemeData Outlined Button Theme Data class material
- IconButtonThemeDataclass
used with the IconButton, the IconButtonTheme or the overall Theme's ThemeData.iconButtonTheme. material.IconButtonThemeData IconButtonThemeData Icon Button Theme Data class material
- ActionIconThemeDataclass
BackButton, CloseButton, DrawerButton, and EndDrawerButton with ActionIconTheme.of or the overall Theme's ThemeData.actionIconTheme. material.ActionIconThemeData ActionIconThemeData Action Icon Theme Data class material
- CardTheme.newconstructor
Creates a theme that can be used for ThemeData.cardTheme. material.CardTheme.CardTheme.new CardTheme new Card Theme.new constructor material
- RadioThemeData.newconstructor
Creates a theme that can be used for ThemeData.radioTheme. material.RadioThemeData.RadioThemeData.new RadioThemeData new Radio Theme Data.new constructor material
- CardThemeData.newconstructor
Creates a theme that can be used for ThemeData.cardTheme. material.CardThemeData.CardThemeData.new CardThemeData new Card Theme Data.new constructor material
- SwitchThemeData.newconstructor
Creates a theme that can be used for ThemeData.switchTheme. material.SwitchThemeData.SwitchThemeData.new SwitchThemeData new Switch Theme Data.new constructor material
- CheckboxThemeData.newconstructor
Creates a theme that can be used for ThemeData.checkboxTheme. material.CheckboxThemeData.CheckboxThemeData.new CheckboxThemeData new Checkbox Theme Data.new constructor material
- AppBarTheme.newconstructor
Creates a theme that can be used for ThemeData.appBarTheme. material.AppBarTheme.AppBarTheme.new AppBarTheme new App Bar Theme.new constructor material
- ScrollbarThemeData.newconstructor
Creates a theme that can be used for ThemeData.scrollbarTheme. material.ScrollbarThemeData.ScrollbarThemeData.new ScrollbarThemeData new Scrollbar Theme Data.new constructor material
- DialogTheme.newconstructor
Creates a dialog theme that can be used for ThemeData.dialogTheme. material.DialogTheme.DialogTheme.new DialogTheme new Dialog Theme.new constructor material
- CarouselViewThemeData.newconstructor
Creates a theme that can be used for ThemeData.carouselViewTheme. material.CarouselViewThemeData.CarouselViewThemeData.new CarouselViewThemeData new Carousel View Theme Data.new constructor material
- BottomAppBarTheme.newconstructor
Creates a theme that can be used for ThemeData.bottomAppBarTheme. material.BottomAppBarTheme.BottomAppBarTheme.new BottomAppBarTheme new Bottom App Bar Theme.new constructor material
- BottomSheetThemeData.newconstructor
Creates a theme that can be used for ThemeData.bottomSheetTheme. material.BottomSheetThemeData.BottomSheetThemeData.new BottomSheetThemeData new Bottom Sheet Theme Data.new constructor material
- DataTableThemeData.newconstructor
Creates a theme that can be used for ThemeData.dataTableTheme. material.DataTableThemeData.DataTableThemeData.new DataTableThemeData new Data Table Theme Data.new constructor material
- DialogThemeData.newconstructor
Creates a dialog theme that can be used for ThemeData.dialogTheme. material.DialogThemeData.DialogThemeData.new DialogThemeData new Dialog Theme Data.new constructor material
- DividerThemeData.newconstructor
Creates a theme that can be used for DividerTheme or ThemeData.dividerTheme. material.DividerThemeData.DividerThemeData.new DividerThemeData new Divider Theme Data.new constructor material
- DrawerThemeData.newconstructor
Creates a theme that can be used for ThemeData.drawerTheme and DrawerTheme. material.DrawerThemeData.DrawerThemeData.new DrawerThemeData new Drawer Theme Data.new constructor material
- NavigationRailThemeData.newconstructor
Creates a theme that can be used for ThemeData.navigationRailTheme. material.NavigationRailThemeData.NavigationRailThemeData.new NavigationRailThemeData new Navigation Rail Theme Data.new constructor material
- SearchBarThemeData.newconstructor
Creates a theme that can be used for ThemeData.searchBarTheme. material.SearchBarThemeData.SearchBarThemeData.new SearchBarThemeData new Search Bar Theme Data.new constructor material
- SearchViewThemeData.newconstructor
Creates a theme that can be used for ThemeData.searchViewTheme. material.SearchViewThemeData.SearchViewThemeData.new SearchViewThemeData new Search View Theme Data.new constructor material
- SnackBarThemeData.newconstructor
Creates a theme that can be used for ThemeData.snackBarTheme. material.SnackBarThemeData.SnackBarThemeData.new SnackBarThemeData new Snack Bar Theme Data.new constructor material
- NavigationDrawerThemeData.newconstructor
Creates a theme that can be used for ThemeData.navigationDrawerTheme and NavigationDrawerTheme. material.NavigationDrawerThemeData.NavigationDrawerThemeData.new NavigationDrawerThemeData new Navigation Drawer Theme Data.new constructor material
- BottomNavigationBarThemeData.newconstructor
Creates a theme that can be used for ThemeData.bottomNavigationBarTheme. material.BottomNavigationBarThemeData.BottomNavigationBarThemeData.new BottomNavigationBarThemeData new Bottom Navigation Bar Theme Data.new constructor material
- TimePickerThemeData.newconstructor
Creates a theme that can be used for TimePickerTheme or ThemeData.timePickerTheme. material.TimePickerThemeData.TimePickerThemeData.new TimePickerThemeData new Time Picker Theme Data.new constructor material
- TabBarTheme.newconstructor
Creates a tab bar theme that can be used with ThemeData.tabBarTheme. material.TabBarTheme.TabBarTheme.new TabBarTheme new Tab Bar Theme.new constructor material
- MaterialBannerThemeData.newconstructor
Creates a theme that can be used for MaterialBannerTheme or ThemeData.bannerTheme. material.MaterialBannerThemeData.MaterialBannerThemeData.new MaterialBannerThemeData new Material Banner Theme Data.new constructor material
Version changes
- ThemeData's accent properties have been deprecated2.5.0deprecated
ThemeData accentColor, accentColorBrightness, accentIconTheme and accentTextTheme properties have been deprecated. The ThemeData accentColor, accentColorBrightness, accentIconTheme and accentTextTheme properties have been deprecated because the Material library
- ThemeData's toggleableActiveColor property has been deprecated3.7.0deprecated
SwitchListTile`, `Checkbox`, `CheckboxListTile`, `Radio`, `RadioListTile` now use `ColorScheme.secondary` color for their toggleable widget. `ThemeData.toggleableActiveColor` is deprecated and will eventually be removed. The widgets using `ThemeData.toggleableActiveColor` color
- TextSelectionTheme migration2.0.0breaking
`, you need to update them to use the new equivalent properties on `ThemeData.textSelectionTheme`: | Before | After | |--------------------------------------|-----------------------------------------------| | `ThemeData.cursorColor` | `TextSelectionThemeData.cursorColor` | | `ThemeData.textSelectionColor` | `TextSelectionThemeData.selectionColor` | | `ThemeData.textSelectionHandleColor` | `TextSelectionThemeData.selectionHandleColor` | **Code before migration:** ```dart ThemeData
- Deprecate ThemeData.indicatorColor in favor of TabBarThemeData.indicatorColor3.32.0deprecated
ThemeData.indicatorColor` parameter was deprecated in favor of the `TabBarThemeData.indicatorColor` parameter. The `ThemeData.indicatorColor` is deprecated in favor of a component-specific theme. Use `TabBarThemeData` to override the default indicator
- The ThemeData.useMaterial3 property is now set to true by default3.16.0breaking
components, new component themes, and updated component visuals. As of this release, `ThemeData.useMaterial3` is set `true` by default. Prior to the 3.16 release, the changes were
- Deprecate ThemeData.dialogBackgroundColor in favor of DialogThemeData.backgroundColor3.29.0deprecated
ThemeData.dialogBackgroundColor` parameter was deprecated in favor of the `DialogThemeData.backgroundColor` parameter. The `ThemeData.dialogBackgroundColor` is deprecated in favor of a component-specific theme. Use `DialogThemeData` to override the default background
- Material Theme System Updates3.32.0breaking
overrides for the defaults of the component visual properties. Previously, the type of `ThemeData.cardTheme` was `Object?` to accept both `CardTheme` and `CardThemeData`. Now that the type has been
- FloatingActionButton and ThemeData's accent properties1.17.0breaking
( floatingActionButtonTheme: FloatingActionButtonThemeData( foregroundColor: Colors.red, ), ), ) ``` FloatingActionButton ThemeData Theme ColorScheme FloatingActionButtons FloatingActionButtonTheme RawMaterialButton ThemeData.accentTextTheme FloatingActionButtonThemeData
- Component theme normalization updates3.35.0breaking
like these for a more consistent theming experience in the material library. In `ThemeData`: - The type of the `appBarTheme` property has been changed from `AppBarTheme` to `AppBarThemeData
- Migrating to Material 33.16.0breaking
removed as part of Flutter's deprecation policy. ### Colors The default values for `ThemeData.colorScheme` are updated to match the Material 3 Design spec. The `ColorScheme.fromSeed` constructor generates
- Deprecate ButtonBar in favor of OverflowBar3.24.0deprecated
deprecated in favor of the more efficient `OverflowBar` widget. As a result, `ThemeData.buttonBarTheme` and `ButtonBarTheme` were also deprecated. - Replace `ButtonBar` widget with `OverflowBar` widget. - By default, `ButtonBar` aligns
- Deprecated API removed after v3.103.13.0removed
that reached end of life after the 3.10 stable release have been removed. ThemeData.fixTextFieldOutlineLabel ThemeData OverscrollIndicatorNotification.disallowGlow StretchingOverscrollIndicator GlowingOverscrollIndicator OverscrollIndicatorNotification ColorScheme.primaryVariant ColorScheme.secondaryVariant ColorScheme.primaryContainer ColorScheme.secondaryContainer ColorScheme ThemeData.primaryColorBrightness Brightness ThemeData.primaryColor
- Deprecated API removed after v3.73.10.0removed
stable release have been removed. Code before migration: ```dart var myTheme = ThemeData( //... accentColor: Colors.blue, //... ); var color = myTheme.accentColor; ``` Code after migration: ```dart var myTheme = ThemeData( //... colorScheme: ColorScheme
- Page transitions replaced by ZoomPageTransitionsBuilder3.0.0breaking
define builders explicitly for the target platforms. Code before migration: ```dart MaterialApp( theme: ThemeData(colorScheme: ColorScheme.fromSeed(seedColor: Colors.deepPurple)), ) ``` Code after migration: ```dart MaterialApp( theme: ThemeData( pageTransitionsTheme
- Material 3 Tokens Update in Flutter3.27.0breaking
revert to the original default colors: Code before migration: ```dart final ColorScheme colors = ThemeData().colorScheme; ``` Code after migration: ```dart final ColorScheme colors = ThemeData().colorScheme.copyWith( onPrimaryContainer: const
- Deprecated API removed after v3.133.16.0removed
PlatformsViewsService PlatformViewsService TextSelectionOverlay SelectionOverlay.fadeDuration TextSelectionOverlay.fadeDuration SelectionOverlay RenderEditable ScrollBehavior MaterialScrollBehavior ThemeData GlowingOverscrollIndicator StretchingOvercrollIndicator ThemeData.useMaterial3 StretchingOverscrollIndicator PaintingBinding ImageProvider DecoderCallback PaintingBinding.instantiateImageCodec PaintingBinding.instantiateImageCodecFromBuffer ImageProvider.load ImageProvider.loadBuffer DecoderBufferCallback TestWindow WidgetTester TestWidgetsFlutterBinding TestPlatformDispatcher
- Deprecated API removed after v3.193.22.0removed
after the 3.19 stable release have been removed. TextTheme TextStyle ThemeData Color ThemeData.colorScheme BottomAppBarTheme ColorScheme CupertinoContextMenu.previewBuilder CupertinoContextMenu CupertinoContextMenu.animationOpensAt Scrollbar.showTrackOnHover Scrollbar ScrollbarThemeData.showTrackOnHover ScrollbarThemeData.trackVisibility ScrollbarThemeData MaterialState MaterialStateProperty KeepAliveHandle.release KeepAliveHandle
- Deprecate app bar color3.35.0deprecated
color: Colors.red, elevation: 2.0, ) // AppBarThemeData constructor AppBarThemeData( color: Colors.green, elevation: 4.0, ) // AppBarThemeData copyWith themeData.copyWith( color: Colors.purple, elevation: 2.0, ) ``` Code after migration: ```dart // AppBarTheme constructor AppBarTheme( backgroundColor: Colors.blue, elevation