Version 1.49.3
UWP support and canvas clipping · Preview only · NuGet · GitHub Release
Highlights
A feature-packed beta that brings Windows UWP support, improved canvas clipping APIs, better custom platform support, and important fixes for text encoding and canvas save/restore operations.
Breaking Changes
None in this release.
New Features
Platform
- Windows UWP support — SkiaSharp can now be used in Universal Windows Platform apps.
- Custom platform support — A new mechanism allows using SkiaSharp on unofficially supported platforms (such as Linux) by disabling the default native library inclusion. Set
<ShouldIncludeNativeSkiaSharp>False</ShouldIncludeNativeSkiaSharp>in your project and manually include a native library namedlibSkiaSharp.
API Surface
SKCanvasclipping — New overloads forClipRectandClipPaththat acceptSKRegionOperationand antialias parameters, enabling clip region resets. Also addedGetClipBoundsandGetClipDeviceBoundsfor querying the current clip.
void ClipRect(SKRect rect, SKRegionOperation operation = SKRegionOperation.Intersect, bool antialias = false);
void ClipPath(SKRect rect, SKRegionOperation operation = SKRegionOperation.Intersect, bool antialias = false);
bool GetClipBounds(ref SKRect bounds);
bool GetClipDeviceBounds(ref SKRectI bounds);
Bug Fixes
SKCanvas.Save/SKCanvas.SaveLayerreturn values — These methods now correctly return the value from native code.- Text encoding handling —
SKPaint.MeasureText,BreakText,GetTextPath, andGetPosTextPathnow use the encoding fromSKPaint.TextEncodinginstead of incorrectly converting to UTF-16, matching the behavior of text drawing operations.
Platform Support
| Platform | What's New |
|---|---|
| 🪟 Windows | UWP support added |
| 🐧 Linux | Custom platform mechanism enables unofficial support |