% For more details see the end of file

\edef\atsign{\the\catcode64 }

\catcode`\@=11
\newif\ifj@mps
\def\1{\let\re@lspace= }\1 %
\def\spacedtext{\j@mpstrue\def\prevch@r{}\ifvmode\leavevmode\fi\t@stnextch}
\def\t@stnextch{\futurelet\next\t@stendspaced}
\def\t@stendspaced{\ifx\next\egroup
      \let\next\prevch@r
   \else
      \ifx\next\re@lspace
         \let\next\e@tspace
      \else
         \ifx\next\-%
           \j@mpsfalse \let\next\e@tnexttok
         \else
           \let\next\e@tnexttok
         \fi
      \fi
   \fi\next}
\def\e@tspace{\def\nextch@r{\space}\afterassignment\joinch@rs\let\next= }
\def\e@tnexttok#1{\def\nextch@r{#1}\joinch@rs}
\def\joinch@rs{{\setbox0=\hbox{\prevch@r}\setbox1=\hbox{\nextch@r}%
                \setbox2=\hbox{\prevch@r\nextch@r}%
   \dimen0=\wd0 \advance\dimen0 by\wd1 \advance\dimen0 by-\wd2
   \prevch@r
   \ifj@mps\kern-\dimen0\interchar@cterspace\fi}\j@mpstrue%
   \let\prevch@r=\nextch@r\t@stnextch}
\def\intercharspace#1{\def\interchar@cterspace{\kern#1}}
\catcode`\@=\atsign\relax

\endinput

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
%  \spacedtext         is must be used as font swith inside braces.
%
%  \intercharspace{<dimen>} sets the amount inserted between every two
%                      neighbour characters.
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
