mirror of
https://git.lyx.org/repos/lyx.git
synced 2025-01-21 23:09:40 +00:00
Fix bug 4212
* Text2.cpp (deleteEmptyParagraphMechanism): * paragraph_func.cpp (breakParagraph): make sure that the start of appendix marker is not lost when deleting or breaking a paragraph git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20121 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
fc2f8c8e4f
commit
6e974a3d42
@ -813,7 +813,11 @@ bool Text::deleteEmptyParagraphMechanism(Cursor & cur,
|
||||
max(old.pit() - 1, pit_type(0)),
|
||||
min(old.pit() + 1, old.lastpit()));
|
||||
ParagraphList & plist = old.text()->paragraphs();
|
||||
bool const soa = oldpar.params().startOfAppendix();
|
||||
plist.erase(boost::next(plist.begin(), old.pit()));
|
||||
// do not lose start of appendix marker (bug 4212)
|
||||
if (soa)
|
||||
boost::next(plist.begin(), old.pit())->params().startOfAppendix(true);
|
||||
|
||||
// see #warning (FIXME?) above
|
||||
if (cur.depth() >= old.depth()) {
|
||||
|
@ -134,7 +134,10 @@ void breakParagraph(BufferParams const & bparams,
|
||||
}
|
||||
|
||||
if (!isempty) {
|
||||
bool const soa = par.params().startOfAppendix();
|
||||
par.params().clear();
|
||||
// do not lose start of appendix marker (bug 4212)
|
||||
par.params().startOfAppendix(soa);
|
||||
par.layout(bparams.getTextClass().defaultLayout());
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user