mirror of
https://github.com/ShareX/ShareX.git
synced 2024-07-04 22:21:23 +12:00
Use anti aliasing for text drawing
This commit is contained in:
parent
9ab94c9fec
commit
63c685bf1d
|
@ -28,6 +28,7 @@
|
|||
using System.Collections.Generic;
|
||||
using System.Drawing;
|
||||
using System.Drawing.Drawing2D;
|
||||
using System.Drawing.Text;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading;
|
||||
|
@ -84,7 +85,9 @@ public override void OnDraw(Graphics g)
|
|||
using (Brush textBrush = new SolidBrush(Options.Color))
|
||||
using (StringFormat sf = new StringFormat { Alignment = Options.AlignmentHorizontal, LineAlignment = Options.AlignmentVertical })
|
||||
{
|
||||
g.TextRenderingHint = TextRenderingHint.AntiAliasGridFit;
|
||||
g.DrawString(Text, font, textBrush, Rectangle, sf);
|
||||
g.TextRenderingHint = TextRenderingHint.SystemDefault;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue