use utf8;
use strict;
use warnings;
no warnings 'qw';
use Shiar_Sheet::KeyboardChars 'kbchars';
our %get;

# card suits at 50,00,60,7B mapped differently depending on keyboard
my %rows = qw(
	p ♣  , ♥  ; ♠  . ♦
	q ┌  w ┬  e ┐  r ─  t ●  y ▌  u ▄  i ▗  o ▖
	a ├  s ┼  d ┤  f ╱  g ╲  h ◢  j ◣  k ▝  l ▘
	z └  x ┴  c ┘  v ▏  b ▕  n ▁  m ▔
);

if (exists $get{compat}) {
	%rows = (%rows, qw(
		q ┏  w ┳  e ┓  r ━
		a ┣  s ╋  d ┫
		z ┗  x ┻  c ┛  v ▎  b 🮇  n ▂  m 🮂
	));
}

my $groups = kbchars(\%rows);

while (my ($k, $c) = each %rows) {
	$groups->{def}{''}{$k}[0] = (
		$c =~ /\p{In=1.1}/ ? 'g2' :
		$c =~ /\p{In=4.0}/ ? 'g3' :
		$c =~ /[\x{1FB00}-\x{1FBFF}]/ ? 'g5' : # Age=V13.0
		'g0'
	);
}

+{
	%{ $groups },
	version => '1.0',
	title => 'Atari graphics',
	category => 'legacy/graph',
	moderows => '1-',
	intro => join("\n",
		'<abbr title="ATARI Standard Code for Information Interchange">ATASCII</abbr>',
		'characters from 8-bit Atari machines starting with the 1979 models 400 and 800,',
		'with modern <a href="/keyboard/altgr/unigraph">Unicode</a> equivalents.',
		'Similar to <a href="/keyboard/altgr/c64">PETSCII</a>',
		'and <a href="/keyboard/altgr/msx-graph">MSX graph</a>.',
	),
	image => 'data/keyboard/thumb/atari-130xe.jpg',
	flag => {
		g2 => ['standard' => 'original Unicode 1993'],
		g3 => ['extended' => 'Unicode 4.0'],
		g5 => ['legacy'   => 'exceptional <em>symbols for legacy computing</em> in Unicode since <abbr title="Unicode 13.0">2020</abbr>'],
		g9 => ['color'    => 'presentational controls represented by anachronistic hearts'],
	},
}
