ParseOptionsUseErrorColor Property

Gets or sets a value that indicates whether error messages should use color.

Definition

Namespace: Ookii.CommandLine
Assembly: Ookii.CommandLine (in Ookii.CommandLine.dll) Version: 4.0.0+bb7ed9a8fdfd1cb21824750a8cf508863ad15086
C#
public bool? UseErrorColor { get; set; }

Property Value

NullableBoolean
to enable color output; to disable color output; or to enable it if the error output supports it.

Remarks

Only the parsing methods that automatically handle errors will use this property.

If this property is and the Error property is , color will be used if the standard error stream supports it, as determined by the VirtualTerminalEnableColor(StandardStream) method.

If this property is set to explicitly, virtual terminal sequences may be included in the output even if it's not supported, which may lead to garbage characters appearing in the output.

See Also