From 992e4dfca033049d2099e10f2b75310f5ce3b8be Mon Sep 17 00:00:00 2001 From: scawful Date: Sun, 26 Nov 2023 16:49:32 -0500 Subject: [PATCH] add HOVER_HINT macro --- src/app/core/constants.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/app/core/constants.h b/src/app/core/constants.h index d10adce2..0016dab3 100644 --- a/src/app/core/constants.h +++ b/src/app/core/constants.h @@ -48,6 +48,9 @@ ImGui::EndTable(); \ } +#define HOVER_HINT(string) \ + if (ImGui::IsItemHovered()) ImGui::SetTooltip(string); + #define PRINT_IF_ERROR(expression) \ { \ auto error = expression; \