Mountea-Framework/MounteaInventoryEquipment

UI Content Theme

pavlicekdominik opened this issue · 0 comments

UI Content Theme

Purpose: The UI Content Theme provides specific styling options for individual UI elements or groups of elements. This allows for fine-tuning and distinctive styles for particular types of content (e.g., different button styles for different actions).

Class: UUIContentTheme (extends UDataAsset)

Properties and Methods:

Each subclass of UUIContentTheme will define properties and potentially methods relevant to the UI element it styles. Examples include:

  • UButtonTheme:

    • NormalStateStyle: FButtonStyle - Defines the button's appearance.
  • UFontTheme:

    • PrimaryFontStyle: FTextStyle - Defines the style for headers.
    • SecondaryFontStyle: FTextStyle - Defines the style for body text.
  • UColorTheme:

    • PrimaryColorSet: FLinearColor - Defines primary colors for certain UI elements or content types.
    • SecondaryColorSet: FLinearColor - Defines secondary colors for accenting or contrast.
    • TertiaryColorSet: FLinearColor - Defines tertiary colors for accenting or contrast.
    • QuaternaryColorSet: FLinearColor - Defines quaternary colors for accenting or contrast.
  • UCategoryTheme: (Subclass of UButtonTheme)

    • Tailored specifically for categorizing items or actions within the UI.
    • CategoryBrush: FSlateBrush
      • for category icons, ensuring flexible visual representation.

Theme Inheritance and Override Mechanism:

  • Inheritance: UI elements would by default reference the parent's theme. This ensures consistency and reduces the need to set a theme for each element manually.

  • Override: UI elements can optionally reference a specific UUIContentTheme to override the inherited theme for customization.

Example:

An inventory screen could use the global UUITheme, but individual elements like rare item slots or special action buttons could use their respective UUIContentTheme to stand out, reflecting their importance or uniqueness.