// ------------------------------------------------------------------------------ // // This code was generated by a tool. // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. // // ------------------------------------------------------------------------------ using System; using System.Diagnostics; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; using HexaGen.Runtime; using System.Numerics; namespace Dalamud.Bindings.ImGui { /// /// To be documented. /// [StructLayout(LayoutKind.Sequential)] public partial struct ImGuiTableColumnSettings { /// /// To be documented. /// public float WidthOrWeight; /// /// To be documented. /// public uint UserID; /// /// To be documented. /// public sbyte Index; /// /// To be documented. /// public sbyte DisplayOrder; /// /// To be documented. /// public sbyte SortOrder; public byte RawBits0; /// /// To be documented. /// public unsafe ImGuiTableColumnSettings(float widthOrWeight = default, uint userId = default, sbyte index = default, sbyte displayOrder = default, sbyte sortOrder = default, byte sortDirection = default, byte isEnabled = default, byte isStretch = default) { WidthOrWeight = widthOrWeight; UserID = userId; Index = index; DisplayOrder = displayOrder; SortOrder = sortOrder; SortDirection = sortDirection; IsEnabled = isEnabled; IsStretch = isStretch; } public byte SortDirection { get => Bitfield.Get(RawBits0, 0, 2); set => Bitfield.Set(ref RawBits0, value, 0, 2); } public byte IsEnabled { get => Bitfield.Get(RawBits0, 2, 1); set => Bitfield.Set(ref RawBits0, value, 2, 1); } public byte IsStretch { get => Bitfield.Get(RawBits0, 3, 1); set => Bitfield.Set(ref RawBits0, value, 3, 1); } /// /// To be documented. /// public unsafe void Destroy() { fixed (ImGuiTableColumnSettings* @this = &this) { ImGui.DestroyNative(@this); } } } /// /// To be documented. /// #if NET5_0_OR_GREATER [DebuggerDisplay("{DebuggerDisplay,nq}")] #endif public unsafe struct ImGuiTableColumnSettingsPtr : IEquatable { public ImGuiTableColumnSettingsPtr(ImGuiTableColumnSettings* handle) { Handle = handle; } public ImGuiTableColumnSettings* Handle; public bool IsNull => Handle == null; public static ImGuiTableColumnSettingsPtr Null => new ImGuiTableColumnSettingsPtr(null); public ImGuiTableColumnSettings this[int index] { get => Handle[index]; set => Handle[index] = value; } public static implicit operator ImGuiTableColumnSettingsPtr(ImGuiTableColumnSettings* handle) => new ImGuiTableColumnSettingsPtr(handle); public static implicit operator ImGuiTableColumnSettings*(ImGuiTableColumnSettingsPtr handle) => handle.Handle; public static bool operator ==(ImGuiTableColumnSettingsPtr left, ImGuiTableColumnSettingsPtr right) => left.Handle == right.Handle; public static bool operator !=(ImGuiTableColumnSettingsPtr left, ImGuiTableColumnSettingsPtr right) => left.Handle != right.Handle; public static bool operator ==(ImGuiTableColumnSettingsPtr left, ImGuiTableColumnSettings* right) => left.Handle == right; public static bool operator !=(ImGuiTableColumnSettingsPtr left, ImGuiTableColumnSettings* right) => left.Handle != right; public bool Equals(ImGuiTableColumnSettingsPtr other) => Handle == other.Handle; /// public override bool Equals(object obj) => obj is ImGuiTableColumnSettingsPtr handle && Equals(handle); /// public override int GetHashCode() => ((nuint)Handle).GetHashCode(); #if NET5_0_OR_GREATER private string DebuggerDisplay => string.Format("ImGuiTableColumnSettingsPtr [0x{0}]", ((nuint)Handle).ToString("X")); #endif /// /// To be documented. /// public ref float WidthOrWeight => ref Unsafe.AsRef(&Handle->WidthOrWeight); /// /// To be documented. /// public ref uint UserID => ref Unsafe.AsRef(&Handle->UserID); /// /// To be documented. /// public ref sbyte Index => ref Unsafe.AsRef(&Handle->Index); /// /// To be documented. /// public ref sbyte DisplayOrder => ref Unsafe.AsRef(&Handle->DisplayOrder); /// /// To be documented. /// public ref sbyte SortOrder => ref Unsafe.AsRef(&Handle->SortOrder); /// /// To be documented. /// public byte SortDirection { get => Handle->SortDirection; set => Handle->SortDirection = value; } /// /// To be documented. /// public byte IsEnabled { get => Handle->IsEnabled; set => Handle->IsEnabled = value; } /// /// To be documented. /// public byte IsStretch { get => Handle->IsStretch; set => Handle->IsStretch = value; } /// /// To be documented. /// public unsafe void Destroy() { ImGui.DestroyNative(Handle); } } }