Theme

ceramic.Entitytracker.Modelelements.Theme (Class)

Comprehensive theme configuration for the elements UI system.

Defines all visual properties including colors, fonts, spacing, and alpha values for various UI components. Themes can be customized per-context or per-component.

Features:

  • Serializable properties for persistence
  • Color tinting for theme variations
  • Cloning for creating theme variants
  • Support for custom fonts

The theme uses a consistent naming scheme:

  • light*: Brightest variants
  • medium*: Mid-tone variants
  • dark*: Darker variants
  • darker*: Darkest variants
See: Context, Model

Instance Members

elements
backgroundInFormLayout: Bool

Whether to show background colors in form layouts


elements
fieldTextColor: ceramic.Color

Color for text in input fields


elements
fieldPlaceholderColor: ceramic.Color

Color for placeholder text in empty fields


elements
lightTextColor: ceramic.Color

Light text color for primary content


elements
mediumTextColor: ceramic.Color

Medium text color for secondary content


elements
darkTextColor: ceramic.Color

Dark text color for tertiary content


elements
darkerTextColor: ceramic.Color

Darker text color for least prominent content


elements
iconColor: ceramic.Color

Default color for icons and glyphs


elements
customMediumFont: ceramic.BitmapFont

Custom medium weight font override


elements
mediumFont: ceramic.BitmapFont

Medium weight font (uses custom or falls back to default)


elements
customBoldFont: ceramic.BitmapFont

Custom bold font override


elements
boldFont: ceramic.BitmapFont

Bold font (uses custom or falls back to default)


elements
lighterBorderColor: ceramic.Color

elements
lightBorderColor: ceramic.Color

elements
mediumBorderColor: ceramic.Color

elements
darkBorderColor: ceramic.Color

elements
lightBackgroundColor: ceramic.Color

elements
mediumBackgroundColor: ceramic.Color

elements
darkBackgroundColor: ceramic.Color

elements
darkerBackgroundColor: ceramic.Color

elements
selectionBorderColor: ceramic.Color

elements
highlightColor: ceramic.Color

elements
highlightPendingColor: ceramic.Color

elements
formItemSpacing: Float

elements
formPadding: Float

elements
tabsMarginY: Float

elements
focusedFieldSelectionColor: ceramic.Color

elements
focusedFieldBorderColor: ceramic.Color

elements
overlayBackgroundColor: ceramic.Color

elements
overlayBackgroundAlpha: Float

elements
overlayBorderColor: ceramic.Color

elements
overlayBorderAlpha: Float

elements
buttonBackgroundColor: ceramic.Color

elements
buttonOverBackgroundColor: ceramic.Color

elements
buttonPressedBackgroundColor: ceramic.Color

elements
buttonFocusedBorderColor: ceramic.Color

elements
tabsBackgroundColor: ceramic.Color

elements
tabsBackgroundAlpha: Float

elements
tabsHoverBackgroundColor: ceramic.Color

elements
tabsHoverBackgroundAlpha: Float

elements
tabsBorderColor: ceramic.Color

elements
disabledTabTextAlpha: Float

elements
disabledTabBorderAlpha: Float

elements
windowBackgroundColor: ceramic.Color

elements
windowBackgroundAlpha: Float

elements
windowBorderColor: ceramic.Color

elements
windowBorderAlpha: Float

elements
invalidateBackgroundInFormLayout(): Void

elements
invalidateFieldTextColor(): Void

elements
invalidateFieldPlaceholderColor(): Void

elements
invalidateLightTextColor(): Void

elements
invalidateMediumTextColor(): Void

elements
invalidateDarkTextColor(): Void

elements
invalidateDarkerTextColor(): Void

elements
invalidateIconColor(): Void

elements
invalidateCustomMediumFont(): Void

elements
invalidateCustomBoldFont(): Void

elements
invalidateLighterBorderColor(): Void

elements
invalidateLightBorderColor(): Void

elements
invalidateMediumBorderColor(): Void

elements
invalidateDarkBorderColor(): Void

elements
invalidateLightBackgroundColor(): Void

elements
invalidateMediumBackgroundColor(): Void

elements
invalidateDarkBackgroundColor(): Void

elements
invalidateDarkerBackgroundColor(): Void

elements
invalidateSelectionBorderColor(): Void

elements
invalidateHighlightColor(): Void

elements
invalidateHighlightPendingColor(): Void

elements
invalidateFormItemSpacing(): Void

elements
invalidateFormPadding(): Void

elements
invalidateTabsMarginY(): Void

elements
invalidateFocusedFieldSelectionColor(): Void

elements
invalidateFocusedFieldBorderColor(): Void

elements
invalidateOverlayBackgroundColor(): Void

elements
invalidateOverlayBackgroundAlpha(): Void

elements
invalidateOverlayBorderColor(): Void

elements
invalidateOverlayBorderAlpha(): Void

elements
invalidateButtonBackgroundColor(): Void

