From 81f23035286c51a7d5ed231c40808150d25f57c5 Mon Sep 17 00:00:00 2001 From: dakkar Date: Sat, 8 Nov 2008 17:06:17 +0000 Subject: inventario di "tutti", script per tabellarlo (ha un po' di problemi), immagini --- tabella.pl | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 tabella.pl (limited to 'tabella.pl') diff --git a/tabella.pl b/tabella.pl new file mode 100644 index 0000000..b30aac6 --- /dev/null +++ b/tabella.pl @@ -0,0 +1,30 @@ +#!/usr/bin/perl +use strict; +use warnings; + +my @lineterm=qw(& & \\\\); +my $state=0;my $mline=0; +while (my $line=<>) { + if ($state==0) { + if ($line=~/matrix/) {$state=1}; + } + if ($state==1) { + if ($line=~/{/) {$state=2}; + } + if ($state==2) { + $line=~s[}\s*(&|\\\\|)\s*(%.*)?$][} $lineterm[$mline%3] $2\n] + and ++$mline; + } + print $line; + if ($mline==18) { + $mline=0; + print <<'EOM'; +}; +\end{tikzpicture} + +\begin{tikzpicture} +\matrix +{ +EOM + } +} -- cgit v1.2.3