summaryrefslogtreecommitdiff
path: root/tex/context/base/typo-spa.mkiv
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2010-07-15 15:01:00 +0200
committerHans Hagen <pragma@wxs.nl>2010-07-15 15:01:00 +0200
commit84903d24d6d930438bb3cc4322c4b14271b713aa (patch)
tree7f5fca13da2c9e1c81e61fbcac67f61d55f13800 /tex/context/base/typo-spa.mkiv
parentcb0c6e65703831a34d0ba909f703994a0825beac (diff)
downloadcontext-84903d24d6d930438bb3cc4322c4b14271b713aa.tar.gz
beta 2010.07.15 15:01
Diffstat (limited to 'tex/context/base/typo-spa.mkiv')
-rw-r--r--tex/context/base/typo-spa.mkiv14
1 files changed, 8 insertions, 6 deletions
diff --git a/tex/context/base/typo-spa.mkiv b/tex/context/base/typo-spa.mkiv
index e059b62e4..c877fdf67 100644
--- a/tex/context/base/typo-spa.mkiv
+++ b/tex/context/base/typo-spa.mkiv
@@ -38,20 +38,22 @@
{\ifcsname\??ch:#1\endcsname
\begingroup % for the moment we use modes, in ordere to avoid interface translation
\getparameters[\??ch][\c!left=0,\c!right=0,\c!alternative=0,#3]%
- \ctxlua{spacings.setspacing(\getvalue{\??ch:#1},\number#2,\@@chleft,\@@chright,\@@chalternative)}%
+ \ctxlua{typesetting.spacings.setup(\getvalue{\??ch:#1},\number#2,\@@chleft,\@@chright,\@@chalternative)}%
\endgroup
\fi}
-\def\setcharacterspacing
- {\ctxlua{spacings.enable()}%
- \gdef\setcharacterspacing[##1]{\attribute\spacingattribute\csname\??ch:##1\endcsname\relax}%
- \setcharacterspacing}
+\unexpanded\def\setcharacterspacing[#1]%
+ {\ctxlua{typesetting.spacings.set(\number\csname\??ch:#1\endcsname)}}
-\def\resetcharacterspacing
+\unexpanded\def\resetcharacterspacing % fast one
{\attribute\spacingattribute\attributeunsetvalue}
\letvalue{\??ch:\s!reset}\attributeunsetvalue
+\appendtoks
+ \resetcharacterspacing
+\to \everyresettypesetting
+
% \setcharacterspacing[frenchpunctuation]
% «\type{bla}»\crlf « \type{bla}»\crlf
% «bla »\crlf « bla»\crlf « bla »\crlf