Cédric Luthi and Patrik Svensson
786b7670da
Fix the style parameter nullable annotation on AnsiConsoleExtensions
...
The style parameter is actually nullable. Also, the documentation of the style parameter has been made explicit that `Style.Plain` is used when a `null` style is passed.
2021-08-31 18:52:34 +02:00
Patrik Svensson and Patrik Svensson
e169df6303
Add support for manipulating individual table rows
...
Closes #500
2021-08-14 23:35:07 +02:00
Antonio Valentini and GitHub
d532e1011f
Add default value parameter to Confirm extension
...
Closes #482
2021-07-12 08:47:36 +02:00
Patrik Svensson and Phil Scott
5f97f2300c
Support cancellation of prompts
...
Closes #417
2021-07-11 23:10:17 -04:00
Patrik Svensson and Phil Scott
865552c3f2
Add support for selecting prompt items
...
Closes #447
2021-06-28 08:41:24 -04:00
Patrik Svensson and Phil Scott
450d87f5d3
Add support for fake input in asciicast recordings
...
* Fixes a bug with `SelectionPrompt` and page size.
* Allow `IAnsiConsoleInput` to return `null`.
2021-05-23 22:22:44 -04:00
Phil Scott and Patrik Svensson
46abadaccb
Add AsciiCast demos for docs
2021-05-23 23:30:14 +02:00
Patrik Svensson and Phil Scott
3dea412785
Add live display support
...
This commit also adds functionality to LiveRenderable that should
fix some problems related to vertical overflow.
Closes #316
Closes #415
2021-05-20 19:41:10 -04:00
Patrik Svensson and Phil Scott
315a52f3e9
Add support for hierarchical list prompts
...
Closes #412
2021-05-18 11:34:16 -04:00
Patrik Svensson and Phil Scott
6549436356
Fix line break regression
...
In commit d1d94cd , we accidentally introduced a regression
since conhost requires all line breaks to be `\r\n`.
2021-05-10 17:42:49 -04:00
Patrik Svensson and Patrik Svensson
d1d94cdebe
Add Length and Lines properties to Paragraph
...
* Adds Length and Lines to `Paragraph`, `Markup` and `Text`.
* Do not use Environment.NewLine
2021-05-03 17:24:44 +02:00
Patrik Svensson and Phil Scott
cba02070f9
Add method to get VT/ANSI codes for renderables
2021-04-23 13:09:44 -04:00
Patrik Svensson and Phil Scott
3463dde543
Add method to write VT/ANSI control codes
...
Adds a new extension method IAnsiConsole.WriteAnsi that writes
VT/ANSI control codes to the console. If VT/ANSI control codes are
not supported, nothing will be written.
2021-04-22 22:16:10 -04:00
Patrik Svensson and Phil Scott
3e2eea730b
Add output abstraction and reorganize profile
...
* Moves ColorSystem from Profile to Capabilities
* Renames Tty to IsTerminal
* Adds IAnsiConsoleOutput to make output more flexible
Closes #343
Closes #359
Closes #369
2021-04-13 21:39:54 -04:00
Patrik Svensson and Phil Scott
2fe2bb3c32
Add parameterless Clear method for IAnsiConsole
...
Closes #338
2021-04-11 22:01:14 -04:00
Phil Scott and Patrik Svensson
254880e93a
Replaces emoji regex with ReadOnlySpan implementation
...
The RegEx runtime perf was never anything noticeable - it was the startup time that was eating over a third of time during initialization.
This shaves 200ms off the startup time.
2021-04-04 04:10:25 +02:00
Patrik Svensson and Phil Scott
6f16081f42
Add support for indeterminate progress
...
This commit also changes the behavior of ProgressContext.IsFinished.
Only tasks that have been started will be taken into consideration,
and not indeterminate tasks.
Closes #329
Closes #331
2021-04-03 09:42:49 -04:00
Patrik Svensson and Phil Scott
20650f1e7e
Change IAnsiConsole to render IRenderable
...
This makes it possible for encoders to output better representation
of the actual objects instead of working with chopped up segments.
* IAnsiConsole.Write now takes an IRenderable instead of segments
* Calculating cell width does no longer require a render context
* Removed RenderContext.LegacyConsole
* Removed RenderContext.Encoding
* Added Capabilities.Unicode
2021-03-28 09:06:06 -04:00
Alexey Golub and Patrik Svensson
8830779875
Add params to ProgressExtensions.Columns(...)
...
This way you can omit `new ProgressColumn[] { ... }` and just list the columns separated by comma.
2021-03-25 21:11:51 +01:00
Patrik Svensson and Phil Scott
7f6f2437b1
Add support for exclusive mode
2021-03-15 13:14:40 -04:00
Patrik Svensson and Phil Scott
9502aaf2b9
Allow markup in selection prompts
...
Closes #221
2021-03-14 21:27:44 -04:00
Phil Scott and Patrik Svensson
e4dda283bb
Adds overloads for MarkUp methods without args
...
These methods don't require a string.format call so we'll directly call the Render method without a call to string.format.
Added bonus of a a couple fewer allocations too.
2021-03-08 15:04:55 +01:00
stf and Phil Scott
1c769c6610
Add Progress.HideCompleted
2021-03-04 07:47:00 -05:00
Oskar Klintrot and Patrik Svensson
c64884854f
Make it possible to set Value directly
2021-02-25 11:56:32 +01:00
Bastian Eicher and Patrik Svensson
a1050fc676
Handle output to stderr
2021-02-14 18:08:42 +01:00
Patrik Svensson and Patrik Svensson
102e2dc38d
Allow formatting breakdown charts with lambda expr
...
Relates to #252
2021-02-13 17:09:51 +01:00
Patrik Svensson and Patrik Svensson
705cf745ea
Add formatting support for breakdown chart values
...
Closes #252
2021-02-05 11:53:55 +01:00
Patrik Svensson and Patrik Svensson
b64e016e8c
Add breakdown chart support
...
This also cleans up the bar chart code slightly and fixes
some minor bugs that were detected in related code.
Closes #244
2021-02-01 01:03:39 +01:00
Patrik Svensson and Patrik Svensson
a23bec4082
Add profile support
...
Closes #231
2021-01-19 17:53:03 +01:00
Patrik Svensson and Patrik Svensson
07db28bb6f
Add enhancements to progress widget
...
* Adds TransferSpeedColumn
* Adds DownloadedColumn
* Adds ElapsedTimeColumn
* Minor enhancements to existing columns
2021-01-12 14:10:07 +01:00
Patrik Svensson and Patrik Svensson
8261b25e5c
Fix tree rendering
...
Fixes some tree rendering problems where lines were not properly drawn
at some levels during some circumstances.
* Change the API back to only allow one root.
* Now uses a stack based approach to rendering instead of recursion.
* Removes the need for measuring the whole tree in advance.
Leave this up to each child to render.
2021-01-10 15:55:11 +01:00
Patrik Svensson and Patrik Svensson
0e0f4b4220
Add interactive prompts for selecting values
...
* Adds SelectionPrompt
* Adds MultiSelectionPrompt
Closes #210
2021-01-09 09:37:28 +01:00
Patrik Svensson and Patrik Svensson
1f211d3e1f
Add convenience methods for tree nodes
2021-01-03 23:28:55 +01:00
Patrik Svensson and Patrik Svensson
87e6b42409
Add tree example
2021-01-03 23:28:55 +01:00
Patrik Svensson and Patrik Svensson
4bfb24bfcb
Streamline tree API a bit
2021-01-03 23:28:55 +01:00
Patrik Svensson and Patrik Svensson
179e243214
Clean up table rendering a bit
2021-01-02 09:33:22 +01:00
Simon Cropp and Patrik Svensson
e71db7f78c
fix some nullability issues
2020-12-31 11:09:03 +01:00
Patrik Svensson and Patrik Svensson
7dccb310f3
Add support for bar charts
...
Closes #103
2020-12-23 10:05:08 +01:00
Patrik Svensson and Patrik Svensson
1cf30f62fc
Add autocomplete for text prompt
...
Closes #166
2020-12-22 11:31:22 +01:00
Patrik Svensson and Patrik Svensson
acf01e056f
Clean up status related code a bit
2020-12-09 08:37:32 +01:00
Patrik Svensson and Patrik Svensson
501db5d287
Add status support
2020-12-09 00:07:02 +01:00
Patrik Svensson and Patrik Svensson
ae32785f21
Add progress task list support
2020-12-04 07:29:48 +01:00
Patrik Svensson and Patrik Svensson
4f6eca4fcb
Fix rendering of exceptions with generic params
...
Closes #145
2020-11-24 22:16:17 +01:00
Patrik Svensson and Patrik Svensson
a59e0dcb21
Add FIGlet text support
...
Closes #97
2020-11-22 03:09:42 +01:00
Patrik Svensson and Patrik Svensson
0d209d8f18
Add text prompt support
2020-11-19 12:24:04 +01:00
Patrik Svensson and Patrik Svensson
380c6aca45
Add net5.0 target framework
2020-11-11 15:28:32 +01:00
Patrik Svensson and Patrik Svensson
b1da5e7ba8
Add support for markup text in panel header
2020-11-07 20:43:53 +01:00
Patrik Svensson and Patrik Svensson
a1d11e9d0c
Add support for moving the cursor
2020-10-28 18:57:08 +01:00
Martin Andersen and Patrik Svensson
bca1c889d1
Add Padding extension
...
Add extension method for specifying horizontal and vertical padding.
Similar constructor for `Padding` already existed.
Update documentation for table column appearance (padding).
Update
`Should_Render_Padded_Object_Correctly_When_Nested_Within_Other_Object`
test to use new extension method.
2020-10-27 09:09:30 +01:00
Patrik Svensson and Patrik Svensson
e7f497050c
Add row and column accessors for tables and grids
2020-10-26 18:15:27 +01:00