Phosphor::Theme
Maps semantic names to Style values, so widgets ask for :accent or
:error rather than hardcoding colors — the same widget renders
correctly whether an app uses phosphor's built-in look or a custom one.
Widget#sync is the only place that calls app.theme — MockWidget
never touches it directly, keeping mocks publishable independent of any
app's color choices.
See DESIGN.md § "Style and Theme" for the full rationale.
Constants
The built-in theme. Every color uses AdaptiveColor so it looks
correct on both dark terminals (the common case) and light terminals
(VS Code's default, many macOS users) without any configuration.
Constructors
Instance methods
Fetches the Style registered for name. Raises KeyError naming the
missing key if name isn't set — use #[]? for a safe lookup instead.
Fetches the Style registered for name, or nil if it isn't set.
Style applied to a bordered widget/screen's border when it does not
hold focus — dimmer than #focus_border_style, so unfocused panels
recede visually.
The set of box-drawing characters Border draws with. Defaults to
BorderStyle::SQUARE; pass a different predefined style (or a custom
one) at construction time to change every bordered widget/screen in
the app at once.
Style applied to a bordered widget/screen's border when it holds
focus — a lighter gray than #blur_border_style so the focused panel
reads as "active" without resorting to a jarring accent color.
Returns a new Theme with overrides layered on top of this one —
keys in overrides replace this theme's value for that key; every
other key keeps its current value. border_style, focus_border_style,
and blur_border_style follow the same rule: pass a value to override
it, or omit it (leave nil) to carry forward this theme's current
value. Does not mutate self.