Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiline WriteLine causes artifacts with Progress, Status #415

Closed
AHelper opened this issue May 15, 2021 · 0 comments · Fixed by #423
Closed

Multiline WriteLine causes artifacts with Progress, Status #415

AHelper opened this issue May 15, 2021 · 0 comments · Fixed by #423
Labels
bug Something isn't working

Comments

@AHelper
Copy link

AHelper commented May 15, 2021

Information

  • OS: Windows 10
  • Version: 0.39.0
  • Terminal: Powershell, Windows Terminal

Describe the bug
It appears that AnsiConsole.WriteLine (and MarkdownLine, etc.) doesn't handle lines that are longer than the console width when a status or progress is also rendered.

To Reproduce
Here's an example the demonstrates the problem:

using System.Linq;
using Spectre.Console;

AnsiConsole.Status()
           .Start("This is a really long status message that will get written over", ctx =>
           {
               foreach (var width in Enumerable.Range(1, 200))
               {
                   AnsiConsole.WriteLine(string.Join("", Enumerable.Repeat('x', width)));
               }
           });

Expected behavior
WriteLine should prevent rendered status/progress bar from getting overwritten and mixed into the output.

Screenshots
spectre-line-wrap-bug
A Thread.Sleep was added in the foreach for the screenshot above, otherwise the same code

Additional context

  • A workaround is to chunk output text by console width and print each.
@AHelper AHelper added the bug Something isn't working label May 15, 2021
phil-scott-78 pushed a commit that referenced this issue May 20, 2021
This commit also adds functionality to LiveRenderable that should
fix some problems related to vertical overflow.

Closes #316
Closes #415
phil-scott-78 added a commit to phil-scott-78/spectre.console that referenced this issue Apr 1, 2024
phil-scott-78 added a commit to phil-scott-78/spectre.console that referenced this issue Apr 1, 2024
…pt output spectreconsole#415 spectreconsole#694"

This reverts commit 71a5d83.

The commit introduced major flickering when working with LiveRenderables

Fixes spectreconsole#1466
patriksvensson pushed a commit that referenced this issue Apr 1, 2024
…pt output #415 #694"

This reverts commit 71a5d83.

The commit introduced major flickering when working with LiveRenderables

Fixes #1466
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant