From: Vincent van Ravesteijn Date: Fri, 25 Jun 2010 03:33:15 +0000 (+0000) Subject: Fix the enabling/disabling of the custom latex font encoding lineedit. X-Git-Tag: 2.0.0~3102 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=fb99c8115a65abd2b510af7a78e0d13e218885fa;p=features.git Fix the enabling/disabling of the custom latex font encoding lineedit. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34694 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/frontends/qt4/GuiDocument.cpp b/src/frontends/qt4/GuiDocument.cpp index 693bd57be4..8c71cf93c2 100644 --- a/src/frontends/qt4/GuiDocument.cpp +++ b/src/frontends/qt4/GuiDocument.cpp @@ -1525,7 +1525,10 @@ void GuiDocument::xetexChanged(bool xetex) fontModule->fontencLA->setEnabled(!xetex); fontModule->fontencCO->setEnabled(!xetex); - fontModule->fontencLE->setEnabled(!xetex); + if (xetex) + fontModule->fontencLE->setEnabled(false); + else + fontencChanged(fontModule->fontencCO->currentIndex()); } @@ -2788,11 +2791,13 @@ void GuiDocument::paramsToDialog() if (nn >= 0) fontModule->fontsDefaultCO->setCurrentIndex(nn); - if (bp_.fontenc == "global") + if (bp_.fontenc == "global") { fontModule->fontencCO->setCurrentIndex(0); - else if (bp_.fontenc == "default") + fontModule->fontencLE->setEnabled(false); + } else if (bp_.fontenc == "default") { fontModule->fontencCO->setCurrentIndex(2); - else { + fontModule->fontencLE->setEnabled(false); + } else { fontModule->fontencCO->setCurrentIndex(1); fontModule->fontencLE->setText(toqstr(bp_.fontenc)); }