Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!usenet.ins.cwru.edu!mephisto!mcnc!rti!sas!bts From: bts@sas.UUCP (Brian T. Schellenberger) Newsgroups: comp.text Subject: Re: LaTeX table caption wrap how ? Keywords: captions tables wrap latex Message-ID: <1378@sas.UUCP> Date: 12 Dec 89 18:59:42 GMT References: <3251@tahoe.unr.edu> Reply-To: bts@sas.UUCP (Brian T. Schellenberger) Distribution: usa Organization: SAS Institute Inc, Cary NC Lines: 25 [Email isn't worth the paper it's printed on . . .] Just create a macro which puts the tabular in a box and gets its width; requires diving into TeX (untested) (and sketchy, but should give the idea if you know plain TeX any; maybe someone else can develop this better . . . \newbox\boxbox \newbox\boxtoo \newenvironment{boxtab}[1] {\def\boxcap{#1} \setbox\boxbox=\bgroup} {\egroup \setbox\boxtoo=\vbox{\hsize=\wd\boxbox\boxcap} \begin{table} \boxbox \caption{\boxtoo} \end{table} } \begin{boxtab}{caption} this & that \\ and & more \end{boxtab} -- -- Brian, the Man from Babble-on. ...!mcnc!rti!sas!bts -- (Brian Schellenberger) "No one will ever write a song called 'Nitro Burning Funny Cars'" -- THE DEAD MILKMEN, "Nitro Burning Funny Cars"