Interface SurfaceTheme<T extends SurfaceTheme<T>>

Type Parameters:
T - The type of the dynamic theme.
All Superinterfaces:
BaseTheme<T>, ElevationTheme<T>
All Known Subinterfaces:
DynamicColor<T>
All Known Implementing Classes:
AppTheme, AppWidgetTheme

public interface SurfaceTheme<T extends SurfaceTheme<T>> extends ElevationTheme<T>
An ElevationTheme to implement the surface theme.
  • Method Details

    • getSurfaceColor

      @ColorInt int getSurfaceColor(boolean resolve, boolean inverse)
      Returns the surface color used by this theme.
      Parameters:
      resolve - true to resolve the auto color.
      inverse - true to resolve the inverse color.
      Returns:
      The surface color used by this theme.
    • getSurfaceColor

      @ColorInt int getSurfaceColor(boolean resolve)
      Returns the surface color used by this theme.
      Parameters:
      resolve - true to resolve the auto color.
      Returns:
      The surface color used by this theme.
    • getSurfaceColor

      @ColorInt int getSurfaceColor()
      Returns the surface color used by this theme.
      Returns:
      The surface color used by this theme.
    • setSurfaceColor

      @NonNull T setSurfaceColor(@ColorInt int surfaceColor, boolean generateTint)
      Set the surface color used by this theme.
      Parameters:
      surfaceColor - The surface color to be set.
      generateTint - true to automatically generate the tint color also.
      Returns:
      The SurfaceTheme object to allow for chaining of calls to set methods.
      See Also:
    • setSurfaceColor

      @NonNull T setSurfaceColor(@ColorInt int surfaceColor)
      Set the surface color used by this theme.

      It will automatically generate the tint color also.

      Parameters:
      surfaceColor - The surface color to be set.
      Returns:
      The SurfaceTheme object to allow for chaining of calls to set methods.
      See Also:
    • getTintSurfaceColor

      @ColorInt int getTintSurfaceColor(boolean resolve, boolean inverse)
      Returns the surface tint color used by this theme.
      Parameters:
      resolve - true to resolve the auto color.
      inverse - true to resolve the inverse color.
      Returns:
      The surface tint color used by this theme.
    • getTintSurfaceColor

      @ColorInt int getTintSurfaceColor(boolean resolve)
      Returns the surface tint color used by this theme.
      Parameters:
      resolve - true to resolve the auto color.
      Returns:
      The surface tint color used by this theme.
    • getTintSurfaceColor

      @ColorInt int getTintSurfaceColor()
      Returns the surface tint color used by this theme.
      Returns:
      The surface tint color used by this theme.
    • setTintSurfaceColor

      @NonNull T setTintSurfaceColor(@ColorInt int tintSurfaceColor)
      Set the surface tint color used by this theme.
      Parameters:
      tintSurfaceColor - The surface tint color to be set.
      Returns:
      The SurfaceTheme object to allow for chaining of calls to set methods.
    • isBackgroundSurface

      boolean isBackgroundSurface()
      Checks whether the background should be used as the surface.
      Returns:
      true if the background should be used as surface.