PeachDrawing.Skia.SkiaRenderContext

SkiaRenderContext(SkiaTextEngine, SkiaImageCodec, ISkiaTextShaper, FontSet) Constructor

Makes a context.

public SkiaRenderContext(PeachDrawing.Skia.SkiaTextEngine textEngine=PeachDrawing.Skia.SkiaTextEngine.PeachDrawing, PeachDrawing.Skia.SkiaImageCodec imageCodec=PeachDrawing.Skia.SkiaImageCodec.Auto, PeachDrawing.Skia.ISkiaTextShaper? textShaper=null, PeachDrawing.Text.FontSet? fontSet=null);

Parameters

textEngine SkiaTextEngine

which engine shapes and draws text

imageCodec SkiaImageCodec

which decoder turns an encoded image into pixels

textShaper ISkiaTextShaper

for Native, what shapes text into glyphs: null uses a basic one that needs nothing beyond Skia (no ligatures, kerning or complex scripts); pass one over a shaping library (such as HarfBuzz) for those. Ignored by the other engine.

fontSet FontSet

the set of fonts the PeachDrawing text engine resolves families from, or null for one of this context’s own. Give several contexts one set and a font added to it is read once, however many documents use it; call SyncFonts() to make a context see fonts added since it was made. Ignored by the native engine, which keeps its own faces per context.