Skip to content

Commit fcc367f

Browse files
committed
Enable antialiasing explicitly
1 parent a09f1e3 commit fcc367f

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/KnowledgePicker.WordCloud/Drawing/SkGraphicEngine.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,16 @@ public sealed class SkGraphicEngine : IGraphicEngine<SKBitmap>
1414
private readonly WordCloudInput wordCloud;
1515

1616
public SkGraphicEngine(ISizer sizer, WordCloudInput wordCloud,
17-
SKTypeface? font = null)
17+
SKTypeface? font = null, bool antialias = true)
1818
{
1919
Sizer = sizer;
2020
Bitmap = new SKBitmap(wordCloud.Width, wordCloud.Height);
2121
canvas = new SKCanvas(Bitmap);
2222
textPaint = new SKPaint
2323
{
2424
Color = SKColor.Parse(wordCloud.TextColor),
25-
Typeface = font
25+
Typeface = font,
26+
IsAntialias = antialias
2627
};
2728
this.wordCloud = wordCloud;
2829
}

0 commit comments

Comments
 (0)