← Blog
0.6.0

LCARS Theme: Star Trek UI Primitives + Bitmap Labels in sigilOS

June 22, 2026 · sigil-video · Sigil-Docs
video lumen theme gpu design 0.6.0

lcars_theme.sg ships the LCARS (Library Computer Access/Retrieval System) UI skin for Lumen WM — the Star Trek aesthetic as a fully-integrated sigilOS theme. 7 palette colors, 5 geometry primitives, and bitmap text labels via glyph.sg. Both GPU-first (gpu_submit; silicon-pending) and software-2D fallback paths are present. LCARS-PASS + LCARS-LABEL-PASS on x86. (sigil-video d1faa81, 3b57ba3)

LCARS theme primitives on x86
LCARS theme primitives — panel_header, hbar, elbow, quarter-circle cutout — x86 PASS

The LCARS palette

Commit d1faa81 defines 7 compile-time palette constants via the Lumen theme token system:

TokenRole
lcars_orange()Title bar color — the defining LCARS stripe
lcars_gold()Bottom sidebar section accent
lcars_tan()Panel fill — large content area background
lcars_blue()Section accent
lcars_purple()Secondary accent
lcars_black()Background / corner cutout
lcars_ltblue()Light blue highlight

All values are compile-time constants. The theme token system means Lumen apps reference lcars_orange() symbolically — no magic numbers, no runtime palette lookup.


5 geometry primitives

The LCARS visual language is built from a small set of shapes: filled rectangles, rounded bars, and the signature elbow with its inner corner cutout. lcars_theme.sg delivers all of them:

lcars_fill_rect
lcars_fill_rect(x,y,w,h,color) — rectangle fill. GPU path: gpu_submit rect-fill CAP_ACCEL. Software-2D: fill_span loops.
lcars_fill_circle
lcars_fill_circle(cx,cy,r,color) — solid filled circle for rounded bar caps.
lcars_fill_qcircle_br
lcars_fill_qcircle_br(cx,cy,r,color) — bottom-right quarter-circle for inner corner cutouts. The characteristic "bitten corner" of the LCARS elbow.
lcars_hbar
lcars_hbar(x,y,w,h,color) — horizontal pill bar: rectangle body + left semicircle cap.
lcars_elbow
lcars_elbow(x,y,w,h,color) — L-shaped bar with rounded inner corner cutout. The LCARS signature shape — the structural element that defines the aesthetic.

The lcars_panel_header(x,y,w,fh,hh,sw) function composes these primitives into a full-width header bar with a 3-color sidebar stack: orange top section, tan mid section, gold bottom section.


lcars_label() — bitmap text

Commit 3b57ba3 adds lcars_label(): up to 8 ASCII characters rendered as 8×16 bitmap glyphs in any LCARS palette color.

The implementation uses glyph.sg gch() for 1-bit glyph extraction. GPU path: identical to lcars_fill_rectgpu_submit (silicon-pending bind at kernel integration; no code change needed). Software-2D fallback: gch() MSB-first 1-bit blit, scales with cpuaccel fill_span.

lcars_label bitmap text on x86
lcars_label() — 'LCARS' in orange on tan panel bar, bitmap glyph verify x86 PASS

The label test populates an 'L' atlas (all 16 rows = 0xFF for a fully-lit glyph block), draws a tan panel bar, then renders "LCARS" at coordinates (8, 20) in lcars_orange(). The pixel oracle checks two things:

Result: LCARS-LABEL-PASS glyph=ok bar=ok.


GPU-first pattern

Every primitive follows the standing GPU-first / software-2D-floor rule. GPU path calls gpu_submit with the appropriate CAP_ACCEL command — the silicon bind happens at kernel integration and requires no code change in lcars_theme.sg. The software-2D fallback is always present for the Pi 3 / 1 GB floor. One HAL, two backends.

lcars_fill_rect(x,y,w,h,color)
  ├── GPU path  → gpu_submit(rect-fill, CAP_ACCEL)   # silicon-pending
  └── SW-2D     → fill_span loop (Pi 3 floor)

The same structure applies to lcars_fill_circle, lcars_fill_qcircle_br, lcars_hbar, lcars_elbow, and lcars_label. No primitive is GPU-only; every primitive has a tested software fallback.


LCARS-PASS oracle

The acceptance test runs on a 160×120 framebuffer. lcars_panel_header(hh=20, sw=32) is called, then pixel oracles check 6 zones:

ZoneExpected colorResult
Orange header stripelcars_orange()ok
Tan panel filllcars_tan()ok
Gold sidebar bottomlcars_gold()ok
Blue section accentlcars_blue()ok
Untouched content areabackgroundok
Black quarter-circle corner cutoutlcars_black()ok

All 6 zones verified. LCARS-PASS x86.