-
Notifications
You must be signed in to change notification settings - Fork 105
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
issue with tabs when using prioritization #48
Comments
I noticed that without Also it works with |
@vokiel oh nice. Do you want to submit a PR for that? |
It depends on the desired output. For me bold is enough, others may want both (bold + italic). In the second, extra space could be fine. Or maybe it would be better to do more digging into formatter and/or http://github.com/fatih/color (what exactly Italic adds to the output). I would also check if concatenating strings work better in this case. |
Hey @vokiel, did you manage to reproduce the error consistently? |
Hi @mikezter, I've did a simple check on sample based on the todolist:
Results:
With
|
it looks like |
I think the relevant code of package color is here https://github.com/fatih/color/blob/master/color.go#L365 and here https://github.com/fatih/color/blob/master/color.go#L346 constants are defined here: https://github.com/fatih/color/blob/master/color.go#L45 I am not too familiar with ANSI escapes (or ist SGR?) so i'm interested to learn about the problem here. |
I modified the test program from @vokiel and instead of
I printed the string directly to the console with
The result is It looks like |
Update:
The issue is that the The test data in the repo doesn't have this combination of double digit and |
Any updates? I found this, which states that |
@NonerKao that was also my observation. The tabwriter is confused by the additional control characters. I was looking into changing the tabwriter to add support for those control sequences. I'm currently traveling and don't have support to my machine, but when I'm back in 8 days I'd like to setup a PR with my changes. |
@ingorichter That's great! Looking forward to the fix :) Just FYI, the |
Any news? |
I ran some tests using @prataprc 's patch to |
Because the root cause lies in I will deal with this recently. |
I've finished the color-aware tabwriter modification, so I will submit a PR later which will replace the dependency |
Okay, now I'm way behind of the things I wanted to do after my long trip. Thanks for putting up the fix. I'll check it out in the afternoon. 👍 |
@ingorichter Thanks for the survey! What you pointed out was pretty helpful for me to submit this patch. |
I can't seem to figure this one out. It only happens sometimes.
The text was updated successfully, but these errors were encountered: