-
Notifications
You must be signed in to change notification settings - Fork 43
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
feature request: hover text #61
Comments
How about this:
"Options" has the form of a JSON object, with the outer "{}" removed.
"hover-timeout": SECONDS |
Not sure what the difference between info-html and popup-html would be. Also, another problem is, that it has to be HTML code then. At least for the use case I have in mind, it would be much simpler if I can use the standard escape codes (for color etc) to format some string. |
"Not sure what the difference between info-html and popup-html would be." The info-html uses the "info block" - the little "mini-buffer" you see on the lower-right when re-sie the window, or when you hover a link. It is normally a single short line. The pop-html would be shown near the mouse, and may be multiple lines. An alternative would be use the same option, but with a separate "Also, another problem is, that it has to be HTML code then" |
I think we should not think in terms of what is simple to implement for DomTerm, but rather:
I think if this feature is HTML only, this will probably always stay a DomTerm-only implementation. |
Well, we do have to also consider implementation complexity. However, I agree that text-with-escape-codes is preferable, and I think I can implement that with modest effort. |
Some tentative conclusions and suggestions:
where options has the form of a JSON object with the outer curly braces removed. For example:
However, since the escape sequences will be machine-generated and machine-read (rather than human-read), the benefits are probably not worth the extra complication.
|
It might make sense to extend the OSC 8 hyperlink escape sequence. DomTerm recently got a nice mechanism for displaying links (see the screenshot here) and it could be easily extended for application-supplied hover information. Rather than come up with a new OSC code, reusing OSC 8 migh be best:
The following _ params_ are suggsted:
When a
|
It would be nice to let some hover-text appear when I move over some text with the mouse (such as additional information about some object, file, or so).
The terminal escape code syntax could be something like
<start-hover>visible<mid-hover>hover-text<end-hover>
(similar syntax as hyperlinks). The hover text ideally could again contain other escape codes (such as support for colors).The text was updated successfully, but these errors were encountered: