You don’t need to change to math mode every time you want to type a greek letter in normal text. Loading the textgreek
package allows typesetting greek letters, generally just by adding a text
-prefix to the letter name, e.g. for it would be:
\usepackage{textgreek} ... \textDelta\textbeta
The letters will adapt to the font style you are using (bold, italics, small capitals, etc.)
Furthermore, the author provides three different font types, cbgreek
(default), euler
, and artemisia
. The font type can be change through the optional argument, when loading the package:
\usepackage[euler]{textgreek}
The differences are minor for most letters, check the documentation for details.
Complete command list (copied from the documentation):
Note, is an exception. Since the
textcomp
package already provided a command textmu
, the author decided to call it textmugreek
instead. Use the latter to avoid unexpected results.
For better results with greek *language* use babel or xetex. The greek letters in math mode are just symbols (no stresses or accents in a straightforward way)
Good tip however
Thank you for the comment. I agree, writing a text with these commands would be a pain. Best, Tom.
It’s good to know, however. Thanks, Tom!
What’s the difference with using
\ensuremath{\alpha}
…Any way, what’s the problem with typing
$\beta$
everytime ?Hi there,
The main advantage probably is that you don’t have to worry about font style (e.g. bold), it works just like for normal text. Also, the letters are not in italics by default. Other than that, I think you are right, it’s a personal choice whether you prefer switching to math mode or using the
textgreek
package.By the way, for bold symbols in math mode use:
Ensuremath
has it’s own problems (see here for a discussion), but is also a valid choice in most cases.Best, Tom.
Great guide! I will use it from now on! But…
I am having trouble using this with
\usepackage[sc]{mathpazo}
that I put to use the Palatino font.Greek letters (e.g.,
\textbeta
)(1) look ugly and pixelated (when zoomed in)
(2) are not modified by
\textbf
and such(3) are not similar to the Palatino font
If I remove the mathpazo package everything works (but I get the standard LaTeX font).
Does anyone know a workaround for this? I know (3) is not the packages fault, but I would love to have upright greek fonts Palatino-like.
Thanks
If you are keen, you can try customizing
\textgreekfontmap
. See the package documentation for more information. Best, Tom.Thanks Tom!
Was wondering a long time, whether this would be possible. Thanks!
Noticed, that the optional package is named “artemisia”, not “anthemisia” like written above.
Corrected, many thanks!
In case anyone had the same problem as me… this was the top google result for me, and it works, except LaTeX ignores spaces after I use it. e.g. \textalpha helix comes out as αhelix. A simple way to get around this is using {} brackets. \textalpha{ }helix comes out right.
Thanks for your comment! Best, Tom.
Hey do you know a way of using those in the acronym package?
sry figured the problem out by myself 🙂 was no problem with the package itself
no problem, thanks for the feedback.
Hi. I tried to use the package textgreek. However, even with a very minimal example (see below), I get pixelated fonts. What is the issue?
Hi Enrico,
Not sure what Editor/OS you are on. Perhaps the problem is with your PDF viewer. Did you try looking the the PDF with Acrobat/Preview?
Best, Tom