blob: c5269b9142e4577dc4fca79f7e0b777ad29c5de2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
#!/usr/bin/perl
while (<>) {
# strip any ctrl-d's
$_ =~ s/^//;
# get rid of any non-postscript commands
if (/^%/) {
do {
$_ = <>;
} until ( /^%/ ) || eof() ;
if (! eof()) {
print;
}
}
# fix bug in long titles from MS Word
elsif (/^%%Title:/) {
s/.
$/
/;
print;
}
# remove VM test
elsif (/^\/VM?/) {
print "/VM? { pop } bind def
\n";
do {
$_ = <>;
} until (/def
/) || eof() ;
}
else {
print;
}
}
|