Escaped numbers in brackets cause incorrect WordWrap #23
Labels
No Label
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
No Milestone
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: tslocum/cview#23
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Here's an example line:
If you use
cview.WordWrap
, a newline is inserted at the first space before the numbers, sofacilisi[1][2]
starts the new line, even though it hasn't hit the max number of columns. Empty brackets ([][]
) do not cause the issue.The bracketed numbers alone still cause the issue:
...urna. Nulla facilisi [1][2] Morbi massa nibh, fauc...
Removing the space to the right fixes the issue:
...urna. Nulla facilisi [1][2]Morbi massa nibh, fauc...
The issue still occurs with spacing and words between the numbers:
Nulla facilisi[2] example[1] Morbi massa nibh, faucibus
, with the newline starting right beforeexample[1]
.Please note that
cview.Escape
was used before wrapping, and all the examples above show the brackets how they are displayed and were typed, not how they are represented internally by cview.I've also had this happen with escaped words in brackets as well. Do have an idea what's causing it? Is it some error in the system that tries to skip over style tags?
mentioned in issue #27
WordWrap
does not seem to have been intended for use with escaped text. I've just addedTextView.SetWrapWidth
so that no text manipulation is required.I'm not sure I agree with this, but we can talk further in #27. Thank you.