TeXhax Digest Sunday, March 13, 1988 Volume 88 : Issue 24 [SCORE.STANFORD.EDU]TEXHAX24.88 Editor: Malcolm Brown Today's Topics: Re: delatex Dropped Capital Macro TeX-to-C JTeX widows and clubs in LaTeX Common TeX patch 2.7 PXtoPK changes for VAX/VMS dvi2ps using pk files Re: Common TeX patch 2.7 new bibtex using native fonts Bug in Kellerman & Smith version 2.2.0 of PXtoPX site-specific environment in LaTeX (?) how to get Common TeX? Very narrow columns in Plain TeX Re: Very narrow columns in Plain TeX Gosling Emacs Macros for LaTeX ---------------------------------------------------------------------- Date: Thu, 3 Mar 88 15:49:50 PST From: unido!ubrinf!mond!bengt@uunet.UU.NET (Bengt Martensson) Subject: Re: delatex Delatex etc is frequently discussed in this forum. Last summer I wrote some GNU Emacs functions for this. It does a more complete job than other approaches I have seen, and it is customizable. It can both be used as is (although it is slightly--but not prohibitively--slow of course), but in particular I would like to regard it as a part of the discussion. Among its features is that all environments in a user modifiable list are deleted. A selected number of commands (defined in another user definable list) will get their arguments junked. It is easily adaptable to other TeX-dialects, using all kinds of weird characters for escape and grouping. I include the file in this mailing, although I suspect that the moderator will find it to large and file it at a ftp-able location instead. Bengt Martensson +49 421 218-2948 Institut fur Dynamische Systeme, Universitat Bremen +49 421 171713 (home) Postfach 330 440, D-2800 Bremen 33 F.R.G. UUCP: ...unido!ubrinf!mond!bengt %%% Bengt's GNU Emacs code is too long for normal digest distribution. For %%% those on ARPANET with FTP capability, you can transfer Bengt's %%% submission by ``getting'' the file: %%% MARTENSSON.TXH %%% from the machine ``SCORE.STANFORD.EDU''. For those on BITNET, a copy %%% has been forwarded to TEX-L. Malcolm ;;; Detex ;;; Bengt Martensson ;;; LastEditDate="Sun Oct 4 17:54:06 1987" ;;; For redistribution the same rules apply as for GNU Emacs. ------------------------------ Date: Fri, 4 Mar 88 03:04 PST From: Subject: Dropped Capital Macro This topic never seems to go away! I sent the macros below to a few people earlier, but it seems there is always more discussion in this forum. Well here is my Dropped Capital Macro, called \illuminate. I modified \illuminatenext today following a suggestion by Tom Reid in a recent TeXhax. %------------------------------------------------------------------------------ % "Illuminate" the first letter of a paragraph. I.e., use a big letter % taking up more than one line. --- Donald Arseneau % % The first letter is lowered so its baseline matches a baseline further % down. There is at least one \normalbaselineskip between the bottom of the % letter and the baseline of the first line below the letter. The letter % projects above the top baseline anywhere from 1 ex to 1\baselineskip + % 1 ex. Since this can be higher than one \baselineskip, \illuminate % might need to be preceded by some vertical skip. % \font\illumfont=cmr17 scaled \magstep 3 % Or whatever you want. % % For truly beautiful output, you should choose \illumfont so its % capital letter height is an integer\baselineskip greater than the % normal text's capital letter height. This \illumfont is good for % tenpoint text with a baselineskip of about 14pt. % \newdimen\illower \newcount\indlinecount \newbox\illet % %------------------------------------------------------------------------------ % \def\illuminate#1{% %------Put the first letter in a box: ------------------------------------ \setbox\illet=\hbox{\illumfont #1}% %------Check if following is a space-------------------------------------- \futurelet\next\ILLuminATE} \def\ILLuminATE{{% \expandafter\ifx\space\next\setbox\illet=\hbox{\box\illet\ }\fi \global\hangindent=\wd\illet \hangafter=-1 %------Get the number of lines needing indentation------------------------ % Make room for descenders, being sure to leave a \normalbaselineskip: \illower=\dp\illet \advance\illower by 0.98\normalbaselineskip % (use .98 to make integer rounding go the right way.) \indlinecount=\illower \divide\indlinecount by \baselineskip \advance \hangafter by -\indlinecount % Calculate room for the height that is shifted down, making sure % that 1 ex sticks up above the first baseline : \illower=\ht\illet \advance\illower by -1 ex % Convert lowering to an integer number of lines: \indlinecount=\illower \divide \indlinecount by \baselineskip \global\advance\hangafter by -\indlinecount %------Keep the whole letter on one page---------------------------------- % (necessary because it gets its depth removed) \advance\illower by 1\baselineskip \vskip 0pt plus \illower \penalty -200 \vskip 0pt plus -\illower %------Get the distance to lower ----------------------------------------- % Make sure lowered box has no depth: \illower=\indlinecount\baselineskip \dp\illet=-\illower %------ In case \illuminate was generated by \everypar,------------------- % prevent recursion when we restart the paragraph. % Illumination prevents \everypar from happening. \everypar={\relax} %------ Do it------------------------------------------------------------- \noindent\llap{\lower\illower\box\illet}% }\ignorespaces} % %------------------------------------------------------------------------------ % To use \illuminate from within a macro (\chapter for example), end that % macro with: % ... \illuminatenext\ignorespaces} % and blank lines after the macro invocation will not interfere with the % illumunation. % % Unfortunately, \everypar gets invoked AFTER the paragraph starts, but % following a suggestion by Tom Reid, we can back out of the new pararaph. % \def\illuminatenext{\toks255=\everypar \everypar={\global\everypar=\toks255 \setbox\illet=\lastbox %Eat thebox that starts the paragraph \vskip-\parskip\illuminate}} % %------------------------------------------------------------------------------ Some examples of use could be: \illuminate T'was brillig ... mome raths outgrabe. \illuminate Questions of taste... \def\head#1{\bigskip\centerline{{\bf #1}}\medskip\illuminatenext\ignorespaces} % And to make every paragraph start with a large dropped capital: \parskip=\bigskipamount \everypar={\setbox\illet=\lastbox \vskip-\parskip\illuminate} % ... as in \illuminatenext. ----------------------------- Donald Arseneau I am TRIUMF asnd@triumfcl.bitnet 4004 Wesbrook Mall asnd@dac.triumf.cdn Vancouver, BC arseneau@mtsg.ubc.ca Canada V6T 2A3 ------------------------------ Date: Fri, 4 Mar 88 8:54:32 EST From: shashi@ms.uky.edu Subject: TeX-to-C I was able to compile and run it on an AT&T 3B20 machine without any siginificant changes. I have it running at TeX level 2.7 and plan to put TeX level 2.9 soon. I had tried to compile and run CommonTex on 3b20 before. It compiles correct but the footnotes disappear on it. It goes thru all motions of creating a footnote but the text gets lost. So I tried to fix it, but it does have some structure definitions of which 3B20 C compiler (even if it does not complain) can not make good use. 3B20 is very sensitive about 'boundaries' and its address space runs in opposite direction as that of vax. I had known this from experience of porting other software from vax to it. And CommonTex (because it tries to run similar to Knuth's code? ) does it (use specific addressing) all over the code... To add insult to injury, 3B20 C also does not 'sign-extend'. My guess is THAT was main reason behind my disappearing footnotes. Anyway, I have been reading a lot of comparison of CommonTex and TeX-to-C in texhax and thought I should put in my dime's worth :-) Shashi Sathaye Computing Center University of Kentucky Lexington Ky. 40506 ------------------------------ Date: Fri, 4 Mar 88 09:13:04 EST From: Charlie Martin Subject: JTeX Could someone forward me the path to the JTeX stuff? The one I had (PS: on Turing.stanford.edu) doesn't seem to work. Thanks, Charlie Martin (crm@cs.duke.edu,mcnc!duke!crm) ------------------------------ Date: Fri, 4 Mar 88 14:28:12 GMT From: Paul Karger Subject: widows and clubs in LaTeX I have had problems with widow and club lines in my LaTeX output, and although I raised the parameters suggested in the TeX Book, the widows and clubs have not gone away. I am using the doublespace.sty file from the Rochester collection, written by Stephen Page, with the stretch factor set to 1.5. (I am required to multiple-space the document, unfortunately.) I have set the relevant TeX parameters as follows: \widowpenalty=1500 \displaywidowpenalty=1300 \clubpenalty=1500 The widows and clubs seem most common around LaTeX section headings and just before footnotes, but they sometimes appear just between simple paragraphs. I may have missed some parameter, or I may not have made the values large enough. I would like to avoid using the \pagebreak and \nopagebreak commands, if possible. Would any TeXnician out there be able to shed some light on the problem? Thank you. Paul Karger ------------------------------ Date: Fri, 4 Mar 88 17:52:21 -0100 From: mcvax!ruuinf!piet@uunet.UU.NET (Piet van Oostrum) Subject: Common TeX patch 2.7 In the patches for common tex v. 2.7 I sent out some time ago unfortunately one line was missing from the module par.c. I just overlooked this line when converting and typing the corrections from TUGBOAT. Here is the diff for the additional line: --- par.c Fri Mar 4 11:55:08 1988 *************** *** 247,252 break; } } } break_width[1] += disc_width; if (t == 0) s = link(v); --- 247,253 ----- break; } } + incr (t); } break_width[1] += disc_width; if (t == 0) s = link(v); Thanks to mcvax!CUNYVM.CUNY.EDU!XMATroot%DDATHD21.bitnet (K.-Th. Schleicher) for noting this. Piet van Oostrum, Dept of Computer Science, University of Utrecht Budapestlaan 6, P.O. Box 80.012, 3508 TA Utrecht, The Netherlands Telephone: +31-30-531806 UUCP: ...!mcvax!ruuinf!piet ------------------------------ Date: Fri, 4 Mar 88 14:00 EST From: Subject: PXtoPK changes for VAX/VMS Modified rapture! I found PXtoPK.WEB on LISTSERV@TAMVM1.BITNET. Now what I need is a VAX/VMS change file. Can anyone out there supply one over Bitnet? And while I have the pulpit, why does LISTSERV@TAMVM1 have so many empty filelists? Are all those files going to appear there Real Soon Now? What will it take to make it happen? Dare I hope that one day not only any TeX related stuff I need, but the change files I need as well, will be available over Bitnet from one central source? Rich Holmes Richard S. Holmes Phone: (315)423-3891 or Physics Department -2701 Syracuse University BITNET: Rich@SUHEP Syracuse, NY 13244 ------------------------------ Subject: dvi2ps using pk files Date: Fri, 04 Mar 88 13:01:09 PST From: Phil Windley Has anyone modified dvi2ps to use pk files rather than gf files? I don't keep all the gf files around and would like to be able to use dvi2ps anyway. Phil Windley Robotics Research Lab University of California, Davis ------------------------------ From: monardo@renoir.Berkeley.EDU (Pat Monardo) Subject: Re: Common TeX patch 2.7 Date: Fri, 04 Mar 88 13:26:56 PST by the way, Common TeX trip.log diffs now show only 2 glue_set discrepancies which is acceptable i believe. Also there are about a dozen memory usage differences which is also acceptable. pat ------------------------------ Date: Fri, 4 Mar 88 17:02:23 PST From: rusty%velveeta.Berkeley.EDU@berkeley.edu (rusty wright) Subject: new bibtex What a nasty program! Whenever I give it the wrong filename it deletes all of my files! ------------------------------ From: DLATEX%UCBCMSA.BITNET@forsythe.stanford.edu Date: Sat, 05 Mar 88 09:33 PST Subject: using native fonts Hello Beebe Driver Enthusiasts, Has anyone out there made some mods to the Beebe suite of drivers to allow one to use the fonts which reside in the laserwriter (Helvetica, Times-Roman ,etc...) ? I already have the tfm files for these, I just need the source code mods. If anyone responds to this, I am willing to collect the results and make them known to Dr. Beebe and this community of TeX'ers. Thanks in advance. Doug Henderson dlatex@cmsa.berkeley.edu 186 University Hall Berkeley, CA 94720 (415) 642-9485 ------------------------------ Subject: Bug in Kellerman & Smith version 2.2.0 of PXtoPX From: adk%FSU.BITNET@CUNYVM.CUNY.EDU Date: Sat, 5-MAR-1988 17:19 TeXhax Digest Friday, January 15, 1988 Volume 88 : Issue 05 Date: Wed, 13 Jan 88 14:23 EST From: "Jerry Leichter (LEICHTER-JERRY@CS.YALE.EDU)" Subject: Creating PK fonts from PX fonts for DVIDIS ... PK font files produced from PX font files using Version 2.2 of PXTOPK. This version has a serious bug that leads it to compute spurious values for the X- and Y-offset fields. A quick check with PKTYPE will usually reveal values for these fields in the millions; correct values are rarely more than 20 in absolute value... TeXhax Digest Thursday, February 11, 1988 Volume 88 : Issue 14 Date: Mon, 8 Feb 88 10:43 PST From: Don Hosek Subject: PXtoPK problems on VMS Be aware that you may encounter 2 different problems with VMS PXtoPK (version 2.3); the first involves a minor bug in the CHange file as distributed by Jerry Leichter (and perhaps others). In line 326, ask:=status(pk_file)<>0; should be shanged to ask:= status(pxl_file)<>0; this minor bug will cause errors opening the PXL file when prompting the user to go undetected and the program will then give a file not found error on PXLFILE.DAT when it first attempts to read from the PXL file... ------------------------------------------------------------------------------ I finally found time to chase down the bug in Kellerman & Smith's version of PXtoPK which was causing the problems when I tried to set up DVIDIS. The K&S version calls itself "VAX/VMS Version 2.2.0, April 1986", and the error is that there are two occurences of the line begin a:=a+@"40000000; a:=a+40000000; his:=a div @"10000 - @"8000; in their change file, which ought to be begin a:=a+@"40000000; a:=a+@"40000000; his:=a div @"10000 - @"8000; The strange thing is that their change file fixed the bug which was fixed in version 2.3 of PXtoPK, but introduced this bug instead. There is a sort of symmetry involved, as their version of PKtoPX had a bug in it as well. As far as I can tell, neither can ever have worked... ------------------------------ From: Date: Sun, 6 Mar 88 01:13:09 EST Subject: site-specific environment in LaTeX (?) I am using LaTeX with Common TeX version 2.1.1 and printing output for the most part on a Postscript printer with dvi2ps. Using the \special command, it is sometimes convenient to insert raw Postscript code into a LaTeX document and I have done this frequently. It would be nice, though, to have a more general and friendly method for doing this sort of thing. Along these lines, I would like to create a LaTeX environment: \begin{site-specific}{postscript}{6in}{4in} raw Postscript code % % The {6in} and {4in} parameters to this environment would be % the size of the box in which LaTeX (TeX) would put the site % specific picture or text. % \end{installation-specific} Then, by specifying something other than {postscript} as the first argument to the site-specific environment, the environment would "do the right thing" for whatever sort of site-specfic printer codes I wanted to insert. I would like to achieve this by having TeX write the contained text out to a file and then include that file into the dvi2xxx output with a \special command. The question is: how can I get TeX to put the text enclosed by my environment into a separate file and not attempt to typeset it? The ideas I've had so far (some of which I've tried) include: o Changing to an active character and defining it as a macro. This didn't work because I couldn't figure out how to enclose a line in a group automatically so that I could write it to a file. \bgroup and \begingroup didn't seem to work. o Redefining every character that anyone might want to use in the site-specific code as a macro which writes itself out to the file. This didn't seem terribly practical. o Redirecting the output from TeX to a different file for the duration of the environment. This is not right, since I don't want TeX to try to interpret it. o Writing a macro to be invoked by the \begin{site-specific} which reads from the input file directly until it finds a \end. I haven't tried this, but it doesn't seem terribly likely as I can't figure out how to read from the default input file, from the current position. This has been fairly frustrating, but what I think is going on is that I'd like to take the input text after TeX has chewed on it, but before it has digested it (to use the terminology in the TeXBook) and write it to a file instead of letting TeX's stomach get at it. Basically, I'd like to slit TeX's throat. Does anyone have any suggestions? Sincerely, Aaron Goodisman Student Information Processing Board MIT aaron@ATHENA.MIT.EDU arpa aaron%athena.mit.edu@MITVMA bitnet ...!mit-athena!aaron uucp (?) ------------------------------ Date: Sat, 5 Mar 88 17:00 EDT From: David Forster Subject: how to get Common TeX? Can someone out there please tell me how I can get a copy of Pat Monardo's Common TeX? I heard it could be ftp'd from SDCSVAX.UCSD.EDU, but I can't get through to it for some reason. Is there a site closer to Western Massachusetts (at least in terms of networks) that I could get it from? Or is there some kind soul ought there who would copy it onto tape for me (data cartridge or 1/2" reel) if I sent them the tape, plus one SASE? Please e-mail replies directly to me, since I don't read this list too often. Thanks! David Forster ARPA/MILnet: forster@cs.umass.edu CSnet: forster@umass-cs BITnet: forster@umass UUCP: ...!seismo!forster%umass-cs@csnet-relay.arpa (I *THINK!*) or ...!harvard!forster%umass-cs@csnet-relay.arpa (ditto) ------------------------------ Date: Mon, 07 Mar 88 12:31:02 AST From: "dErRiCk WeBbEr - Ack Phtt." Subject: Very narrow columns in Plain TeX Hi. I've been trying to get plain TeX to produce acceptable 2-inch wide columns for a newspaper. Unfortunately, just setting \hsize=2.0in leaves horrible gaps in many paragraphs and begins others with just one word on the line. Here's a simulated example: ``The beat- ings are not limited to parks and beaches. They're (now) happen- ing outside bars, even hospitals,'' said Gilbertson. The gaps occur even though it appears there are several good ways TeX could fill the space. I'm not a TeX whiz, but I tried adjusting \linepenalty and \hyphenpenalty without effect. Can anyone suggest other settings to modify. Has anyone had success producing such narrow columns with plain TeX? Derrick Webber, Editor k bitnet: The Gem Student Newspaper k or: WEBBER%UPEI.BITNET@WISCVM.WISC.EDU University of Prince Edward Island k ``Newspapers are to comfort the Canada k afflicted and afflict the comfortable'' k --John Winkler %%% %%% Barbara Beeton is quick with a reply: %%% ------------------------------ Date: Mon 7 Mar 88 11:50:14-PST From: Barbara Beeton Subject: Re: Very narrow columns in Plain TeX plain tex isn't really set up to handle very narrow columns. one approach to "loosening up" tex's line-breaking is to increase the amount of stretch permissible in inter-word spaces. in turn, there are two ways of doing this -- redefining \spaceskip and \xspaceskip, or resetting \fontdimen3 (interword stretch) to be more generous for NNthe affected fonts. i'd generally recommend the latter, and in fact, have used it in the tugboat headers -- tugbot.sty (look for the string "stretchy"). the standard \fontdimen settings for spacing parameters are given on page 433 of the texbook. -- barbara beeton ------------------------------ Date: 7 Mar 88 16:23 -0500 From: naren Subject: Gosling Emacs Macros for LaTeX I am looking for Emacs Macros for LaTeX. Were they ever posted before? Anyone knows where I can find them? Thanks. Naren Narendra Mehta, Systems & Computer Eng. Department, Carleton University, Ottawa, Canada UUCP: {allegra,decvax,ihnp4,linus,utzoo}!watmath!clan!naren ARPA: naren%sce.carleton.cdn%ubc.csnet@csnet-relay.arpa ------------------------------ %%% %%% subscriptions, address changes to: texhax-request@score.stanford.edu %%% please send a valid arpanet address!! %%% %%% BITNET distribution: subscribe by sending the following %%% line to LISTSERV@TAMVM1.BITNET: %%% SUBSCRIBE TEX-L %%% %%% submissions to: texhax@score.stanford.edu %%% %%%\bye %%% ------------------------------ End of TeXhax Digest ************************** -------