Class DWriteLocalizedStrings
Represents a collection of strings indexed by locale name.
Implements
Inherited Members
Namespace: JeremyAnsel.DirectX.DWrite
Assembly: JeremyAnsel.DirectX.DWrite.dll
Syntax
[SecurityCritical]
public class DWriteLocalizedStrings : DXComObject, IDisposable
Constructors
| Edit this page View SourceDWriteLocalizedStrings(nint)
Initializes a new instance of the DWriteLocalizedStrings class.
Declaration
public DWriteLocalizedStrings(nint comPtr)
Parameters
| Type | Name | Description |
|---|---|---|
| nint | comPtr |
Fields
| Edit this page View SourceDWriteLocalizedStringsGuid
The interface GUID.
Declaration
public static readonly Guid DWriteLocalizedStringsGuid
Field Value
| Type | Description |
|---|---|
| Guid |
Methods
| Edit this page View SourceFindLocaleName(ReadOnlySpan<char>)
Gets the index of the item with the specified locale name.
Declaration
public uint FindLocaleName(ReadOnlySpan<char> localeName)
Parameters
| Type | Name | Description |
|---|---|---|
| ReadOnlySpan<char> | localeName | Locale name to look for. |
Returns
| Type | Description |
|---|---|
| uint | Receives the zero-based index of the locale name/string pair. |
FindLocaleName(string)
Gets the index of the item with the specified locale name.
Declaration
public uint FindLocaleName(string localeName)
Parameters
| Type | Name | Description |
|---|---|---|
| string | localeName | Locale name to look for. |
Returns
| Type | Description |
|---|---|
| uint | Receives the zero-based index of the locale name/string pair. |
GetCount()
Gets the number of language/string pairs.
Declaration
public uint GetCount()
Returns
| Type | Description |
|---|---|
| uint |
GetLocaleName(uint)
Copies the locale name with the specified index to the specified array.
Declaration
public string GetLocaleName(uint index)
Parameters
| Type | Name | Description |
|---|---|---|
| uint | index | Zero-based index of the locale name. |
Returns
| Type | Description |
|---|---|
| string |
GetLocaleName(uint, Span<char>)
Copies the locale name with the specified index to the specified array.
Declaration
public void GetLocaleName(uint index, Span<char> name)
Parameters
| Type | Name | Description |
|---|---|---|
| uint | index | Zero-based index of the locale name. |
| Span<char> | name | The locale name. |
GetLocaleNameLength(uint)
Gets the length in characters (not including the null terminator) of the locale name with the specified index.
Declaration
public uint GetLocaleNameLength(uint index)
Parameters
| Type | Name | Description |
|---|---|---|
| uint | index | Zero-based index of the locale name. |
Returns
| Type | Description |
|---|---|
| uint | Receives the length in characters, not including the null terminator. |
GetString(uint)
Copies the string with the specified index to the specified array.
Declaration
public string GetString(uint index)
Parameters
| Type | Name | Description |
|---|---|---|
| uint | index | Zero-based index of the string. |
Returns
| Type | Description |
|---|---|
| string |
GetString(uint, Span<char>)
Copies the string with the specified index to the specified array.
Declaration
public void GetString(uint index, Span<char> str)
Parameters
| Type | Name | Description |
|---|---|---|
| uint | index | Zero-based index of the string. |
| Span<char> | str | The string. |
GetStringLength(uint)
Gets the length in characters (not including the null terminator) of the string with the specified index.
Declaration
public uint GetStringLength(uint index)
Parameters
| Type | Name | Description |
|---|---|---|
| uint | index | Zero-based index of the string. |
Returns
| Type | Description |
|---|---|
| uint | Receives the length in characters, not including the null terminator. |