We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
If I have a label and want to output some multi-line text, which is aligned, how to do this?
label: my text is here and should continue here
text.Warp(..., text.WarpIndent(""), text.WrapPadded(6)) doesn't work, because with an empty string, the padding is applied to the first line too.
text.Warp(..., text.WarpIndent(""), text.WrapPadded(6))
The text was updated successfully, but these errors were encountered:
It's a bug indeed, indent is replaced by the padding as it's an empty string: https://github.com/MichaelMure/go-term-text/blob/master/wrap.go#L57-L59
There should be some marker string to signify "no indent", or use a pointer with nil.
Sorry, something went wrong.
Deleting those lines should be enough. If I use "" that's meaning don't do any indenting.
No branches or pull requests
If I have a label and want to output some multi-line text, which is aligned, how to do this?
text.Warp(..., text.WarpIndent(""), text.WrapPadded(6))
doesn't work, because with an empty string, the padding is applied to the first line too.The text was updated successfully, but these errors were encountered: