Skip to content
ConsoleMonster

API Reference

Struct

ThemeStyle

Namespace ConsoleMonster.Styling
Assembly ConsoleMonster
Base ValueType
Modifiers sealed

The definition of one theme token: optional foreground and background theme colours plus decorations.

Inheritance

  • ValueType
  • ThemeStyle

Usage

Explore 3 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

Accepted by parameters 2

Constructors

public ThemeStyle(ThemeColor? foreground, ThemeColor? background = null, TextDecoration decoration = None) #

Creates a theme style.

Parameters

foreground ConsoleMonster.Styling.ThemeColor? requiredposition: 0
Foreground, or null for the terminal default.
background ConsoleMonster.Styling.ThemeColor? = null optionalposition: 1
Background, or null for the terminal default.
decoration ConsoleMonster.Styling.TextDecoration = None optionalposition: 2
Decorations.

Methods

public Style Resolve(ColorDepth depth) #
Returns: Style

Resolves to a concrete style for a colour depth.

Parameters

depth ConsoleMonster.Capabilities.ColorDepth requiredposition: 0
The depth.

Returns

The style.

Properties

public ThemeColor? Foreground { get; } #

Foreground, or null for the terminal default.

public ThemeColor? Background { get; } #

Background, or null for the terminal default.

public TextDecoration Decoration { get; } #

Decorations.