[Tex/LaTex] Replace quotation marks (or: use << and >> as csquote like auto-quotes)

csquotespunctuationxetex

I use french quotation marks (<< and >>) in many documents. Is there any way I can define in the style file to replace all french quotation marks by english ones?

Furthermore I'd like to have english quotation marks no matter if I type <<hello>> or "hello". Is this possible?

EDIT: I read about the package csquotes but did not manage to replace my french marks because it seems like only single characters are allowed.

\documentclass[a4paper]{article}
\usepackage{polyglossia}
\setdefaultlanguage[]{english}

\setsansfont[Ligatures=TeX,Mapping=tex-text]{Open Sans}
\setmainfont[Ligatures=TeX,Mapping=tex-text]{Open Sans}
\setmonofont[]{Consolas}

\usepackage[autostyle=true,english=british]{csquotes}
\MakeOuterQuote{"}
\MakeAutoQuote{<}{>}

\begin{document}


"An example using normal quotes"

< Example >

<<Second Example using french quotes>>

``Should look like this''

\end{document}

enter image description here

If I make < and >as my AutoQuote Delimiters, the original Quotation Marks are treated like nested quotations. Any suggestions to work around this?

Best Answer

With \MakeOuterQuote (and \MakeInnerQuote) you can define a single character such as " that is use for opening and closing quotes. With \MakeAutoQuote you must define two distinct characters, such as > and < for opening and closing. In the latter case csquotes can find the quotation level itself.

Here’s an example how to use \MakeAutoQuote. By default the output quotation marks ar set language depend, but that can be changed by options.

\documentclass[english]{article}

\usepackage{babel}

\usepackage{csquotes}
    \MakeOuterQuote{"}
    \MakeAutoQuote{>}{<}

\begin{document}
>Test automatic outer and >inner< quotes<

"Test manual outer quotes"
\end{document}

result

It is impossible to use >> or << as a delimiter since it must be a single character. So you may use the search and replace feature of your editor to change this …