From 282d705aba1fbae0b3ff79de43df0d719e13f5e2 Mon Sep 17 00:00:00 2001 From: Matthew Leibowitz Date: Sun, 23 Apr 2017 06:51:10 -0400 Subject: [PATCH] A few more tweaks --- tests/Tests/SKPaintTest.cs | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/tests/Tests/SKPaintTest.cs b/tests/Tests/SKPaintTest.cs index 88f32a30..834e9409 100644 --- a/tests/Tests/SKPaintTest.cs +++ b/tests/Tests/SKPaintTest.cs @@ -71,30 +71,30 @@ namespace SkiaSharp.Tests { using (var bitmap = new SKBitmap(new SKImageInfo(200, 200))) using (var canvas = new SKCanvas(bitmap)) - using (var tf = SKTypeface.FromFamilyName("Arial Black")) + using (var tf = SKTypeface.FromFamilyName("Arial")) using (var paint = new SKPaint { TextSize = 50, IsAntialias = true, Typeface = tf }) { canvas.Clear(SKColors.White); canvas.Scale(1, 2); canvas.DrawText("Skia", 10, 60, paint); - Assert.AreEqual(SKColors.Black, bitmap.GetPixel(53, 86), "Antialias (1)"); - Assert.AreEqual(SKColors.White, bitmap.GetPixel(87, 64), "Antialias (2)"); - Assert.AreEqual(SKColors.Black, bitmap.GetPixel(121, 86), "Antialias (3)"); + Assert.AreEqual(SKColors.Black, bitmap.GetPixel(49, 92), "Antialias (1)"); + Assert.AreEqual(SKColors.White, bitmap.GetPixel(73, 63), "Antialias (2)"); + Assert.AreEqual(SKColors.Black, bitmap.GetPixel(100, 89), "Antialias (3)"); } using (var bitmap = new SKBitmap(new SKImageInfo(200, 200))) using (var canvas = new SKCanvas(bitmap)) - using (var tf = SKTypeface.FromFamilyName("Arial Black")) + using (var tf = SKTypeface.FromFamilyName("Arial")) using (var paint = new SKPaint { TextSize = 50, Typeface = tf }) { canvas.Clear(SKColors.White); canvas.Scale(1, 2); canvas.DrawText("Skia", 10, 60, paint); - Assert.AreEqual(SKColors.Black, bitmap.GetPixel(53, 86), "Non-Antialias (1)"); - Assert.AreEqual(SKColors.White, bitmap.GetPixel(87, 64), "Non-Antialias (2)"); - Assert.AreEqual(SKColors.Black, bitmap.GetPixel(121, 86), "Non-Antialias (3)"); + Assert.AreEqual(SKColors.Black, bitmap.GetPixel(49, 92), "Non-Antialias (1)"); + Assert.AreEqual(SKColors.White, bitmap.GetPixel(73, 63), "Non-Antialias (2)"); + Assert.AreEqual(SKColors.Black, bitmap.GetPixel(100, 89), "Non-Antialias (3)"); } } }