X-Git-Url: http://git.asbjorn.biz/?p=swftools.git;a=blobdiff_plain;f=doc%2Fcodebeautifier.pl;h=de760261ed2adcae54577ae674f6b3f500457cb4;hp=6225c83ba1575763ddaf338ebe1ae947f2e0f1c5;hb=cfde3bddd44142b4582624dac65f0602cab8e899;hpb=1b92dcdf739c6b827ac037ce74a9d9df0fc857a8 diff --git a/doc/codebeautifier.pl b/doc/codebeautifier.pl index 6225c83..de76026 100644 --- a/doc/codebeautifier.pl +++ b/doc/codebeautifier.pl @@ -4,14 +4,19 @@ while() $code .= $_ if(!/CALLPERL/); $name = $1 if(/.flash.*name=([^&][^ ]*)/); $name = $1 if(/.flash.*name="([^&]*)"/); + chomp $name; } elsif(/\[CALLPERL .*right\]/ ... /\[CALLPERL end\]/) { $highlight .= $_ if(!/CALLPERL/); } elsif ($code ne "") { $code =~ s/"/"/g; + +# print stderr "Warning: ttf->swf\n" if($code =~ s/Arial.ttf/Arial.swf/g); + open(fi, ">tmp.sc");print fi $code;close(fi); - system("swfc tmp.sc"); + print stderr "swfc tmp.sc ($name)\n"; + system("swfc tmp.sc >&2"); ($embed = `swfdump -e $name`) =~ /WIDTH="([^"]*)"/; $width = $1; print "";