Why custom TEX command for labels does not work in MetaPost?
up vote
2
down vote
favorite
I'm trying to use text labels in MetaPost with TeX. The problem is that -tex=... option of MetaPost does not work.
This example works with mpost test.mp:
prologues := 3;
beginfig(1);
label.lrt("e", (0,0));
endfig;
end
This example does not work with mpost -tex=csplain test.mp:
prologues := 3;
beginfig(1);
label.lrt("é", (0,0));
endfig;
end
(csplain is provided by texlive-lang-czechslovak package)
Why -tex=... option of MetaPost does not work?
metapost
|
show 2 more comments
up vote
2
down vote
favorite
I'm trying to use text labels in MetaPost with TeX. The problem is that -tex=... option of MetaPost does not work.
This example works with mpost test.mp:
prologues := 3;
beginfig(1);
label.lrt("e", (0,0));
endfig;
end
This example does not work with mpost -tex=csplain test.mp:
prologues := 3;
beginfig(1);
label.lrt("é", (0,0));
endfig;
end
(csplain is provided by texlive-lang-czechslovak package)
Why -tex=... option of MetaPost does not work?
metapost
Usebtex é etexor see 8.2 “Font Map Files” of the manual.
– Henri Menke
yesterday
@HenriMenkebtex ... etexworks. Is it possible to usepkfonts? (I get this warning:Warning: font lhr10 cannot be found in any fontmapfile!)
– Igor Liferenko
yesterday
I'm not a font expert but don'tpkfonts only have 128 slots? I don't think they haveéencoded. Also if you're not usingbtex ... etexMetaPost does not need a TeX engine and the parameter-tex=csplainis ignored.
– Henri Menke
yesterday
@HenriMenkepkfonts can use 256 slots; for example, to use pk-variant ofé, runcsplain test.tex+dvips testwith the following~/.dvipsrc:p /dev/null
– Igor Liferenko
yesterday
@HenriMenke The number of slots is just a function of the encoding. T1 has 256. OT1 has 128. (Just examples.) That's just the TFM stuff. What kind of thing tells TeX what goes in the boxes the TFM describes is another matter.
– cfr
19 hours ago
|
show 2 more comments
up vote
2
down vote
favorite
up vote
2
down vote
favorite
I'm trying to use text labels in MetaPost with TeX. The problem is that -tex=... option of MetaPost does not work.
This example works with mpost test.mp:
prologues := 3;
beginfig(1);
label.lrt("e", (0,0));
endfig;
end
This example does not work with mpost -tex=csplain test.mp:
prologues := 3;
beginfig(1);
label.lrt("é", (0,0));
endfig;
end
(csplain is provided by texlive-lang-czechslovak package)
Why -tex=... option of MetaPost does not work?
metapost
I'm trying to use text labels in MetaPost with TeX. The problem is that -tex=... option of MetaPost does not work.
This example works with mpost test.mp:
prologues := 3;
beginfig(1);
label.lrt("e", (0,0));
endfig;
end
This example does not work with mpost -tex=csplain test.mp:
prologues := 3;
beginfig(1);
label.lrt("é", (0,0));
endfig;
end
(csplain is provided by texlive-lang-czechslovak package)
Why -tex=... option of MetaPost does not work?
metapost
metapost
asked yesterday
Igor Liferenko
2,025729
2,025729
Usebtex é etexor see 8.2 “Font Map Files” of the manual.
– Henri Menke
yesterday
@HenriMenkebtex ... etexworks. Is it possible to usepkfonts? (I get this warning:Warning: font lhr10 cannot be found in any fontmapfile!)
– Igor Liferenko
yesterday
I'm not a font expert but don'tpkfonts only have 128 slots? I don't think they haveéencoded. Also if you're not usingbtex ... etexMetaPost does not need a TeX engine and the parameter-tex=csplainis ignored.
– Henri Menke
yesterday
@HenriMenkepkfonts can use 256 slots; for example, to use pk-variant ofé, runcsplain test.tex+dvips testwith the following~/.dvipsrc:p /dev/null
– Igor Liferenko
yesterday
@HenriMenke The number of slots is just a function of the encoding. T1 has 256. OT1 has 128. (Just examples.) That's just the TFM stuff. What kind of thing tells TeX what goes in the boxes the TFM describes is another matter.
– cfr
19 hours ago
|
show 2 more comments
Usebtex é etexor see 8.2 “Font Map Files” of the manual.
– Henri Menke
yesterday
@HenriMenkebtex ... etexworks. Is it possible to usepkfonts? (I get this warning:Warning: font lhr10 cannot be found in any fontmapfile!)
– Igor Liferenko
yesterday
I'm not a font expert but don'tpkfonts only have 128 slots? I don't think they haveéencoded. Also if you're not usingbtex ... etexMetaPost does not need a TeX engine and the parameter-tex=csplainis ignored.
– Henri Menke
yesterday
@HenriMenkepkfonts can use 256 slots; for example, to use pk-variant ofé, runcsplain test.tex+dvips testwith the following~/.dvipsrc:p /dev/null
– Igor Liferenko
yesterday
@HenriMenke The number of slots is just a function of the encoding. T1 has 256. OT1 has 128. (Just examples.) That's just the TFM stuff. What kind of thing tells TeX what goes in the boxes the TFM describes is another matter.
– cfr
19 hours ago
Use
btex é etex or see 8.2 “Font Map Files” of the manual.– Henri Menke
yesterday
Use
btex é etex or see 8.2 “Font Map Files” of the manual.– Henri Menke
yesterday
@HenriMenke
btex ... etex works. Is it possible to use pk fonts? (I get this warning: Warning: font lhr10 cannot be found in any fontmapfile!)– Igor Liferenko
yesterday
@HenriMenke
btex ... etex works. Is it possible to use pk fonts? (I get this warning: Warning: font lhr10 cannot be found in any fontmapfile!)– Igor Liferenko
yesterday
I'm not a font expert but don't
pk fonts only have 128 slots? I don't think they have é encoded. Also if you're not using btex ... etex MetaPost does not need a TeX engine and the parameter -tex=csplain is ignored.– Henri Menke
yesterday
I'm not a font expert but don't
pk fonts only have 128 slots? I don't think they have é encoded. Also if you're not using btex ... etex MetaPost does not need a TeX engine and the parameter -tex=csplain is ignored.– Henri Menke
yesterday
@HenriMenke
pk fonts can use 256 slots; for example, to use pk-variant of é, run csplain test.tex + dvips test with the following ~/.dvipsrc: p /dev/null– Igor Liferenko
yesterday
@HenriMenke
pk fonts can use 256 slots; for example, to use pk-variant of é, run csplain test.tex + dvips test with the following ~/.dvipsrc: p /dev/null– Igor Liferenko
yesterday
@HenriMenke The number of slots is just a function of the encoding. T1 has 256. OT1 has 128. (Just examples.) That's just the TFM stuff. What kind of thing tells TeX what goes in the boxes the TFM describes is another matter.
– cfr
19 hours ago
@HenriMenke The number of slots is just a function of the encoding. T1 has 256. OT1 has 128. (Just examples.) That's just the TFM stuff. What kind of thing tells TeX what goes in the boxes the TFM describes is another matter.
– cfr
19 hours ago
|
show 2 more comments
1 Answer
1
active
oldest
votes
up vote
3
down vote
accepted
If you don't want to escape to TeX you have to use a font which has this glyph, e.g. texnansi-lmr10. It is important that the input file is encoded in ISO Latin 1.
prologues := 3;
defaultfont := "texnansi-lmr10";
beginfig(1);
label.lrt("é", (0,0));
endfig;
end
It is probably easier to just typeset the labels with TeX by using (as you showed in the question) mpost -tex=csplain test.mp. In this case the file must be encoded in UTF-8.
prologues := 3;
beginfig(1);
label.lrt(btex é etex, (0,0));
endfig;
end
For more info see chapter 9 “Traditional labels and annotations” of Toby Thurston's excellent “Drawing with MetaPost” (PDF).
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
3
down vote
accepted
If you don't want to escape to TeX you have to use a font which has this glyph, e.g. texnansi-lmr10. It is important that the input file is encoded in ISO Latin 1.
prologues := 3;
defaultfont := "texnansi-lmr10";
beginfig(1);
label.lrt("é", (0,0));
endfig;
end
It is probably easier to just typeset the labels with TeX by using (as you showed in the question) mpost -tex=csplain test.mp. In this case the file must be encoded in UTF-8.
prologues := 3;
beginfig(1);
label.lrt(btex é etex, (0,0));
endfig;
end
For more info see chapter 9 “Traditional labels and annotations” of Toby Thurston's excellent “Drawing with MetaPost” (PDF).
add a comment |
up vote
3
down vote
accepted
If you don't want to escape to TeX you have to use a font which has this glyph, e.g. texnansi-lmr10. It is important that the input file is encoded in ISO Latin 1.
prologues := 3;
defaultfont := "texnansi-lmr10";
beginfig(1);
label.lrt("é", (0,0));
endfig;
end
It is probably easier to just typeset the labels with TeX by using (as you showed in the question) mpost -tex=csplain test.mp. In this case the file must be encoded in UTF-8.
prologues := 3;
beginfig(1);
label.lrt(btex é etex, (0,0));
endfig;
end
For more info see chapter 9 “Traditional labels and annotations” of Toby Thurston's excellent “Drawing with MetaPost” (PDF).
add a comment |
up vote
3
down vote
accepted
up vote
3
down vote
accepted
If you don't want to escape to TeX you have to use a font which has this glyph, e.g. texnansi-lmr10. It is important that the input file is encoded in ISO Latin 1.
prologues := 3;
defaultfont := "texnansi-lmr10";
beginfig(1);
label.lrt("é", (0,0));
endfig;
end
It is probably easier to just typeset the labels with TeX by using (as you showed in the question) mpost -tex=csplain test.mp. In this case the file must be encoded in UTF-8.
prologues := 3;
beginfig(1);
label.lrt(btex é etex, (0,0));
endfig;
end
For more info see chapter 9 “Traditional labels and annotations” of Toby Thurston's excellent “Drawing with MetaPost” (PDF).
If you don't want to escape to TeX you have to use a font which has this glyph, e.g. texnansi-lmr10. It is important that the input file is encoded in ISO Latin 1.
prologues := 3;
defaultfont := "texnansi-lmr10";
beginfig(1);
label.lrt("é", (0,0));
endfig;
end
It is probably easier to just typeset the labels with TeX by using (as you showed in the question) mpost -tex=csplain test.mp. In this case the file must be encoded in UTF-8.
prologues := 3;
beginfig(1);
label.lrt(btex é etex, (0,0));
endfig;
end
For more info see chapter 9 “Traditional labels and annotations” of Toby Thurston's excellent “Drawing with MetaPost” (PDF).
answered yesterday
Henri Menke
67k7148255
67k7148255
add a comment |
add a comment |
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%2f460225%2fwhy-custom-tex-command-for-labels-does-not-work-in-metapost%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
Use
btex é etexor see 8.2 “Font Map Files” of the manual.– Henri Menke
yesterday
@HenriMenke
btex ... etexworks. Is it possible to usepkfonts? (I get this warning:Warning: font lhr10 cannot be found in any fontmapfile!)– Igor Liferenko
yesterday
I'm not a font expert but don't
pkfonts only have 128 slots? I don't think they haveéencoded. Also if you're not usingbtex ... etexMetaPost does not need a TeX engine and the parameter-tex=csplainis ignored.– Henri Menke
yesterday
@HenriMenke
pkfonts can use 256 slots; for example, to use pk-variant ofé, runcsplain test.tex+dvips testwith the following~/.dvipsrc:p /dev/null– Igor Liferenko
yesterday
@HenriMenke The number of slots is just a function of the encoding. T1 has 256. OT1 has 128. (Just examples.) That's just the TFM stuff. What kind of thing tells TeX what goes in the boxes the TFM describes is another matter.
– cfr
19 hours ago