Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!julius.cs.uiuc.edu!rpi!clarkson!ub!acsu.buffalo.edu From: xiaofei@acsu.buffalo.edu (Xiaofei Wang) Newsgroups: comp.text.tex Subject: Re: Large initial Message-ID: <53779@eerie.acsu.Buffalo.EDU> Date: 8 Jan 91 21:01:43 GMT References: <1869@ruunsa.fys.ruu.nl> Sender: news@acsu.Buffalo.EDU Distribution: comp.text.tex Organization: SUNY Buffalo Lines: 33 Nntp-Posting-Host: lictor.acsu.buffalo.edu In article <1869@ruunsa.fys.ruu.nl> spit@ruunsa.fys.ruu.nl (Werenfried Spit) writes: * DD oes someone have a TeX macro that produces a large * D D initial in the first line of a paragraph, somewhat * DD like the big D in front of this one. I figure one * has to twiddle a little bit with \hangindent, but I do * not get it completely right. * * Thanks in advance * * The following code was not written by me but I know it works. It is LaTeX and I will be happy if some one changes it to TeX. The big letter extendes to two lines, almost. And I would be happy also if some one can make it bigger or smaller. I don't have good knowledge of LaTeX or time to do these. \documentstyle{article} \begin{document} \def\bigfirstletter#1#2{{\noindent \setbox0\hbox{\Huge #1}\setbox1\hbox{#2}\setbox2\hbox{(}% \count0=\ht0\advance\count0 by\dp0\count1\baselineskip \advance\count0 by-\ht1\advance\count0 by\ht2 \dimen1=.5ex\advance\count0 by\dimen1\divide\count0 by\count1 \advance\count0 by1\dimen0\wd0 \advance\dimen0 by.25em\dimen1=\ht0\advance\dimen1 by-\ht1 \global\hangindent\dimen0\global\hangafter-\count0 \hskip-\dimen0\setbox0\hbox to\dimen0{\raise-\dimen1\box0\hss}% \dp0=0in\ht0=0in\box0}#2} \bigfirstletter This works very well. The first letter `T' is bigger than the others. See where the second line go? Guess what? It is behind T. and also see where the third line go? guess what? It is aligned with T. \end{document}