Class ColorSettings
The color settings class
Inheritance
Namespace: Terminaux.Colors
Assembly: Terminaux.dll
Syntax
public class ColorSettings
Constructors
| Edit this page View SourceColorSettings()
Makes a new instance of color settings
Declaration
public ColorSettings()
ColorSettings(ColorSettings)
Makes a new instance of color settings
Declaration
public ColorSettings(ColorSettings settings)
Parameters
Type | Name | Description |
---|---|---|
ColorSettings | settings | Settings instance to copy the color configuration from |
Properties
| Edit this page View SourceColorBlindnessSeverity
The color blindness severity (Only for color blindness formulas):
Declaration
public double ColorBlindnessSeverity { get; set; }
Property Value
Type | Description |
---|---|
double |
ColorTransformationFormula
The color transformation formula to use when generating transformed colors, such as color blindness.
Declaration
public TransformationFormula ColorTransformationFormula { get; set; }
Property Value
Type | Description |
---|---|
TransformationFormula |
EnableColorTransformation
Enables the color transformation to adjust to color blindness upon making a new instance of color
Declaration
public bool EnableColorTransformation { get; set; }
Property Value
Type | Description |
---|---|
bool |
Opacity
The opacity at which the color will be calculated.
Declaration
public int Opacity { get; set; }
Property Value
Type | Description |
---|---|
int |
Remarks
This fades the color to the current background color of the console currently set by
SetConsoleColor(Color, bool, bool, bool). That color can be overridable by
setting the OpacityColor property to any color you want. Set it to 0, and you'll get the
color that is the same as the value of the OpacityColor property. Set it to 255, and you'll
get the color that you've created using the Color(int, int, int, ColorSettings) constructor
and its siblings.
This is still fake transparency for GUI applications, but should behave like real transparency in console
applications that use background colors.
OpacityColor
The opacity color to fade the new instances of colors to using the opacity as the threshold.
Declaration
public Color OpacityColor { get; set; }
Property Value
Type | Description |
---|---|
Color |
Remarks
See the Remarks section of Opacity for more info about how we use this color to calculate the transparency.
UseTerminalPalette
If enabled, calls to PlainSequence and its siblings return color ID if said color is either a 256 color or a 16 color. Otherwise, calls to these properties are wrappers to PlainSequenceTrueColor and its siblings. By default, it's enabled.
Declaration
public bool UseTerminalPalette { get; set; }
Property Value
Type | Description |
---|---|
bool |