Browse Source

Wrap tooltip text

master
Macoy Madson 6 months ago
parent
commit
591d4ae34a
  1. 3
      src/ImGui.cake

3
src/ImGui.cake

@ -18,7 +18,8 @@
(defun imgui-do-tooltip (text (* (const char)) shortcut (* (const char)))
(when (imgui-call IsItemHovered)
(imgui-call BeginTooltip)
(imgui-call Text "%s" text)
(imgui-call PushTextWrapPos (* (imgui-call GetFontSize) 35.0f))
(imgui-call TextWrapped "%s" text)
(when shortcut
(imgui-call TextDisabled "%s" shortcut))
(imgui-call EndTooltip)))

Loading…
Cancel
Save