Class BackgroundStyle.Builder

java.lang.Object
com.luciad.drawing.BackgroundStyle.Builder
All Implemented Interfaces:
AutoCloseable
Enclosing class:
BackgroundStyle

public static final class BackgroundStyle.Builder extends Object implements AutoCloseable
A builder class for creating background styles.
  • Constructor Details Link icon

  • Method Details Link icon

    • finalize Link icon

      protected void finalize()
      Overrides:
      finalize in class Object
    • close Link icon

      public void close()
      Specified by:
      close in interface AutoCloseable
    • build Link icon

      @NotNull public BackgroundStyle build()
      Returns a newly created background style, based on the properties set on this builder.
      Returns:
      a newly created background style.
    • padding Link icon

      @NotNull public BackgroundStyle.Builder padding(double padding)
      Sets the padding that is added around the content to determine the size of the background.

      This property is optional. By default, the padding is 2.

      Parameters:
      padding - the padding in device independent pixels.
      Returns:
      this builder
    • backgroundColor Link icon

      @NotNull public BackgroundStyle.Builder backgroundColor(@NotNull android.graphics.Color color)
      Sets the background color.

      This property is optional. The default is a semi-transparent white color.

      Parameters:
      color - the background color.
      Returns:
      this builder.
    • frameWidth Link icon

      @NotNull public BackgroundStyle.Builder frameWidth(double width)
      Sets the width of the frame that is painted.

      If 0, no frame is painted.

      This property is optional. By default, the frame width is 1.

      Parameters:
      width - the width of the frame in device independent pixels.
      Returns:
      this builder
    • frameColor Link icon

      @NotNull public BackgroundStyle.Builder frameColor(@NotNull android.graphics.Color color)
      Sets the color of the frame that is painted.

      This property is optional. By default, the frame color is black.

      Parameters:
      color - the frame color.
      Returns:
      this builder.