- Removed the weird pre/postamble stuff that Sjouke asked for.

- Introduced an 'attacktemplate' file.
This commit is contained in:
ccremers 2004-04-23 13:23:33 +00:00
parent 8fda9c6d2b
commit 4cefc16543
3 changed files with 25 additions and 12 deletions

9
src/attacktemplate.tex Normal file
View File

@ -0,0 +1,9 @@
\documentclass{article}
\usepackage{a4wide}
\usepackage{msc}
\begin{document}
\input{attack}
\end{document}

View File

@ -43,8 +43,6 @@ latexInit (const System sys, int argc, char **argv)
{
int i;
printf ("\\documentclass{article}\n");
printf ("\\usepackage{msc}\n");
printf ("%%\n");
printf ("%% LaTeX output generated by %s\n", progname);
printf ("%% Input:\n");
@ -56,20 +54,15 @@ latexInit (const System sys, int argc, char **argv)
printf ("\n");
printf ("%%\n");
printf ("\\begin{document}\n\n");
/* comment macro (used for debugging) */
printf ("\\newcommand{\\comment}[1]{}\n");
/* preamble */
printf ("\\input{preamble}\n");
}
void
latexDone (const System sys)
{
printf ("\\input{postamble}\n");
printf ("\n\\end{document}\n\n");
/* closing of the document */
}
void

View File

@ -8,15 +8,26 @@
# ./testl ns3
#
file=../spdl/$1.spdl outfile=tempattack
file=../spdl/$1.spdl
template=../src/attacktemplate
if [ -f $file ]
then
./scyther --latex $file -o $outfile.tex
latex $outfile.tex
xdvi $outfile.dvi
../src/scyther --latex $file -o attack.tex
latex $template.tex
mv $template.dvi attack.dvi
dvips attack.dvi -o attack.ps
# xdvi attack.dvi # for Xdvi
# kdvi attack.dvi # for KDE environment
kghostview attack.ps # postscript in KDE
else
echo "No file $file found."
fi