Différences
Ci-dessous, les différences entre deux révisions de la page.
Les deux révisions précédentesRévision précédente | |||
fichiers:postscript:afficher_la_sortie_de_metapost_dans_ghostscript [2018/12/04 00:22] – jejust | 5_fichiers:postscript:afficher_la_sortie_de_metapost_dans_ghostscript [2023/12/28 20:18] (Version actuelle) – Remise en forme. jejust | ||
---|---|---|---|
Ligne 1: | Ligne 1: | ||
- | ====== Displaying MetaPost output in `ghostscript` ====== | + | ====== Displaying MetaPost output in “ghostscript” ====== |
MetaPost ordinarily expects its output to be included in some context | MetaPost ordinarily expects its output to be included in some context | ||
where the " | where the " | ||
- | defined --- for example, as a figure in TeX document. | + | defined --- for example, as a figure in TeX document. |
- | debugging your MetaPost code, you may want to view it in a | + | your MetaPost code, you may want to view it in a |
- | [[https:// | + | '' |
other PostScript) previewer, but note that viewers (even | other PostScript) previewer, but note that viewers (even | ||
- | [[https:// | + | '' |
- | // | + | have the fonts loaded, and you'll experience an error such as |
- | an error such as | + | |
< | < | ||
Error: /undefined in cmmi10 | Error: /undefined in cmmi10 | ||
</ | </ | ||
+ | |||
There is provision in MetaPost for avoiding this problem: issue the | There is provision in MetaPost for avoiding this problem: issue the | ||
- | command '' | + | command |
Unfortunately, | Unfortunately, | ||
Ligne 33: | Ligne 32: | ||
indirectly from a simple wrapper '' | indirectly from a simple wrapper '' | ||
- | < | + | < |
prologues := 2; | prologues := 2; | ||
input MyFigure | input MyFigure | ||
Ligne 42: | Ligne 41: | ||
mp " | mp " | ||
</ | </ | ||
- | (which will work without the quote marks if you're not using a Unix | + | (which will work without the quote marks if you're not using a Unix shell). |
- | shell). | + | |
A suitable LaTeX route would involve processing | A suitable LaTeX route would involve processing | ||
'' | '' | ||
- | <code latex> | + | <code latex MyFigure.tex> |
\documentclass{article} | \documentclass{article} | ||
\usepackage{graphicx} | \usepackage{graphicx} | ||
Ligne 56: | Ligne 54: | ||
\end{document} | \end{document} | ||
</ | </ | ||
- | Processing the resulting DVI file with the '' | ||
- | command | ||
+ | Processing the resulting DVI file with the '' | ||
<code bash> | <code bash> | ||
dvips -E -o MyFigure.eps MyFigure | dvips -E -o MyFigure.eps MyFigure | ||
</ | </ | ||
would then give a satisfactory Encapsulated PostScript file. This | would then give a satisfactory Encapsulated PostScript file. This | ||
- | procedure may be automated using the Perl script | + | procedure may be automated using the Perl script '' |
- | '' | + | thus saving a certain amount of tedium. |
The Plain TeX user may use an adaptation, by | The Plain TeX user may use an adaptation, by | ||
Ligne 80: | Ligne 77: | ||
----- | ----- | ||
- | |||
//Source:// [[faquk> | //Source:// [[faquk> | ||
- | {{htmlmetatags> | + | {{htmlmetatags> |
- | metatag-og: | + | metatag-og: |
metatag-og: | metatag-og: | ||
}} | }} | ||