Enum Class BackgroundBlendMode

java.lang.Object
java.lang.Enum<BackgroundBlendMode>
com.oorian.css.BackgroundBlendMode
All Implemented Interfaces:
Serializable, Comparable<BackgroundBlendMode>, Constable

public enum BackgroundBlendMode extends Enum<BackgroundBlendMode>
CSS background-blend-mode property values for blending background layers.

The background-blend-mode property defines how an element's background images and background color blend with each other. These are similar to blend modes found in image editing software.

Usage:


 element.setBackgroundBlendMode(BackgroundBlendMode.MULTIPLY);
 element.setBackgroundBlendMode(BackgroundBlendMode.OVERLAY);
 
Since:
2012
Version:
1.0
Author:
Marvin P. Warble Jr.
See Also:
  • Enum Constant Details

    • NORMAL

      public static final BackgroundBlendMode NORMAL
      Normal blend mode (default).
    • MULTIPLY

      public static final BackgroundBlendMode MULTIPLY
      Multiplies the colors.
    • SCREEN

      public static final BackgroundBlendMode SCREEN
      Lightens by inverting, multiplying, then inverting again.
    • OVERLAY

      public static final BackgroundBlendMode OVERLAY
      Combines multiply and screen.
    • DARKEN

      public static final BackgroundBlendMode DARKEN
      Retains the darkest pixels of both layers.
    • LIGHTEN

      public static final BackgroundBlendMode LIGHTEN
      Retains the lightest pixels of both layers.
    • COLOR_DODGE

      public static final BackgroundBlendMode COLOR_DODGE
      Brightens by dividing bottom layer by inverted top layer.
    • SATURATION

      public static final BackgroundBlendMode SATURATION
      Preserves saturation from the top layer.
    • COLOR

      public static final BackgroundBlendMode COLOR
      Preserves hue and saturation from the top layer.
    • LUMINOSITY

      public static final BackgroundBlendMode LUMINOSITY
      Preserves luminosity from the top layer.
  • Method Details

    • values

      public static BackgroundBlendMode[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static BackgroundBlendMode valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • getValue

      public String getValue()
      Returns the CSS value string.
      Returns:
      the CSS value
    • toString

      public String toString()
      Returns the CSS value string.
      Overrides:
      toString in class Enum<BackgroundBlendMode>
      Returns:
      the CSS value