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

Add support for setting an (optional) ID on OSC-8 hyperlinks #568

Closed
dnkl opened this issue Oct 14, 2022 · 0 comments · Fixed by #570
Closed

Add support for setting an (optional) ID on OSC-8 hyperlinks #568

dnkl opened this issue Oct 14, 2022 · 0 comments · Fixed by #570

Comments

@dnkl
Copy link
Contributor

dnkl commented Oct 14, 2022

OSC-8 hyperlinks can be assigned an optional ID parameter (https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda#the-escape-sequence)

This information is used by the terminal emulator to group together an URL that has been split up into multiple pieces (e.g. a hyperlinked being line-breaked in a multi-pane application).

See https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda#hover-underlining-and-the-id-parameter for a thorough description of why this is useful, and how terminal emulators benefit from having proper IDs set.

I picture tcell allowing hyperlinks to be assigned an optional ID. If unassigned, do what we do today (rely on terminal emulator heuristics). But leave it up to the application to allocate and assign IDs.

rockorager added a commit to rockorager/tcell that referenced this issue Oct 15, 2022
OSC8 escape sequences allow for marking up hyperlinks in the terminal.
An optional `id` parameter is defined to allow applications to signal to
the terminal that (potentially) broken character sequences belong to the
same URL and should be treated as if they were connected.

Add support for optional id parameters, set by the application. Update
test case for ti.EnterUrl.

Fixes: gdamore#568
Reference: https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda#hover-underlining-and-the-id-parameter
rockorager added a commit to rockorager/tcell that referenced this issue Oct 15, 2022
OSC8 escape sequences allow for marking up hyperlinks in the terminal.
An optional `id` parameter is defined to allow applications to signal to
the terminal that (potentially) broken character sequences belong to the
same URL and should be treated as if they were connected.

Add support for optional id parameters, set by the application. Update
test case for ti.EnterUrl.

Fixes: gdamore#568
Reference: https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda#hover-underlining-and-the-id-parameter
gdamore pushed a commit that referenced this issue Oct 17, 2022
OSC8 escape sequences allow for marking up hyperlinks in the terminal.
An optional `id` parameter is defined to allow applications to signal to
the terminal that (potentially) broken character sequences belong to the
same URL and should be treated as if they were connected.

Add support for optional id parameters, set by the application. Update
test case for ti.EnterUrl.

Fixes: #568
Reference: https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda#hover-underlining-and-the-id-parameter
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

Successfully merging a pull request may close this issue.

1 participant