Subject: TeXhax Digest V89 #51 From: TeXhax Digest Errors-To: TeXhax-request@cs.washington.edu Maint-Path: TeXhax-request@cs.washington.edu To: TeXhax-Distribution-List:; Reply-To: TeXhax@cs.washington.edu TeXhax Digest Wednesday, May 17, 1989 Volume 89 : Issue 51 Moderators: Tiina Modisett and Pierre MacKay %%% The TeXhax digest is brought to you as a service of the TeX Users Group %%% %%% in cooperation with the UnixTeX distribution service at the %%% %%% University of Washington %%% Today's Topics: Needed: Program to trace file dependencies in TeX/LaTeX Re: Problem with LaTeX optional argument LaTeX question about indices Re: Problems with Handy Little Font Re: TeXhax Digest V89 40 Problem with \global in LaTeX .AUX file Paragraph with last line centred Equation numbers with \cases Re: French quotation marks LaTeX optional style file for NSF proposals? Re: Needed: Help with hyphenation "Big" TeX for CMS A self-study gentle introduction to TeX Re: Three questions (or something like that) Re: Graphics in Tex PostScript definitions in TeX ------------------------------------------------------------------------ Date: Mon, 15 May 89 18:08:03 CDT From: Don Hosek Subject: Needed: Program to trace file dependencies in TeX/LaTeX Keywords: TeX, LaTeX, file dependencies Does anybody have a program that could, given a root file, trace all \input and \include commands (actually, it should also be possible to extend the list of commands which perform an \input) and list the files that are used for that TeX run? (also nice would be the same thing for MF) dh Don Hosek Internet: U33297@UICVM.UIC.EDU 3916 Elmwood Bitnet: U33297@UICVM.BITNET Stickney, IL 60402 DHOSEK@YMIR.BITNET Work: 312-996-2981 UUNet: dhosek@jarthur.claremont.edu JANET: U33297%UICVM.UIC.EDU@UK.AC.EARN-RELAY ------------------------------------------------------------------------------- Date: Wed, 17 May 89 15:32 EDT From: "Jerry Leichter (LEICHTER-JERRY@CS.YALE.EDU)" Subject: Re: Problem with LaTeX optional argument Keywords: LaTeX, error message In a recent TeXhax, Michael Barr (at least that's the name in his example, the message is unsigned and has a meaningless return address) asks whey the following LaTeX input results in an error message: \twocolumn[ \begin{center} {\LARGE\bf Fuzzy Sets and Toposes}\\[3ex] Michael Barr\\ Department of Mathematics and Statistics\\ McGill University\\ 805 Sherbrooke St., W.\\ Montr\'eal, Qu\'ebec \\ Canada H3A 2K6 \end{center} ] This is one of the "gotcha's" in LaTeX. The problem is that LaTeX - and a human reading the input - thing of [ ... ] as a bracketed construct, so that any embedded [ ... ] pairs are recursively matched. However, square brackets have no special meaning to TeX. When TeX extracts the optional argument for \twocolumn, it will match up to the first ], which will destroy the meaning of the input. The way to get around this is to enclose the argument in a { .. } pair. TeX requires that macro arguments have matched curly braces. TeX will not look inside them for a matching ] : \twocolumn[{ \begin{center} {\LARGE\bf Fuzzy Sets and Toposes}\\[3ex] Michael Barr\\ Department of Mathematics and Statistics\\ McGill University\\ 805 Sherbrooke St., W.\\ Montr\'eal, Qu\'ebec \\ Canada H3A 2K6 \end{center} }] Jerry --------------------------------------------------------------------------- Date: Wed, 17 May 89 14:45:10 EDT From: Gary Ansok <"STOSC::ANSOK"@scivax.STSCI.EDU> Subject: LaTeX question about indices Keywords: LaTeX, indices Is there a way to get an index with sub-entries automatically created in LaTeX? As far as we know, \item and \subitem (and \subsubitem) will create this (in the theindex environment) if you already have the index entries with page numbers in a file. But we would like to have the index automatically created by \index, and we do not know if there is a way to do this. By the way, what we are looking for is an index that looks like topic, 100, 110, 200 subtopic, 100 subtopic2, 110 topic2, ... If we can't find what we're looking for, we'll have to settle for topic, 100, 110, 200 topic, subtopic, 100 topic, subtopic2, 110 topic2, ... Please reply directly to me as I do not read this mailing list. Thanks in advance for any help you can offer. Gary Ansok "STOSC::ANSOK"@scivax.stsci.edu ansok@stsci.bitnet Famous Disclaimers #1: "I know nothing, Col. Hogan! Nooo-thingg!"--Sgt. Schultz ----------------------------------------------------------------------------- Date: Mon, 15 May 89 17:01:28 CDT From: Don Hosek Subject: Re: Problems with Handy Little Font Keywords: Handy Little Font The problem you describe is most definitely a typo... it seems that all of the braces {...} in the listings have been omitted. Fortunately, there weren't very many. They belong in the following places: (1) when right or left appears on a draw statement (e.g., draw z18--z17right..z16--z7; should be draw z18--z17{right}..z16--z7; (2) at the point where you encountered the error, z6z5-z2 should be z6{z5-z2}. dh P.S. When you get it fixed, could you send me the source so I don't have to type it in myself? Don Hosek Internet: U33297@UICVM.UIC.EDU 3916 Elmwood Bitnet: U33297@UICVM.BITNET Stickney, IL 60402 DHOSEK@YMIR.BITNET Work: 312-996-2981 UUNet: dhosek@jarthur.claremont.edu JANET: U33297%UICVM.UIC.EDU@UK.AC.EARN-RELAY ---------------------------------------------------------------------------- Date: Mon, 15 May 89 10:42:20 EDT From: PORTER Subject: Re: TeXhax Digest V89 40 Keywords: TeX, METAFONT, MVS/TSO/E Does anybody have a TeX && METAFONT & ... change file(s) made explicitly for MVS/TSO/E? I have been using the CMS version, and it compiles ok after a little updating. However, the special routines ATTN202, USESTACK and TERMATTN were not included. If these routines work for MVS/TSO/E then I would be quite happy with them. (I am particularly interested in the USESTACK routine since it is not too likely that we will actually be running TeX from TSO/E, more likely as a batch job. This is because we are investigating other TMPs, notably ROSCOE.) In any case, any help would be appreciated. Mike Porter ------------------------------------------------------------------------------- Date: Mon, 15 May 1989 06:57:22.06 CDT From: (George D. Greenwade) Subject: Problem with \global in LaTeX .AUX file Keywords: LaTeX, \global I have a question which I can find no easy answer to. I am writing a style option file in LaTeX to evaluate the current page number, current running page number and total number of pages to produce: Page x of y (x=runningpagenumber, y=total number of pages). To do so is seemingly easy, simply define the statements. The problem is that I need to write to the .AUX (\@mainaux) file a token which points to a \global-ly defined variable. Without the \global assignment, the .AUX does not supercede the default definition in the style; without a default definition, the style file crashes. The relevant portions of the .STY are below, as well as the .LIS from running the file. Any ideas, solutions, etc., will be appreciated. Once this is cleaned up, the file will go to Clarkson and be posted here. Thanks in advance. FROM PAGEOF.STY (in development; prints Page x of y using a variation of headerfooter.sty [where \oddpageheader, etc. are defined]). The \enddocument definition uses: \def\enddocument{\@checkend{document} ..... omitted text ...... \immediate\write\@auxout{% %%%%%% \string\evaltext} %%%%%%% ..... omitted text ...... Where \evaltext points to \def\evaltext{ \ifnum\totalpagecount > 0 \gdef\totalpagecounttext{\totalpagecount} \fi \def\pageof{Page \therunningpage\ of \totalpagecounttext} \ifnum\therunningpage = \thepage \oddpageheader{}{}{} \evenpageheader{}{}{} \fi \ifnum\therunningpage < \thepage >> \global\oddpageheader{}{}{\bf \thepage} \evenpageheader{\bf \thepage}{}{}\fi \ifnum\therunningpage > \thepage \oddpageheader{}{}{\bf \thepage} \evenpageheader{\bf \thepage}{}{} \fi \pagefooter{}{\pageof}{} } The \global on the line marked >> in the \evaltext definition produces the following from the .LIS file: ! Use of \global doesn't match its definition. \evaltext ...ge < \thepage \global \oddpageheader {}{}{\bf \thepage } \evenp... although it writes \evaltext to the .AUX and understands that a \global evaluation is needed to operate correctly (I am also aware that a \global is ultimately needed on the following \ifnum conditional, as well, but why crash twice?) %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% George D. Greenwade, Director Bitnet: BED_GDG@SHSU Center for Business and Economic Research THEnet: SHSU::BED_GDG Sam Houston State University Internet: BED_GDG@SHSU.BITNET Huntsville, Texas USA 77341-2056 Voice: (409) 294-1518 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ------------------------------------------------------------------------- Date: Tue, 16 May 89 12:55:48 BST From: Mike Spivey Subject: Paragraph with last line centred Keywords: TeX, paragraphs Try this: \hsize=3in \vsize=5in \parindent=0pt \leftskip=0pt plus1fil \rightskip=0pt plus-1fil \parfillskip=0pt plus2fil How can paragraphs be set with the last line centred, rather than filled with blank space at the right? A simple solution is the four assignments above (the assignment to {\tt\string\parindent} is optional). This is much easier than collecting the paragraph in boxes then dissecting the remains. How does it work? On all but the last line of the paragraph, the {\tt\string\leftskip} and {\tt\string\rightskip} cancel each other's stretch component, so that the highest non-zero glue order for stretching is the finite stretch of the spaces between words. These expand so that the line fills the measure, and the infinite glue doesn't stretch at all. On the last line of the paragraph, the infinite glue doesn't cancel; instead, there's 1fil at the left and a total of 1fil at the right. The highest non-zero glue order is infinite, and the infinite glue stretches to centre the line. \bye ------------------------------------------------------------------------- Date: Sat, 13 May 89 13:02:49 EDT From: quinlan@astrosun.TN.CORNELL.EDU (Gerry Quinlan) Subject: Equation numbers with \cases Keywords: equation numbers, \cases I would like to be able to format an equation with two parts as shown below: / | x, x<<1; (1a) f(x) = | | 1/x, x>>1. (1b) \ The bracket after the = sign is meant to be a large {. This is similar to the output of the \cases command, except that I want equation numbers on the right of each part. If I try $$f(x)=\cases{x,&$x\ll0$;\eqno(1a)\cr 1/x,&$x\gg1$.\eqno(1b)\cr}$$ the equation numbers get stuck right after the equation, i.e., they are not right justfied. Sticking \hfil or \hfill before the \eqno does not help. I cannot find any examples like this in the Texbook. Does anyone know an easy solution? Thanks. Gerry Quinlan quinlan@tcgould.tn.cornell.edu ----------------------------------------------------------------------------- Date: Fri, 12 May 89 14:20:39 EDT From: jsv@cs.brown.edu Subject: Re: French quotation marks Keywords: French quotes I use two macros I've defined called \frlquote and \frrquote. You can rename them anyway you want. Here they are: \def\frlquote{\vbox{\offinterlineskip \hbox{${\scriptscriptstyle\langle\!\langle}$}\kern-0.1pt}\hskip -.6pt plus.3pt minus.2pt~} \def\frrquote{~\hskip -.6pt plus.3pt minus.2pt\vbox{\offinterlineskip \hbox{$\scriptscriptstyle\rangle\!\rangle$}\kern-0.1pt}} For example, you could write. . . C'est le \frlquote star\frrquote du film. --------------------------------------------------------------------------- Date: Wed, 17 May 89 12:05 CDT From: U2591AA@VMS.UCC.OKSTATE.EDU Subject: LaTeX optional style file for NSF proposals? Keywords: LaTeX, NSF style file Has anyone put together a style file (perhaps as an option to the article or report styles) for writing NSF grant proposals? If so, and you are willing to share it, where can it be obtained? Please respond directly to me. If there are several submissions, I will post a summary to TeXhax. Scott McCullough Dept. of Physics u2591aa@vms.ucc.okstate.edu (Internet) Oklahoma State University U2591AA@UCCVMS (bitnet) Stillwater, OK 74078-0444 (405) 744-5801 ------------------------------------------------------------------------- Date: Mon, 15 May 89 14:47:15 EDT From: jsg@arbortext.com Subject: Re: Needed: Help with hyphenation Keywords: TeX, hyphenation The reason that the word "photoproduction" doesn't hyphenate in the example: \hsize = .7in \hyphenation{pho-to-pro-duc-tion} photoproduction\par \end is that it's the first word of a paragraph. Technically (hidden under a double dangerous bend on page 454 of The TeXbook), hyphenatable words must be preceded by glue. The first word of a paragraph, instead, is preceded by an empty box whose width is \parindent. You can make the first word hyphenatable by putting a zero-width piece of glue before it as follows: \hsize = .7in \hyphenation{pho-to-pro-duc-tion} \hskip 0pt photoproduction\par \end In this version "photoproduction" hyphenates, but still causes an overfull boxe because there is no stretchability in the glue on the first line. Something like this will get rid of the error message: \raggedright \hsize = .7in \hyphenation{pho-to-pro-duc-tion} \hskip 0pt photoproduction\par \end John Gourlay ArborText, Inc. jsg@arbortext.com uunet!umix!arbortext!jsg ------------------------------------------------------------------------------- Date: Mon, 15 May 89 14:06:02 CDT From: Don Hosek Subject: "Big" TeX for CMS Keywords: Big TeX, CMS Has anybody given any thought to creating a "big" TeX for CMS? Because of VM's memory management, it seems that the standard method of increasing array sizes etc. will not work since that will either require ALL TeX users to get VM's with a larger storage area (not necessarily a good thing), or require that a "big" and a "normal" TeX co-exist, which could become somewhat of a pain to maintain. The other alternative, allocating chunks of mem dynamically as they are needed seems like a fairly substantial task and may cause some performance degredation. Comments anyone? dh Don Hosek Internet: U33297@UICVM.UIC.EDU 3916 Elmwood Bitnet: U33297@UICVM.BITNET Stickney, IL 60402 DHOSEK@YMIR.BITNET Work: 312-996-2981 UUNet: dhosek@jarthur.claremont.edu JANET: U33297%UICVM.UIC.EDU@UK.AC.EARN-RELAY -------------------------------------------------------------------------- Date: Mon, 15 May 89 11:26:25 MST From: "Mike Coffin" Subject: A self-study gentle introduction to TeX Keywords: TeX I would be happy to look at your current draft and give you some feedback. I think this is a sorely needed item. Mike Coffin mike@arizona.edu Univ. of Ariz. Dept. of Comp. Sci. {allegra,cmcl2}!arizona!mike Tucson, AZ 85721 (602)621-2858 --------------------------------------------------------------------------- Date: Fri, 12 May 89 15:44:57 edt From: Brian T. Schellenberger Subject: Re: Three questions (or something like that) Keywords: macros Somebody recentely asked for macros that are invoked on each line. Here is one to generate a large, commented-out area--one of the specific applications he asked about. Just something I happen to have lying around. The basic idea is that We read in the next line (delimited by the end-of-line character in a group; after the group, we read in the next line, and so on, until we hit the string \end{ignore} on a line by itself, at which point we stop. And yes, this is some of the most bizarre TeX code I've written; if you don't quite grok it, don't feel too bad. P.S.: Your 1st question fails because \begin{verbatim}, much like this command, looks for the literal string \end{verbatim} to end rather than actually *executing* the \end{verbatim} command when it sees it. Thus, in cannot be nested. \makeatother \begingroup% \catcode`\^^M=\other% \catcode`\[=1 \catcode`\]=2% \catcode`\{=\other \catcode`\}=\other% \gdef \ignore % [% \catcode`\^^M=\other \catcode`\#=\other% \catcode`\{=\other \catcode`\}=\other% \ignore@line% ]% % \gdef \ignore@flag [\end{ignore}]% % \gdef \ignore@line #1^^M% [% \bgroup% \def\@tempa[#1]% \ifx \@tempa \ignore@flag% \aftergroup \clean@ignore% \else% \aftergroup \ignore@line% \fi% \egroup% ]% \endgroup \def \endignore {\rule{0pt}{0pt}} \def \clean@ignore {\end{ignore}} \let \endignore = \endtrivlist \makeatletter % unless this is a .sty file. Brian, the Man from Babble-on. ...!mcnc!rti!sas!bts ---------------------------------------------------------------------------- Date: Wed, 17 May 89 11:32:14 NZT From: Russell Fulton Subject: Re: Graphics in Tex Keywords: TeX, graphics Tugboat 10.1 has finally mad it to the Antipodeas! I was interested to read the two articles on graphics in TeX by David Rogers and Bart Childs et al. I am stirred to make a few comments on them: Firstly the two articles address different issues, both of which are must be addressed in any graphics system for TeX. David Roger's article address the problem of generating graphics from within a TeX document. Bart Childs article discusses the inclusion of graphics generated by other systems. We have an ISO graphics standard (GKS). Lets not invent yet another graphic file format. CGM ( GKS's metafile ) is to graphic system what dvi files are to Tex and there already is a lot of software around for translating them to various device dependent forms. I agree with David that CGM is more powerful than is necessary for this aplication but think that the fact that there is alot of GKS system in use now is too important to ignore. I like Davids subset of graphics operators, but I think that they should emit specials into the dvi file with CGM commands. The dvi program can then assemble the CGM file from the embeded specials and pass it to the CGI processor to convert it into device dependent form. If the dvi driver does not have the ability to handle CGM files then it will ignore the specials. This scheme involves modifying current dvi drivers but not the definition of the dvi files. I know that this will take time but the alternative are systems that involve lots of steps ( Bart Childs lists 6 steps to include a cgm file) and most of our users will find it easier to do the whole job on a Mac and not bother with TeX at all. One of the stickest problems is letting TeX know what sized box to allocate for included graphics. Don Berrymans program is a step in the right direction. Its a pity that CGM files don't have a direct equivalent of PostScript's %%Bounding box. What ever scheme is adopted it must be simple, easy to use, address inclusion of graphics generated by other software and support the generation of graphics from within TeX its self. Russell Fulton, Computer Centre, University of Auckland, New Zealand. --------------------------------------------------------------------------- Date: Wed, 17 May 89 13:45:39 -0700 From: Tomas G. Rokicki Subject: PostScript definitions in TeX Keywords: PostScript, TeX To facilitate the inclusion of PostScript definitions in your TeX document, most dvi2ps drivers out there support some variant of the `\special{header=fn}' which includes a prologue file that may contain definitions. Note that PostScript definitions in the `Page' portion of the PostScript document will not span that page due to save/restore pairs. Drivers such as my dvips that support `literal' PostScript specials (i.e., `\special{"any PostScript text here}') should also support literal PostScript definitions (in dvips, `\special{! PS definitions}') that are collected and inserted with the other header information. tom ------------------------------------------------------------------------------- %%% Concerning subscriptions, address changes, unsubscribing: %%% BITNET: send a one-line mail message to LISTSERV@xxx %%% where xxx is the nearest geographical site in the %%% tree shown below %%% SUBSCRIBE TEX-L % to subscribe %%% or UNSUBSCRIBE TEX-L %%% %%% Here is the BITNET re-distribution tree as shown in a recent %%% REVIEW (The geography is guessed at from the subscription list) %%% %%% CLVM TAMVM1 FINHUTC %%% | | (Finland, UK, Scand, CERN) %%% | | | %%% TeXhax ----> UWAVM ----- MARIST ----- EB0UB011 ----- BNANDP11 %%% | (France,Italy,Spain) (Belgium) %%% | | %%% UBVM HEARN --- DEARN %%% (Netherlands) (Germany) %%% %%% Internet: send a similar one line mail message to %%% TeXhax-request@cs.washington.edu %%% Please be sure you send a valid internet address!! %%% in the form name@domain or name%routing@domain %%% and use the style of the Bitnet one-line message, so that %%% we can find your subscription request easily. %%% %%% All submissions to: TeXhax@cs.washington.edu %%% %%% Back issues available for FTPing as: %%% machine: directory: filename: %%% JUNE.CS.WASHINGTON.EDU TeXhax/TeXhaxyy.nn %%% yy = last two digits of current year %%% nn = issue number %%% %%%\bye %%% End of TeXhax Digest ************************** -------