2

There are many related questions and answers. I looked at Installing EB Garamond for pdfLaTeX (encore) and tried the lua answer there. lualatex from a freshly instlled Miktex on this MWE

\documentclass{memoir}
\usepackage{fontspec}
\setmainfont[Ligatures=TeX]{EB Garamond}
\begin{document}

The Quick Brown Fox Jumps Over The Lazy Dog. 0123456789 

\emph{Try italics.} \\
{\bfseries Try bold face} \\
{\scshape Try small caps} \\

\end{document}

produces

starting package maintenance...
installation directory: C:\Users\eb\AppData\Roaming\MiKTeX\2.9
package repository: http://mirrors.rit.edu/CTAN/systems/win32/miktex/tm/packages/
lightweight database digest: 8a9d030e8c8fa3aaa59a4f1bbb445ea5
going to download 8096508 bytes
going to install 181 file(s) (1 package(s))
downloading http://mirrors.rit.edu/CTAN/systems/win32/miktex/tm/packages/tipa.tar.lzma...
8096508 bytes, 765.27 KB/Sec
extracting files from tipa.tar.lzma...
======================================================================

(C:/Users/eb/AppData/Roaming/MiKTeX/2.9//tex/latex/tipa/t3enc.def(save: C:/Users
/eb/AppData/Local/MiKTeX/2.9/luatex-cache/generic/fonts/otf/lmromanslant10-regul
ar.lua)(save: C:/Users/eb/AppData/Local/MiKTeX/2.9/luatex-cache/generic/fonts/ot
f/lmromanslant10-regular.luc)(save: C:/Users/eb/AppData/Local/MiKTeX/2.9/luatex-
cache/generic/fonts/otf/lmroman10-italic.lua)(save: C:/Users/eb/AppData/Local/Mi
KTeX/2.9/luatex-cache/generic/fonts/otf/lmroman10-italic.luc)(save: C:/Users/eb/
AppData/Local/MiKTeX/2.9/luatex-cache/generic/fonts/otf/lmroman10-bold.lua)(save
: C:/Users/eb/AppData/Local/MiKTeX/2.9/luatex-cache/generic/fonts/otf/lmroman10-
bold.luc) ("C:/Program Files (x86)/MiKTeX 2.9/tex/latex/euenc/eu2lmss.fd")(save:
 C:/Users/eb/AppData/Local/MiKTeX/2.9/luatex-cache/generic/fonts/otf/lmsans10-re
gular.lua)(save: C:/Users/eb/AppData/Local/MiKTeX/2.9/luatex-cache/generic/fonts
/otf/lmsans10-regular.luc))
("C:/Program Files (x86)/MiKTeX 2.9/tex/latex/graphics/graphicx.sty"
("C:/Program Files (x86)/MiKTeX 2.9/tex/latex/graphics/keyval.sty")
("C:/Program Files (x86)/MiKTeX 2.9/tex/latex/graphics/graphics.sty"
("C:/Program Files (x86)/MiKTeX 2.9/tex/latex/graphics/trig.sty")
("C:/Program Files (x86)/MiKTeX 2.9/tex/latex/00miktex/graphics.cfg")
("C:/Program Files (x86)/MiKTeX 2.9/tex/latex/pdftex-def/pdftex.def"
("C:/Program Files (x86)/MiKTeX 2.9/tex/generic/oberdiek/ltxcmds.sty")
("C:/Program Files (x86)/MiKTeX 2.9/tex/generic/oberdiek/pdftexcmds.sty"
(C:/Program Files (x86)/MiKTeX 2.9/scripts/oberdiek/pdftexcmds.lua))))))
("C:/Program Files (x86)/MiKTeX 2.9/tex/latex/fontspec/fontspec.cfg")))
luaotfload | cache : No lookup cache, creating empty.
luaotfload | db : Reload initiated; reason: "unresolved font name: 'ebgaramond12
'"
luaotfload | db : Font index saved

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!
! fontspec error: "font-not-found"
! 
! The font "EBGaramond12" cannot be found.

The Miktex package manager says ebgaramond is there.

The fontspec documentation is pretty dense.

I've looked at http://docs.miktex.org/manual/advanced.html#psfonts, to no avail.I can't examine updmap.cfg because windows 7 search doesn't find it and I don't know where to look by hand.

Edit: As per @UlrikeFischer comment:

eb@7J8B8W1 ~
$  luaotfload-tool -u -vv
...
luaotfload | util : Task completed successfully

eb@7J8B8W1 ~
$  luaotfload-tool --alias=luaotfload-tool --find="ebgaramond"
luaotfload | resolve : Cannot find "ebgaramond".

