summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/generic/mfpic/grafbase.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/source/generic/mfpic/grafbase.dtx')
-rw-r--r--Master/texmf-dist/source/generic/mfpic/grafbase.dtx97
1 files changed, 48 insertions, 49 deletions
diff --git a/Master/texmf-dist/source/generic/mfpic/grafbase.dtx b/Master/texmf-dist/source/generic/mfpic/grafbase.dtx
index 87cff9829cb..013d7adf8d3 100644
--- a/Master/texmf-dist/source/generic/mfpic/grafbase.dtx
+++ b/Master/texmf-dist/source/generic/mfpic/grafbase.dtx
@@ -1,6 +1,6 @@
% \iffalse
%%% File: grafbase.dtx
-%%% A part of mfpic 1.03 2009/11/18
+%%% A part of mfpic 1.04 2010/03/30
%%%
% -------------------------------------------------------------------
%
@@ -19,7 +19,7 @@
%
%<*driver>
\ProvidesFile{grafbase.dtx}
- [2009/11/18 v1.03. Metafont/post macros to interface with mfpic.]%
+ [2010/03/30 v1.04. Metafont/post macros to interface with mfpic.]%
\documentclass{ltxdoc}
\usepackage{docmfp}
@@ -185,10 +185,11 @@ fi
boolean grafbase; grafbase := true;
string fileversion, filedate;
-fileversion := "1.03"; filedate := "2009/11/18";
+fileversion := "1.04"; filedate := "2010/03/30";
-message " Loading grafbase macros, version " & fileversion & " " &
- filedate & ".";
+message " Loading grafbase macros version " &
+ fileversion & ", " & filedate & ".";
+message " ";
def GBmsg expr s = message "Grafbase (" & jobname & "): " & s; enddef;
def GBwarn expr s = GBmsg "Warning, " & s; enddef;
@@ -232,7 +233,7 @@ def checkversions (expr g)=
fi
enddef;
-checkversions (103);
+checkversions (104);
% \end{macrocode}
%
@@ -246,6 +247,35 @@ elseif base_name <> "plain": input plain;
fi
% \end{macrocode}
+% \DescribeRoutine{GBdebug}
+% The \gbc{debug} flag is for developers, who should set it before
+% inputing \file{grafbase}.
+% \DescribeRoutine{GBenddebug}
+% These two routines start and end debug messages.
+%
+% \DescribeRoutine{mftitle}
+% The \gbc{mftitle} macro is useful when debugging.
+% It will put its argument, which should be a string, as a TFM comment,
+% and also print it to the terminal and log file.
+% \begin{macrocode}
+if not boolean debug: boolean debug; debug := false; fi
+
+def GBdebug =
+ begingroup
+ save >>; def >> = message " " & enddef;
+ message "Grafbase DEBUG";
+enddef;
+def GBenddebug =
+ message "End DEBUG";
+ >> "";
+ endgroup
+enddef;
+
+vardef mftitle expr t =
+ if string t: t; message t; fi
+enddef;
+
+% \end{macrocode}
%
% \DescribeVariable{METAPOST}
% We try to determine which of \MF{} or \MP{} is using these macros.
@@ -266,14 +296,12 @@ fi
% \begin{macrocode}
boolean METAPOST;
METAPOST := known color Geamparalele din Babadag;
-numeric metapostversion;
%<*MF>
if METAPOST:
GBerrmsg ("wrong compiler.")
"This file is for Metafont. For Metapost use grafbase.mp.";
fi
-metapostversion := 0;
%</MF>
%<*MP>
@@ -319,34 +347,6 @@ fi
%</MP>
% \end{macrocode}
%
-% \DescribeRoutine{GBdebug}
-% The \gbc{debug} flag is for developers, who should set it before
-% inputing \file{grafbase}.
-% \DescribeRoutine{GBenddebug}
-% These two routines start and end debug messages.
-%
-% \DescribeRoutine{mftitle}
-% The \gbc{mftitle} macro is useful when debugging.
-% It will put its argument, which should be a string, as a TFM comment,
-% and also print it to the terminal and log file.
-% \begin{macrocode}
-if not boolean debug: boolean debug; debug := false; fi
-
-def GBdebug =
- begingroup
- save >>; def >> = message enddef;
- >> "Grafbase DEBUG";
-enddef;
-def GBenddebug =
- >> "End DEBUG";
- endgroup
-enddef;
-
-vardef mftitle expr t =
- if string t: t; message t; fi
-enddef;
-
-% \end{macrocode}
%
% \subsection{Setting up the font, \MF{} only}\label{font}
%
@@ -369,31 +369,30 @@ enddef;
%<*MF>
if unknown mode:
GBerrmsg ("Metafont mode is unknown.")
- "Set mode to a known mode. Perhaps localfont or ljfour. "
- & "If you proceed, a generic 600dpi mode will be used.";
- if known localfont: mode := localfont;
+ "Set mode to a known mode, perhaps ljfour. "
+ & "If you proceed, localfont will be tried. "
+ & "If that is unknown, a generic mode will be tried.";
+ if known localfont: mode := localfont;
else:
+ if unknown GBresolution: GBresolution := 600 fi;
mode_def GBgeneric =
- proofing := 0;
- fontmaking := 1;
- tracingtitles := 0;
- if unknown pixels_per_inch:
- pixels_per_inch := 600;
- fi
- blacker := 0;
- fillin := 0;
- o_correction := 1;
+ mode_param (pixels_per_inch, GBresolution);
+ mode_param (blacker, 0);
+ mode_param (fillin, 0);
+ mode_param (o_correction, 1);
+ mode_common_setup_;
enddef;
mode := GBgeneric;
fi
fi
-
mode_setup;
+
if debug:
GBdebug;
>> "pixels_per_inch = " & decimal pixels_per_inch;
GBenddebug;
fi
+
font_identifier := "MFpic graphics";
font_coding_scheme := "Arbitrary";
interim designsize := 128pt#;