Escape sequence and UI to mark text as hyperlink with URL
@jtriplett
Submitted by Josh Triplett Link to original bug (#779734)
Description
(This would require changes in both VTE and gnome-terminal; filing it on gnome-terminal first for discussion.)
I'd like to have a terminal escape sequence that marks subsequent text as a hyperlink with a specified URL, and a sequence based on the same escape that marks the end of the link. That would allow programs running in the terminal to provide hyperlinks based on context that wouldn't work via general URL recognition.
As an example: apt-listchanges knows that its content consists of Debian changelogs. Debian changelogs have a standard pattern to specify a Debian bug number. When displayed in a web browser, apt-listchanges turns those URLs into hyperlinks. If gnome-terminal (and VTE) supported an escape sequence for hyperlinks, then apt-listchanges could emit that escape sequence to turn bug numbers into hyperlinks within less and gnome-terminal.
Within VTE, this would require adding such an escape sequence, remembering the URL, and providing that information to the program embedding VTE. Within gnome-terminal, this would require extending the existing hyperlink treatment to show an URL on hover or in the context menu, and provide the "Open Link" and "Copy Link Address" menu items.
Does this seem like reasonable functionality to support?