commit 88a2414839f7dd29ae086482612c001b72a61ebe
Author: Juergen Spitzmueller <[email protected]>
Date: Fri Mar 1 07:18:28 2024 +0100
Do not \cprotect in table cells
---
src/Paragraph.cpp | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/Paragraph.cpp b/src/Paragraph.cpp
index 1d4861e64e..49713a8b9a 100644
--- a/src/Paragraph.cpp
+++ b/src/Paragraph.cpp
@@ -4284,9 +4284,10 @@ bool Paragraph::isHardHyphenOrApostrophe(pos_type pos)
const
bool Paragraph::needsCProtection(bool const fragile) const
{
// first check the layout of the paragraph, but only in insets
+ // and not in tables
InsetText const * textinset = inInset().asInsetText();
bool const maintext = textinset
- ? textinset->text().isMainText()
+ ? textinset->text().isMainText() || inInset().lyxCode() ==
CELL_CODE
: false;
if (!maintext && layout().needcprotect) {
--
lyx-cvs mailing list
[email protected]
http://lists.lyx.org/mailman/listinfo/lyx-cvs