From 449a89825b38b730a5f47b0fc5329ebe10a3278c Mon Sep 17 00:00:00 2001 From: Juergen Spitzmueller Date: Sat, 10 Dec 2016 16:13:02 +0100 Subject: [PATCH] Fix xhtml output of French double guillemets (spacing) --- src/insets/InsetQuotes.cpp | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/src/insets/InsetQuotes.cpp b/src/insets/InsetQuotes.cpp index e4f058c6e2..29d9251697 100644 --- a/src/insets/InsetQuotes.cpp +++ b/src/insets/InsetQuotes.cpp @@ -309,7 +309,19 @@ int InsetQuotes::plaintext(odocstringstream & os, docstring InsetQuotes::getQuoteEntity() const { const int quoteind = quote_index[side_][language_]; - return from_ascii(html_quote[times_][quoteind]); + docstring res = from_ascii(html_quote[times_][quoteind]); + // in French, thin spaces are added inside double guillemets + // FIXME: this should be done by a separate quote type. + if (prefixIs(context_lang_, "fr") + && times_ == DoubleQuotes && language_ == FrenchQuotes) { + // THIN SPACE (U+2009) + docstring const thin_space = from_ascii(" "); + if (side_ == LeftQuote) + res += thin_space; + else + res = thin_space + res; + } + return res; } -- 2.39.2