mirror of
https://github.com/Geckon01/Watermark.Net.git
synced 2026-06-13 01:03:32 +03:00
Fixed default text watermark font
This commit is contained in:
@@ -75,8 +75,13 @@ namespace Watermark.Net.src.WatermarkNet.Types
|
||||
/// </summary>
|
||||
public TextWatermark()
|
||||
{
|
||||
var availableFont = SystemFonts.Families.FirstOrDefault();
|
||||
if (availableFont == default)
|
||||
{
|
||||
throw new Exception("No available fonts found in the system");
|
||||
}
|
||||
_color = Color.White;
|
||||
_font = SystemFonts.CreateFont("Arial", 12);
|
||||
_font = availableFont.CreateFont(1);
|
||||
_padding = 10f;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user