[LyX/master] Less expensive OP first as this might be called often.

Pavel Sanda sanda at lyx.org
Wed May 10 09:36:58 UTC 2023


commit b198a36a363bb6a084407d476942d68ef5fb5e86
Author: Pavel Sanda <sanda at lyx.org>
Date:   Wed May 10 12:43:14 2023 +0200

    Less expensive OP first as this might be called often.
---
 src/insets/InsetQuotes.cpp |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/insets/InsetQuotes.cpp b/src/insets/InsetQuotes.cpp
index 9896ec8..f582360 100644
--- a/src/insets/InsetQuotes.cpp
+++ b/src/insets/InsetQuotes.cpp
@@ -1031,11 +1031,11 @@ pair<int, int> InsetQuotes::isWords() const
 		QuoteStyle style = (style_ == QuoteStyle::Dynamic) ? global_style_ : style_;
 
 		// in French, thin spaces are added inside double guillemets
-		if (prefixIs(context_lang_, "fr")
-		    && level_ == QuoteLevel::Primary
+		if (level_ == QuoteLevel::Primary
 		    && (style == QuoteStyle::Swiss
 			|| style == QuoteStyle::French
-			|| style == QuoteStyle::FrenchIN)) {
+			|| style == QuoteStyle::FrenchIN)
+		    && prefixIs(context_lang_, "fr")) {
 			// space added by default for all formats
 			length++;
 		}


More information about the lyx-cvs mailing list