On Wednesday 21 September 2005 14:54, Georg Baum wrote:
>
> Comments?

I need this patch to run doc_toc.py with several documents. Haven't you 
noticed it?

Index: LyX.py
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/lib/lyx2lyx/LyX.py,v
retrieving revision 1.24
diff -u -p -r1.24 LyX.py
--- LyX.py      19 Sep 2005 11:31:26 -0000      1.24
+++ LyX.py      21 Sep 2005 14:10:24 -0000
@@ -284,7 +284,7 @@ class LyX_Base:
         " Set the value of the header parameter."
         i = find_token(self.header, '\\' + param, 0)
         if i == -1:
-            self.warning(3, 'Parameter not found in the header: %s' % param)
+            self.warning('Parameter not found in the header: %s' % param, 3)
             return
         self.header[i] = '\\%s %s' % (param, str(value))

@@ -375,7 +375,7 @@ class LyX_Base:
                     steps.append(step[0])
         else:
             mode = "revert"
-            relation_format = format_relation
+            relation_format = format_relation[:]
             relation_format.reverse()
             last_step = None


  The first fixes a wrong order of arguments, the second fix is the one 
important here. Since in python we have assignment by reference, as I was 
reversing format_relation everytime we called the file.convert

> Georg

-- 
José Abílio

Reply via email to