commit 2a4d7f1d58fddbd724bbafc36a7b65e4551b5b7e
Author: Juergen Spitzmueller <[email protected]>
Date: Sat Nov 22 09:34:17 2025 +0100
Fix background LaTeX color for \colorbox
Also fix a glitch in the dialog
---
src/frontends/qt/GuiBox.cpp | 2 +-
src/insets/InsetBox.cpp | 8 ++++----
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/frontends/qt/GuiBox.cpp b/src/frontends/qt/GuiBox.cpp
index 14ca00e752..859f474b9c 100644
--- a/src/frontends/qt/GuiBox.cpp
+++ b/src/frontends/qt/GuiBox.cpp
@@ -405,7 +405,7 @@ docstring GuiBox::dialogToParams() const
params.framecolor =
fromqstr(frameColorCO->getData(frameColorCO->currentIndex()));
else
- params.framecolor = "foreground";
+ params.framecolor = "default";
if (backgroundColorCO->isEnabled())
params.backgroundcolor =
fromqstr(backgroundColorCO->getData(backgroundColorCO->currentIndex()));
diff --git a/src/insets/InsetBox.cpp b/src/insets/InsetBox.cpp
index fc42fe39b9..39b144de4a 100644
--- a/src/insets/InsetBox.cpp
+++ b/src/insets/InsetBox.cpp
@@ -513,14 +513,14 @@ void InsetBox::latex(otexstream & os, OutputParams const
& runparams) const
if (params_.inner_box) {
if (params_.use_parbox) {
if (params_.backgroundcolor != "none" && btype ==
Frameless) {
- os << maybeBeginL << "\\colorbox{" <<
params_.backgroundcolor << "}{";
+ os << maybeBeginL << "\\colorbox{" <<
getBackgroundColor() << "}{";
needEndL = !maybeBeginL.empty();
}
os << "\\parbox";
} else if (params_.use_makebox) {
if (!width_string.empty()) {
if (params_.backgroundcolor != "none") {
- os << maybeBeginL << "\\colorbox{" <<
params_.backgroundcolor << "}{";
+ os << maybeBeginL << "\\colorbox{" <<
getBackgroundColor() << "}{";
needEndL = !maybeBeginL.empty();
}
os << "\\makebox";
@@ -537,7 +537,7 @@ void InsetBox::latex(otexstream & os, OutputParams const &
runparams) const
os << "[" << params_.hor_pos << "]";
} else {
if (params_.backgroundcolor != "none") {
- os << maybeBeginL << "\\colorbox{" <<
params_.backgroundcolor << "}";
+ os << maybeBeginL << "\\colorbox{" <<
getBackgroundColor() << "}";
needEndL = !maybeBeginL.empty();
}
else
@@ -547,7 +547,7 @@ void InsetBox::latex(otexstream & os, OutputParams const &
runparams) const
}
else {
if (params_.backgroundcolor != "none" && btype ==
Frameless) {
- os << maybeBeginL << "\\colorbox{" <<
params_.backgroundcolor << "}{";
+ os << maybeBeginL << "\\colorbox{" <<
getBackgroundColor() << "}{";
needEndL = !maybeBeginL.empty();
}
os << "\\begin{minipage}";
--
lyx-cvs mailing list
[email protected]
https://lists.lyx.org/mailman/listinfo/lyx-cvs