How can my master.tex file find font files stored in a subfolder to my working directory?
up vote
2
down vote
favorite
I need to use the font Gotham Rounded, and have so far placed the eights font files (.otf) in my working folder, i.e. the folder containing my master.tex file. This works fine. When compiling my masterfile XeLatex produces a Pdf of my manuscript with the Gotham font.
However, if I move the eight font files to a subfolder ("myFonts") of my working folder, then XeLaTeX is not able to find them.
How do I tell XeLaTeX where I have placed my font files? Can I set the path to the font files somewhere, and how will the path look?
In my preable I have placed the following code for my font choise:
usepackage{fontspec}
% Gotham Rounded
setmainfont[
BoldFont=GothamRnd-Bold.otf,
ItalicFont=GothamRnd-LightIta.otf,
BoldItalicFont=GothamRnd-BoldIta.otf,
]{GothamRnd-Light.otf}
Thanks for any help!
fonts fontspec
add a comment |
up vote
2
down vote
favorite
I need to use the font Gotham Rounded, and have so far placed the eights font files (.otf) in my working folder, i.e. the folder containing my master.tex file. This works fine. When compiling my masterfile XeLatex produces a Pdf of my manuscript with the Gotham font.
However, if I move the eight font files to a subfolder ("myFonts") of my working folder, then XeLaTeX is not able to find them.
How do I tell XeLaTeX where I have placed my font files? Can I set the path to the font files somewhere, and how will the path look?
In my preable I have placed the following code for my font choise:
usepackage{fontspec}
% Gotham Rounded
setmainfont[
BoldFont=GothamRnd-Bold.otf,
ItalicFont=GothamRnd-LightIta.otf,
BoldItalicFont=GothamRnd-BoldIta.otf,
]{GothamRnd-Light.otf}
Thanks for any help!
fonts fontspec
1
Generally, addingPath=./myFonts/,to the options should work
– egreg
4 hours ago
Thanks. Where exactly do I add the string "Path =./myFonts/ " ?
– myotis
3 hours ago
In the options tosetmainfont
– egreg
3 hours ago
add a comment |
up vote
2
down vote
favorite
up vote
2
down vote
favorite
I need to use the font Gotham Rounded, and have so far placed the eights font files (.otf) in my working folder, i.e. the folder containing my master.tex file. This works fine. When compiling my masterfile XeLatex produces a Pdf of my manuscript with the Gotham font.
However, if I move the eight font files to a subfolder ("myFonts") of my working folder, then XeLaTeX is not able to find them.
How do I tell XeLaTeX where I have placed my font files? Can I set the path to the font files somewhere, and how will the path look?
In my preable I have placed the following code for my font choise:
usepackage{fontspec}
% Gotham Rounded
setmainfont[
BoldFont=GothamRnd-Bold.otf,
ItalicFont=GothamRnd-LightIta.otf,
BoldItalicFont=GothamRnd-BoldIta.otf,
]{GothamRnd-Light.otf}
Thanks for any help!
fonts fontspec
I need to use the font Gotham Rounded, and have so far placed the eights font files (.otf) in my working folder, i.e. the folder containing my master.tex file. This works fine. When compiling my masterfile XeLatex produces a Pdf of my manuscript with the Gotham font.
However, if I move the eight font files to a subfolder ("myFonts") of my working folder, then XeLaTeX is not able to find them.
How do I tell XeLaTeX where I have placed my font files? Can I set the path to the font files somewhere, and how will the path look?
In my preable I have placed the following code for my font choise:
usepackage{fontspec}
% Gotham Rounded
setmainfont[
BoldFont=GothamRnd-Bold.otf,
ItalicFont=GothamRnd-LightIta.otf,
BoldItalicFont=GothamRnd-BoldIta.otf,
]{GothamRnd-Light.otf}
Thanks for any help!
fonts fontspec
fonts fontspec
asked 4 hours ago
myotis
4541314
4541314
1
Generally, addingPath=./myFonts/,to the options should work
– egreg
4 hours ago
Thanks. Where exactly do I add the string "Path =./myFonts/ " ?
– myotis
3 hours ago
In the options tosetmainfont
– egreg
3 hours ago
add a comment |
1
Generally, addingPath=./myFonts/,to the options should work
– egreg
4 hours ago
Thanks. Where exactly do I add the string "Path =./myFonts/ " ?
– myotis
3 hours ago
In the options tosetmainfont
– egreg
3 hours ago
1
1
Generally, adding
Path=./myFonts/, to the options should work– egreg
4 hours ago
Generally, adding
Path=./myFonts/, to the options should work– egreg
4 hours ago
Thanks. Where exactly do I add the string "Path =./myFonts/ " ?
– myotis
3 hours ago
Thanks. Where exactly do I add the string "Path =./myFonts/ " ?
– myotis
3 hours ago
In the options to
setmainfont– egreg
3 hours ago
In the options to
setmainfont– egreg
3 hours ago
add a comment |
1 Answer
1
active
oldest
votes
up vote
2
down vote
Just add the path. I also recommend a clearer syntax.
usepackage{fontspec}
% Gotham Rounded
setmainfont{GothamRnd}[
Path=./MyFonts/,
Extension=.otf,
UprightFont=*-Light,
BoldFont=*-Bold,
ItalicFont=*-LightIta,
BoldItalicFont=*-BoldIta,
]
The * stands for the main argument to setmainfont.
Thanks a lot! I will test out your solution soon.
– myotis
2 hours ago
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
2
down vote
Just add the path. I also recommend a clearer syntax.
usepackage{fontspec}
% Gotham Rounded
setmainfont{GothamRnd}[
Path=./MyFonts/,
Extension=.otf,
UprightFont=*-Light,
BoldFont=*-Bold,
ItalicFont=*-LightIta,
BoldItalicFont=*-BoldIta,
]
The * stands for the main argument to setmainfont.
Thanks a lot! I will test out your solution soon.
– myotis
2 hours ago
add a comment |
up vote
2
down vote
Just add the path. I also recommend a clearer syntax.
usepackage{fontspec}
% Gotham Rounded
setmainfont{GothamRnd}[
Path=./MyFonts/,
Extension=.otf,
UprightFont=*-Light,
BoldFont=*-Bold,
ItalicFont=*-LightIta,
BoldItalicFont=*-BoldIta,
]
The * stands for the main argument to setmainfont.
Thanks a lot! I will test out your solution soon.
– myotis
2 hours ago
add a comment |
up vote
2
down vote
up vote
2
down vote
Just add the path. I also recommend a clearer syntax.
usepackage{fontspec}
% Gotham Rounded
setmainfont{GothamRnd}[
Path=./MyFonts/,
Extension=.otf,
UprightFont=*-Light,
BoldFont=*-Bold,
ItalicFont=*-LightIta,
BoldItalicFont=*-BoldIta,
]
The * stands for the main argument to setmainfont.
Just add the path. I also recommend a clearer syntax.
usepackage{fontspec}
% Gotham Rounded
setmainfont{GothamRnd}[
Path=./MyFonts/,
Extension=.otf,
UprightFont=*-Light,
BoldFont=*-Bold,
ItalicFont=*-LightIta,
BoldItalicFont=*-BoldIta,
]
The * stands for the main argument to setmainfont.
answered 3 hours ago
egreg
702k8618723146
702k8618723146
Thanks a lot! I will test out your solution soon.
– myotis
2 hours ago
add a comment |
Thanks a lot! I will test out your solution soon.
– myotis
2 hours ago
Thanks a lot! I will test out your solution soon.
– myotis
2 hours ago
Thanks a lot! I will test out your solution soon.
– myotis
2 hours ago
add a comment |
Thanks for contributing an answer to TeX - LaTeX Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f463220%2fhow-can-my-master-tex-file-find-font-files-stored-in-a-subfolder-to-my-working-d%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
Generally, adding
Path=./myFonts/,to the options should work– egreg
4 hours ago
Thanks. Where exactly do I add the string "Path =./myFonts/ " ?
– myotis
3 hours ago
In the options to
setmainfont– egreg
3 hours ago