File math2svg.py.patch of Package python-svgmath
--- math2svg.py.orig 2007-12-27 22:13:47.000000000 +0100
+++ math2svg.py 2007-12-27 23:37:12.000000000 +0100
@@ -1,4 +1,4 @@
-#! /usr/bin/env python
+#!/usr/bin/env python
"""Command-line tool to replace MathML with SVG throughout a document.
@@ -10,6 +10,9 @@
from svgmath.tools.saxtools import XMLGenerator, ContentFilter
from svgmath.mathhandler import MathHandler, MathNS
+#CONFIGDIR=os.path.dirname(__file__)
+CONFIGDIR="/etc/SVGMath/"
+
def open_or_die(fname, fmode, role):
try: return open(fname, fmode)
except IOError, xcpt:
@@ -92,7 +95,7 @@
# Determine config file location
if configfile is None:
- configfile = os.path.join(os.path.dirname(__file__), "svgmath.xml")
+ configfile = os.path.join(CONFIGDIR, "svgmath.xml")
config = open_or_die(configfile, "rb", "configuration")
# Create the converter as a content handler.
@@ -117,4 +120,4 @@
sys.exit(exitcode)
if __name__ == "__main__":
- main()
\ Kein Zeilenumbruch am Dateiende.
+ main()