Struct ScrollbarPaletteRequest
- Namespace
- SharpConsoleUI.Helpers.Scrollbar
- Assembly
- SharpConsoleUI.dll
The inputs to Resolve(ScrollbarPaletteRequest): everything the shared colour cascade needs to pick a scrollbar's thumb and track colours.
public readonly record struct ScrollbarPaletteRequest : IEquatable<ScrollbarPaletteRequest>
- Implements
- Inherited Members
- Extension Methods
Constructors
ScrollbarPaletteRequest(Color?, Color?, ITheme?, bool, bool, Color, bool)
The inputs to Resolve(ScrollbarPaletteRequest): everything the shared colour cascade needs to pick a scrollbar's thumb and track colours.
public ScrollbarPaletteRequest(Color? ThumbOverride, Color? TrackOverride, ITheme? Theme, bool HasFocus, bool IsEnabled, Color Background, bool UseTableThemeKeys = false)
Parameters
ThumbOverrideColor?An explicit per-instance thumb colour, if the control was given one. Wins outright.
TrackOverrideColor?An explicit per-instance track colour, if the control was given one. Wins outright.
ThemeIThemeThe active theme, or
nullif none is available.HasFocusboolWhether the scrollable control currently has focus.
IsEnabledboolWhether the scrollable control is enabled. A disabled bar dims to its unfocused colours.
BackgroundColorThe cell background every scrollbar cell paints with.
UseTableThemeKeysboolWhen
true, reads TableScrollbarThumbColor/TableScrollbarTrackColor instead of the general ScrollbarThumbColor family. Table themes its bars independently of every other scrollable control; those two keys have no unfocused variants.
Properties
Background
The cell background every scrollbar cell paints with.
public Color Background { get; init; }
Property Value
HasFocus
Whether the scrollable control currently has focus.
public bool HasFocus { get; init; }
Property Value
IsEnabled
Whether the scrollable control is enabled. A disabled bar dims to its unfocused colours.
public bool IsEnabled { get; init; }
Property Value
Theme
The active theme, or null if none is available.
public ITheme? Theme { get; init; }
Property Value
ThumbOverride
An explicit per-instance thumb colour, if the control was given one. Wins outright.
public Color? ThumbOverride { get; init; }
Property Value
TrackOverride
An explicit per-instance track colour, if the control was given one. Wins outright.
public Color? TrackOverride { get; init; }
Property Value
UseTableThemeKeys
When true, reads TableScrollbarThumbColor/TableScrollbarTrackColor
instead of the general ScrollbarThumbColor family. Table themes its bars
independently of every other scrollable control; those two keys have no unfocused variants.
public bool UseTableThemeKeys { get; init; }