elements
invalidateButtonOverBackgroundColor(): Void

elements
invalidateButtonPressedBackgroundColor(): Void

elements
invalidateButtonFocusedBorderColor(): Void

elements
invalidateTabsBackgroundColor(): Void

elements
invalidateTabsBackgroundAlpha(): Void

elements
invalidateTabsHoverBackgroundColor(): Void

elements
invalidateTabsHoverBackgroundAlpha(): Void

elements
invalidateTabsBorderColor(): Void

elements
invalidateDisabledTabTextAlpha(): Void

elements
invalidateDisabledTabBorderAlpha(): Void

elements
invalidateWindowBackgroundColor(): Void

elements
invalidateWindowBackgroundAlpha(): Void

elements
invalidateWindowBorderColor(): Void

elements
invalidateWindowBorderAlpha(): Void

elements
clone(?toTheme: Theme): Theme

Creates a deep copy of this theme.

Name Type Default Description
toTheme Theme (optional) Optional theme instance to copy into (creates new if null)
Returns Description
Theme The cloned theme

elements
applyTint(?baseTheme: Theme, tint: ceramic.Color): Void

Apply the given tint color using baseTheme as lightness references.

Recolors most theme elements while preserving relative brightness relationships. Selection and highlight colors are not affected (use applyAltTint for those).

Name Type Default Description
baseTheme Theme (optional) Base theme to derive lightness values from (defaults to context theme)
tint ceramic.Color Color to tint the theme with (uses HSLuv color space)

elements
applyAltTint(?baseTheme: Theme, tint: ceramic.Color): Void

Apply the given alt tint color using baseTheme as lightness references.

Specifically tints selection, highlight, and focus colors. Use this for accent color customization.

Name Type Default Description
baseTheme Theme (optional) Base theme to derive lightness values from (defaults to context theme)
tint ceramic.Color Accent color to apply (uses HSLuv color space)

elements
applyBackgroundColor(color: ceramic.Color): Void

Sets the background color for tabs and windows.

Name Type Description
color ceramic.Color The background color to apply

elements
applyTextColor(color: ceramic.Color): Void

Sets all text color variants to the same color. Useful for high contrast or monochrome themes.

Name Type Description
color ceramic.Color The text color to apply to all variants

elements
new(): Void

Creates a new Theme with default dark color scheme.

Private Members

elements
unobservedBackgroundInFormLayout: Bool

elements
unobservedFieldTextColor: ceramic.Color

elements
unobservedFieldPlaceholderColor: ceramic.Color

elements
unobservedLightTextColor: ceramic.Color

elements
unobservedMediumTextColor: ceramic.Color

elements
unobservedDarkTextColor: ceramic.Color

elements
unobservedDarkerTextColor: ceramic.Color

elements
unobservedIconColor: ceramic.Color

elements
unobservedCustomMediumFont: ceramic.BitmapFont

elements
unobservedCustomBoldFont: ceramic.BitmapFont

elements
unobservedLighterBorderColor: ceramic.Color

elements
unobservedLightBorderColor: ceramic.Color

elements
unobservedMediumBorderColor: ceramic.Color

elements
unobservedDarkBorderColor: ceramic.Color

elements
unobservedLightBackgroundColor: ceramic.Color

elements
unobservedMediumBackgroundColor: ceramic.Color

elements
unobservedDarkBackgroundColor: ceramic.Color

elements
unobservedDarkerBackgroundColor: ceramic.Color

elements
unobservedSelectionBorderColor: ceramic.Color

elements
unobservedHighlightColor: ceramic.Color

elements
unobservedHighlightPendingColor: ceramic.Color

elements
unobservedFormItemSpacing: Float

elements
unobservedFormPadding: Float

elements
unobservedTabsMarginY: Float

elements
unobservedFocusedFieldSelectionColor: ceramic.Color

elements
unobservedFocusedFieldBorderColor: ceramic.Color

elements
unobservedOverlayBackgroundColor: ceramic.Color

elements
unobservedOverlayBackgroundAlpha: Float

elements
unobservedOverlayBorderColor: ceramic.Color

elements
unobservedOverlayBorderAlpha: Float

elements
unobservedButtonBackgroundColor: ceramic.Color

elements
unobservedButtonOverBackgroundColor: ceramic.Color

elements
unobservedButtonPressedBackgroundColor: ceramic.Color

elements
unobservedButtonFocusedBorderColor: ceramic.Color

elements
unobservedTabsBackgroundColor: ceramic.Color

elements
unobservedTabsBackgroundAlpha: Float

elements
unobservedTabsHoverBackgroundColor: ceramic.Color

elements
unobservedTabsHoverBackgroundAlpha: Float

elements
unobservedTabsBorderColor: ceramic.Color

elements
unobservedDisabledTabTextAlpha: Float

elements
unobservedDisabledTabBorderAlpha: Float

elements
unobservedWindowBackgroundColor: ceramic.Color

elements
unobservedWindowBackgroundAlpha: Float

