SKTextBlob.Create Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
| Name | Description |
|---|---|
| Create(ReadOnlySpan<Char>, SKFont, SKPoint) |
Creates a new text blob from the specified text. |
| Create(String, SKFont, SKPoint) |
Creates a new text blob from the specified text. |
| Create(ReadOnlySpan<Byte>, SKTextEncoding, SKFont, SKPoint) |
Creates a new text blob from the specified encoded text. |
| Create(IntPtr, Int32, SKTextEncoding, SKFont, SKPoint) |
Creates a new text blob from the specified encoded text pointer. |
Create(ReadOnlySpan<Char>, SKFont, SKPoint)
Creates a new text blob from the specified text.
public static SkiaSharp.SKTextBlob? Create(ReadOnlySpan<char> text, SkiaSharp.SKFont font, SkiaSharp.SKPoint origin = default);
Parameters
- text
- ReadOnlySpan<Char>
The text to shape and render.
- font
- SKFont
The font used to shape the text.
- origin
- SKPoint
The origin point for the text blob.
Returns
A new text blob, or null if creation fails.
Applies to
Create(String, SKFont, SKPoint)
Creates a new text blob from the specified text.
public static SkiaSharp.SKTextBlob? Create(string text, SkiaSharp.SKFont font, SkiaSharp.SKPoint origin = default);
Parameters
- text
- String
The text to shape and render.
- font
- SKFont
The font used to shape the text.
- origin
- SKPoint
The origin point for the text blob.
Returns
A new text blob, or null if creation fails.
Applies to
Create(ReadOnlySpan<Byte>, SKTextEncoding, SKFont, SKPoint)
Creates a new text blob from the specified encoded text.
public static SkiaSharp.SKTextBlob? Create(ReadOnlySpan<byte> text, SkiaSharp.SKTextEncoding encoding, SkiaSharp.SKFont font, SkiaSharp.SKPoint origin = default);
Parameters
- text
- ReadOnlySpan<Byte>
The encoded text bytes to shape and render.
- encoding
- SKTextEncoding
The text encoding of the input text.
- font
- SKFont
The font used to shape the text.
- origin
- SKPoint
The origin point for the text blob.
Returns
A new text blob, or null if creation fails.
Applies to
Create(IntPtr, Int32, SKTextEncoding, SKFont, SKPoint)
Creates a new text blob from the specified encoded text pointer.
public static SkiaSharp.SKTextBlob? Create(IntPtr text, int length, SkiaSharp.SKTextEncoding encoding, SkiaSharp.SKFont font, SkiaSharp.SKPoint origin = default);
Parameters
- text
- IntPtr
A pointer to the encoded text data.
- length
- Int32
The length of the text data in bytes.
- encoding
- SKTextEncoding
The text encoding of the input text.
- font
- SKFont
The font used to shape the text.
- origin
- SKPoint
The origin point for the text blob.
Returns
A new text blob, or null if creation fails.