SurfaceColorEnum enum

This enum represents the new surface colors introduced in Material Design 3.0.

The different colors represent different tones and can be used to convey hierarchy, depth, and focus. They can be used as background colors for surfaces such as cards, dialog boxes, or containers.

To select a surface color for a widget, use the SurfaceColorEnum values with the PaneContainerWidget. The corresponding color is selected using the NewSurfaceTheme.getSurfaceColor method and the current theme.

For more information about the new surface colors, see the Material Design 3.0 blog post: https://material.io/blog/tone-based-surface-color-m3

Inheritance

Constructors

SurfaceColorEnum()
const

Values

surface → const SurfaceColorEnum

The lowest tone color that can be used as a background for a surface.

surfaceContainerLowest → const SurfaceColorEnum

A slightly higher tone color that can be used for low-emphasis surfaces.

surfaceContainerLow → const SurfaceColorEnum

A higher tone color that can be used for medium-emphasis surfaces.

surfaceContainer → const SurfaceColorEnum

A higher tone color that can be used for high-emphasis surfaces.

surfaceContainerHigh → const SurfaceColorEnum

A higher tone color that can be used for elevated surfaces, such as dialogs.

surfaceContainerHighest → const SurfaceColorEnum

The highest tone color that can be used as a background for a surface.

Properties

hashCode int
The hash code for this object.
no setterinherited
index int
A numeric identifier for the enumerated value.
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

Constants

values → const List<SurfaceColorEnum>
A constant List of the values in this enum, in order of their declaration.