Skip to content

4. Useful additions

David Shnayder edited this page Mar 2, 2024 · 1 revision

Useful Additions

To generally aid the programmer, and make the usage simpler, it is recommended to use:

using static PrettyConsole.Console

Which will give you access to all the features with writing the namespace, however, this also means that using some functions from System.Console will produce a code-base that looks conflicting. For this reason many functions from System.Console where also implemented here, for example Clear and NewLine. Using them will be easier, and the calls would be inlined so don't worry about performance at all.

There is also a ClearNextLines(int) method that does what it says, it may be a niche case to need this, but it can be very helpful when dealing with other outputs that override lines (instead of just adding), such as progress bars and more.

Clone this wiki locally