Hide
Overview
Section titled “Overview”Hides a visible PrismaView. This method sets the view’s visibility flag to prevent it from being rendered, while preserving its state and resources. If the view has focus when hidden, it will be automatically unfocused.
Syntax
Section titled “Syntax”void Hide(PrismaView view);Parameters
Section titled “Parameters”view (required)
Section titled “view (required)”- Type:
PrismaView - Description: The
PrismaViewto hide
Return Value
Section titled “Return Value”This method returns void.
Usage Examples
Section titled “Usage Examples”// Hide a visible viewPrismaUI->Hide(view);Behavior Details
Section titled “Behavior Details”- Sets the
isHiddenflag totrue - View stops rendering immediately
- View stops processing input events
- If view has focus, automatically calls
Unfocus:- Unpauses the game (if paused by
Focus) - Disables input capture
- Closes focus menu
- Restores game control
- Unpauses the game (if paused by
- View state and content are preserved
Best Practices
Section titled “Best Practices”- Temporary Hiding: Use for UI that will be shown again
- State Preservation: Hidden views keep their state and content
- Focus Awareness: Remember that hiding automatically unfocuses
- Performance: More efficient than destroying and recreating views
- Pair with Show: Use
Showto make hidden views visible again