X-Git-Url: http://git.shiar.nl/sheet.git/blobdiff_plain/5ee97692d42eea5defce6d1ea12dc84e9578f608..f4ca24ee41993be5098b4ba675561537803c272a:/sample.plp diff --git a/sample.plp b/sample.plp index 15323a3..be68403 100644 --- a/sample.plp +++ b/sample.plp @@ -1,13 +1,16 @@ <(common.inc.plp)><: +my $textinc = 'data/unicode-sampler/unicode.txt'; + Html({ title => "unicode sampler", version => '2.0', stylesheet => [qw'light dark mono red'], + data => [$textinc], }); -open my $source, '<', 'data/unicode-sampler/unicode.txt' - or die "Could not open text: $!\n"; +open my $source, '<', $textinc + or Abort("Could not open text at $textinc", 501, $!); local $/ = "\n\n"; my $top = readline $source; @@ -19,7 +22,7 @@ print $intro; while (my $p = readline $source) { EscapeHTML($p); - $p =~ s{ \A (\N+:) \n\Z }{

$1

}x; + $p =~ s{ \A ((\pL+) \N*:) \n\Z }{

$1

}x; print $p; }