[LyX/master] Improve UI feedback in child document settings (#13343)

Juergen Spitzmueller spitz at lyx.org
Sun Jun 28 10:26:47 UTC 2026


commit b41a4c3d521796b6bff39ab0080073e93ff7f3aa
Author: Juergen Spitzmueller <spitz at lyx.org>
Date:   Sun Jun 28 12:26:25 2026 +0200

    Improve UI feedback in child document settings (#13343)
    
    \includeonly makes no sense with only one child, so
    do not offer it.
---
 src/frontends/qt/GuiDocument.cpp | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/frontends/qt/GuiDocument.cpp b/src/frontends/qt/GuiDocument.cpp
index a46d21aee2..4717dba8e7 100644
--- a/src/frontends/qt/GuiDocument.cpp
+++ b/src/frontends/qt/GuiDocument.cpp
@@ -4958,6 +4958,10 @@ void GuiDocument::updateIncludeonlyDisplay()
 {
 	if (includeonlys_.empty()) {
 		masterChildModule->includeallRB->setChecked(true);
+		// Disable "Include selected only" if there is
+		// only one to select from
+		masterChildModule->includeonlyRB->setEnabled(
+			masterChildModule->childrenTW->topLevelItemCount() > 1);
 		masterChildModule->childrenTW->setEnabled(false);
 		masterChildModule->maintainGB->setEnabled(false);
 	} else {


More information about the lyx-cvs mailing list