Functions | |
| void | imgui_init (const char *ini) |
| Initialize ImGui context with galaxy. | |
| void | imgui_set_theme (const float scale) noexcept |
| Set imgui theme. | |
| void | imgui_handle_events (const SDL_Event &events) |
| Handle events in ImGui. | |
| void | imgui_new_frame () |
| Begin setting up ImGui pass. | |
| void | imgui_render () |
| Render imgui. | |
| void | imgui_exit () |
| Destroy imgui context. | |
| void | imgui_notify_success (const char *msg) |
| ImGui success notification. | |
| void | imgui_notify_info (const char *msg) |
| ImGui info notification. | |
| void | imgui_notify_warning (const char *msg) |
| ImGui warning notification. | |
| void | imgui_notify_error (const char *msg) |
| ImGui error notification. | |
| void | imgui_center_next_window () |
| Make sure the next window opened is centered on the monitor. | |
| void | imgui_confirm (const char *msg, std::move_only_function< void(void)> &&yes={}, std::move_only_function< void(void)> &&no={}) |
| Handles a popup for a yes/no situation. | |
| ImGuiInputTextFlags | imgui_default_flags () noexcept |
| Get default text input flags. | |
| void galaxy::ui::imgui_init | ( | const char * | ini | ) |
Initialize ImGui context with galaxy.
| ini | Layout ini file. Can include a path. |
Definition at line 48 of file ImGuiHelpers.cpp.
|
noexcept |
Set imgui theme.
Need to call when window is resized.
| scale | Display scale factor. |
Definition at line 102 of file ImGuiHelpers.cpp.
| void galaxy::ui::imgui_handle_events | ( | const SDL_Event & | events | ) |
Handle events in ImGui.
| events | Event data. |
Definition at line 173 of file ImGuiHelpers.cpp.
| void galaxy::ui::imgui_new_frame | ( | ) |
Begin setting up ImGui pass.
Definition at line 181 of file ImGuiHelpers.cpp.
| void galaxy::ui::imgui_render | ( | ) |
Render imgui.
Definition at line 191 of file ImGuiHelpers.cpp.
| void galaxy::ui::imgui_exit | ( | ) |
Destroy imgui context.
Definition at line 201 of file ImGuiHelpers.cpp.
| void galaxy::ui::imgui_notify_success | ( | const char * | msg | ) |
ImGui success notification.
| msg | Message to display. |
Definition at line 211 of file ImGuiHelpers.cpp.
| void galaxy::ui::imgui_notify_info | ( | const char * | msg | ) |
ImGui info notification.
| msg | Message to display. |
Definition at line 216 of file ImGuiHelpers.cpp.
| void galaxy::ui::imgui_notify_warning | ( | const char * | msg | ) |
ImGui warning notification.
| msg | Message to display. |
Definition at line 221 of file ImGuiHelpers.cpp.
| void galaxy::ui::imgui_notify_error | ( | const char * | msg | ) |
ImGui error notification.
| msg | Message to display. |
Definition at line 226 of file ImGuiHelpers.cpp.
| void galaxy::ui::imgui_center_next_window | ( | ) |
Make sure the next window opened is centered on the monitor.
Definition at line 231 of file ImGuiHelpers.cpp.
| void galaxy::ui::imgui_confirm | ( | const char * | msg, |
| std::move_only_function< void(void)> && | yes = {}, | ||
| std::move_only_function< void(void)> && | no = {} ) |
Handles a popup for a yes/no situation.
| msg | Text to display on confirmation box. |
| yes | Code to run if user selects yes. |
| no | Code to run if user selects no. |
Definition at line 237 of file ImGuiHelpers.cpp.
|
nodiscardnoexcept |
Get default text input flags.
Definition at line 267 of file ImGuiHelpers.cpp.