使用 csquotes 包实现不同的引号

使用 csquotes 包实现不同的引号

对于德语文档,我使用csquotes软件包的 guillemets 选项。但文档中有一节我想使用德语的“常规”引号——“常规”表示不选择 guillemets 选项时获得的引号。可以同时使用两者吗?如果可以,如何操作?

为了说清楚,让我补充一点,我想要的是该csquotes包中适用于两种引号类型的功能。

对此的 MWE 如下:

\documentclass{memoir}

\usepackage[german]{babel}

\usepackage[
  german = guillemets,%quotes,<- I'd like to have both quot. marks in the same document
  autostyle = true,
  autopunct,
  csdisplay = true,
]{csquotes}


\begin{document}
Written in English but \enquote{meant to be used} in a document written in German.
\end{document}    

答案1

如果您想保留csquotes功能,只需使用

\setquotestyle[quotes]{german}

\setquotestyle[guillemets]{german}

梅威瑟:

\documentclass{memoir}

\usepackage[german]{babel}

\usepackage[
  german = guillemets,%quotes,<- I'd like to have both quot. marks in the same document
  autostyle = true,
  autopunct,
  csdisplay = true,
]{csquotes}

\begin{document}
Written in English but \enquote{meant to be used} in a document written in German.

\setquotestyle[quotes]{german}
Written in English but \enquote{meant to be used} in a document written in German.

\setquotestyle[guillemets]{german}
Written in English but \enquote{meant to be used} in a document written in German.

\end{document} 

输出

在此处输入图片描述

否则,您始终可以使用\glqq\grqq

\documentclass{memoir}

\usepackage[german]{babel}

\usepackage[
  german = guillemets,%quotes,<- I'd like to have both quot. marks in the same document
  autostyle = true,
  autopunct,
  csdisplay = true,
]{csquotes}

\newcommand{\defaultquote}[1]{\glqq #1\grqq}

\begin{document}
Written in English but \enquote{meant to be used} in a document written in German.

Written in English but \defaultquote{meant to be used} in a document written in  German.

\end{document}

输出

在此处输入图片描述

相关内容