elements
unobservedWindowBorderColor: ceramic.Color

elements
unobservedWindowBorderAlpha: Float

elements
emitBackgroundInFormLayoutChange(current: Bool, previous: Bool): Void

Event when backgroundInFormLayout field changes.

Name Type
current Bool
previous Bool

elements
emitFieldTextColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when fieldTextColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitFieldPlaceholderColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when fieldPlaceholderColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitLightTextColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when lightTextColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitMediumTextColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when mediumTextColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitDarkTextColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when darkTextColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitDarkerTextColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when darkerTextColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitIconColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when iconColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitCustomMediumFontChange(current: ceramic.BitmapFont, previous: ceramic.BitmapFont): Void

Event when customMediumFont field changes.

Name Type
current ceramic.BitmapFont
previous ceramic.BitmapFont

elements
emitCustomBoldFontChange(current: ceramic.BitmapFont, previous: ceramic.BitmapFont): Void

Event when customBoldFont field changes.

Name Type
current ceramic.BitmapFont
previous ceramic.BitmapFont

elements
emitLighterBorderColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when lighterBorderColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitLightBorderColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when lightBorderColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitMediumBorderColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when mediumBorderColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitDarkBorderColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when darkBorderColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitLightBackgroundColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when lightBackgroundColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitMediumBackgroundColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when mediumBackgroundColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitDarkBackgroundColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when darkBackgroundColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitDarkerBackgroundColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when darkerBackgroundColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitSelectionBorderColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when selectionBorderColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitHighlightColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when highlightColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitHighlightPendingColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when highlightPendingColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitFormItemSpacingChange(current: Float, previous: Float): Void

Event when formItemSpacing field changes.

Name Type
current Float
previous Float

elements
emitFormPaddingChange(current: Float, previous: Float): Void

Event when formPadding field changes.

Name Type
current Float
previous Float

elements
emitTabsMarginYChange(current: Float, previous: Float): Void

Event when tabsMarginY field changes.

Name Type
current Float
previous Float

elements
emitFocusedFieldSelectionColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when focusedFieldSelectionColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitFocusedFieldBorderColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when focusedFieldBorderColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitOverlayBackgroundColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when overlayBackgroundColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitOverlayBackgroundAlphaChange(current: Float, previous: Float): Void

Event when overlayBackgroundAlpha field changes.

Name Type
current Float
previous Float

elements
emitOverlayBorderColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when overlayBorderColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitOverlayBorderAlphaChange(current: Float, previous: Float): Void

Event when overlayBorderAlpha field changes.

Name Type
current Float
previous Float

elements
emitButtonBackgroundColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when buttonBackgroundColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitButtonOverBackgroundColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when buttonOverBackgroundColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitButtonPressedBackgroundColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when buttonPressedBackgroundColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitButtonFocusedBorderColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when buttonFocusedBorderColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitTabsBackgroundColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when tabsBackgroundColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitTabsBackgroundAlphaChange(current: Float, previous: Float): Void

Event when tabsBackgroundAlpha field changes.

Name Type
current Float
previous Float

elements
emitTabsHoverBackgroundColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when tabsHoverBackgroundColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitTabsHoverBackgroundAlphaChange(current: Float, previous: Float): Void

Event when tabsHoverBackgroundAlpha field changes.

Name Type
current Float
previous Float

elements
emitTabsBorderColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when tabsBorderColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitDisabledTabTextAlphaChange(current: Float, previous: Float): Void

Event when disabledTabTextAlpha field changes.

Name Type
current Float
previous Float

elements
emitDisabledTabBorderAlphaChange(current: Float, previous: Float): Void

Event when disabledTabBorderAlpha field changes.

Name Type
current Float
previous Float

elements
emitWindowBackgroundColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when windowBackgroundColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitWindowBackgroundAlphaChange(current: Float, previous: Float): Void

Event when windowBackgroundAlpha field changes.

Name Type
current Float
previous Float

elements
emitWindowBorderColorChange(current: ceramic.Color, previous: ceramic.Color): Void

Event when windowBorderColor field changes.

Name Type
current ceramic.Color
previous ceramic.Color

elements
emitWindowBorderAlphaChange(current: Float, previous: Float): Void

Event when windowBorderAlpha field changes.

Name Type
current Float
previous Float

Metadata

Name Parameters
:build tracker.macros.EventsMacro.build()
:autoBuild tracker.macros.EventsMacro.build()
:build ceramic.macros.EntityMacro.buildForCompletion()
:autoBuild ceramic.macros.EntityMacro.buildForCompletion()
:build tracker.macros.ObservableMacro.build()
:autoBuild tracker.macros.ObservableMacro.build()
:build tracker.macros.SerializableMacro.build()
:autoBuild tracker.macros.SerializableMacro.build()