Skip to content
This repository has been archived by the owner on Dec 31, 2022. It is now read-only.

Support GetForegroundDrawList #180

Merged
merged 1 commit into from
Jun 18, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions DrawList.go
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,11 @@ func WindowDrawList() DrawList {
return DrawList(C.iggGetWindowDrawList())
}

// ForegroundDrawList returns the DrawList for over all windows.
func ForegroundDrawList() DrawList {
return DrawList(C.iggGetForegroundDrawList())
}

// BackgroundDrawList returns the DrawList for the background behind all windows.
func BackgroundDrawList() DrawList {
return DrawList(C.iggGetBackgroundDrawList())
Expand Down
5 changes: 5 additions & 0 deletions wrapper/DrawList.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,11 @@ IggDrawList iggGetWindowDrawList()
return static_cast<IggDrawList>(const_cast<ImDrawList *>(ImGui::GetWindowDrawList()));
}

IggDrawList iggGetForegroundDrawList()
{
return static_cast<IggDrawList>(const_cast<ImDrawList *>(ImGui::GetForegroundDrawList()));
}

IggDrawList iggGetBackgroundDrawList()
{
return static_cast<IggDrawList>(const_cast<ImDrawList *>(ImGui::GetBackgroundDrawList()));
Expand Down
1 change: 1 addition & 0 deletions wrapper/DrawList.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ extern void iggPushClipRect(IggDrawList handle, IggVec2 const *min, IggVec2 cons
extern void iggPopClipRect(IggDrawList handle);

extern IggDrawList iggGetWindowDrawList();
extern IggDrawList iggGetForegroundDrawList();
extern IggDrawList iggGetBackgroundDrawList();

#ifdef __cplusplus
Expand Down