Skip to main content

Module ui_primitives

Module ui_primitives 

Source
Expand description

High-level UI primitive drawing functions.

These convenience functions wrap UiLayer to provide common UI patterns: stat displays, combat HUD, menus, status bars, labeled panels, etc.

Structs§

UiColors
Common UI color palette.

Functions§

draw_combat_log
Draw a combat log panel with scrolling text lines.
draw_floating_damage
Draw a damage number floating up from a position.
draw_fps_overlay
Draw FPS and frame stats in the top-right corner.
draw_hp_bar
Draw an HP bar with label.
draw_menu
Draw a menu with a list of options, highlighting the selected one.
draw_mp_bar
Draw an MP bar with label.
draw_notification
Draw a notification banner centered at the top of the screen.
draw_separator
Draw a horizontal separator line.
draw_stamina_bar
Draw a stamina bar with label.
draw_stat_line
Draw a stat line: “Label: Value” with colored value.
draw_stat_line_justified
Draw a key-value pair right-aligned within a given width.
draw_titled_panel
Draw a labeled panel with a title in the top border.
draw_tooltip
Draw a tooltip box near (x, y) with text content.
draw_xp_bar
Draw an XP bar with label.