1.1 --- a/XSLForms/Prepare.py Sat Nov 11 01:42:41 2006 +0000
1.2 +++ b/XSLForms/Prepare.py Sat Nov 11 01:42:52 2006 +0000
1.3 @@ -3,7 +3,7 @@
1.4 """
1.5 Preparation of templating stylesheets.
1.6
1.7 -Copyright (C) 2005 Paul Boddie <paul@boddie.org.uk>
1.8 +Copyright (C) 2005, 2006 Paul Boddie <paul@boddie.org.uk>
1.9
1.10 This library is free software; you can redistribute it and/or
1.11 modify it under the terms of the GNU Lesser General Public
1.12 @@ -125,6 +125,18 @@
1.13
1.14 _make_document(template_name, output_name, stylesheet_names, encoding)
1.15
1.16 +# Template repair functions.
1.17 +
1.18 +def fix_namespaces(template_name, output_name, stylesheet_names=["FixNamespace.xsl"], encoding=None):
1.19 +
1.20 + """
1.21 + Fix damage done to document namespaces by various editing tools, taking the
1.22 + document identified by 'template_name' and producing a new document with the
1.23 + given 'output_name'.
1.24 + """
1.25 +
1.26 + _make_document(template_name, output_name, stylesheet_names, encoding)
1.27 +
1.28 # Qt Designer functions.
1.29
1.30 def make_qt_fragment(template_name, output_name, widget_name, stylesheet_names=["QtDesignerExtract.xsl"], encoding=None):