latin: edgewrite svg row
authorMischa POSLAWSKY <perl@shiar.org>
Wed, 12 Apr 2017 23:31:00 +0000 (01:31 +0200)
committerMischa POSLAWSKY <perl@shiar.org>
Mon, 22 May 2017 15:55:30 +0000 (17:55 +0200)
Corner data from official <http://depts.washington.edu/ewrite/>.

writing-latn.inc.pl

index 60b24f960d9b38ac07122b05eca283ff89fdb6b4..640dd9bd32c75d2ea5d0043b513779ea92dfbbd5 100644 (file)
@@ -175,6 +175,23 @@ unistrokes => {
                'M3,4',
        ],
 },
+edgewrite => {
+       title => 'EdgeWrite',
+       style => 'svg path { stroke-linecap: round; stroke-linejoin: round }',
+       list => [
+               map { '<svg width="14" height="14" viewBox="-1 -1 10 10">'.$_.'</svg>' }
+               map {
+                       my @coords = map { $_ % 2 << 3, $_ >> 1 << 3 } split //; # x,y,
+                       sprintf('<circle cx="%s" cy="%s" r="1"/>', @coords[0, 1]) . # start point
+                       sprintf('<path d="M%s"/>', "@coords")
+               }
+               # corners (0..3) clockwise from top-left in order
+               qw(
+                       213 0232 1023 1323 01023 102 10132 0213 02 132 02123 023 20313 2031
+                       10231 0102 10131 201 1032 013 0231 021 02131 0312 0313 0123  01
+               )
+       ],
+},
 #graffiti => {
 #      title => 'Palm Graffiti',
 #},