summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/context/base/mkxl/font-glf.mklx
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/context/base/mkxl/font-glf.mklx')
-rw-r--r--Master/texmf-dist/tex/context/base/mkxl/font-glf.mklx41
1 files changed, 41 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/context/base/mkxl/font-glf.mklx b/Master/texmf-dist/tex/context/base/mkxl/font-glf.mklx
new file mode 100644
index 00000000000..2c23f226eed
--- /dev/null
+++ b/Master/texmf-dist/tex/context/base/mkxl/font-glf.mklx
@@ -0,0 +1,41 @@
+%D \module
+%D [ file=font-glf,
+%D version=2020.12.21,
+%D title=\CONTEXT\ Font Macros,
+%D subtitle=Glyph Scaling,
+%D author=Hans Hagen,
+%D date=\currentdate,
+%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
+%C details.
+
+\writestatus{loading}{ConTeXt Font Macros / Glyph Scaling}
+
+\unprotect
+
+%D Experiment:
+
+\installcorenamespace{tweakedfont}
+
+\installcommandhandler \??tweakedfont {tweakedfont} \??tweakedfont
+
+\appendtoks
+ % we can optimize for zero and 1000 .. maybe also options?
+ \overloaded\frozen\protected\edefcsname\currenttweakedfont\endcsname
+ {\begincsname\tweakedfontparameter\c!style\endcsname
+ \glyphxscale \numexpr\numericscale\tweakedfontparameter\c!xscale*\glyphxscale/\plusthousand\relax
+ \glyphyscale \numexpr\numericscale\tweakedfontparameter\c!yscale*\glyphyscale/\plusthousand\relax
+ \glyphxoffset\dimexpr\glyphxoffset+\tweakedfontparameter\c!xoffset\relax
+ \glyphyoffset\dimexpr\glyphyoffset+\tweakedfontparameter\c!yoffset\relax}%
+\to \everydefinetweakedfont
+
+\setuptweakedfont
+ [\c!scale=\plusthousand,
+ \c!xscale=\tweakedfontparameter\c!scale,
+ \c!yscale=\tweakedfontparameter\c!scale,
+ \c!xoffset=\zeropoint,
+ \c!yoffset=\zeropoint]
+
+\protect \endinput