PresentationWatermarkSlideOptions

Inheritance: java.lang.Object, com.groupdocs.watermark.options.WatermarkOptions, com.groupdocs.watermark.options.PresentationWatermarkOptions, com.groupdocs.watermark.options.PresentationWatermarkBaseSlideOptions

public final class PresentationWatermarkSlideOptions extends PresentationWatermarkBaseSlideOptions

Represents options when adding watermark to a Presentation document slide.

Learn more:

The following example demonstrates how to add a watermark to a particular slide of a Power Point presentation.

PresentationLoadOptions loadOptions = new PresentationLoadOptions(); Watermarker watermarker = new Watermarker(“C:\Documents\test.ppt”, loadOptions);

TextWatermark watermark = new TextWatermark(“Test watermark”, new Font(“Arial”, 36, FontStyle.Bold | FontStyle.Italic)); watermark.setHorizontalAlignment(HorizontalAlignment.Center); watermark.setVerticalAlignment(VerticalAlignment.Center);

PresentationWatermarkSlideOptions options = new PresentationWatermarkSlideOptions(); options.setSlideIndex(0); options.setLocked(false); // default options.setProtectWithUnreadableCharacters(false); // default options.setName(null); // default options.setAlternativeText(null); // default

watermarker.save(“C:\Documents\watermarked_test.ppt”); watermarker.close();

Constructors

Constructor Description
PresentationWatermarkSlideOptions() Initializes a new instance of the [PresentationWatermarkSlideOptions](../../com.groupdocs.watermark.options/presentationwatermarkslideoptions) class.

Methods

Method Description
getSlideIndex() Gets the index of slide to add the watermark to.
setSlideIndex(int value) Sets the index of slide to add the watermark to.

PresentationWatermarkSlideOptions()

public PresentationWatermarkSlideOptions()

Initializes a new instance of the [PresentationWatermarkSlideOptions](../../com.groupdocs.watermark.options/presentationwatermarkslideoptions) class.

getSlideIndex()

public final int getSlideIndex()

Gets the index of slide to add the watermark to.

Returns: int - The index of slide to add the watermark to.


-1 means all slides.

setSlideIndex(int value)

public final void setSlideIndex(int value)

Sets the index of slide to add the watermark to.

Parameters:

Parameter Type Description
value int The index of slide to add the watermark to.

-1 means all slides. |