diff options
author | Karl Berry <karl@freefriends.org> | 2013-05-03 23:38:10 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2013-05-03 23:38:10 +0000 |
commit | 4291df261e03a62e720c46473e08b04c1d69c452 (patch) | |
tree | 78743ad2ed3ada604860937970638667dedb30ff /Master/texmf-dist/source/latex/feynmp-auto/feynmp-auto.dtx | |
parent | 1e17ed5c41d36b50fefdc9b895c388c24532e9b1 (diff) |
feynmp-auto (3may13)
git-svn-id: svn://tug.org/texlive/trunk@30223 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex/feynmp-auto/feynmp-auto.dtx')
-rw-r--r-- | Master/texmf-dist/source/latex/feynmp-auto/feynmp-auto.dtx | 37 |
1 files changed, 32 insertions, 5 deletions
diff --git a/Master/texmf-dist/source/latex/feynmp-auto/feynmp-auto.dtx b/Master/texmf-dist/source/latex/feynmp-auto/feynmp-auto.dtx index 5be176fa8f0..a9d3dff1ed7 100644 --- a/Master/texmf-dist/source/latex/feynmp-auto/feynmp-auto.dtx +++ b/Master/texmf-dist/source/latex/feynmp-auto/feynmp-auto.dtx @@ -30,7 +30,7 @@ %<package>\NeedsTeXFormat{LaTeX2e}[2008/04/05] %<package>\ProvidesPackage{feynmp-auto} %<*package> - [2013/03/12 v1.0 Automatic processing of feynmp graphics] + [2013/05/03 v1.1 Automatic processing of feynmp graphics] %</package> % %<*driver> @@ -48,7 +48,7 @@ %</driver> % \fi % -% \CheckSum{113} +% \CheckSum{129} % % \CharacterTable % {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z @@ -67,6 +67,7 @@ % Right brace \} Tilde \~} % % +% \changes{v1.1}{2013/05/03}{Added `force' option} % \changes{v1.0}{2013/03/12}{Initial version} % % \GetFileInfo{feynmp-auto.dtx} @@ -84,7 +85,7 @@ % \DoNotIndex{\@outfmf,\closeout,\CurrentOption,\equaltojobname,\fmfcmd} % \DoNotIndex{\fmf@revision,\if@fmfio,\IfFileExists,\ifmeasuring@} % \DoNotIndex{\immediate,\jobname,\openout,\p@rcent,\PassOptionsToPackage} -% \DoNotIndex{\RequirePackage,\write,\z@} +% \DoNotIndex{\RequirePackage,\write,\z@,\newif} % % \title{The \textsf{feynmp-auto} package\thanks{This document % corresponds to \textsf{feynmp-auto}~\fileversion, dated \filedate.}} @@ -97,7 +98,16 @@ % This package is just a wrapper around \textsf{feynmp}; it receives % exactly the same options as that package and works in exactly the % same way, so refer to its documentation for the specific commands -% and environments. +% and environments. There is just one option specific to +% \textsf{feynmp-auto}: with +% \begin{flushleft} +% \verb|\usepackage[force]{feynmp-auto}| +% \end{flushleft} +% the checks whether the \hologo{METAPOST} files are not changed from +% the previous \hologo{LaTeX} run get disabled. This option might come +% handy when one is switching from \textsf{feynmp} to +% \textsf{feynmp-auto} or, possibly, for the very final runs where one +% wants to be \emph{really} sure that everything is updated. % % What the present package adds is the automatic call of % \hologo{METAPOST} at \verb|\end{fmffile}|, taking advantage of the @@ -139,7 +149,10 @@ % % In both the above cases, adding the \texttt{-shell-escape} option to % the call of the \hologo{LaTeX} run is sufficient (but beware for -% security risks and run with the option only files from safe sources). +% security risks and run with the option only files from safe +% sources). The \texttt{-shell-escape} used to be called +% \texttt{-enable-write18} in older versions of \hologo{MiKTeX}, but +% newer versions (the 2.9 in particular) understand both. % % The package will emit a warning if shell escape is not enabled, % which may happen if the call of the engine has the option @@ -168,9 +181,12 @@ % \subsection{Options} % All options are passed to \textsf{feynmp} % \begin{macrocode} +\newif\iffnmpa@force +\DeclareOption{force}{\fnmpa@forcetrue} \DeclareOption*{\PassOptionsToPackage{\CurrentOption}{feynmp}} \ProcessOptions\relax % \end{macrocode} +% % \subsection{Required packages and preliminary code} % \begin{macrocode} \RequirePackage{feynmp} @@ -232,6 +248,17 @@ } \fi % \end{macrocode} +% If the \texttt{force} option has been given, then we override in the +% same way the macros. A bit of code duplication, but this avoids +% complicated conditional nestings. +% \begin{macrocode} +\iffnmpa@force + \let\fnmpa@gethash\relax + \def\fnmpa@processmp{% + \IfFileExists{\thefmffile.mp}{\immediate\write18{mpost \thefmffile}}{}% + } +\fi +% \end{macrocode} % % \subsection*{Patching the macros of \textsf{feynmp}} % We finally need to inject the code in the macros responsible for the |