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

Support crayon codes in complete and incomplete #78

Open
josswright opened this issue Dec 3, 2018 · 1 comment
Open

Support crayon codes in complete and incomplete #78

josswright opened this issue Dec 3, 2018 · 1 comment
Labels
feature a feature request or enhancement

Comments

@josswright
Copy link

I found in issue #32, and the related pull request #52, that progress supports colour codes from crayon in its format strings.

I was trying, though, to use colour codes for the progress bar itself via the incomplete and complete options. This gives me an error due to the resulting string being not equal to 1: Error in assert_single_char(incomplete) : nchar(x) == 1 is not TRUE.

Is this easily fixable? It would make my progress bars much prettier!

@HenrikBengtsson
Copy link

HenrikBengtsson commented Apr 8, 2021

I've created PR #118 for this. It'll allows you to do:

library(progress)
library(crayon)
pb <- progress_bar$new(width=40L, complete=bgBlue(" "), incomplete=bgCyan(" "), current=bgCyan("|"))

resulting in:

flameshot_2021-04-07T200251

@gaborcsardi gaborcsardi added the feature a feature request or enhancement label Nov 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature a feature request or enhancement
Projects
None yet
Development

No branches or pull requests

3 participants