summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2012-12-06 22:36:00 +0100
committerHans Hagen <pragma@wxs.nl>2012-12-06 22:36:00 +0100
commit898996a6e7727a0530533135ce19570647c924fb (patch)
treed3e47b8f48040374eca1d7269b17331311de6ea3
parent319e43c29e0d220b6067658db9c4ecf51984e8c4 (diff)
downloadcontext-898996a6e7727a0530533135ce19570647c924fb.tar.gz
beta 2012.12.06 22:36
-rw-r--r--tex/context/base/cont-new.mkii2
-rw-r--r--tex/context/base/cont-new.mkiv2
-rw-r--r--tex/context/base/context-version.pdfbin4146 -> 4146 bytes
-rw-r--r--tex/context/base/context-version.pngbin40551 -> 40530 bytes
-rw-r--r--tex/context/base/context.mkii2
-rw-r--r--tex/context/base/context.mkiv2
-rw-r--r--tex/context/base/meta-ini.mkiv56
-rw-r--r--tex/context/base/status-files.pdfbin24533 -> 24548 bytes
-rw-r--r--tex/context/base/status-lua.pdfbin199336 -> 199334 bytes
-rw-r--r--tex/generic/context/luatex/luatex-fonts-merged.lua2
10 files changed, 47 insertions, 19 deletions
diff --git a/tex/context/base/cont-new.mkii b/tex/context/base/cont-new.mkii
index 7d9a14b94..749ec9477 100644
--- a/tex/context/base/cont-new.mkii
+++ b/tex/context/base/cont-new.mkii
@@ -11,7 +11,7 @@
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.
-\newcontextversion{2012.12.06 18:39}
+\newcontextversion{2012.12.06 22:36}
%D This file is loaded at runtime, thereby providing an
%D excellent place for hacks, patches, extensions and new
diff --git a/tex/context/base/cont-new.mkiv b/tex/context/base/cont-new.mkiv
index b42f5950a..952d14da1 100644
--- a/tex/context/base/cont-new.mkiv
+++ b/tex/context/base/cont-new.mkiv
@@ -11,7 +11,7 @@
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.
-\newcontextversion{2012.12.06 18:39}
+\newcontextversion{2012.12.06 22:36}
%D This file is loaded at runtime, thereby providing an excellent place for
%D hacks, patches, extensions and new features.
diff --git a/tex/context/base/context-version.pdf b/tex/context/base/context-version.pdf
index 1f24b3b44..afeae25e9 100644
--- a/tex/context/base/context-version.pdf
+++ b/tex/context/base/context-version.pdf
Binary files differ
diff --git a/tex/context/base/context-version.png b/tex/context/base/context-version.png
index 3aabb7163..7002ba4ae 100644
--- a/tex/context/base/context-version.png
+++ b/tex/context/base/context-version.png
Binary files differ
diff --git a/tex/context/base/context.mkii b/tex/context/base/context.mkii
index a7ac7da5e..71a16df3a 100644
--- a/tex/context/base/context.mkii
+++ b/tex/context/base/context.mkii
@@ -20,7 +20,7 @@
%D your styles an modules.
\edef\contextformat {\jobname}
-\edef\contextversion{2012.12.06 18:39}
+\edef\contextversion{2012.12.06 22:36}
%D For those who want to use this:
diff --git a/tex/context/base/context.mkiv b/tex/context/base/context.mkiv
index a4d349d30..387888068 100644
--- a/tex/context/base/context.mkiv
+++ b/tex/context/base/context.mkiv
@@ -25,7 +25,7 @@
%D up and the dependencies are more consistent.
\edef\contextformat {\jobname}
-\edef\contextversion{2012.12.06 18:39}
+\edef\contextversion{2012.12.06 22:36}
%D For those who want to use this:
diff --git a/tex/context/base/meta-ini.mkiv b/tex/context/base/meta-ini.mkiv
index 89f6b4dc9..fec3a64f9 100644
--- a/tex/context/base/meta-ini.mkiv
+++ b/tex/context/base/meta-ini.mkiv
@@ -56,12 +56,12 @@
\let\stopMPdefinitions\relax
-\unexpanded\def\startMPextensions#1\stopMPextensions
+\unexpanded\def\startMPextensions#1\stopMPextensions % for all instances, when enabled
{\global\t_meta_extensions\expandafter{\the\t_meta_extensions#1}}
\let\stopMPextensions\relax
-\unexpanded\def\startMPinitializations#1\stopMPinitializations
+\unexpanded\def\startMPinitializations#1\stopMPinitializations % for all instances, when enables
{\global\t_meta_initializations\expandafter{\the\t_meta_initializations#1}}
\let\stopMPinitializations\relax
@@ -450,6 +450,28 @@
\expandafter\meta_prepare_variable_yes
\fi}
+\unexpanded\def\meta_prepare_instance_variables
+ {\expandafter\processcommalist\expandafter[\m_meta_instance_variables]\meta_prepare_instance_variable}
+
+\unexpanded\def\meta_prepare_instance_variable#1%
+ {\edef\m_meta_current_variable_template
+ {\??graphicvariable\currentmpvariableclass:#1}%
+ \edef\m_meta_current_variable
+ {\csname
+ \ifcsname\m_meta_current_variable_template\endcsname
+ \m_meta_current_variable_template
+ \else\ifcsname\??graphicvariable\currentMPgraphicname:#1\endcsname
+ \??graphicvariable\currentMPgraphicname:#1%
+ \else
+ \meta_unknown_variable_template
+ \fi\fi
+ \endcsname}%
+ \ifx\m_meta_current_variable\empty
+ \expandafter\meta_prepare_variable_nop
+ \else
+ \expandafter\meta_prepare_variable_yes
+ \fi}
+
\def\meta_prepare_variable_nop
{\expandafter \let\csname\m_meta_current_variable_template\endcsname\meta_prepare_variable_default}
@@ -576,15 +598,18 @@
\def\meta_unique_graphic#1#2%
{\meta_begin_graphic_group{#1}%
- \setupMPvariables[\currentMPgraphicname][#2]%
- \getvalue{\??mpgraphic\currentMPgraphicname}\empty
- %\getvalue{\??mpgraphic#1}\empty
+% \setupMPvariables[\currentMPgraphicname][#2]%
+ \setupMPvariables[#1][#2]%
+ \getvalue{\??mpgraphic#1}\empty
\meta_end_graphic_group}
\def\meta_handle_use_graphic#1#2#3%
{\begingroup
\edef\currentmpvariableclass{#1}%
- \meta_prepare_variables{#2}%
+ \edef\m_meta_instance_variables{#2}%
+ \ifx\m_meta_instance_variables\empty \else
+ \meta_prepare_instance_variables
+ \fi
\meta_enable_include % redundant
\meta_process_graphic{#3}%
\endgroup}
@@ -608,7 +633,10 @@
\def\meta_handle_reusable_graphic#1#2#3%
{\begingroup
\edef\currentmpvariableclass{#1}%
- \meta_prepare_variables{#2}%
+ \edef\m_meta_instance_variables{#2}%
+ \ifx\m_meta_instance_variables\empty \else
+ \meta_prepare_instance_variables
+ \fi
\meta_enable_include % redundant
\global\advance\c_meta_object_counter\plusone
\setobject{MP}{\number\c_meta_object_counter}\hbox{\meta_process_graphic{#3}}% was vbox, graphic must end up as hbox
@@ -629,9 +657,9 @@
\def\meta_use_graphic#1#2%
{\meta_begin_graphic_group{#1}%
- \doifsomething{#2}{\setupMPvariables[\currentMPgraphicname][#2]}%
- \getvalue{\??mpgraphic\currentMPgraphicname}\empty
- %\getvalue{\??mpgraphic#1}\empty
+% \doifsomething{#2}{\setupMPvariables[\currentMPgraphicname][#2]}%
+ \doifsomething{#2}{\setupMPvariables[#1][#2]}%
+ \getvalue{\??mpgraphic#1}\empty
\meta_end_graphic_group}
\let\reuseMPgraphic \useMPgraphic % we can save a setup here if needed
@@ -666,9 +694,9 @@
\def\meta_unique_page_graphic#1#2%
{\meta_begin_graphic_group{#1}%
\let\overlaystamp\overlaypagestamp
- \setupMPvariables[\m_meta_page_prefix:\currentMPgraphicname][#2]% prefix is new here
- \getvalue{\??mpgraphic\m_meta_page_prefix:\currentMPgraphicname}{}%
- %\getvalue{\??mpgraphic\m_meta_page_prefix:#1}{}%
+% \setupMPvariables[\m_meta_page_prefix:\currentMPgraphicname][#2]% prefix is new here
+ \setupMPvariables[\m_meta_page_prefix:#1][#2]% prefix is new here
+ \getvalue{\??mpgraphic\m_meta_page_prefix:#1}{}%
\meta_end_graphic_group}
%D One way of defining a stamp is:
@@ -690,7 +718,7 @@
{\processcommalist[#1]\meta_extend_overlay_stamp}
\def\meta_extend_overlay_stamp#1%
- {\meta_prepare_variable{#1}%
+ {\meta_prepare_instance_variable{#1}%
\edef\overlaystamp{\overlaystamp:\MPvariable{#1}}}
%D \macros
diff --git a/tex/context/base/status-files.pdf b/tex/context/base/status-files.pdf
index da59bd28c..84c7adbe3 100644
--- a/tex/context/base/status-files.pdf
+++ b/tex/context/base/status-files.pdf
Binary files differ
diff --git a/tex/context/base/status-lua.pdf b/tex/context/base/status-lua.pdf
index d4b46d04b..9b7fd7ee5 100644
--- a/tex/context/base/status-lua.pdf
+++ b/tex/context/base/status-lua.pdf
Binary files differ
diff --git a/tex/generic/context/luatex/luatex-fonts-merged.lua b/tex/generic/context/luatex/luatex-fonts-merged.lua
index e29b47f55..4b5d60492 100644
--- a/tex/generic/context/luatex/luatex-fonts-merged.lua
+++ b/tex/generic/context/luatex/luatex-fonts-merged.lua
@@ -1,6 +1,6 @@
-- merged file : luatex-fonts-merged.lua
-- parent file : luatex-fonts.lua
--- merge date : 12/06/12 18:39:21
+-- merge date : 12/06/12 22:36:49
do -- begin closure to overcome local limits and interference