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

Actually keep the cursor on the right terminal side #356

Merged
merged 1 commit into from Jan 26, 2022

Conversation

sigmaSd
Copy link
Contributor

@sigmaSd sigmaSd commented Jan 26, 2022

Test case:

use indicatif::{ProgressBar, ProgressStyle};

fn main() {
    let pb = ProgressBar::new(500).with_style(ProgressStyle::default_bar().template("hello {bar}"));
    for _ in 0..1024 {
        pb.inc(1);
    }
    pb.finish_with_message("done");
    println!("Something");
}

1b13d6f didn't actually work as you can see with the test case, apparently moving the cursor to the right will never reach the last column, writing spaces instead actually works

@djc djc merged commit 8ff5e6f into console-rs:main Jan 26, 2022
@djc
Copy link
Collaborator

djc commented Jan 26, 2022

Thanks for fixing it!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants