Repository navigation
The Look Model
Brian Jr edited this page Nov 17, 2026
·
2 revisions
A Look is four small things plus optional art:
| Piece | File | What it is |
|---|---|---|
| Enum value |
app/.../ui/theme/LookStyle.kt → TccUiLook
|
The Look's id + display name |
| Spec |
app/.../ui/theme/TccLookSpec.kt → <Name>LookSpec + specForLook()
|
Shapes, fonts, and which style each part uses |
| Colors |
app/.../ui/theme/TccLookColors.kt → resolveLookColors()
|
Per-Look colors derived from the active palette |
| Fonts (optional) |
app/src/main/res/font/tcc_*.ttf + ui/theme/TccFonts.kt
|
Bundled OFL fonts |
| Renderers (only for a new visual style) | app/.../ui/components/looks/<Name>Renderers.kt |
Custom drawing for cards/tiles/gauges/sliders/nav |
The LookTraits inside a spec pick one value from each style enum:
-
CardStyle,TileStyle,GaugeStyle,SliderStyle,NavStyle,BackdropStyle,HeaderStyle
Each enum value maps (in ui/components/looks/LookRenderers.kt, via the .renderer() when blocks) to a renderer object. The first few values are shared BuiltIn*Renderers; every other value belongs to one Look's *Renderers.kt.
-
Level 1 — Remix existing styles (recommended, ~1 file of real work). Compose a new Look purely from style values that already exist (e.g.
CardStyle.GLASS+TileStyle.NEON+GaugeStyle.RING+ a bundled font + new colors). No rendering code — just enum + spec + colors. Most "new themes" are this. -
Level 2 — New visual style (advanced). Invent a new card/tile/gauge/slider/nav look. Add an enum value to the relevant style enum, write a renderer object implementing the interface, and wire it into the
.renderer()when. The Kotlin compiler forces you to handle the new value (exhaustivewhen), which is a helpful checklist.
The companion's Themes section has a Theme Studio that builds looks on the device with no code, so reach for it before adding a built-in Look. If you change the Look system, read Theme Studio first: it covers how user looks are stored and what has to stay in sync (the CUSTOM styles, CustomLook, and the pack format).
Next: Quick Start: Level 1