Public bug reported:
If you highlight text in gnome-terminal and right-click it, you get a
"Copy as HTML" option. The HTML that gnome-terminal generates when using
that feature contains <font> tags. font tags were depreciated in HTML
4.01, and made obsolete entirely in HTML 5. (See:
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/font).
Attached is a sample of the HTML generated by gnome-terminal.
The correct behavior would be to include style info such as font colors
inside the "style" attribute of a <span> tag, rather than using <font>
tags. That is to say,
<font color="#ffffff">
should be replaced by
<span style="color: #ffffff">,
and
</font>
should be replaced by
</span>
This bug exists in gnome terminal through version 3.38.1-1ubuntu1, and
it exists in Ubuntu 21.04 as well as in prior versions of Ubuntu.
I've attached both a copy of the output of Copy As HTML, containing the
deprecated <font> tag. Below is a fixed version of this output that
doesn't rely on the <font> tag:
<pre><span style="color: #4E9A06"><b>alecto@styx</b></span>:<span style="color:
#3465A4"><b>~</b></span>$ ls apps
<span style="color:
#4E9A06"><b>Bitwarden-1.27.1-x86_64_a6df18330216c2546e435c5a9c5df432.AppImage</b></span>
<span style="color: #3465A4"><b>gitkraken</b></span>
<span style="color:
#4E9A06"><b>session-desktop-linux-x86_64-1.6.7_18e4489c1ba2c40986ad03ca6522e187.AppImage</b></span>
<span style="color: #3465A4"><b>sources</b></span>
<span style="color: #4E9A06"><b>alecto@styx</b></span>:<span style="color:
#3465A4"><b>~</b></span>$
</pre>
** Affects: gnome-terminal (Ubuntu)
Importance: Undecided
Status: New
** Tags: gnome
** Attachment added: "Sample of html generated by "Copy as HTML" option; sample
contains depreciated HTML tags."
https://bugs.launchpad.net/bugs/1938605/+attachment/5514951/+files/gnome-terminal.html
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1938605
Title:
Gnome Terminal "Copy As HTML" produces HTML containing depreciated
features
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gnome-terminal/+bug/1938605/+subscriptions
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs