Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 54329ac

Browse files
author
Thomas G. Lockhart
committed
Utility to add the stylesheet "s0" definition to an RTF file.
This stylesheet must be present for Applixware to be happy generating a ToC. M$Word does not seem to care one way or the other.
1 parent c6cbf56 commit 54329ac

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

doc/src/sgml/fixrtf

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
#!/bin/sh
2+
# fixrtf
3+
# Repair (slightly) damaged RTF generated by jade
4+
# Applixware wants the s0 stylesheet defined, whereas
5+
# M$Word does not care about it.
6+
# (c) 2001, Thomas Lockhart, PostgreSQL Inc.
7+
8+
flist=$@
9+
if [ "$flist" = "" ] ; then
10+
flist=*.rtf
11+
fi
12+
13+
for f in $flist ; do
14+
echo -n "Repairing $f..."
15+
if [ -r $f ] ; then
16+
(sed 's/{\\stylesheet{\\s1/{\\stylesheet{\\s0 Normal 0;}{\\s1/g' $f > $f.new \
17+
&& mv -f $f.new $f \
18+
&& echo " done") || echo " failed"
19+
else
20+
echo " file not found"
21+
fi
22+
done
23+
exit

0 commit comments

Comments
 (0)