mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-09 18:31:04 +00:00
Consider the case where there is not any layout name.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10143 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
4a85fd5ed0
commit
7400f85b89
@ -1,3 +1,8 @@
|
||||
2005-07-06 José Matos <jamatos@lyx.org>
|
||||
|
||||
* lyx_1_1_5.py (replace_protected_separator): Make it robust
|
||||
to layout name absence.
|
||||
|
||||
2005-07-06 José Matos <jamatos@lyx.org>
|
||||
|
||||
* LyX.py (read): Add support for cases where the body begins
|
||||
|
@ -33,7 +33,11 @@ def replace_protected_separator(file):
|
||||
break
|
||||
j = find_token_backwards(lines, "\\layout", i)
|
||||
#if j == -1: print error
|
||||
layout = layout_exp.match(lines[j]).group(1)
|
||||
layout_m = layout_exp.match(lines[j])
|
||||
if layout_m:
|
||||
layout = layout_m.group(1)
|
||||
else:
|
||||
layout = "Standard"
|
||||
|
||||
if layout == "LyX-Code":
|
||||
result = ""
|
||||
|
Loading…
Reference in New Issue
Block a user