Skip to content

Migrate inline /// docs to mdoc XML (Graphite backend + pre-existing) #181

Description

@mattleibow

Migrate inline /// XML doc comments to mdoc XML

SkiaSharp/HarfBuzzSharp source code does not carry /// XML doc comments — the public API
reference is authored here in mono/SkiaSharp-API-docs as mdoc/ECMA XML. Some inline ///
comments have nevertheless landed in the binding sources. This issue captures that inline
documentation verbatim so it can be re-authored as mdoc XML, and so nothing is lost when the
comments are stripped from source.

Two groups:

  • Group A — Graphite backend (NEW). Added by SkiaSharp PR #3968 / skia PR #236. These ///
    comments are being removed from source as part of PR #3968 (once this issue is on record).
    Re-apply them as mdoc XML after the Graphite API is merged and the doc skeletons are generated.
  • Group B — pre-existing. Older inline /// on public members already in main. Left in
    source
    for now; captured here for eventual migration.

Scope: public/protected members only (internal/private inline comments are excluded, per
what the docs repo covers). Each item shows the member signature (with source line) and the
verbatim doc block; tick it once the equivalent mdoc XML exists.


GROUP A — Graphite (NEW; to be REMOVED from source in PR #3968)

binding/SkiaSharp/Gpu/Graphite/SKGraphiteContext.cs (18 documented public members)

  • Type: public unsafe class SKGraphiteContext : SKObject (L12)
    /// <summary>
    /// Root object for the Graphite GPU backend. Vends recorders, accepts and submits recordings,
    /// and owns GPU resources. Single-thread-affine — do not share across threads.
    /// Must outlive every <see cref="SKGraphiteRecorder"/>, <see cref="SKGraphiteRecording"/>,
    /// and Graphite-backed <see cref="SKSurface"/> derived from it.
    /// </summary>

  • [SKGraphiteContext] public static bool IsBackendAvailable (SKGraphiteBackend backend) (L43)
    /// <summary>True if the requested Graphite backend was compiled into this build of libSkiaSharp.</summary>

  • [SKGraphiteContext] public static SKGraphiteContext CreateVulkan (SKGraphiteVkBackendContext backendContext) (L47)
    /// <summary>
    /// Create a Graphite context for the Vulkan backend. Returns null when the backend isn't
    /// available (see <see cref="IsBackendAvailable"/>) or when the driver rejected the call.
    /// The caller may dispose <paramref name="backendContext"/> as soon as this returns.
    /// </summary>

  • [SKGraphiteContext] public static SKGraphiteContext CreateMetal (SKGraphiteMtlBackendContext backendContext) (L55)
    /// <summary>
    /// Create a Graphite context for the Metal backend (macOS / iOS only). Returns null when
    /// the backend isn't available (see <see cref="IsBackendAvailable"/>) or when the driver
    /// rejected the call. The caller may drop <paramref name="backendContext"/> as soon as
    /// this returns.
    /// </summary>

  • [SKGraphiteContext] public static SKGraphiteContext CreateDawn (SKGraphiteDawnBackendContext backendContext) (L64)
    /// <summary>
    /// Create a Graphite context for the Dawn (WebGPU) backend. Returns null when the backend
    /// isn't available (see <see cref="IsBackendAvailable"/>) or when Dawn rejected the call.
    /// The caller may drop <paramref name="backendContext"/> as soon as this returns.
    /// </summary>

  • [SKGraphiteContext] public static SKGraphiteContext CreateDawn (SKGraphiteDawnBackendContext backendContext, SKGraphiteContextOptions options) (L72)
    /// <inheritdoc cref="CreateDawn(SKGraphiteDawnBackendContext)"/>

  • [SKGraphiteContext] public static SKGraphiteContext CreateMetal (SKGraphiteMtlBackendContext backendContext, SKGraphiteContextOptions options) (L89)
    /// <inheritdoc cref="CreateMetal(SKGraphiteMtlBackendContext)"/>

  • [SKGraphiteContext] public static SKGraphiteContext CreateVulkan (SKGraphiteVkBackendContext backendContext, SKGraphiteContextOptions options) (L104)
    /// <inheritdoc cref="CreateVulkan(SKGraphiteVkBackendContext)"/>

  • [SKGraphiteContext] public SKGraphiteRecorder CreateRecorder (long recorderBudgetBytes = -1) (L179)
    /// <summary>
    /// Vend a fresh recorder. Each recorder is single-thread-affine; multiple recorders may
    /// be used concurrently on different threads against the same context.
    /// </summary>

  • [SKGraphiteContext] public SKGraphiteRecorder CreateRecorder ( (L186)
    /// <summary>
    /// Vend a recorder with a managed image-upload callback attached. Without one, Graphite
    /// drops every draw whose source <see cref="SKImage"/> is not already Graphite-backed
    /// (it does not auto-upload like Ganesh). For a ready-made LRU policy pass
    /// <c>cache.FindOrCreate</c> + <c>cache.Dispose</c> from a new
    /// <see cref="SKGraphiteImageCache"/>.
    ///
    /// <paramref name="findOrCreateDispose"/>, if supplied, runs at recorder teardown
    /// <em>before</em> the native recorder is destroyed — use it to release any
    /// graphite-backed images the callback's closure captured (releasing them after
    /// destruction is undefined behavior).
    /// </summary>

  • [SKGraphiteContext] public SKGraphiteInsertStatus InsertRecording (SKGraphiteRecording recording) (L263)
    /// <summary>
    /// Submit a recording for execution. Non-success values are returned verbatim,
    /// not thrown — callers branch on the enum.
    /// </summary>

  • [SKGraphiteContext] public SKGraphiteInsertStatus InsertRecording (SKGraphiteInsertRecordingInfo info) (L278)
    /// <inheritdoc cref="InsertRecording(SKGraphiteRecording)"/>

  • [SKGraphiteContext] public bool Submit () (L282)
    /// <summary>
    /// Submit pending GPU work. Returns false if submission failed.
    /// </summary>

  • [SKGraphiteContext] public bool Submit (SKGraphiteSubmitInfo submitInfo) (L288)
    /// <summary>
    /// Submit pending GPU work with explicit options. Returns false if submission failed.
    ///
    /// <para><see cref="SKGraphiteSubmitInfo.Sync"/> = true blocks until the GPU is done.
    /// Throws <see cref="InvalidOperationException"/> on contexts created in a non-yielding
    /// (browser/WASM) environment; use <see cref="CheckAsyncWorkCompletion"/> instead.</para>
    /// </summary>

  • [SKGraphiteContext] public void DeleteBackendTexture (SKGraphiteBackendTexture backendTexture) (L316)
    /// <summary>
    /// Schedule a backend texture for release. Equivalent to
    /// <see cref="SKGraphiteRecorder.DeleteBackendTexture"/>.
    /// </summary>

  • [SKGraphiteContext] public void CheckAsyncWorkCompletion () (L327)
    /// <summary>
    /// Drive pending async readback / finished callbacks. Callbacks fire on the calling thread.
    /// </summary>

  • [SKGraphiteContext] public void RequestReadPixels ( (L333)
    /// <summary>
    /// Kick off an async pixel readback. <paramref name="callback"/> fires on whichever thread
    /// next drives completion via <see cref="CheckAsyncWorkCompletion"/> (or
    /// <see cref="Submit(SKGraphiteSubmitInfo)"/> with <c>Sync = true</c>), with <c>null</c>
    /// on failure. The caller drives completion themselves — this method does not block.
    /// </summary>
    /// <param name="dstInfo">Target pixel format. RGBA_8888/Premul is supported on every backend.</param>
    /// <param name="srcRect">Region of <paramref name="surface"/> to read.</param>

  • [SKGraphiteContext] public void RequestReadPixels ( (L367)
    /// <inheritdoc cref="RequestReadPixels(SKSurface, SKImageInfo, SKRectI, SKGraphiteRescaleGamma, SKGraphiteRescaleMode, Action{SKGraphiteAsyncReadResult})"/>

binding/SkiaSharp/Gpu/Graphite/SKGraphiteBackendTexture.cs (4 documented public members)

  • Type: public unsafe class SKGraphiteBackendTexture : SKObject (L7)
    /// <summary>
    /// Wraps a caller-allocated GPU texture (e.g. a <c>VkImage</c> from a
    /// swap chain) so Graphite can draw into it or sample from it. The
    /// underlying GPU object is NOT freed by <c>Dispose</c> — only this
    /// wrapper. Caller retains ownership of the GPU texture for its full
    /// Vulkan/Metal/Dawn lifetime.
    ///
    /// Use with <see cref="SKSurface.Create(SKGraphiteRecorder, SKGraphiteBackendTexture, SKColorType)"/>
    /// to render into the wrapped texture.
    /// </summary>

  • [SKGraphiteBackendTexture] public static SKGraphiteBackendTexture CreateVulkan ( (L24)
    /// <summary>
    /// Wrap an externally-allocated <c>VkImage</c>. Returns null if the
    /// image is invalid or the format is not supported by Graphite. The
    /// VkImage's memory must already be bound; this wrapper does NOT
    /// allocate or bind memory.
    /// </summary>
    /// <param name="imageLayout">VkImageLayout the image is in when handed to Skia.</param>

  • [SKGraphiteBackendTexture] public static SKGraphiteBackendTexture CreateMetal ( (L49)
    /// <summary>
    /// Wrap an externally-allocated id&lt;MTLTexture&gt;. The wrapper does
    /// NOT call retain or release on the passed-in texture — caller must
    /// keep it alive for the BackendTexture's lifetime.
    /// </summary>

  • [SKGraphiteBackendTexture] public static SKGraphiteBackendTexture CreateDawn (IntPtr wgpuTexture) (L69)
    /// <summary>
    /// Wrap an externally-allocated <c>WGPUTexture</c>. Dimensions and format
    /// are queried directly from the texture. The wrapper does NOT retain
    /// the texture — caller must keep it alive for the BackendTexture's
    /// lifetime. Any SKSurface/SKImage built from this BackendTexture
    /// <em>does</em> retain it, at which point the caller may drop their reference.
    /// </summary>

binding/SkiaSharp/Gpu/Graphite/SKGraphiteRecorder.cs (4 documented public members)

  • Type: public unsafe class SKGraphiteRecorder : SKObject (L12)
    /// <summary>
    /// A short-lived recording context vended by a <see cref="SKGraphiteContext"/>.
    /// Drawing commands target a recorder; <see cref="Snap"/> produces a Recording for
    /// later submission. Single-thread-affine; multiple recorders may be used concurrently
    /// on different threads against the same parent context.
    /// </summary>

  • [SKGraphiteRecorder] public SKGraphiteRecording Snap () (L60)
    /// <summary>
    /// Produce a Recording from the work queued on this recorder. Returns null when there
    /// are no draws to snap. After being inserted via <see cref="SKGraphiteContext.InsertRecording(SKGraphiteRecording)"/>,
    /// a recording is consumed and should be disposed.
    /// </summary>

  • [SKGraphiteRecorder] public SKGraphiteBackendTexture CreateBackendTexture (int width, int height, SKGraphiteTextureInfo info) (L71)
    /// <summary>
    /// Allocate a fresh Skia-managed GPU texture. Pair the result with
    /// <see cref="DeleteBackendTexture"/> (or <see cref="SKGraphiteContext.DeleteBackendTexture"/>).
    /// Returns null on failure.
    /// </summary>

  • [SKGraphiteRecorder] public void DeleteBackendTexture (SKGraphiteBackendTexture backendTexture) (L88)
    /// <summary>
    /// Schedule the underlying GPU texture for release. The
    /// <see cref="SKGraphiteBackendTexture"/> wrapper itself must still
    /// be disposed separately (or via <c>using</c>).
    /// </summary>

binding/SkiaSharp/Gpu/Graphite/SKGraphiteImageCache.cs (3 documented public members)

  • Type: public sealed class SKGraphiteImageCache : IDisposable (L8)
    /// <summary>
    /// Upload-once + LRU cache to back
    /// <see cref="SKGraphiteContext.CreateRecorder(long, SKGraphiteFindOrCreateImageDelegate, Action)"/>.
    /// Construct one, pass <see cref="FindOrCreate"/> and <see cref="Dispose"/> to the recorder.
    /// One cache per recorder — cached graphite-backed images reference resources owned by
    /// that recorder and become invalid when the recorder is destroyed.
    /// </summary>

  • [SKGraphiteImageCache] public SKImage FindOrCreate (SKGraphiteRecorder recorder, SKImage image, bool mipmapped) (L30)
    /// <summary>
    /// Matches the <see cref="SKGraphiteFindOrCreateImageDelegate"/> signature; pass directly
    /// to <see cref="SKGraphiteContext.CreateRecorder(long, SKGraphiteFindOrCreateImageDelegate, Action)"/>.
    /// </summary>

  • [SKGraphiteImageCache] public void Dispose () (L76)
    /// <summary>
    /// Release every cached graphite-backed image. Must run before the owning recorder
    /// is destroyed — typically wired via the <c>onDispose</c> argument to
    /// <see cref="SKGraphiteContext.CreateRecorder(long, SKGraphiteFindOrCreateImageDelegate, Action)"/>.
    /// Safe to call multiple times.
    /// </summary>

binding/SkiaSharp/Gpu/Graphite/SKGraphiteMtlBackendContext.cs (5 documented public members)

  • Type: public unsafe class SKGraphiteMtlBackendContext : IDisposable (L10)
    /// <summary>
    /// Caller-supplied Metal handles used to bring up a Graphite Metal context.
    /// <see cref="MtlDevice"/> and <see cref="MtlQueue"/> are id&lt;MTLDevice&gt; and
    /// id&lt;MTLCommandQueue&gt; passed as CFTypeRef-compatible handles.
    /// </summary>

  • [SKGraphiteMtlBackendContext] public IntPtr MtlDevice (L20)
    /// <summary>id&lt;MTLDevice&gt; (CFRetainable Obj-C handle).</summary>

  • [SKGraphiteMtlBackendContext] public IntPtr MtlQueue (L31)
    /// <summary>id&lt;MTLCommandQueue&gt; (CFRetainable Obj-C handle).</summary>

  • [SKGraphiteMtlBackendContext] public IMTLDevice Device (L46)
    /// <summary>
    /// Strongly-typed id&lt;MTLDevice&gt;. Setting this also updates <see cref="MtlDevice"/>;
    /// setting <see cref="MtlDevice"/> directly clears this cached reference.
    /// </summary>

  • [SKGraphiteMtlBackendContext] public IMTLCommandQueue Queue (L58)
    /// <summary>
    /// Strongly-typed id&lt;MTLCommandQueue&gt;. Setting this also updates <see cref="MtlQueue"/>;
    /// setting <see cref="MtlQueue"/> directly clears this cached reference.
    /// </summary>

binding/SkiaSharp/Gpu/Graphite/SKGraphiteAsyncReadResult.cs (6 documented public members)

  • Type: public sealed unsafe class SKGraphiteAsyncReadResult : IDisposable (L7)
    /// <summary>
    /// Per-plane pixel data delivered to the callback passed to
    /// <c>SKGraphiteContext.RequestReadPixels</c>. Only valid for the
    /// duration of that callback — copy what you need before returning.
    /// </summary>

  • [SKGraphiteAsyncReadResult] public int PlaneCount (L21)
    /// <summary>Number of pixel planes (1 for RGBA, 2/3 for YUV variants).</summary>

  • [SKGraphiteAsyncReadResult] public IntPtr GetPlaneData (int planeIndex) (L29)
    /// <summary>Raw pointer to plane <paramref name="planeIndex"/>'s pixel data.</summary>

  • [SKGraphiteAsyncReadResult] public int GetPlaneRowBytes (int planeIndex) (L38)
    /// <summary>Stride in bytes for plane <paramref name="planeIndex"/>.</summary>

  • [SKGraphiteAsyncReadResult] public void CopyPlaneTo (int planeIndex, Span<byte> destination, int rowCount) (L47)
    /// <summary>
    /// Copy <paramref name="rowCount"/> rows of plane <paramref name="planeIndex"/> verbatim
    /// (including any per-row padding) into <paramref name="destination"/>.
    /// </summary>

  • [SKGraphiteAsyncReadResult] public void Dispose () (L71)
    /// <summary>Invalidates this wrapper; called automatically when the callback returns.</summary>

binding/SkiaSharp/Gpu/Graphite/SKGraphiteFindOrCreateImageDelegate.cs (1 documented public members)

  • Type: public delegate SKImage SKGraphiteFindOrCreateImageDelegate (SKGraphiteRecorder recorder, SKImage image, bool mipmapped); (L5)
    /// <summary>
    /// Convert <paramref name="image"/> (raster or lazy) to a Graphite-backed image suitable for
    /// drawing on <paramref name="recorder"/>, or return null to drop the draw. The returned
    /// SKImage's reference is consumed by Skia.
    ///
    /// THREADING: runs on the recorder's owning thread, not necessarily the thread that
    /// constructed the callback. Any caches captured in the closure must be thread-safe.
    ///
    /// EXCEPTIONS: never throw — the FFI boundary catches and converts to a null return
    /// (draw dropped).
    /// </summary>

binding/SkiaSharp/Gpu/Graphite/SKGraphiteDawnBackendContext.cs (4 documented public members)

  • Type: public unsafe class SKGraphiteDawnBackendContext : IDisposable (L8)
    /// <summary>
    /// Caller-supplied Dawn (WebGPU) handles used to bring up a Graphite Dawn context.
    ///
    /// On WebAssembly (browser) targets the resulting context runs in non-yielding
    /// mode: <see cref="SKGraphiteContext.Submit(SKGraphiteSubmitInfo)"/> rejects
    /// <see cref="SKGraphiteSubmitInfo.Sync"/> = true; drive readbacks through
    /// <see cref="SKGraphiteContext.CheckAsyncWorkCompletion"/>.
    /// </summary>

  • [SKGraphiteDawnBackendContext] public IntPtr WgpuInstance (L20)
    /// <summary>WGPUInstance handle.</summary>

  • [SKGraphiteDawnBackendContext] public IntPtr WgpuDevice (L23)
    /// <summary>WGPUDevice handle.</summary>

  • [SKGraphiteDawnBackendContext] public IntPtr WgpuQueue (L26)
    /// <summary>WGPUQueue handle.</summary>

source/SkiaSharp.Vulkan/SkiaSharp.Vulkan.SharpVk/SKGraphiteSharpVkBackendContext.cs (1 documented public members)

  • Type: public unsafe class SKGraphiteSharpVkBackendContext : SKGraphiteVkBackendContext (L6)
    /// <summary>
    /// Strongly-typed <see cref="SKGraphiteVkBackendContext"/> that accepts SharpVk handle
    /// objects (<see cref="Instance"/>, <see cref="PhysicalDevice"/>, <see cref="Device"/>,
    /// <see cref="Queue"/>) instead of raw <see cref="IntPtr"/>s. Setting a typed handle
    /// writes the corresponding raw handle through to the base class, so the resulting
    /// context can be built via <see cref="SKGraphiteContext.CreateVulkan(SKGraphiteVkBackendContext)"/>.
    /// This mirrors <see cref="GRSharpVkBackendContext"/> for the Graphite backend.
    /// </summary>

binding/SkiaSharp/Gpu/Graphite/SKGraphiteVkBackendContext.cs (1 documented public members)

  • Type: public unsafe class SKGraphiteVkBackendContext : IDisposable (L13)
    /// <summary>
    /// Caller-supplied Vulkan handles + procedure-address callback used to bring up a
    /// Graphite Vulkan context. The Vulkan handles are never freed by SkiaSharp — caller
    /// retains ownership for the lifetime of the resulting <see cref="SKGraphiteContext"/>.
    /// </summary>

binding/SkiaSharp/Gpu/Graphite/SKGraphiteTextureInfo.cs (2 documented public members)

  • Type: public unsafe class SKGraphiteTextureInfo : SKObject (L7)
    /// <summary>
    /// Backend-erased description of a Graphite texture (format, sample count, mipmap).
    /// Build via the per-backend factories (<see cref="CreateVulkan"/>, …).
    /// </summary>

  • [SKGraphiteTextureInfo] public static SKGraphiteTextureInfo CreateVulkan (SKGraphiteVkTextureInfo info) (L18)
    /// <summary>Build a TextureInfo from Vulkan-specific fields. Returns null on failure.</summary>

binding/SkiaSharp/Gpu/Graphite/SKGraphiteRecording.cs (1 documented public members)

  • Type: public unsafe class SKGraphiteRecording : SKObject (L7)
    /// <summary>
    /// An immutable command list produced by <see cref="SKGraphiteRecorder.Snap"/>.
    /// Insert via <see cref="SKGraphiteContext.InsertRecording(SKGraphiteRecording)"/> to execute
    /// on the GPU; reusing a recording after insertion is undefined behavior.
    /// </summary>

GROUP B — pre-existing (CAPTURE only; stays in source)

binding/SkiaSharp/SKTypeface.cs (3 documented public members)

  • [SKTypeface] public bool HasGetKerningPairAdjustments (L361)
    /// <summary>
    /// If false, then <see cref="GetKerningPairAdjustments(ReadOnlySpan{ushort})"/> will never return nonzero
    /// adjustments for any possible pair of glyphs.
    /// </summary>

  • [SKTypeface] public int[] GetKerningPairAdjustments (ReadOnlySpan<ushort> glyphs) (L373)
    /// <summary>
    /// Gets a kerning adjustment for each sequential pair of glyph indices in <paramref name="glyphs"/>.
    /// </summary>
    /// <param name="glyphs">The sequence of glyph indices to get kerning adjustments for.</param>
    /// <returns>
    /// Adjustments are returned in design units, relative to <see cref="UnitsPerEm"/>.
    /// </returns>
    /// <remarks>
    /// For backwards-compatibility reasons, an additional zero entry is present at the end of the array.
    /// </remarks>

  • [SKTypeface] public bool GetKerningPairAdjustments (ReadOnlySpan<ushort> glyphs, Span<int> adjustments) (L390)
    /// <summary>
    /// Gets a kerning adjustment for each sequential pair of glyph indices in <paramref name="glyphs"/>.
    /// </summary>
    /// <param name="glyphs">The sequence of glyph indices to get kerning adjustments for.</param>
    /// <param name="adjustments">
    /// The span that will hold the output adjustments, one per adjacent pari of <paramref name="glyphs"/>.
    /// Adjustments are returned in design units, relative to <see cref="UnitsPerEm"/>.
    /// This must contain a minimum of glyphs.Length - 1 elements.
    /// </param>
    /// <returns>
    /// True if any kerning pair adjustments were written to <paramref name="adjustments"/>.
    /// False if the typeface does not contain adjustments for any of the given pairs of glyphs.
    /// </returns>
    /// <remarks>
    /// If this function returns false, then the first <paramref name="glyphs"/>.Length - 1 elements of <paramref name="adjustments"/> will be zero.
    /// Elements of <paramref name="adjustments"/> beyond <paramref name="glyphs"/>.Length - 1 will not be modified.
    /// </remarks>

binding/SkiaSharp/PlatformLock.cs (5 documented public members)

  • Type: public interface IPlatformLock (L25)
    /// <summary>
    /// Abstracts a platform dependant lock implementation
    /// </summary>

  • Type: public static partial class PlatformLock (L38)
    /// <summary>
    /// Helper class to create a IPlatformLock instance, by default according to the current platform
    /// but also client toolkits can plugin their own implementation.
    /// </summary>

  • [PlatformLock] public static IPlatformLock Create () (L44)
    /// <summary>
    /// Creates a platform lock
    /// </summary>
    /// <returns></returns>

  • [PlatformLock] public static Func<IPlatformLock> Factory (L54)
    /// <summary>
    /// The factory for creating platform locks
    /// </summary>
    /// <remarks>
    /// Use this to plugin your own lock implementation. Must be set
    /// before using other SkiaSharp functionality that causes the lock
    /// to be created (currently only used by SkiaSharps internal
    /// HandleDictionary).
    /// </remarks>

  • [PlatformLock] public static IPlatformLock DefaultFactory () (L65)
    /// <summary>
    /// Default platform lock factory
    /// </summary>
    /// <returns>A reference to a new platform lock implementation</returns>

binding/HarfBuzzSharp/HBColor.cs (8 documented public members)

  • Type: public readonly struct HBColor : IEquatable<HBColor> (L7)
    /// <summary>
    /// Represents a HarfBuzz color value (<c>hb_color_t</c>) with BGRA byte ordering.
    /// </summary>
    /// <remarks>
    /// HarfBuzz stores colors as <c>0xBBGGRRAA</c> (Blue in high byte, Alpha in low byte).
    /// This differs from <c>SKColor</c> which uses ARGB: <c>0xAARRGGBB</c>.
    /// Use the named properties (<see cref="Red"/>, <see cref="Green"/>, <see cref="Blue"/>,
    /// <see cref="Alpha"/>) to correctly access color channels.
    /// </remarks>

  • [HBColor] public HBColor (uint value) (L20)
    /// <summary>
    /// Creates an <see cref="HBColor"/> from a raw <c>hb_color_t</c> value.
    /// </summary>

  • [HBColor] public HBColor (byte red, byte green, byte blue, byte alpha) (L28)
    /// <summary>
    /// Creates an <see cref="HBColor"/> from individual RGBA components.
    /// </summary>

  • [HBColor] public byte Red (L36)
    /// <summary>
    /// Gets the red channel value.
    /// </summary>

  • [HBColor] public byte Green (L41)
    /// <summary>
    /// Gets the green channel value.
    /// </summary>

  • [HBColor] public byte Blue (L46)
    /// <summary>
    /// Gets the blue channel value.
    /// </summary>

  • [HBColor] public byte Alpha (L51)
    /// <summary>
    /// Gets the alpha channel value.
    /// </summary>

  • [HBColor] public uint Value (L56)
    /// <summary>
    /// Gets the raw <c>hb_color_t</c> value (BGRA byte ordering: <c>0xBBGGRRAA</c>).
    /// </summary>

source/SkiaSharp.HarfBuzz/SkiaSharp.HarfBuzz/ColorExtensions.cs (6 documented public members)

  • Type: public static class ColorExtensions (L5)
    /// <summary>
    /// Extension methods for converting between <see cref="HBColor"/> and SkiaSharp color types.
    /// </summary>

  • [ColorExtensions] public static SKColor ToSKColor (this HBColor hbColor) (L10)
    /// <summary>
    /// Converts an <see cref="HBColor"/> to an <see cref="SKColor"/>.
    /// </summary>

  • [ColorExtensions] public static SKColorF ToSKColorF (this HBColor hbColor) (L18)
    /// <summary>
    /// Converts an <see cref="HBColor"/> to an <see cref="SKColorF"/> (normalized 0.0–1.0 channels).
    /// </summary>

  • [ColorExtensions] public static SKColor[] ToSKColors (this HBColor[] hbColors) (L30)
    /// <summary>
    /// Converts an array of <see cref="HBColor"/> values to an array of <see cref="SKColor"/>.
    /// </summary>

  • [ColorExtensions] public static HBColor ToHBColor (this SKColor color) (L44)
    /// <summary>
    /// Converts an <see cref="SKColor"/> to an <see cref="HBColor"/>.
    /// </summary>

  • [ColorExtensions] public static HBColor ToHBColor (this SKColorF color) (L52)
    /// <summary>
    /// Converts an <see cref="SKColorF"/> to an <see cref="HBColor"/> (clamped to 0–255 range).
    /// </summary>

binding/SkiaSharp/SKCanvas.cs (1 documented public members)

  • [SKAutoCanvasRestore] public void Restore () (L1261)
    /// <summary>
    /// Perform the restore now, instead of waiting for the Dispose.
    /// Will only do this once.
    /// </summary>

Metadata

Metadata

Assignees

No one assigned

    Labels

    doc-enhancementThe issue is a request for new content, or a new way of presenting content.documentation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions