On Mon, Mar 31, 2003 at 03:36:01PM +0200, Jean-Marc Lasgouttes wrote:
> >>>>> "Jos?" == Jos? Matos <[EMAIL PROTECTED]> writes:
> 
> Jos?> On Friday 28 March 2003 17:54, John Levon wrote:
> >> > What is the status of that? Is it supposed to be safe now?
> >> 
> >> Jose said "it was probably OK" or something. It works for me ...
> >> but I don't know python
> 
> Jos?>   The original code is from Dekel, John's fix looks reasonable
> Jos?> to me and I would need to see different cases to fully assert
> Jos?> the validity of the patch.
> 
> Jos?>   That said I think that Jonh code is correct, is deals with one
> Jos?> missing case that is not dealt now, so it should go.
> 
> Unfortunately this is false :( See the message I forwarded a minute
> ago.

This is easy to fix. Attached is an updated patch
? x.lyx
Index: lyxconvert_218.py
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/lib/lyx2lyx/lyxconvert_218.py,v
retrieving revision 1.33
diff -u -p -r1.33 lyxconvert_218.py
--- lyxconvert_218.py   14 Mar 2003 15:00:02 -0000      1.33
+++ lyxconvert_218.py   31 Mar 2003 15:53:53 -0000
@@ -403,9 +403,13 @@ def remove_figinset(lines):
        else:
            display = "color"
 
-       subcaptionText = get_value(lines, "subcaption", i+1, j)
-       if subcaptionText != "":
-           subcaptionText = '"'+subcaptionText+'"'
+       subcaptionText = ""
+       subcaptionLine = find_token(lines, "subcaption", i+1, j)
+       if subcaptionLine != -1:
+            subcaptionText = lines[subcaptionLine][11:]
+           if subcaptionText != "":
+               subcaptionText = '"'+subcaptionText+'"'
+
        k = find_token(lines, "subfigure", i+1,j)
        if k == -1:
            subcaption = 0

Reply via email to