Wrapped URLs fail
Opened this issue · 2 comments
Hi! I have a problem with long urls that are wrapped: they become broken for the terminal emulator. I use foot, here's what happens:
cat > /tmp/test
https://a.very.long/url/that/will/be/broken/by/page/when/it/is/wrapped/due/to/being/longer/than/the/terminal/window/which/is/problematic/when/trying/to/detect/urls/with/my/terminal/emulator
CTRL-D
nvimpager -p /tmp/test
Now, assuming the url is longer than page's window, if I hit CTRL-SHIFT-U (foot binding for "URL mode"), only the first line of the URL is recognised. This only happens inside page, not in plain less. Any way I can help debug this?
In my digging, I found this, which maybe hints a path to a solution: neovim/neovim#28817
Thanks!
If I understand the linked issue correctly you suggest that we implement such a plugin in nvimpager:
- parse the text for hyperlinks
- add extmarks with the
url
option to the hyperlink
And then neovim will emit the OSC-8 sequence for the terminal.
Indeed, I think that would solve the issue and long urls would be actionable inside nvimpager. Having said that, I have not a clear idea on how much work would that imply. But it'd be great to have that functionality, yeah! :)
Thanks for nvimpager!!