Skip Menu |

This queue is for tickets about the HTML-FromANSI CPAN distribution.

Report information
The Basics
Id: 110281
Status: new
Priority: 0/
Queue: HTML-FromANSI

People
Owner: Nobody in particular
Requestors: adavies42 [...] me.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Doesn't Handle Extended Color Codes
Date: Thu, 10 Dec 2015 18:54:47 -0500
To: bug-HTML-FromANSI [...] rt.cpan.org
From: adavies42 <adavies42 [...] me.com>
HTML::FromANSI 1.01 doesn't understand 256-color (ESC[38;5;<i>m) or 24-bit color (ESC[38;2;<r>;<g>;<b>m) codes. (It seems to be mis-interpreting them as various other codes.) 256-color: actual: $ printf '\e[38;5;201mfoo\e[m'|ansi2html -f <tt><font face='fixedsys, lucida console, terminal, vga, monospace' style='line-height: 1; letter-spacing: 0; font-size: 12pt'><span style='color: gray; background: dimgray; text-decoration: underline; '>foo</span><span style='color: black; background: black; '><br></span></font></tt>$ expected: $ printf '\e[38;5;201mfoo\e[m'|ansi2html -f <tt><font face='fixedsys, lucida console, terminal, vga, monospace' style='line-height: 1; letter-spacing: 0; font-size: 12pt'><span style='color: #f0f; background: black; '>foo</span><span style='color: black; background: black; '><br></span></font></tt>$ 24-bit color: actual: $ printf '\e[38;2;123;123;123mfoo\e[m\n'|ansi2html -f <tt><font face='fixedsys, lucida console, terminal, vga, monospace' style='line-height: 1; letter-spacing: 0; font-size: 12pt'><span style='color: gray; background: black; text-decoration: underline; '>foo</span><span style='color: black; background: black; '><br></span></font></tt>$ expected: $ printf '\e[38;2;123;123;123mfoo\e[m\n'|ansi2html -f <tt><font face='fixedsys, lucida console, terminal, vga, monospace' style='line-height: 1; letter-spacing: 0; font-size: 12pt'><span style='color: #7b7b7b; background: black; '>foo</span><span style='color: black; background: black; '><br></span></font></tt>$ -- Aaron Davies adavies42@me.com