com.groupdocs.viewer.domain

Class Watermark



  • public class Watermark
    extends Object

    Represents a container for the page watermark properties.

    • Constructor Detail

      • Watermark

        public Watermark(String text)

        Initializes a new instance of the Watermark class.

        Parameters:
        text - The text.
      • Watermark

        public Watermark(String text,
                 Color color,
                 int position,
                 float width)

        Initializes a new instance of the Watermark class.

        Parameters:
        text - The text.
        color - The color.
        position - The position.
        width - The width.
    • Method Detail

      • getColor

        public Color getColor()

        The watermark text color.

        Returns:
        the color
      • getFontName

        public String getFontName()

        The watermark text font name e.g. "MS Gothic" or "Verdana". In case you want to specify custom font please add path to the font directories list in ViewerConfig class.

        Returns:
        a String object.
      • getPosition

        public int getPosition()

        The watermark text color.

        Returns:
        the position
      • getText

        public String getText()

        The watermark text.

        Returns:
        the text
      • getWidth

        public float getWidth()

        The watermark width.

        Returns:
        the width
      • setColor

        public void setColor(Color value)
        Sets color.
        Parameters:
        value - the value
      • setFontName

        public void setFontName(String value)

        The watermark text font name e.g. "MS Gothic" or "Verdana". In case you want to specify custom font please add path to the font directories list in ViewerConfig class.

        Parameters:
        value - a String object.
      • setPosition

        public void setPosition(int value)

        The watermark position.

        Parameters:
        value - the value
      • setText

        public void setText(String value)

        The watermark text.

        Parameters:
        value - the value
      • setWidth

        public void setWidth(float value)

        The watermark width.

        Parameters:
        value - the value