mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-24 21:55:29 +00:00
Do not set layout for no-op paragraph break
When breaking paragraph in an empty top-level paragraph, nothing happens on screen but yet there is an undo step because the layout is reset to what it already was. Avoid this case. Fixes bug #10089.
This commit is contained in:
parent
07c7dae367
commit
2ad52918da
@ -743,7 +743,8 @@ void Text::breakParagraph(Cursor & cur, bool inverse_logic)
|
||||
else {
|
||||
docstring const & lay = cur.paragraph().usePlainLayout()
|
||||
? tclass.plainLayoutName() : tclass.defaultLayoutName();
|
||||
setLayout(cur, lay);
|
||||
if (lay != layout.name())
|
||||
setLayout(cur, lay);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user