Guillemets (»«) symbol in LaTeX
In this tutorial, I will show you how to get the Guillemets symbol in LaTeX and how can you replace this "..." with «...».
The following table lists the commands and output required to print these symbols in LaTeX.
| Command | Output |
|---|---|
\guillemetleft | « |
\guillemetright | » |
\guilsinglleft | ‹ |
\guilsinglright | › |
Before using these commands, you need to load the T1 font encoding with the fontenc package. Like this.
\usepackage[T1]{fontenc}
\documentclass{article}
\usepackage[T1]{fontenc}
\begin{document}
\verb|\guillemetleft| $\rightarrow$ \guillemetleft
\verb|\guillemetright| $\rightarrow$ \guillemetright
\verb|\guilsinglleft| $\rightarrow$ \guilsinglleft
\verb|\guilsinglright| $\rightarrow$ \guilsinglright
\guillemetleft text\guillemetright
\guilsinglleft text\guilsinglright
\end{document}Output:

Also, you can put << and >> directly from the keyboard. But in this case, you have to load the lmodern package in the preamble of your document. Take a look.
\documentclass{article}
\usepackage{lmodern}
\begin{document}
My name is <<Parvez>> and I write <<latex>> tutorials on <<codespeedy>>.
\end{document}Output:

How to replace this “…” with «…» in LaTeX
To replace all "..." symbols used in a document with «...», you need to use the csquotes package, and be sure to set the language using the babel package. And Use this \MakeOuterQuote{"} in the preamble of your document. You can understand better if you see the example below.
\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{csquotes}
\usepackage[french]{babel} % or use [francais]
\MakeOuterQuote{"}
\begin{document}
"text"
My name is "Parvez" and I write "latex" tutorials on "codespeedy".
\end{document}Output:

Also, you can use \og ...\fg{} other than "...". The \og ...\fg{} will also replaced by the «...». But in this case, you don’t have to use the \MakeOuterQuote{"} option. Take a look.
\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{csquotes}
\usepackage[french]{babel}
\begin{document}
My name is \og Parvez\fg{} and I write \og latex\fg{} tutorials on \og codespeedy\fg{}.
\end{document}Output:

Leave a Reply