DiagramShapeWatermarkOptions

DiagramShapeWatermarkOptions class

Represents watermark adding options when adding shape watermark to a Visio document.

public sealed class DiagramShapeWatermarkOptions : DiagramWatermarkOptions

Constructors

Name Description
DiagramShapeWatermarkOptions() Initializes a new instance of the DiagramShapeWatermarkOptions class.

Properties

Name Description
IsLocked { get; set; } Gets or sets a value indicating whether an editing of the shape in Visio is forbidden.
PlacementType { get; set; } Gets or sets a value specifying to what pages a watermark should be added.

Remarks

Learn more:

Examples

Add protected watermark to all pages of the Visio document.

DiagramLoadOptions loadOptions = new DiagramLoadOptions();
using (Watermarker watermarker = new Watermarker(@"D:\test.vsdx", loadOptions))
{
    TextWatermark watermark = new TextWatermark("watermark test", new Font("Arial", 42));

    DiagramShapeWatermarkOptions options = new DiagramShapeWatermarkOptions();
    options.IsLocked = true;
    options.PlacementType = DiagramWatermarkPlacementType.AllPages; // default

    watermarker.Add(watermark, options);
    watermarker.Save();
}

See Also