mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-29 05:01:49 +00:00
Second part of bug 4050 fix
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@19168 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
972ec40b73
commit
61cb6824a6
@ -1226,10 +1226,7 @@ def revert_accent(document):
|
|||||||
if j < len(document.body[i]) - 1:
|
if j < len(document.body[i]) - 1:
|
||||||
document.body.insert(i+1, document.body[i][j+1:])
|
document.body.insert(i+1, document.body[i][j+1:])
|
||||||
# Delete the accented character
|
# Delete the accented character
|
||||||
if j > 0:
|
document.body[i] = document.body[i][:j]
|
||||||
document.body[i] = document.body[i][:j-1]
|
|
||||||
else:
|
|
||||||
document.body[i] = u''
|
|
||||||
# Finally add the InsetLaTeXAccent
|
# Finally add the InsetLaTeXAccent
|
||||||
document.body[i] += "\\i \\%s{}" % inverse_special_accent_map[accent]
|
document.body[i] += "\\i \\%s{}" % inverse_special_accent_map[accent]
|
||||||
break
|
break
|
||||||
@ -1248,10 +1245,7 @@ def revert_accent(document):
|
|||||||
if j < len(document.body[i]) - 1:
|
if j < len(document.body[i]) - 1:
|
||||||
document.body.insert(i+1, document.body[i][j+1:])
|
document.body.insert(i+1, document.body[i][j+1:])
|
||||||
# Delete the accented characters
|
# Delete the accented characters
|
||||||
if j > 1:
|
|
||||||
document.body[i] = document.body[i][:j-1]
|
document.body[i] = document.body[i][:j-1]
|
||||||
else:
|
|
||||||
document.body[i] = u''
|
|
||||||
# Finally add the InsetLaTeXAccent
|
# Finally add the InsetLaTeXAccent
|
||||||
document.body[i] += "\\i \\%s{%s}" % (inverse_accent_map[accent], accented_char)
|
document.body[i] += "\\i \\%s{%s}" % (inverse_accent_map[accent], accented_char)
|
||||||
break
|
break
|
||||||
|
Loading…
Reference in New Issue
Block a user