Skip to content

Commit

Permalink
Merge pull request #16 from KCoen/docking
Browse files Browse the repository at this point in the history
Change imgui submodule to docking branch
  • Loading branch information
aybe authored Feb 21, 2023
2 parents c1c89ce + 9cc20e1 commit 36b43ba
Show file tree
Hide file tree
Showing 10 changed files with 4,345 additions and 2,225 deletions.
3 changes: 2 additions & 1 deletion DearGenerator/TypeMaps/TypeMapEnumImGui.tt
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@
"ImGuiTableRowFlags",
"ImGuiTreeNodeFlags",
"ImGuiViewportFlags",
"ImGuiWindowFlags"
"ImGuiWindowFlags",
"ImGuiDockNodeFlags"
};

Generate(types, "Constants.ImGuiNamespace");
Expand Down
44 changes: 23 additions & 21 deletions DearImGui.Generator/LibraryImGui.cs
Original file line number Diff line number Diff line change
Expand Up @@ -72,27 +72,29 @@ protected override void PostprocessIgnores(ASTContext ctx)
{
base.PostprocessIgnores(ctx);

Ignore(ctx, "ImDrawData", "CmdLists", IgnoreType.Property); // manual
Ignore(ctx, "ImDrawList", "ClipRectStack", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "CmdHeader", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "Data", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "FringeScale", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "IdxWritePtr", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "OwnerName", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "Path", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "Splitter", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "TextureIdStack", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "VtxCurrentIdx", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "VtxWritePtr", IgnoreType.Property); // intern
Ignore(ctx, "ImFontAtlas", "IsBuilt", IgnoreType.Property); // manual
Ignore(ctx, "ImFontAtlas", "TexUvLines", IgnoreType.Property); // manual
Ignore(ctx, "ImFontAtlasCustomRect", "IsPacked", IgnoreType.Property); // manual
Ignore(ctx, "ImFontConfig", "Name", IgnoreType.Property); // manual
Ignore(ctx, "ImFontGlyph", "Colored", IgnoreType.Property); // manual
Ignore(ctx, "ImFontGlyph", "Visible", IgnoreType.Property); // manual
Ignore(ctx, "ImFontGlyph", "Codepoint", IgnoreType.Property); // manual
Ignore(ctx, "ImGuiIO", "MouseClickedPos", IgnoreType.Property); // manual
Ignore(ctx, "ImGuiStyle", "Colors", IgnoreType.Property); // manual
Ignore(ctx, "ImDrawData", "CmdLists", IgnoreType.Property); // manual
Ignore(ctx, "ImDrawList", "ClipRectStack", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "CmdHeader", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "Data", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "FringeScale", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "IdxWritePtr", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "OwnerName", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "Path", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "Splitter", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "TextureIdStack", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "VtxCurrentIdx", IgnoreType.Property); // intern
Ignore(ctx, "ImDrawList", "VtxWritePtr", IgnoreType.Property); // intern
Ignore(ctx, "ImFontAtlas", "IsBuilt", IgnoreType.Property); // manual
Ignore(ctx, "ImFontAtlas", "TexUvLines", IgnoreType.Property); // manual
Ignore(ctx, "ImFontAtlasCustomRect", "IsPacked", IgnoreType.Property); // manual
Ignore(ctx, "ImFontConfig", "Name", IgnoreType.Property); // manual
Ignore(ctx, "ImFontGlyph", "Colored", IgnoreType.Property); // manual
Ignore(ctx, "ImFontGlyph", "Visible", IgnoreType.Property); // manual
Ignore(ctx, "ImFontGlyph", "Codepoint", IgnoreType.Property); // manual
Ignore(ctx, "ImGuiIO", "MouseClickedPos", IgnoreType.Property); // manual
Ignore(ctx, "ImGuiIO", "MouseDragMaxDistanceAbs", IgnoreType.Property); // manual

Ignore(ctx, "ImGuiStyle", "Colors", IgnoreType.Property); // manual

Ignore(ctx, "ImNewWrapper", null, IgnoreType.Class); // unused

Expand Down
2 changes: 1 addition & 1 deletion DearImGui.Generator/Passes/ImGuiSummaryPass.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@ public sealed class ImGuiSummaryPass : ImSummaryPass
}
.ToImmutableSortedSet();

protected override string HeaderUrl { get; } = @"https://github.com/ocornut/imgui/blob/9aae45eb4a05a5a1f96be1ef37eb503a12ceb889/imgui.h";
protected override string HeaderUrl { get; } = @"https://github.com/ocornut/imgui/blob/9cd9c2eff99877a3f10a7f9c2a3a5b9c15ea36c6/imgui.h";
}
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,13 @@ private static void DebugProcCallback(

var str = builder.ToString();

throw new InvalidOperationException(str);
if (severity == DebugSeverity.DebugSeverityNotification || severity == DebugSeverity.DebugSeverityLow)
{
Debug.WriteLine(str);
}
else
{
throw new InvalidOperationException(str);
}
}
}
1 change: 1 addition & 0 deletions DearImGui.OpenTK/ImGuiController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -344,6 +344,7 @@ private void InitializeFlags()
IO.BackendFlags |= ImGuiBackendFlags.HasMouseCursors;

IO.ConfigFlags |= ImGuiConfigFlags.NavEnableKeyboard;
IO.ConfigFlags |= ImGuiConfigFlags.DockingEnable;
}

private unsafe void InitializeFont(string? fontPath, float? fontSize)
Expand Down
Loading

0 comments on commit 36b43ba

Please sign in to comment.