IGlyphSet
ConsoleMonster.Glyphs
Resolves semantic glyphs for one tier. Implement it for a custom set, or wrap a built-in one.
Usage
Explore 12 API references to this type
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by 1
- Property RenderContext.Glyphs
Accepted by parameters 11
- Constructor RenderContext.RenderContext
- Method GlyphSetExtensions.Icon
- Method GlyphSetExtensions.StatusSymbol
- Extension method IGlyphSet.Icon
- Extension method IGlyphSet.StatusSymbol
- Method MenuItem.IconText
- Method TestRunText.FailureLine
- Method TestRunText.Heartbeat
- Method TestRunText.Path
- Method TestRunText.SummaryLine
- Method TestRunText.Totals
Methods
public abstract string Get(Glyph glyph) #Returns a semantic glyph.
Parameters
- glyph ConsoleMonster.Glyphs.Glyph
- The glyph name.
Returns
string The text (may be wider than one cell, for example tree prefixes or ASCII ellipsis).public abstract BoxGlyphs GetBox(BoxStyle style) #Returns border glyphs, falling back to a style the tier can show.
Parameters
- style ConsoleMonster.Glyphs.BoxStyle
- The requested style.
public abstract string HorizontalFill(int eighths) #A partial horizontal block for eighths of a cell (1-8), or empty when the tier cannot show it.
Parameters
- eighths int
- Filled eighths, 1-8.
Returns
string The glyph, or an empty string.public abstract string StatusMarker(StatusKind status) #The marker shown for a status. Full and Basic return one symbol; Ascii returns a bracketed word such as [OK] so status stays readable without colour.
Parameters
- status ConsoleMonster.Styling.StatusKind
- The status.
Returns
string The marker text.public abstract string VerticalFill(int eighths) #A partial vertical block for eighths of a cell (1-8), or empty when the tier cannot show it.
Parameters
- eighths int
- Filled eighths, 1-8.
Returns
string The glyph, or an empty string.Properties
public abstract GlyphTier Tier { get; } #The tier this set targets.
public abstract bool SupportsBraille { get; } #Whether braille patterns (U+2800-U+28FF) render reliably.
public abstract bool SupportsHalfBlocks { get; } #Whether half blocks (▀▄) render reliably.
public abstract IReadOnlyList<string> SpinnerFrames { get; } #Spinner animation frames.
public abstract IReadOnlyList<string> VerticalRamp { get; } #Vertical levels from empty (index 0) to full (last index), used by sparklines.
Extension Methods
public static string Icon(IGlyphSet glyphs, Icon icon) #The text of an icon catalog key in the glyph set's tier (see Icons). Custom glyph sets resolve by their IGlyphSet.Tier; the status icons (warning, done) use the set's own symbols. A key from another pack (pack:name) is looked up by its name; an unknown key draws the item mark.
Parameters
- glyphs ConsoleMonster.Glyphs.IGlyphSet
- The glyph set.
- icon ConsoleMonster.Icon
- The icon.
Returns
string One cell of text.public static string StatusSymbol(IGlyphSet glyphs, StatusKind status) #The one-cell symbol of a status in the glyph set's tier: ✓ ✗ ▲ – ● ○ ◆ ‼ ? Ø (Full), the same in Basic, + x ! - * . i E ? / (ASCII). IGlyphSet.StatusMarker is the wider marker for status columns (bracketed words in ASCII).
Parameters
- glyphs ConsoleMonster.Glyphs.IGlyphSet
- The glyph set.
- status ConsoleMonster.Styling.StatusKind
- The status.
Returns
string The symbol.