mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-27 14:29:21 +00:00
InsetText::fixParagraphsFont(): return early and save Font instantiation.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30811 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
a9b2b7f55d
commit
76a7314279
@ -330,16 +330,17 @@ bool InsetText::getStatus(Cursor & cur, FuncRequest const & cmd,
|
||||
|
||||
void InsetText::fixParagraphsFont()
|
||||
{
|
||||
if (!getLayout().isPassThru())
|
||||
return;
|
||||
|
||||
Font font(inherit_font, buffer().params().language);
|
||||
if (getLayout().isPassThru()) {
|
||||
font.setLanguage(latex_language);
|
||||
ParagraphList::iterator par = paragraphs().begin();
|
||||
ParagraphList::iterator const end = paragraphs().end();
|
||||
while (par != end) {
|
||||
par->resetFonts(font);
|
||||
par->params().clear();
|
||||
++par;
|
||||
}
|
||||
font.setLanguage(latex_language);
|
||||
ParagraphList::iterator par = paragraphs().begin();
|
||||
ParagraphList::iterator const end = paragraphs().end();
|
||||
while (par != end) {
|
||||
par->resetFonts(font);
|
||||
par->params().clear();
|
||||
++par;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user