8#ifndef GALAXY_UI_IMGUIHELPERS_HPP_
9#define GALAXY_UI_IMGUIHELPERS_HPP_
13#include <imgui/imgui.h>
14#include <SDL3/SDL_events.h>
98 void imgui_confirm(
const char* msg, std::move_only_function<
void(
void)>&& yes = {}, std::move_only_function<void(
void)>&& no = {});
127 bool imgui_imagebutton(const graphics::Texture2D& texture, const ImVec2& size, const ImVec4& bg_col = ImVec4(0, 0, 0, 0), const ImVec4& tint_col = ImVec4(1, 1, 1, 1));
135 void imgui_image(const graphics::Texture2D& texture, const ImVec2& size);
143 void imgui_image(const graphics::RenderTexture& texture, const ImVec2& size);
156 bool imgui_glm_vec2(const char* label, glm::vec2& vec);
167 bool imgui_glm_vec3(const char* label, glm::vec3& vec);
178 bool imgui_glm_vec4(const char* label, glm::vec4& vec);
189 bool imgui_frect(const char* label, math::fRect& rect);
void imgui_notify_error(const char *msg)
ImGui error notification.
ImGuiInputTextFlags imgui_default_flags() noexcept
Get default text input flags.
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_exit()
Destroy imgui context.
void imgui_init(const char *ini)
Initialize ImGui context with galaxy.
void imgui_center_next_window()
Make sure the next window opened is centered on the monitor.
void imgui_notify_success(const char *msg)
ImGui success notification.
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.
void imgui_notify_info(const char *msg)
ImGui info notification.
void imgui_notify_warning(const char *msg)
ImGui warning notification.
void imgui_render()
Render imgui.