From fc12716a97adcfac33c02f4db2519edc5dedce7c Mon Sep 17 00:00:00 2001 From: Abdelrazak Younes Date: Sun, 4 May 2008 07:50:00 +0000 Subject: [PATCH] We don't want the document dialog to be reset for each new paragraph. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24597 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/frontends/qt4/GuiDocument.cpp | 2 ++ src/frontends/qt4/GuiView.cpp | 9 +++++++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/src/frontends/qt4/GuiDocument.cpp b/src/frontends/qt4/GuiDocument.cpp index 2ba63bacbf..0e42f8f720 100644 --- a/src/frontends/qt4/GuiDocument.cpp +++ b/src/frontends/qt4/GuiDocument.cpp @@ -2167,6 +2167,8 @@ char const * GuiDocument::fontfamilies_gui[5] = { bool GuiDocument::initialiseParams(string const &) { bp_ = buffer().params(); + // Force update on next updateContent() round. + current_id_ = 0; loadModuleInfo(); return true; } diff --git a/src/frontends/qt4/GuiView.cpp b/src/frontends/qt4/GuiView.cpp index e4ff6ccb20..65704847e4 100644 --- a/src/frontends/qt4/GuiView.cpp +++ b/src/frontends/qt4/GuiView.cpp @@ -550,6 +550,9 @@ void GuiView::on_currentWorkAreaChanged(GuiWorkArea * wa) structureChanged(); + // The document settings needs to be reinitialised. + updateDialog("document", ""); + // Buffer-dependent dialogs must be updated. This is done here because // some dialogs require buffer()->text. updateDialogs(); @@ -570,6 +573,8 @@ void GuiView::on_lastWorkAreaRemoved() } #else structureChanged(); + // The document settings needs to be reinitialised. + updateDialog("document", ""); updateDialogs(); #endif } @@ -624,6 +629,8 @@ bool GuiView::event(QEvent * e) // The document structure, name and dialogs might have // changed in another view. structureChanged(); + // The document settings needs to be reinitialised. + updateDialog("document", ""); updateDialogs(); } else { setWindowTitle(qt_("LyX")); @@ -927,8 +934,6 @@ void GuiView::structureChanged() // Navigator needs more than a simple update in this case. It needs to be // rebuilt. updateDialog("toc", ""); - // Same for the document settings dialog. - updateDialog("document", ""); } -- 2.39.2