UsageWriter Constructor

Initializes a new instance of the UsageWriter class.

Definition

Namespace: Ookii.CommandLine
Assembly: Ookii.CommandLine (in Ookii.CommandLine.dll) Version: 4.2.0+a4d3631e4dcc0970081ed435288efdebc1325f83
C#
public UsageWriter(
	LineWrappingTextWriter? writer = null,
	bool? useColor = null
)

Parameters

writer  LineWrappingTextWriter  (Optional)
A LineWrappingTextWriter instance to write usage to, or to write to the standard output stream.
useColor  NullableBoolean  (Optional)
to enable color output using virtual terminal sequences; to disable it; or, to automatically enable it if writer is using the VirtualTerminalEnableColor(StandardStream) method.

Remarks

If the writer parameter is , output is written to a LineWrappingTextWriter for the standard output stream, wrapping at the console's window width. If the stream is redirected, output may still be wrapped, depending on the value returned by ConsoleWindowWidth.

See Also