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

Matched strings get displaced when preceded by multi-byte utf8 chars #129

Open
zenhog opened this issue Dec 12, 2022 · 2 comments
Open

Matched strings get displaced when preceded by multi-byte utf8 chars #129

zenhog opened this issue Dec 12, 2022 · 2 comments

Comments

@zenhog
Copy link

zenhog commented Dec 12, 2022

Like the title and [screenshot](https://i.imgur.com/Fd2DRbp.png suggests, matched text gets displaced when some multi-byte char(s) is(are) present in the line containg the match. As you can see from the screenshot, the same string is matched on the prompt line and the output line, but only the former is displaced. Here the arrow character at the end of the prompt is multi-byte, perhaps the "unticked box" char as well. Anyways, every time a multi-byte char is present on a line, this happens.

My wild guess would be some computation error in the match index. I've tried looking at the code, but unfortunately, I don't speak rust at all.

Let me know if this would be something that would warrant a fix.

@fcsonline
Copy link
Owner

It is a known issue, without a clear solution. #76

@zenhog
Copy link
Author

zenhog commented Dec 14, 2022

One workaround seems to be to actually not render those chars at all in the thumbs pane, that way, the problem doesn't exist, and since those chars are mostly uneeded in the regexps we'd want to match either way, I don't see a problem with that.
Maybe as an option.

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

No branches or pull requests

2 participants