mirror of
https://git.lyx.org/repos/lyx.git
synced 2025-01-12 03:23:12 +00:00
parent
96639d2255
commit
c31cb9fd98
@ -3062,14 +3062,30 @@ def convert_beamerblocks(document):
|
|||||||
if i != -1:
|
if i != -1:
|
||||||
if document.body[parbeg] == "\\begin_inset ERT":
|
if document.body[parbeg] == "\\begin_inset ERT":
|
||||||
ertcontfirstline = parbeg + 5
|
ertcontfirstline = parbeg + 5
|
||||||
# Find the last ERT in this paragraph (which might also be the first)
|
lastertbeg = -1
|
||||||
lastertbeg = find_token_backwards(document.body, "\\begin_inset ERT", j)
|
lastertend = -1
|
||||||
if lastertbeg == -1:
|
while True:
|
||||||
document.warning("Last ERT not found!")
|
# Find the last ERT in this paragraph used for arguments
|
||||||
break
|
# (which might also be the first)
|
||||||
lastertend = find_end_of_inset(document.body, lastertbeg)
|
lastertbeg = find_token_backwards(document.body, "\\begin_inset ERT", j)
|
||||||
if lastertend == -1:
|
if lastertbeg == -1:
|
||||||
document.warning("End of last ERT not found!")
|
document.warning("Last ERT not found!")
|
||||||
|
break
|
||||||
|
lastertend = find_end_of_inset(document.body, lastertbeg)
|
||||||
|
if lastertend == -1:
|
||||||
|
document.warning("End of last ERT not found!")
|
||||||
|
break
|
||||||
|
# Is this ERT really used for an argument?
|
||||||
|
# Note: This will fail when non-argument ERTs actually use brackets
|
||||||
|
# (e.g. \pause{})
|
||||||
|
regexp = re.compile(r'.*[>\]\}]', re.IGNORECASE)
|
||||||
|
cbracket = find_re(document.body, regexp, lastertbeg, lastertend)
|
||||||
|
if cbracket != -1:
|
||||||
|
break
|
||||||
|
if lastertbeg == parbeg:
|
||||||
|
break
|
||||||
|
j = lastertbeg - 1
|
||||||
|
if lastertbeg == -1 or lastertend == -1:
|
||||||
break
|
break
|
||||||
ertcontlastline = lastertend - 3
|
ertcontlastline = lastertend - 3
|
||||||
while True:
|
while True:
|
||||||
|
@ -61,8 +61,8 @@ What's new
|
|||||||
- Fix warning "Missing \use_indices" when converting from 1.6.x format
|
- Fix warning "Missing \use_indices" when converting from 1.6.x format
|
||||||
or older.
|
or older.
|
||||||
|
|
||||||
- Fix conversion of multiple box overlay arguments in beamer when the
|
- Fix several conversion problems of beamer box arguments when the
|
||||||
arguments use multiple ERTs (part of bug 9208).
|
arguments use multiple ERTs (part of bug 9208, bug 9225).
|
||||||
|
|
||||||
- Fix conversion of beamer overlay arguments when the module
|
- Fix conversion of beamer overlay arguments when the module
|
||||||
"beamer-resenumerate" is used (part of bug 9208).
|
"beamer-resenumerate" is used (part of bug 9208).
|
||||||
|
Loading…
Reference in New Issue
Block a user