typo-pnc.mkiv / last modification: 2020-01-30 14:16
%D \module
%D   [       file=typo-pnc,
%D        version=2017.06.23, % experiment in project
%D          title=\CONTEXT\ Typesetting Macros,
%D       subtitle=Punctuation,
%D         author=Hans Hagen,
%D           date=\currentdate,
%D      copyright={PRAGMA ADE \& \CONTEXT\ Development Team}]
%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 Typesetting Macros / Punctuation}


% In manuals we often have "foo e.g. bar" where we then have to compensate spaces
% with "foo e.g.\ bar" so let's see if we can automate that and at the same time
% inject spaces between the snippets. It gets boring writing this kind of code.




\installcommandhandler \??periodkerning {periodkerning} \??periodkerning



\unexpanded\def\resetperiodkerning % fast one

\to \everyresettypesetting

\defineperiodkerning [zerospaceperiods]  [\c!factor=0]
\defineperiodkerning [smallspaceperiods] [\c!factor=.25]
\defineperiodkerning [halfspaceperiods]  [\c!factor=.5]

% If we ever need a command, see typo-krn.mkiv but it doesn't make much sense
% to have it.