Export (0) Print
Expand All

WebImage.AddTextWatermark Method

Adds watermark text to the image.

Namespace:  System.Web.Helpers
Assembly:  System.Web.Helpers (in System.Web.Helpers.dll)

public WebImage AddTextWatermark(
	string text,
	string fontColor,
	int fontSize,
	string fontStyle,
	string fontFamily,
	string horizontalAlign,
	string verticalAlign,
	int opacity,
	int padding
)

Parameters

text
Type: System.String
The text to use as a watermark.
fontColor
Type: System.String
The color of the watermark text.
fontSize
Type: System.Int32
The font size of the watermark text.
fontStyle
Type: System.String
The font style of the watermark text.
fontFamily
Type: System.String
The font type of the watermark text.
horizontalAlign
Type: System.String
The horizontal alignment for watermark text. Values can be "Left", "Right", or "Center".
verticalAlign
Type: System.String
The vertical alignment for the watermark text. Values can be "Top", "Middle", or "Bottom".
opacity
Type: System.Int32
The opacity for the watermark image, specified as a value between 0 and 100.
padding
Type: System.Int32
The size, in pixels, of the padding around the watermark text.

Return Value

Type: System.Web.Helpers.WebImage
The watermarked image.

  • Medium trust for the immediate caller. This member can be used by partially trusted code.
Show:
© 2015 Microsoft