Edit: Progress! \usepackage{ebgaramond} works with pdflatex. (The bold face doesn't, but according to a comment elsewhere by @egreg I shouldn't want it anyway.)

Perhaps I should move my whole project from luatex to pdftex.

Ethan Bolker
  • 9,333
  • 3
  • 42
  • 69
  • Do lualatex works if you use \setmainfont{Arial}? – Ulrike Fischer Jun 10 '14 at 15:24
  • @UlrikeFischer yes, Arial works. (So does arial.) – Ethan Bolker Jun 10 '14 at 15:29
  • Does \setmainfont{EB Garamond 12} work? – cfr Jun 10 '14 at 17:31
  • @cfr No. The 12 doesn't help. – Ethan Bolker Jun 10 '14 at 17:34
  • 1
    Are you sure that you have installed the OpenType version of EB Garamond? –  Jun 10 '14 at 17:59
  • I've only installed what came automatically with miktex. – Ethan Bolker Jun 10 '14 at 18:01
  • Can you tell which fonts were installed as part of MikTeX's ebgaramond package? In particular, do you have only the type1 fonts (pfb files) or do you have opentype (otf) as well? – cfr Jun 10 '14 at 21:00
  • @cfr The Miktex package manager lists files EBGaramond12-Italic.otf and 12-Regular.otf, and .pfb files with the same names. – Ethan Bolker Jun 10 '14 at 21:33
  • The name of your lua cache is odd. Is your miktex up-to-date? Did you run update with the user and admin update manager? Does the cache file contains an entry for ebgaramond? – Ulrike Fischer Jun 10 '14 at 21:54
  • @UlrikeFischer I just uninstalled miktex and reinstalled the latest version. I get essentially the same error message - newer version in the edited question. – Ethan Bolker Jun 11 '14 at 00:46
  • 1
    Can you try compiling a file which loads ebgaramond using pdfTeX? If MiKTeX can't find the type1 versions either, that might suggest that the package just didn't get installed properly at all. – cfr Jun 11 '14 at 01:22
  • Update on a command line the luaotfload database (luaotfload-tool -u -vv) (if it hangs somewhere you will have to blacklist the fonts). Then check with luaotfload-tool --alias=luaotfload-tool --find="ebgaramond" if the font is found. – Ulrike Fischer Jun 11 '14 at 06:48
  • @UlrikeFischer lua can't find the font - see edited question – Ethan Bolker Jun 11 '14 at 12:26
  • @cfr I don't know how to tell pdftex to try ebgaramond. Searches on this site haven't helped me yet. http://tex.stackexchange.com/questions/138718/installing-ebgaramond-for-pdflatex is for ubuntu. – Ethan Bolker Jun 11 '14 at 13:28
  • What command line did you use? Are you sure you are using miktex there? If you want to use the font with pdflatex: \usepackage{ebgaramond} should work directly (naturally without fontspec + setmainfont). – Ulrike Fischer Jun 11 '14 at 13:33
  • @UlrikeFischer Works with pdftex - question edited to say so. – Ethan Bolker Jun 11 '14 at 13:43
  • It isn't that the bold face doesn't work. EB Garamond does not have a bold face by design. – cfr Jun 11 '14 at 15:54
  • @cfr I understand that - it's the essence of egreg's design comment. – Ethan Bolker Jun 11 '14 at 18:56
  • @cfr If you post "use pdflatex instead of lua" as an answer I'll accept it since it serves my purpose. I'll leave the question up since others may need a lua solution. – Ethan Bolker Jun 11 '14 at 20:16
  • @EthanBolker OK. I've posted an answer as requested. Sorry not to help with the lua case - I don't use MiKTeX, I'm afraid. – cfr Jun 11 '14 at 21:46

1 Answers1

6

Provided the type1 fonts have been correctly installed by the package manager, one option may be to use pdfLaTeX for compilation:

\documentclass{memoir}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{ebgaramond}

\begin{document}

  \centering
  The Quick Brown Fox Jumps Over The Lazy Dog.\\
  0123456789\\
  \emph{Try italics.}\\
  {\scshape Try small caps.}

\end{document}

EB Garamond type1

I have omitted the bold test since EB Garamond lacks a bold face by design.

cfr
  • 198,882
  • As per the discussion at http://meta.tex.stackexchange.com/questions/4459/answers-that-solve-the-problem-without-answering-the-question?cb=1 I'm unaccepting this answer - but leaving the upvote and hoping for upvotes from others. – Ethan Bolker Jun 24 '14 at 13:22
  • @EthanBolker As a participant in that discussion, that seems good to me ;). I hope some Lua guru will happen along to actually answer the question! – cfr Jun 24 '14 at 21:10