brutal/Brutal.ImGui/Generated/Structs/ImGuiTextBuffer.gen.cs
Rian Drake b578433e37 first
2026-10-15 17:10:50 +13:00

89 lines
3.1 KiB
C#

// <auto-generated/>
// Generated by Brutal.ImGui.Generator; do not edit by hand.
#nullable enable
using System.Runtime.CompilerServices;
namespace Brutal.ImGuiApi
{
/// <summary>
/// <para>
/// Helper to hold and append into a text buffer (~string builder)
/// </para>
/// <para>
/// C++:
/// <see href="https://github.com/RocketWerkz/imgui/blob/v1.92.2-docking-brutal/imgui.h#L215">imgui.h:215</see>
/// <br/><c>struct ImGuiTextBuffer</c>
/// </para>
/// </summary>
/// <remarks>
/// <para>
/// Forward declarations: ImGui layer
/// </para>
/// </remarks>
[StructLayout(LayoutKind.Explicit, Size = 16)]
public unsafe partial struct ImGuiTextBuffer
{
/// <summary>
/// <para>
/// C++:
/// <see href="https://github.com/RocketWerkz/imgui/blob/v1.92.2-docking-brutal/imgui.h#L2838">imgui.h:2838</see>
/// <br/><c>ImVector&lt;char&gt; Buf</c>
/// </para>
/// </summary>
/// <remarks>
/// <code>
/// Helper: Growable text buffer for logging/accumulating text
/// (this could be called 'ImGuiTextBuilder' / 'ImGuiStringBuilder')
/// </code>
/// </remarks>
[FieldOffset(0)]
public ImVector<byte> Buf;
[FieldOffset(0)]
public fixed byte EmptyString[1];
}
/// <summary>
/// <para>
/// Helper to hold and append into a text buffer (~string builder)
/// </para>
/// <para>
/// C++:
/// <see href="https://github.com/RocketWerkz/imgui/blob/v1.92.2-docking-brutal/imgui.h#L215">imgui.h:215</see>
/// <br/><c>struct ImGuiTextBuffer</c>
/// </para>
/// </summary>
/// <remarks>
/// <para>
/// Forward declarations: ImGui layer
/// </para>
/// </remarks>
public unsafe partial struct ImGuiTextBufferPtr(ImGuiTextBuffer* ptr) : INullable
{
private ImGuiTextBuffer* _ptr = ptr;
public ImGuiTextBuffer* Ptr => _ptr;
public bool IsNull() => _ptr is null;
public static implicit operator ImGuiTextBufferPtr(ImGuiTextBuffer* ptr) => new(ptr);
public static implicit operator ImGuiTextBuffer*(ImGuiTextBufferPtr wrapper) => wrapper.Ptr;
/// <summary>
/// <para>
/// C++:
/// <see href="https://github.com/RocketWerkz/imgui/blob/v1.92.2-docking-brutal/imgui.h#L2838">imgui.h:2838</see>
/// <br/><c>ImVector&lt;char&gt; Buf</c>
/// </para>
/// </summary>
/// <remarks>
/// <code>
/// Helper: Growable text buffer for logging/accumulating text
/// (this could be called 'ImGuiTextBuilder' / 'ImGuiStringBuilder')
/// </code>
/// </remarks>
public ref ImVector<byte> Buf => ref Unsafe.AsRef<ImVector<byte>>(&_ptr->Buf);
public Span<byte> EmptyString => MemoryMarshal.CreateSpan(ref _ptr->EmptyString[0], 1);
}
}