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

Support hyperlinks #31

Open
vanniktech opened this issue Aug 9, 2021 · 3 comments
Open

Support hyperlinks #31

vanniktech opened this issue Aug 9, 2021 · 3 comments
Labels
enhancement New feature or request

Comments

@vanniktech
Copy link
Contributor

I'm using picnic to print out tables for a command line tool. On some tables, I'd like to have hyperlink support. Do you have any ideas / suggestion how to have them clickable by iTerm?

iTerms and other consoles have support for links:

printf '\e]8;;http://example.com\e\\This is a link\e]8;;\e\\\n'

Source

@JakeWharton
Copy link
Owner

Are you saying you want the measurement code to honor the fact that this will only render as 14 characters?

@JakeWharton JakeWharton added the enhancement New feature or request label Aug 10, 2021
@vanniktech
Copy link
Contributor Author

Ideally, having the measurement code honouring this as well as having a method that takes 2 args, hyperlink and displayed text. That way, I don't have to mess with the internals and it's guaranteed picnic will render the hyperlink correctly.

@JakeWharton
Copy link
Owner

Well the terminal renders it and we have no guarantee that it will work. The same is true of colors, multi-codepoint graphemes, etc. though. Picnic doesn't provide any factories for those things and wouldn't for this either. Ideally we would expose a way to configure what types of these exotic measurement utilities would be installed so consumers can do feature defection on their output location.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants