4

Is there a way in LaTeX, which would make some text look like it has been written by a left hander. In italic fonts, is there a distinction between left handed and right handed writing(you can visualize what i am trying to say)?

  • In case this means that you believe that left handed writing is slanted to the left: That's wrong. – Ulrike Fischer May 19 '15 at 14:19
  • @UlrikeFischer is correct that left-handers should not, by convention, slant cursive writing to the left. However, it is not particularly uncommon amongst lefties to do so anyway. – Steven B. Segletes May 19 '15 at 14:25
  • @StevenB.Segletes - Some righties have hand-writing that slopes to the left... – Mico May 19 '15 at 14:32
  • an actual font that has this tendency is cmu -- computer modern "upright italic". it's not slanted to the left, but has the italic lettershapes with an upright orientation. in tugboat, it's used for the headers for "editor's notes", and for this reason is called \EdNoteFont; can be tried out with \documentclass{ltugboat}. – barbara beeton May 19 '15 at 20:40
7

1st paragraph is normal slant handwriting, while the second is leftward slant handwriting.

By convention, left-slant handwriting is not taught (and therefore it does not exist in pre-defined fonts), but a number of lefties and (as Mico notes) some righties adopt the style in their handwriting.

Here, I implement a character iteration scheme, where \charop{} is applied to each character of the sentence (the iteration is needed to allow line-breaking of the result). I define \charop to employ Bruno's \slantbox code (Shear transform a "box") to take the hand-written character and slant it leftward. The slant value may be changed with \renewcommand\currentslant{}.

EDITED to correct parsing when encountering a letter repetition in the input.

\documentclass{article}
\usepackage{emerald}
\usepackage[T1]{fontenc}
\newsavebox\foobox
\newcommand{\slantbox}[2][.5]{\mbox{%
        \sbox{\foobox}{#2}%
        \hskip\wd\foobox
        \pdfsave
        \pdfsetmatrix{1 0 #1 1}%
        \llap{\usebox{\foobox}}%
        \pdfrestore
}}
\newcommand\chariterate[2][c]{\chariteratehelpA#2 \relax\relax}
\def\chariteratehelpA#1 #2\relax{%
  \chariteratehelpB#1\relax\relax%
  \ifx\relax#2\else\ \chariteratehelpA#2\relax\fi
}
\def\chariteratehelpB#1#2\relax{%
  \charop{#1}%
  \ifx\relax#2\else
    \chariteratehelpB#2\relax%
  \fi
}
\def\currentslant{-.7}
\def\charop#1{\slantbox[\currentslant]{#1}}
\begin{document}
\ECFSkeetch
If my goal is to make something look like actual handwritten text,
then this might suffice.\par
\chariterate{While not technically correct, some left handers will
slant their handwriting to the left, anyway.  Let's see if this works in multiline?}\par
%\renewcommand\currentslant{.2}
%\chariterate{Extra right slant}
\end{document}

enter image description here

enter image description here

And here it is using a different, less scratchy, font (and slight adjustments on default slant)

\documentclass{article}
\usepackage{aurical}
\usepackage[T1]{fontenc}
\newsavebox\foobox
\newcommand{\slantbox}[2][.5]{\mbox{%
        \sbox{\foobox}{#2}%
        \hskip\wd\foobox
        \pdfsave
        \pdfsetmatrix{1 0 #1 1}%
        \llap{\usebox{\foobox}}%
        \pdfrestore
}}
\newcommand\chariterate[2][c]{\chariteratehelpA#2 \relax\relax}
\def\chariteratehelpA#1 #2\relax{%
  \chariteratehelpB#1\relax\relax%
  \ifx\relax#2\else\ \chariteratehelpA#2\relax\fi
}
\def\chariteratehelpB#1#2\relax{%
  \charop{#1}%
  \ifx\relax#2\else
    \chariteratehelpB#2\relax%
  \fi
}
\def\currentslant{-.6}
\def\charop#1{\slantbox[\currentslant]{#1}}
\begin{document}
\Fontskrivan\slshape
If my goal is to make something look like actual handwritten text,
then this might suffice.\par
\chariterate{While not technically correct, some left handers will
slant their handwriting to the left, anyway.  Let's see if this works in multiline?}\par
\renewcommand\currentslant{.2}
\chariterate{Extra rightward slant.}
\end{document}

enter image description here

  • @ Steven Thanks for providing this solution. I am sure that just by changing the sign in the \slantbox[] command, we can reverse the slant direction. Is that right? – maulik May 19 '15 at 14:51
  • @maulik If you want normal text, just avoid the \chariterate altogether. But indeed, if one sets the slant value positive, it will slant even more to the right than what it started at. – Steven B. Segletes May 19 '15 at 14:54
  • @maulik Please see my revision, in which I introduce \currentslant as a definition. By changing the value of that, you can affect the slant. – Steven B. Segletes May 19 '15 at 14:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.