A short description of the problem
In a bilingual document whose main language is Hebrew and whose secondary language is English, using the csquotes
package to typeset quotes produces wrong quotation marks even when the active language is set to English.
A demonstration of the problem by way of a minimal working example
I will perform two "experiments" in order to compare their results. I consider the results of the first experiment as demonstrating expected, desirable behavior, whereas the results of the second experiment demonstrate unexpected, undesirable behavior.
Experiment 1: Expected, desirable behavior
I saved the following LaTeX code in ~/Test.tex
.
\documentclass{article}
%\usepackage[bidi=basic,english,hebrew,provide=*]{babel}
%\babelfont{rm}[Renderer=HarfBuzz]{FreeSerif}
\usepackage{csquotes}
\begin{document}
%\selectlanguage{english}
\enquote{hello}
\end{document}
The code typesets the word hello as a quote, using the quoting mechanism provided by the package csquotes
.
I then executed the following commands in the Terminal:
> cd ~
> lualatex Test
The compilation completed successfully. The file ~/Test.log
contained no warnings. As a result of the compilation, the file ~/Test.pdf
was created. When opened in a PDF viewer, the file displayed as follows. (I screenshot only the relevant part of the display.)
Experiment 2: Unexpected, undesirable behavior
In the LaTeX code listed above I uncommented the three commented-out lines. The resulting code uses the babel
package to configure the document's main language as Hebrew, and the document's secondary language as English. The document's body sets the active language to be English, and then typesets the word hello as a quote, using the quoting mechanism provided by the package csquotes
.
Compiling as before, the compilation completed successfully, however ~/Test.log
contained a single warning:
Package csquotes Warning: No style for language 'hebrew'.
(csquotes) Using fallback style on input line 7.
And ~/Test.pdf
displayed as follows.
As can be seen, the quotation marks used are ?
rather than "
as in the first experiment.
Questions
In the second experiment, why didn't the quotation marks typeset as
"
as in the first experiment, despite the fact that the active language at the time the quote was typeset was English?How to change the second example in such as a way as to achieve a correct typesetting of English quotations, while keeping the document a bilingual Hebrew-English document as configured by
babel
?
Similar questions
This question is similar to mine, however in that question the English quotation marks are typeset correctly, whereas in mine they are not.
\usepackage[autostyle]{csquotes}
if you want that it adapts the quotes to the "local" language.