swiftfn / SkiaSwift

Swift wrapper for SkiaSharp's C API
12 stars 1 forks source link

Check the output image of Demo #1

Closed ngocdaothanh closed 5 years ago

ngocdaothanh commented 5 years ago

It doesn't look the same as the output of CSkiaSwift. In CSkiaSwift, there's additional API to set stroke to true/false.

ngocdaothanh commented 5 years ago

It's because the style hasn't been set yet:

public bool IsStroke {
    get => Style != SKPaintStyle.Fill;
    set => Style = value ? SKPaintStyle.Stroke : SKPaintStyle.Fill;
}

https://github.com/mono/SkiaSharp/blob/master/binding/Binding/SKPaint.cs

ngocdaothanh commented 5 years ago

https://github.com/swiftfn/SkiaSwift/commit/f0ab7edaa6502b676e946c730588897bdb46d513