2.6 KiB
2.6 KiB
CanvasKit Changelog
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
[Unreleased]
Added
SkPath.addRoundRect,SkPath.reset,SkPath.rewindexposed.SkCanvas.drawArc,SkCanvas.drawLine,SkCanvas.drawOval,SkCanvas.drawRoundRectexposed.- Can import/export a SkPath to an array of commands. See
CanvasKit.MakePathFromCmdsandSkPath.toCmds. SkCanvas.drawTextBlob()andSkCanvas.SkTextBlob.MakeFromText()to draw text to a canvas.CanvasKit.TextEncodingenum. For use withSkTextBlob.
Changed
SkCanvas.drawText()now requires anSkFontobject.
Removed
SkPaint.setTextSize(),SkPaint.getTextSize(),SkPaint.setTypeface()which should be replaced by usingSkFont.
Fixed
- Potential bug in
ready()if already loaded.
[0.3.1] - 2019-01-04
Added
SkFontnow exposed.MakeCanvasSurfacecan now take a canvas element directly.MakeWebGLCanvasSurfacecan now take a WebGL context as an integer and use it directly.
Changed
CanvasKitInit(...).then()is no longer the recommended way to initialize things. It will be removed in 0.4.0. UseCanvasKitInit(...).ready(), which returns a real Promise.
Removed
SkPaint.measureText- useSkFont.measureTextinstead.
[0.3.0] - 2018-12-18
Added
- Add Canvas2D JS layer. This mirrors the HTML Canvas API. This may be omitted at compile time
it by adding
no_canvasto thecompile.shinvocation. CanvasKit.FontMgr.DefaultRef()andfontmgr.MakeTypefaceFromDatato load fonts.- Exposed
SkPath.setVolatile. Some animations see performance improvements by setting their paths' volatility to true.
Fixed
SkPath.addRectnow correctly draws counter-clockwise vs clockwise.
Changed
CanvasKit.MakeImageShaderno longer takes encoded bytes, but anSkImage, created fromCanvasKit.MakeImageFromEncoded. Additionally, the optional parametersclampIfUnpremulandlocalMatrixhave been exposed.SkPath.arcTonow takesstartAngle,sweepAngle,forceMoveToas additional parameters.SkPath.strokehas a new optionprecisionIt defaults to 1.0.- CanvasKit comes with one font (NotoMono) instead of the Skia TestTypeface. Clients are encouraged
to use the new
fontmgr.MakeTypefaceFromDatafor more font variety.
Removed
CanvasKit.initFonts()- no longer needed.
[0.2.1] - 2018-11-20
Beginning of Changelog history