termcol: link and describe legacy group
authorMischa POSLAWSKY <perl@shiar.org>
Tue, 2 May 2017 18:55:48 +0000 (20:55 +0200)
committerMischa POSLAWSKY <perl@shiar.org>
Mon, 29 May 2017 17:23:11 +0000 (19:23 +0200)
termcol.inc.pl
termcol.plp

index b575944a835c49ee24e6ff577a18e8cb99379ed8..6f256c5a2e4c884613965ef9ac692288b9ccb0ad 100644 (file)
@@ -2,10 +2,10 @@ use 5.014;
 use Shiar_Sheet::Colour 1.05;
 
 +{
 use Shiar_Sheet::Colour 1.05;
 
 +{
-       default => [qw( ansi ansi88 )],
-       more    => [qw( ansi mirc legacy ansi256 )],
+       default => [qw( ansi ansi88 ansi256 )],
+       more    => [qw( ansi mirc pastel slutty solarized ansi88 ansi256 )],
        ansi    => [qw( cga putty xterm tango app html cgarne )],
        ansi    => [qw( cga putty xterm tango app html cgarne )],
-       legacy  => [qw( c64 msx2 mac2 risc arnegame cpc )],
+       legacy  => [qw( c64 msx mac2 risc arnegame dawnbringer cpc cpcboy shiar ppu 64 )],
 
        html => {
                title => 'HTML keywords (inherited by CSS≥2.1 and SVG), mostly identical to X11',
 
        html => {
                title => 'HTML keywords (inherited by CSS≥2.1 and SVG), mostly identical to X11',
index 571b2968b9a8d837ddf000d7aae2d34d5bcb9f5e..2c16fe9999d38001eb8cc167e09337443503c7ee 100644 (file)
@@ -1,14 +1,15 @@
 <(common.inc.plp)><:
 
 Html({
 <(common.inc.plp)><:
 
 Html({
-       title => 'terminal colour cheat sheet',
+       title => ($Request ? 'terminal colour' : 'colour palettes') . ' cheat sheet',
        version => '1.1',
        version => '1.1',
-       description => [
+       description => [!$Request ? "Comparison of various colour palettes." : (
                "Index of all terminal/console colour codes,",
                "with an example result of various environments.",
                "Index of all terminal/console colour codes,",
                "with an example result of various environments.",
-       ],
+       )],
        keywords => [qw'
        keywords => [qw'
-               color code terminal console escape table xterm rxvt
+               color colour code terminal console escape table xterm rxvt
+               ansi vt100 8bit 4bit cga ega vga rgb hsv game emulator display
        '],
        data => ['termcol.inc.pl'],
        stylesheet => [qw'light dark'],
        '],
        data => ['termcol.inc.pl'],
        stylesheet => [qw'light dark'],
@@ -20,18 +21,22 @@ my @draw = map { [$_, s/\W+\z//] } grep { $_ } split m(/),
 my @termlist;
 push @termlist, split /\W+/, $Request || 'default';
 
 my @termlist;
 push @termlist, split /\W+/, $Request || 'default';
 
-:>
-<h1>Terminal colours</h1>
+say "<h1>$_</h1>\n" for $Request ? 'Colour palettes' : 'Terminal colours';
 
 
-<p>
-<span title="ECMA-48">ANSI</span> (VT100, ISO-6429) 16-colour text palette
-as implemented by various systems and programs.
-<:
-print
-       "@termlist" ne 'default' ? 'Additional palettes are included as specified.' :
-       'Also see <a href="/termcol/more">8-bit legacy hardware</a> palettes.';
+say '<p>';
+if ("@termlist" eq 'default') {
+       say '<span title="ECMA-48">ANSI</span> (VT100, ISO-6429) 16-colour text palette';
+       say 'as implemented by various systems and programs.';
+       say 'Also see <a href="/termcol/legacy">8-bit legacy hardware</a> palettes.';
+}
+elsif ("@termlist" eq 'legacy') {
+       say 'Colour palettes of various 8-bit legacy systems and retro games.';
+       say 'Also see <a href="/termcol">ANSI console</a> palettes.';
+}
+else {
+       say 'Comparison of requested colour palettes.';
+}
 :>
 :>
-</p>
 
 <div class="section">
 <:
 
 <div class="section">
 <: