Interface TranslucentTheme<T extends TranslucentTheme<T>>

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

public interface TranslucentTheme<T extends TranslucentTheme<T>> extends BaseTheme<T>
A BaseTheme to implement the translucent theme.
  • Method Summary

    Modifier and Type
    Method
    Description
    float
    Returns the opacity after converting it into the float range.
    int
    Get the opacity value used by this theme.
    int
    getOpacity(boolean resolve)
    Get the opacity value used by this theme.
    boolean
    Checks whether this theme is translucent.
    setOpacity(int opacity)
    Set the opacity value used by this theme.

    Methods inherited from interface com.pranavpandey.android.dynamic.theme.base.BaseTheme

    isHost, setHost
  • Method Details

    • getOpacity

      int getOpacity(boolean resolve)
      Get the opacity value used by this theme.
      Parameters:
      resolve - true to resolve auto opacity.
      Returns:
      The opacity value used by this theme.
    • getOpacity

      int getOpacity()
      Get the opacity value used by this theme.
      Returns:
      The opacity value used by this theme.
    • setOpacity

      @NonNull T setOpacity(int opacity)
      Set the opacity value used by this theme.
      Parameters:
      opacity - The opacity value to be set.
      Returns:
      The TranslucentTheme object to allow for chaining of calls to set methods.
    • getAlpha

      float getAlpha()
      Returns the opacity after converting it into the float range.
      Returns:
      The opacity after converting it into the float range.
    • isTranslucent

      boolean isTranslucent()
      Checks whether this theme is translucent.
      Returns:
      true if this theme is translucent.