summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/context/base/blob-ini.mkiv
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/context/base/blob-ini.mkiv')
-rw-r--r--Master/texmf-dist/tex/context/base/blob-ini.mkiv20
1 files changed, 18 insertions, 2 deletions
diff --git a/Master/texmf-dist/tex/context/base/blob-ini.mkiv b/Master/texmf-dist/tex/context/base/blob-ini.mkiv
index 7f63ec73d91..4fdb9e4b6ce 100644
--- a/Master/texmf-dist/tex/context/base/blob-ini.mkiv
+++ b/Master/texmf-dist/tex/context/base/blob-ini.mkiv
@@ -5,7 +5,7 @@
%D subtitle=Initialization,
%D author=Hans Hagen,
%D date=\currentdate,
-%D copyright=\PRAGMA]
+%D copyright={PRAGMA ADE \& \CONTEXT\ Development Team}]
%C
%C This module is part of the \CONTEXT\ macro||package and is
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
@@ -18,9 +18,25 @@
%D down the road (close to version 1.00 of \LUATEX). Typesetting in
%D pure \LUA\ sometimes makes sense.
+\registerctxluafile{node-typ}{1.001} % experimental
\registerctxluafile{blob-ini}{1.001}
-\endinput
+%D For the moment here:
+
+\unprotect
+
+% this one takes simple (utf) strings
+
+\def\widthofstring#1{\ctxcommand{widthofstring(\!!bs#1\!!es)}}
+
+% this one takes anything that can be typeset
+
+\unexpanded\def\setwidthof#1\to#2%
+ {\bgroup
+ \setbox\scratchbox\hbox{#1}%
+ \expanded{\egroup\def\noexpand#2{\the\wd\scratchbox}}}
+
+\protect \endinput
% \starttext
%