Skip to main content

ui Folder

Folders Index

folderbinding
foldercommands
folderlayout
foldertransform
folderwidgets

Files Index

filehelios/engine/modules/ui/_module.ixx

Module facade for UI components and systems. More...

filemodules/ui/registry.ixx

Component registration for entire UI module. More...

fileUiActionCommandHandler.ixx

Interface for UI action command handlers. More...

fileUiActionCommandManager.ixx

Manager for processing UI action commands. More...

Description

helios::engine::modules::ui

User interface components and systems for game entities.

This module provides components and systems for creating and managing UI elements within the helios engine. It supports viewport-relative positioning, text rendering, menus, and data binding between game state and UI components.

Submodules

SubmodulePurpose
binding/Systems for binding game data to UI components
commands/UI action commands and dispatchers
layout/Layout primitives such as anchors and alignment
transform/UI-specific transform components and positioning systems
widgets/UI widget components (menus, text, etc.) and related systems

Key Classes

ClassPurpose
AnchorEnum defining anchor points for UI positioning
UiTransformComponentViewport-relative positioning with anchor and margin support
UiTransformSystemComputes UI element positions based on viewport and anchor
MenuComponentManages menu items and selection state
UiTextComponentText display with template-based formatting
UiStateComponentTracks interaction states (selected, hovered, focused)
UiStyleComponentDefines colors and scales for different states
UiFocusComponentTracks the currently focused UI entity
UiActionComponentAssociates actions with UI elements
UiActionCommandCommand for triggering UI actions
UiActionCommandManagerProcesses UI action commands with policy-based dispatch
MenuNavigationSystemHandles gamepad input for menu navigation
UiStyleUpdateSystemApplies styles based on interaction state
UiTextBoundsUpdateSystemUpdates AABB bounds when text content changes
Score2UiTextUpdateSystemBinds score data to UI text components

Architecture

The UI module follows the ECS pattern used throughout helios:

1. Components store UI-specific state (anchors, offsets, text content, interaction state) 2. Systems process components each frame to update positions, styling, and content 3. Commands handle UI actions (button presses, menu selections) 4. Bindings connect game state (e.g., scores) to UI widgets

UI elements are positioned relative to viewports using anchors and offsets, allowing for resolution-independent layouts.



Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.15.0.