Path: utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!mcnc!rti!sas!bts From: bts@sas.UUCP (Brian T. Schellenberger) Newsgroups: comp.text Subject: Re: Boxed example in TeX/LaTeX Message-ID: <1078@sas.UUCP> Date: 28 Jun 89 16:57:48 GMT References: <13839@umn-cs.CS.UMN.EDU> Reply-To: bts@sas.UUCP (Brian T. Schellenberger) Organization: SAS Institute Inc, Cary NC Lines: 26 This puts a box around arbitrary text. It also happens to set up \. for leaders, but that's a separate issue. The key is using \bgroup and \egroup. Also, if you want to allow arbitrary text, you *must* take a width a a parameter, or use a hard-coded one (possibly some smidge less than \textwidth). . . . \newenvironment {leaderbox*} [1] { \begingroup \par \noindent \hfill \setbox0=\vbox \bgroup \hsize #1 \@parboxrestore \let \. = \leaderfill } { \egroup \fbox{\box0} \hfill \penalty0 \par \endgroup } -- -- Brian, the Man from Babble-on. ...!mcnc!rti!sas!bts -- "Every jumbled pile of person has a thinking part that wonders what the part that isn't thinking isn't thinking of" -- THEY MIGHT BE GIANTS