Class ImGuiListEnum<TEnum>
Wraps an enum type for ImGui controls, like listboxes.
Inherited Members
Namespace: SadConsole.ImGuiSystem
Assembly: SadConsole.Debug.MonoGame.dll
Syntax
public static class ImGuiListEnum<TEnum> where TEnum : struct, Enum
Type Parameters
| Name | Description |
|---|---|
| TEnum | The enum to wrap. |
Fields
Names
A collection of each enum name.
Declaration
public static string[] Names
Field Value
| Type | Description |
|---|---|
| string[] |
Values
A collection of each enum value.
Declaration
public static TEnum[] Values
Field Value
| Type | Description |
|---|---|
| TEnum[] |
Properties
Count
The count of the enums items.
Declaration
public static int Count { get; }
Property Value
| Type | Description |
|---|---|
| int |
Methods
GetIndexFromValue(TEnum)
Gets an index from a value.
Declaration
public static int GetIndexFromValue(TEnum value)
Parameters
| Type | Name | Description |
|---|---|---|
| TEnum | value | The value to get an index from. |
Returns
| Type | Description |
|---|---|
| int | The index. |
GetValueFromIndex(int)
Gets a value from an index.
Declaration
public static TEnum GetValueFromIndex(int index)
Parameters
| Type | Name | Description |
|---|---|---|
| int | index | Index of the value to get. |
Returns
| Type | Description |
|---|---|
| TEnum | A value. |