summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/metapost/metauml/metauml_state.mp
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2010-09-12 23:03:48 +0000
committerKarl Berry <karl@freefriends.org>2010-09-12 23:03:48 +0000
commit14889c6d7bd31fd163f9cb123c8ba772769d176b (patch)
tree87daf844b7fc365e2a328b7f6b39632e5aa68f94 /Master/texmf-dist/metapost/metauml/metauml_state.mp
parent2468fdd0a97481e170ef878e0839faf948be681a (diff)
metauml 0.2.5 (31jul10)
git-svn-id: svn://tug.org/texlive/trunk@19692 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/metapost/metauml/metauml_state.mp')
-rw-r--r--Master/texmf-dist/metapost/metauml/metauml_state.mp16
1 files changed, 14 insertions, 2 deletions
diff --git a/Master/texmf-dist/metapost/metauml/metauml_state.mp b/Master/texmf-dist/metapost/metauml/metauml_state.mp
index 7d4b348afad..fb9875e262a 100644
--- a/Master/texmf-dist/metapost/metauml/metauml_state.mp
+++ b/Master/texmf-dist/metapost/metauml/metauml_state.mp
@@ -20,8 +20,20 @@ if known _metauml_state_mp:
fi;
_metauml_state_mp:=1;
-input metauml_defaults;
-input util_log;
+% Sadly, this copy of the macro is needed to prevent multiple file loads being shown by MetaPost.
+% The guard values (such as _metauml_mp) do ensure that the file isn't loaded multiple times,
+% but this macro makes sure that MetaPost won't try to load the file and display a message for that.
+def inputonce text libraryFile=
+ if not known scantokens ("_" & str libraryFile & "_mp"):
+ %includeonce% show "Loading " & str libraryFile;
+ scantokens ("input " & str libraryFile);
+ else:
+ %includeonce% show str libraryFile & " already loaded.";
+ fi;
+enddef;
+
+inputonce metauml_defaults;
+inputonce util_log;
vardef StateInfo@#=
attributes(@#);