UtilAsposeAddTextWatermark(Image, String, Font, Color, PointF) Method
Adds a text watermark at the specified position into an image.
Namespace: DevCase.ThirdParty.AsposeAssembly: DevCase.net48.ThirdParty.Aspose (in DevCase.net48.ThirdParty.Aspose.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
public static Image AddTextWatermark(
Image img,
string text,
Font fnt,
Color color,
PointF position
)
Public Shared Function AddTextWatermark (
img As Image,
text As String,
fnt As Font,
color As Color,
position As PointF
) As Image
Dim img As Image
Dim text As String
Dim fnt As Font
Dim color As Color
Dim position As PointF
Dim returnValue As Image
returnValue = UtilAspose.AddTextWatermark(img,
text, fnt, color, position)
public:
static Image^ AddTextWatermark(
Image^ img,
String^ text,
Font^ fnt,
Color color,
PointF position
)
static member AddTextWatermark :
img : Image *
text : string *
fnt : Font *
color : Color *
position : PointF -> Image
No code example is currently available or this language may not be supported.
- img Image
-
The source image.
- text String
-
The watermark text.
- fnt Font
-
The watermark font.
- color Color
-
The watermark color.
- position PointF
-
The watermark position.
Image
The resulting
Image.
Note: Some functionalities of this assembly may require to install one or all of the listed NuGet packages:
Aspose.Imaging by Aspose
This is a code example.
No code example is currently available or this language may not be supported.
' Load an image to add a watermark.
Dim img As Aspose.Imaging.Image = Aspose.Imaging.Image.Load("C:\image.bmp")
' Set the watermark text.
Dim text As String = "ElektroStudios"
' Set the watermark text color.
Dim color As Global.Aspose.Imaging.Color = Aspose.Imaging.Color.White
' Set the watermark text font.
Dim fnt As New Aspose.Imaging.Font("Lucida Console", 32, FontStyle.Bold)
' Add the watermark into the image.
Dim position As New Aspose.Imaging.PointF(10, 10)
img = AddTextWatermark(img:=img, text:=text, fnt:=fnt, color:=color, position:=position)
' Save the image to disk.
img.Save("C:\Watermark.bmp")
' See the resulting image.
Process.Start("C:\Watermark.bmp")
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.