From 02ad3755034eb10eef3184e923f5c8a90283b1a1 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Wed, 16 Jun 2010 19:27:38 +0000 Subject: [PATCH] termcol: title overrides for html and xkcd --- termcol.plp | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/termcol.plp b/termcol.plp index 1ea1a83..b018685 100644 --- a/termcol.plp +++ b/termcol.plp @@ -42,6 +42,10 @@ sub colcell { my %col = ( -html => [ + sprintf('html', + 'HTML keywords (inherited by CSS≥2.1 and SVG), mostly identical to X11', + 'http://www.w3.org/TR/css3-color/#html4', + ), qw/black maroon green olive navy purple cyan silver gray red lime yellow blue fuchsia aqua white/, qw/reset bold dim italic underline blink fastblink @@ -68,6 +72,10 @@ my %col = ( 555753 EF2929 8AE234 FCE94F 729FCF AD7FA8 34E2E2 EEEEEC/, ], -xkcd => [ + sprintf('xkcd', + 'human averages in xkcd survey results', + 'http://blog.xkcd.com/2010/05/03/color-survey-results/', + ), qw/black maroon green olive navy purple teal silver grey red lime yellow blue fuchsia cyan white/, ], @@ -80,10 +88,10 @@ my %col = ( for my $term (qw/cga xterm tango html xkcd/) { print '', "\n"; - print "\n"; + printf "\n", $col{"-$term"}[0] || $term; for my $num (0 .. 15) { my $rgb = $col{$term}[$num + 2]; - my $name = $col{"-$term"}[$num] || $num; + my $name = $col{"-$term"}[$num + 1] || $num; $name = [ $name, ['#333'] ] if $term eq 'xkcd'; print '', colcell($name, $rgb); } -- 2.30.0
$term%s