Namespace ItTiger.TigerCli.Rendering
Classes
- CliDetails
- App-facing convenience builder for one-record key/value detail views ("Name: value" panels).
It removes the manual, error-prone pattern of keeping a parallel header (labels) and record
(values) in sync, of hiding optional fields, and of formatting missing values by hand.
CliDetails is a builder, not a new rendering engine: it converts to a CliTable (via ToTable()) and renders through the existing CliTable → CliGrid pipeline. A detail view is always horizontal — header captions become row labels and the single record becomes the value column — so ToTable() forces Horizontal regardless of the applied preset. The default preset is Details.
Use CliDetails for a single record shown as labelled fields. Use CliTable when you have many records, columnar/tabular data, or need full control over header/record construction.
- CliFrameArea
- Describes a rectangular frame region owned by a CliGrid.
- CliGrid
- Lower-level grid layout and rendering building block used by tables, detail/list builders, and TUI widgets. Most command output should start with CliList<T>, CliDetails, or CliTable; create a CliGrid directly when building custom renderables, composite layouts, or widgets.
- CliList<T>
- App-facing convenience builder for list command output: a column-per-field, record-per-item table.
It removes the manual, error-prone pattern of rendering list headings, spacing, indentation, loops,
and per-column formatting by hand with MarkupLine(string).
CliList<T> is a builder, not a new rendering engine: Render(IEnumerable<T>) projects the items into a CliTable (one header element per column, one record per item) and rendering goes through the existing CliTable → CliGrid pipeline. Columns may carry a semantic ThemeStyle applied to the column's values — use AddKeyColumn(string, Func<T, object?>) for identity/anchor values (Key) and AddPathColumn(string, Func<T, object?>) for path values (Path).
Use CliList<T> for list output, CliDetails for single-record show/details output, and CliTable directly only when lower-level table control is needed.
- CliOverlayRenderers
- Reusable CliOverlayRenderer factories for the common one-dimensional overlays
(vertical scrollbar, horizontal scroll indicators, time-/state-driven text such as a spinner or
clock). The renderers read only the already-measured CliGrid (scroll info) or a
caller-supplied content provider; they own no placement, measurement, or style. Callers (e.g.
InlineDialog) keep ownership of where each overlay is placed and what style it uses, and add the resulting CliOverlay through AddOverlay(CliOverlay) as before.
- CliRenderBuffer
- Low-level dirty-cell console render buffer used by interactive rendering paths.
- CliRenderableComponent
- Base class for renderable components that share layout constraints and convert to a CliGrid for output.
- CliTable
- App-facing convenience API for CliTable: theme-driven defaults plus terse header and record construction. These methods sit on top of the existing Header, Records, FrameConfig, and Orientation members and do not introduce a separate rendering or theming path — table looks come from ITheme.
- CliTableElement
- Describes a single table element (column in Vertical, row in Horizontal). Styling is expressed via CliCellStyle and resolved by the grid's style cascade (grid defaults → axis styles → section defaults → per-cell).
- CliTableHeader
- Represents the header of a CLI table, including visibility and structural elements.
- CliTableStyleRecipe
- A colour-free table style "recipe": the structural and role-based definition of a table preset
(frame configuration, padding, surface role, and title/frame accent roles). A recipe does not
hard-code colours — it references theme roles and surfaces and resolves to a concrete
CliTableStyle through an ITheme.
The built-in "city" recipes are exposed as static properties (e.g. Roma). Because this is a
record, callers can derive their own from a city recipe with awithexpression, then resolve it:public static readonly CliTableStyleRecipe InvoiceRecipe = CliTableStyleRecipe.Roma with { Surface = SurfaceRole.Panel, TitleAccent = TableAccent.Success }; // ... table.ApplyStyle(InvoiceRecipe.Resolve(theme));Table styles never use DialogSurface. An elevated table surface comes from Panel; dialogs/controls keep their own
DialogSurface.
- CliTableStyles
- Convenience facade over the predefined table style presets. CliTableStylePreset is
the source of truth: aliases canonicalize to city presets, and each city preset maps to a
CliTableStyleRecipe. Every factory resolves a recipe through an ITheme
(the CurrentTheme by default) and returns a fresh, fully-resolved
CliTableStyle that can be applied with ApplyStyle(CliTableStyle).
These are presets, not a separate styling system: a recipe defines structure and theme roles only, and the active theme supplies the colours. The result is a plain CliTableStyle, so callers keep full customization freedom afterwards. For a custom preset, derive a CliTableStyleRecipe with a
withexpression and resolve it directly.String-based overloads are a name boundary only (config/plugins/help): they parse to a CliTableStylePreset and delegate to the enum-based methods.
- CliTableTitle
- Title content and style used by CliTable when materializing a table.
Interfaces
- ICliRenderable
- Represents a component that can materialize itself as a CliGrid for measurement and rendering.
Enums
- CliOverlayEdge
- Which edge a horizontal scroll indicator sits on.