mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-03 06:13:01 +00:00
Fix an off-by-one error in the reversion of beamer documents.
(cherry picked from commit dbd4d781dc
)
This commit is contained in:
parent
a640f4244e
commit
20214ee224
@ -3621,12 +3621,12 @@ def revert_newframes(document):
|
|||||||
continue
|
continue
|
||||||
endseq = j
|
endseq = j
|
||||||
subst = ["\\begin_layout %s" % frame_dict[val]]
|
subst = ["\\begin_layout %s" % frame_dict[val]]
|
||||||
esubst = ["\\begin_layout EndFrame", "", "\\end_layout"]
|
esubst = ["", "\\begin_layout EndFrame", "", "\\end_layout"]
|
||||||
endseq = endseq + len(esubst) - len(document.body[j : j])
|
endseq = endseq + len(esubst) - len(document.body[j : j])
|
||||||
if document.body[j] == "\\end_deeper":
|
if document.body[j] == "\\end_deeper":
|
||||||
document.body[j : j] = [""] + esubst
|
|
||||||
else:
|
|
||||||
document.body[j : j] = esubst
|
document.body[j : j] = esubst
|
||||||
|
else:
|
||||||
|
document.body[j+1 : j+1] = esubst
|
||||||
for q in range(i, j):
|
for q in range(i, j):
|
||||||
if document.body[q] == "\\begin_layout %s" % val:
|
if document.body[q] == "\\begin_layout %s" % val:
|
||||||
document.body[q] = "\\begin_layout %s" % document.default_layout
|
document.body[q] = "\\begin_layout %s" % document.default_layout
|
||||||
|
Loading…
Reference in New Issue
Block a user