class
Sheen::Renderer
- Sheen::Renderer
- Reference
- Object
Overview
Terminal renderer holding the color profile and background darkness used to resolve and downsample colors at render time. Inspired by lipglossv1's Renderer.
Defined in:
sheen/renderer.crConstructors
Instance Method Summary
-
#color_profile : Foundation::Profile
The color profile, detected from @output on first use, if not already set explicitly.
-
#color_profile=(profile : Foundation::Profile) : Foundation::Profile
Bypasses detection and sets the color profile explicitly, primarily used for testing
- #env : Foundation::Env
- #env=(env : Foundation::Env)
-
#has_dark_background=(value : Bool) : Bool
Forces background darkness value to value
-
#has_dark_background? : Bool
Detects if the terminal background is dark, caching the result on first read.
- #input : IO
- #input=(input : IO)
-
#output : IO
The output the profile is detected from and that rendering targets.
-
#output=(output : IO)
The output the profile is detected from and that rendering targets.
Constructor Detail
Instance Method Detail
The color profile, detected from @output on first use, if not already set explicitly.
Bypasses detection and sets the color profile explicitly, primarily used for testing
Detects if the terminal background is dark, caching the result on first read.
An explicit #has_dark_background= always wins over implicit detection.