Results for “Color”
Full-text search across Boring Doc explanations, official documentation pages, the Flutter API index and every indexed version change.
Guides
API reference
- Colorsclass
Color and ColorSwatch constants which represent Material design's color palette. material.Colors Colors Colors class material
- ColorSwatchclass
that has a small table of related colors called a "swatch". painting.ColorSwatch ColorSwatch Color Swatch class painting
- ColoredBoxclass
and then draws its child on top of that color. widgets.ColoredBox ColoredBox Colored Box class widgets
- ColorPropertyclass
DiagnosticsProperty that has an Color as value. painting.ColorProperty ColorProperty Color Property class painting
- ColorTweenclass
interpolation between two colors. animation.ColorTween ColorTween Color Tween class animation
- ColorFilteredclass
Applies a ColorFilter to its child. widgets.ColorFiltered ColorFiltered Color Filtered class widgets
- ColorSchemeclass
used to configure the color properties of most components. material.ColorScheme ColorScheme Color Scheme class material
- ColorFilterLayerclass
composite layer that applies a ColorFilter to its children. rendering.ColorFilterLayer ColorFilterLayer Color Filter Layer class rendering
- ColorScheme.lightconstructor
Create a light ColorScheme based on a purple primary color that matches the baseline Material 2 color scheme. material.ColorScheme.ColorScheme.light ColorScheme light Color Scheme.light constructor material
- ColorScheme.newconstructor
Create a ColorScheme instance from the given colors. material.ColorScheme.ColorScheme.new ColorScheme new Color Scheme.new constructor material
- ColorScheme.highContrastLightconstructor
Create a high contrast ColorScheme based on a purple primary color that matches the baseline Material 2 color scheme. material.ColorScheme.ColorScheme.highContrastLight ColorScheme highContrastLight Color Scheme.high Contrast
- ColorSwatch.newconstructor
that has a small table of related colors called a "swatch". painting.ColorSwatch.ColorSwatch.new ColorSwatch new Color Swatch.new constructor painting
- ColorScheme.darkconstructor
color scheme that matches the baseline Material 2 color scheme. material.ColorScheme.ColorScheme.dark ColorScheme dark Color Scheme.dark constructor material
- ColorTween.newconstructor
Creates a Color tween. animation.ColorTween.ColorTween.new ColorTween new Color Tween.new constructor animation
- ColorScheme.highContrastDarkconstructor
Create a high contrast ColorScheme based on the dark baseline Material 2 color scheme. material.ColorScheme.ColorScheme.highContrastDark ColorScheme highContrastDark Color Scheme.high Contrast Dark constructor material
- ColorProperty.newconstructor
Create a diagnostics property for Color. painting.ColorProperty.ColorProperty.new ColorProperty new Color Property.new constructor painting
- ColorFiltered.newconstructor
Creates a widget that applies a ColorFilter to its child. widgets.ColorFiltered.ColorFiltered.new ColorFiltered new Color Filtered.new constructor widgets
- ColorScheme.fromSeedconstructor
Generate a ColorScheme derived from the given seedColor. material.ColorScheme.ColorScheme.fromSeed ColorScheme fromSeed Color Scheme.from Seed constructor material
- ColorScheme.fromSwatchconstructor
Creates a color scheme from a MaterialColor swatch. material.ColorScheme.ColorScheme.fromSwatch ColorScheme fromSwatch Color Scheme.from Swatch constructor material
- ColoredBox.newconstructor
Creates a widget that paints its area with the specified Color. widgets.ColoredBox.ColoredBox.new ColoredBox new Colored Box.new constructor widgets
- ColorFilterLayer.newconstructor
Creates a layer that applies a ColorFilter to its children. rendering.ColorFilterLayer.ColorFilterLayer.new ColorFilterLayer new Color Filter Layer.new constructor rendering
- CupertinoDynamicColorclass
Color subclass that represents a family of colors, and the correct effective color in the color family. cupertino.CupertinoDynamicColor CupertinoDynamicColor Cupertino Dynamic Color class
- MaterialColorclass
Defines a single color as well a color swatch with ten shades of the color. material.MaterialColor MaterialColor Material Color class material
- CupertinoDynamicColor.newconstructor
default effective color is color. cupertino.CupertinoDynamicColor.CupertinoDynamicColor.new CupertinoDynamicColor new Cupertino Dynamic Color.new constructor cupertino
- CupertinoDynamicColor.withBrightnessconstructor
default effective color is color. cupertino.CupertinoDynamicColor.CupertinoDynamicColor.withBrightness CupertinoDynamicColor withBrightness Cupertino Dynamic Color.with Brightness constructor cupertino
- CupertinoDynamicColor.withBrightnessAndContrastconstructor
default effective color is color. cupertino.CupertinoDynamicColor.CupertinoDynamicColor.withBrightnessAndContrast CupertinoDynamicColor withBrightnessAndContrast Cupertino Dynamic Color.with Brightness And Contrast constructor cupertino
- MaterialAccentColorclass
Defines a single accent color as well a swatch of four shades of the accent color. material.MaterialAccentColor MaterialAccentColor Material Accent Color class material
- CupertinoColorsclass
palette of Color constants that describe colors commonly used when matching the iOS platform aesthetics. cupertino.CupertinoColors CupertinoColors Cupertino Colors class cupertino
Version changes
- Introduce new ColorScheme roles3.22.0breaking
color roles in `ColorScheme` include seven tone-based surfaces and containers, and twelve accent colors for primary, secondary, and tertiary groups. This update deprecates three existing
- Color wide gamut support3.27.0breaking
being added to the framework. ### 8-bit unsigned integer constructors Constructors like `Color.fromARGB` remain unchanged and have continued support. To take advantage of Display P3 colors
- Migrating to Material 33.16.0breaking
values for `ThemeData.colorScheme` are updated to match the Material 3 Design spec. The `ColorScheme.fromSeed` constructor generates a `ColorScheme` derived from the given `seedColor`. The colors generated
- ThemeData's accent properties have been deprecated2.5.0deprecated
accentColor: myColor), // ... ); ``` Code after migration: ```dart final ThemeData theme = ThemeData(); MaterialApp( theme: theme.copyWith( colorScheme: theme.colorScheme.copyWith(secondary: myColor), ), //... ) ``` ### `accentColor` The closest backwards compatible [`ColorScheme`][] color is [`ColorScheme.secondary
- Material 3 Tokens Update in Flutter3.27.0breaking
differences in the mappings of the color roles are small. Use `ColorScheme.copyWith` to revert to the original default colors: Code before migration: ```dart final ColorScheme colors
- ListTile reports an error in debug when wrapped in a colored widget3.44.0breaking
widget with a non-transparent background color, such as a `Container` or `ColoredBox` that sets `color`, sits between a `ListTile` and its nearest `Material` ancestor
- Container color optimization1.17.0breaking
ColoredBox` widget has been added to the framework, and the `Container` widget has been optimized to use it if a user specifies a `color` instead
- Deprecate app bar color3.35.0deprecated
constructors and `copyWith` methods. Code before migration: ```dart // AppBarTheme constructor AppBarTheme( color: Colors.blue, elevation: 4.0, ) // AppBarTheme copyWith theme.copyWith( color: Colors.red, elevation: 2.0, ) // AppBarThemeData constructor AppBarThemeData( color
- - Fixes an issue in the `ColorScheme.fromSeed` method to respect the seed color even if the seed color is very bright.3.22.2bugfix
Fixes an issue in the `ColorScheme.fromSeed` method to respect the seed color even if the seed color is very bright
- CupertinoDynamicColor wide gamut support3.38.0breaking
round().clamp(0, 255); } const CupertinoDynamicColor color = CupertinoColors.systemBlue; final intRed = _floatToInt8(color.r); final intGreen = _floatToInt8(color.g); final intBlue = _floatToInt8(color.b); ``` ### Opacity Before
- New Buttons and Button Themes1.20.0breaking
TextButton` look like a default `FlatButton`: ```dart final ButtonStyle flatButtonStyle = TextButton.styleFrom( foregroundColor: Colors.black87, minimumSize: Size(88, 36), padding: EdgeInsets.symmetric(horizontal: 16), shape: const RoundedRectangleBorder( borderRadius: BorderRadius.all(Radius.circular
- Updated default text styles for menus3.16.0breaking
The default text styles used for menus are updated to match the
- Use Color.a instead of Color.alpha to assert the opacity of the color…3.44.0improvement
Color.a instead of Color.alpha to assert the opacity of the color… (Framework, by @ahmedsameha1
- ThemeData's toggleableActiveColor property has been deprecated3.7.0deprecated
Material widgets `Switch`, `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
- Colored box optimization (#176028)3.41.0performance
Colored box optimization (#176028) (Framework, by @definev
- Updated Checkbox.fillColor behavior3.13.0breaking
background in the unselected state. To get the previous behavior, set `Checkbox.fillColor` to `Colors.transparent` in the unselected state and set `Checkbox.side` to the desired color
- TextSelectionTheme migration2.0.0breaking
After | |--------------------------------------|-----------------------------------------------| | `ThemeData.cursorColor` | `TextSelectionThemeData.cursorColor` | | `ThemeData.textSelectionColor` | `TextSelectionThemeData.selectionColor` | | `ThemeData.textSelectionHandleColor` | `TextSelectionThemeData.selectionHandleColor` | **Code before migration:** ```dart ThemeData( cursorColor: Colors.red, textSelectionColor: Colors.green, textSelectionHandleColor: Colors.blue, ) ``` **Code after migration:** ```dart
- Support mixed color spaces in `Color.lerp`3.44.0platform
Support mixed color spaces in `Color.lerp` (Web, by @spydon). Color.lerp
- 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( //... secondary
- Material 3 tokens update3.41.0breaking
have to manually set those properties to their desired color after generating. ColorScheme.fromSeed ColorScheme.fromImageProvider
- Added useOriginalColors flag which allows ImageIcon to bypass IconTheme colorization and use the original colors3.47.0new-feature
Added useOriginalColors flag which allows ImageIcon to bypass IconTheme colorization and use the original colors (Framework, by @zawhtetnaing10). ImageIcon IconTheme
- - Fixes AnimatedOpacity affecting blended color overlay render3.16.5bugfix
Fixes AnimatedOpacity affecting blended color overlay render
- Add saturation ColorFilter.3.41.0new-feature
saturation ColorFilter. (Framework, by @ksokolovskyi). ColorFilter
- - [Impeller] Fixes visual glitches and crashes when using wide gamut color support on iOS.3.10.1bugfix
Impeller] Fixes visual glitches and crashes when using wide gamut color support
- - [Impeller] Fixes an issue causing noise when using combinations of UV mapping and color blending.3.10.3bugfix
Impeller] Fixes an issue causing noise when using combinations of UV mapping and color blending
- Deprecated API removed after v3.103.13.0removed
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 ThemeData.brightness Theme RawScrollbar Scrollbar ScrollbarThemeData CupertinoScrollbar Scrollbar.hoverThickness MaterialStateProperty ScrollbarThemeData.thickness
- Make sure that a ColorFiltered doesn't crash 0x0 environment3.41.0bugfix
Make sure that a ColorFiltered doesn't crash 0x0 environment (Framework, by @ahmedsameha1). ColorFiltered
- Raw images on Web uses correct origin and colors2.10.0breaking
ui.ImageDescriptor.raw` or `ui.decodeImageFromPixels`, causing the resulting images to be upside-down and incorrectly colored (whose red and blue channels are swapped.) The `pixels` argument of `ui.ImageDescriptor.raw
- Manually roll material_color_utilities3.41.0improvement
Manually roll material_color_utilities (Material, by @kevmoo
- Deprecate ThemeData.dialogBackgroundColor in favor of DialogThemeData.backgroundColor3.29.0deprecated
default dialog background color. Code before migration: ```dart theme: ThemeData( dialogBackgroundColor: Colors.orange, ), ``` Code after migration: ```dart theme: ThemeData( dialogTheme: const DialogThemeData(backgroundColor: Colors.orange), ), ``` ThemeData.dialogBackgroundColor DialogThemeData.backgroundColor Dialog AlertDialog
- fix: ColorScheme will removeListener on imageStream twice if there is error loading the image.3.38.0bugfix
ColorScheme will removeListener on imageStream twice if there is error loading the image. (Material, by @dkwingsmt). ColorScheme