TeXhax Digest Thursday, December 31, 1987 Volume 87 : Issue 106 [SCORE.STANFORD.EDU]TEXHAX106.87 Editor: Malcolm Brown Today's Topics: Re: LaTeX list environment question LaTeX for different languages Font modes typesetting directory path diagrams newtheorem oddity book.doc != book.sty? Re: QMS laser printer blank pages (V87 104) Fig to PicTeX converter Pyramid changes and OCR fonts problem with list macros. (texhax #105) Breaking up LaTeX Tables Japanese LaTeX, SliTeX and page parity problem Font questions (TeXhax Digest V87 #104) TeXhax Digest V87 #105 DVIDMD, a previewer for DMD 5620 terminals LaTeX Notes (Re: TeXhax Digest V87 #104) ---------------------------------------------------------------------- From: "Paul H. Calamai" Subject: Re: LaTeX list environment question Steve Buyske : > > > I would like to make a construct a list environment so that I can > have labels that might require two line. Something like > > Professional Something silly, something else silly, some more > Associations: silly things, and so on. > > If I put the label in a \parbox, no matter how I fiddle around, I get > something like: > > Professional Something silly, something else silly, some more > Associations: > silly things, and so on. > > with an ugly extra line. Can anyone give me some advice? > > My apologies if this is an easy question, but I'm new to LaTeX and > desperate to get my C.V. done. > Here is a tex file that will do what you want: % relate_macros.tex 1987 Jun 10 E. Ledoux % Instructions for use are located at the end of this file. % \makeatletter % \newdimen\relateleft \relateleft=\leftmargin % space before label \newdimen\relateright \relateright=\leftmargin % min. space after label \newbox\RELbox \newcount\RELcount \RELcount\z@ \newdimen\RELoldmax \newdimen\RELnewmax % \def\relate{\@ifnextchar [{\RELcontd}{\global\advance\RELcount\@ne \expandafter\RELcontd\expandafter [\romannumeral \the\RELcount]}}% % \def\RELcontd[#1]{\def\RELlabel{#1}% \expandafter\let\expandafter\RELmax\csname RELold@#1\endcsname \ifx\RELmax\relax \RELoldmax0.20\hsize \else \RELoldmax\RELmax \fi \list{}{\labelwidth\RELoldmax \itemindent\z@ \leftmargin\RELoldmax \advance\leftmargin\relateleft \advance\leftmargin\relateright \let\makelabel\RELmakelabel}}% % \def\RELmakelabel#1{\@ifundefined{RELnew@\RELlabel}{\RELnewmax\z@}% {\expandafter\RELnewmax\csname RELnew@\RELlabel\endcsname}% \setbox\RELbox\hbox{\vtop to0pt{\let\\\cr \halign{##\hfil\cr#1\cr} \vss}}% \ifdim\wd\RELbox>\RELnewmax \RELnewmax\wd\RELbox\fi \expandafter\xdef\csname RELnew@\RELlabel\endcsname{\the\RELnewmax}% \hskip\labelsep \hskip-\relateright \hbox to\z@{\box\RELbox\hss}\hfill}% % \def\endrelate{\toks\z@\expandafter{\csname RELold@\RELlabel\endcsname}% \immediate\write\@auxout{\gdef\the\toks0{\csname RELnew@\RELlabel\endcsname}}% \endlist}% % \makeatother \endinput %%% The complete text of Paul's submission is too long for distribution %%% via digest. What follows at this point are instructions for using %%% the "relate" environment. The entire text of Paul's submission %%% is stored at Score for FTPing under the name %%% RELATE.TXH %%% A copy has also been forwarded to the list server for BITNET access. %%% Malcolm ------------------------------ Date: Mon, 21 Dec 87 09:53 SET From: Renzo Beltrame Subject: LaTeX for different languages It seems to me very easy to modify LPLAIN and .STY files in order to have headers, as Abstarct, Reference, etc., parametric. I suggest to introduce suitable \def to obtain this result. This is an example of a possible solution for LPLAIN: \def\Abst@head{Abstract} \outer\def\Abstracthead#1{\def\Abst@head{#1}} \def\Appn@head{Appendix} \outer\def\Appendixhead#1{\def\Appn@head{#1}} \def\Bibl@head{Bibliography} \outer\def\Bibliographyhead#1{\def\Bibl@head{#1}} \def\Chap@head{Chapter} \outer\def\Chapterhead#1{\def\Chap@head{#1}} \def\Fig@head{Figure} \outer\def\Figurehead#1{\def\Fig@head{#1}} \def\Figl@head{List of Figures} \outer\def\Figlisthead#1{\def\Figl@head{#1}} \def\Index@head{Index} \outer\def\Indexhead#1{\def\Index@head{#1}} \def\Pref@head{Preface} \outer\def\Prefacehead#1{\def\Pref@head{#1}} \def\Refc@head{References} \outer\def\Referenceshead#1{\def\Refc@head{#1}} \def\Tocs@head{Contents} \outer\def\Tabofcontentshead#1{\def\Tocs@head{#1}} \def\Tab@head{Table} \outer\def\Tablehead#1{\def\Tab@head{#1}} \def\Tabl@head{List of Tables} \outer\def\Tablisthead#1{\def\Tabl@head{#1}} And this is an example for the ARTICLE STY file: \def\tableofcontents{\section*{\Tocs@head\markboth {\uppercase\Tocs@head}{\uppercase\Tocs@head}} ......... and so on. It should be very useful to standardise this kind of features in a next release of LaTeX. -Renzo Beltrame Acknowledge-To: Renzo Beltrame ------------------------------ Date: Tue, 22 Dec 87 13:28:48 GMT From: Ian Moor Subject: Font modes Is it possible to produce a single font file useable by two different output devices of the same resolution? In our case this is an LN03 and Apple LaserWriter, but obviously a general solution is of more interest. The two print engines require different mode definitions, but I dont want to have two sets of font files on disk for each font in each size. Is there a way of indicating common and differeing data based on device type? Come to think of it - is there a way of determining which device a particular font was built for - I never thought to ask the site that provided ours. ------------------------------ Date: Tue, 22 Dec 87 16:27 CST From: Mark Roseman Subject: typesetting directory path diagrams This has probably been covered before, but I can't recall offhand. What I need is some macros which would allow me to typeset a diagram using TeX which will illustrate the directory setup of a disk, i.e. shows subdirectories, files, etc. as in the following example. When replying, please send mail both to myself and to the net. The example: /H0 | | | ------------ | ----------------------------------------------- | | | | /H0/WORDPROCES | /H0/PROGRAMMING /H0/DISKUTILS | /H0/TERM | | | | | | | | | format | free | phone ../PASCAL ../BASIC09 backup | | | / \ pascal / \ write letter.txt basic09 program.b09 ------------------------------ Subject: newtheorem oddity Date: Tue, 22 Dec 87 16:37:08 PST From: Richard Roy I have experienced precisely the same behavior. The problem has do do with the section counter ( as is clear from the error message ). A solution that achieves the desired result is to define the counters as in an excerpt from one of my macro files: % need newcounter{section} else get into infinite loop with second % [section] optional arg to newtheorem -- 12/15/87 rhr \newcounter{section} \newcounter{theorem} \newtheorem{theorem}{Theorem}[section] \newtheorem{corollary}{Corollary}[theorem] \newtheorem{defn}{Definition}[section] This should solve your problem. The error may be caused by an internally implicit definition of the section counter being invoked since it wasn't explicitly defined. I've cc'ed LL so he may send a more concrete reply. RR ------------------------------ Date: Tue, 22 Dec 87 21:46:51 EST From: mds@l.cc.purdue.edu (Mark Senn) Subject: book.doc != book.sty? The book.sty file is not consistent with book.doc file in score:? Looks like the book.sty file is a "stripped" version of an old version of "book.doc"? Mark ------------------------------ Date: Wed, 23 Dec 87 09:51:16 EST From: "Wayne Podaima, NRC Comp. Services, Ottawa CAN" Subject: Re: QMS laser printer blank pages (V87 104) The ~DCnnnn QMS QUIC command is not meant to print the page (it may if you already have enough stuff on a page - as you found out). The idea is to use ~DCnnnn anywhere in your output, and it outputs that number of pages at the next page eject (whether "~,", FF, or full page). ------------------------------ Date: Wed, 23 Dec 87 11:48:05 EST From: beck@svax.cs.cornell.edu (Micah Beck) Subject: Fig to PicTeX converter PicTeX is an enhanced picture environment for TeX and LaTeX. While it is more powerful than the LaTeX picture environment, it suffers from the same interface problem: the user must explicitly specify each graphics object by a set of coordinates. Fig is a full screen graphics editor which runs under Suntools. The graphics operations it implements are similar to programs like MacDraw. I have developed a Fig-to-PicTeX converter, which tranlates the output of Fig into PicTeX. The implementation is not quite complete. Given the level of interest expressed in PicTeX recently, I thought this a good time to look for Beta sites for the converter. The biggest remaining (known) problem is with splines: Fig generates cubic B-splines, and PicTeX can only generate quadratic curves. PicTeX was developed by Michael Wichura at the Univ. of Chicago statistics department, and is available via anonyomous FTP from june.cs.washington.edu . Fig was developed by Supoj Sutanthavibul at the University of Texas, and is available via anonymous FTP from sally.utexas.edu . If you are interesting in being a Beta-site for my Fig-to-PicTeX converter, please send me mail. Once it has gotten some testing, I'll make it available via anonymous FTP from some site. Micah Beck Department of Computer Science Cornell University beck@svax.cs.cornell.edu ------------------------------ From: trwrb!simpson@trwind.TRW.COM (Scott Simpson) Subject: Pyramid changes and OCR fonts Date: Wed, 23 Dec 87 10:22:22 PST George Hartzell writes of problems with compiling TeX and METAFONT under the Pyramid 4.0 Pascal compiler. I discussed these problems in a previous issue of TeXhax. I have put the changes in the file pub/pyrtexchange4.0.tar on trwind.trw.com. Hopefully the University of Washington will incorporate these changes soon. Also, Dimitri Vulis inquires about OCR fonts. The METAFONT sources for OCR fonts came over USENET a while back. I saved them. Here is the header from one of the files: % OCR-A Optical Character Recognition Font % % Coded in METAFONT84 by Tor Lillqvist, VTT/ATK (Technical Research Centre % of Finland, Computing Services) % (tml@fingate.BITNET, tml@santra.UUCP, mcvax!santra!tml) % % Based on ISO Recommendation R1073, 1st ed., May 1969 (probably % obsolete by now). % % Labels are in French :-) % Contact the author for copies. I don't wish to distribute them. Scott Simpson TRW Space and Defense Sector ...{decvax,ihnp4,ucbvax}!trwrb!simpson (UUCP) trwrb!simpson@trwind.trw.com (ARPA) ------------------------------ Date: Thu, 24 Dec 87 11:33:20 -0100 From: mcvax!ruuinfvax!piet@uunet.UU.NET (Piet van Oostrum) Subject: problem with list macros. (texhax #105) There are two problems with the macros: 1. End-of-lines don't delimit macro arguments by default. If you say \obeylines, the end-of-line markers are translated as ^^M, so in the macro definition you must also delimit the argument with ^^M. However, the definition must take place in an environment where ^^M is not thrown away by the 'mouth' of TeX, so it must have category code 13 (active). This means the definitions must take place inside a group, and hence must be global. 2. The macro definition contains a space between the two arguments, so you must supply a space in the macro call. You probably forgot a space on the last \subentry. This means TeX is looking for the string '] ' and runs into the end of the file. You may end up with unwanted spaces in #2! Here is an updated version: {\catcode`\^^M=13 \gdef\@entry[#1]#2^^M{\cksub=0\ifx#2\empty\cksub=1\fi \ifcase\cksub#1\dotfill#2\or#1\fi} \gdef\@subentry[#1]#2^^M{\quad#1\dotfill#2} \gdef\dotlist{\newcount\cksub\obeylines \let\entry=\@entry\let\subentry=\@subentry \list{}{\rightmargin\z@\leftmargin\z@\item[]}} \gdef\enddotlist{\endlist\par\vspace{\topsep}}} ------------------------------ Date: Thu, 24 Dec 87 09:46 EDT From: Ted Nieland - SRL <@WPAFB-AAMRL.ARPA:NIELAND@FALCON> Subject: Breaking up LaTeX Tables Is there anyway to force a tabular environment in LaTeX to break up it's listing? I have a document where I have some long tables (over a page). LaTeX always wants to put the entire table on one page and, therefore, forces a new page before starting the table. I don't care about the table being broken over pages, just that the spacings between columns being the same. Any ideas on how to do this? M. Edward (Ted) Nieland - Systems Analyst | US Snail: | Arpa Internet: | Systems Research Laboratories, Inc. | TNIELAND@WPAFB-AAMRL.ARPA | 2800 Indian Ripple Road WP 196 | NIELAND%FALCON@WPAFB-AAMRL.ARPA | Dayton, OH 45440 | | A T & T: (513) 255-5156 ------------------------------ Date: Fri 25 Dec 87 10:29:33 From: Hideki Isozaki Subject: Japanese LaTeX, SliTeX and page parity problem (1) I made Japanese version of LaTeX and SliTeX based on Yaski's JTeX. Several style files for JLaTeX are available. You cannot use colors in this version of JSliTeX because there is no room left for invisible kanji fonts. Does anyone have a good idea (and the will) to implement SliTeX without invisible fonts? Japanese characters for JTeX have constant pitch. (2) By the way, we are using IMAGEN with duplexing function. As \maketitle of book.sty generates only one page, the first page exept the title page is even side. Hence, page styles for odd side and even side are applied improperly. Moreover, if the total number of pages is odd, a blank page appears before the real front page. I replaced some occurences of \clearpage by \cleardoublepage in JLaTeX. How did you solve this page parity problem? Hideki ISOZAKI NTT Software Laboratories JUNET isozaki@ntt-20.ntt.junet CSNET isozaki@ntt-20.ntt.jp ARPA isozaki%ntt-20@sumex-aim.stanford.edu ------------------------------ Date: Fri, 25 Dec 87 12:56:06 PST Subject: Font questions (TeXhax Digest V87 #104) 1. mode_def --- both jcb's and MartinRR's question center on the proper use of mode_defs. A mode-def cannot be made up until the physical characteristics of the output device are studied. The model of computer is not relevant to a mode_def except when screen fonts are being considered. jcb's problem is that the mode-def is not properly specified, and METAFONT will always default to the proof mode resolution of 2602gf when that happens. Study what is done in WAITS.MF, or if you want an experimental environment, see the description of 'smode' on P. 269 of the METAFONTbook. (Page 270-271 explains mode_def strategy, and note the line on p.269 if unknown mode: mode=proof; fi which explains unexpected occurrences of 2602gf. Ajit Ranade is overconfident about Nagari-derived fonts, I doubt there are any complete ones at all This is as good a place as any to air a suggestion. I am often asked for the mode_def settings of old fonts, and it is not always possible to recover them. Donald Knuth has up till now not included any specials in genuine CM fonts, but what about special strings recording the value that was used for blacker, fillin and o_corr, along with a string to show what resolution was used. Shall we ask whether these might legitimately be added to normal CM fonts? It would require only minor modifications of the mode_def file, and no change in GF format. (What would it do to existing dvi interpreters?) Pierre A. MacKay TUG Site Coordinator for Unix-flavored TeX ------------------------------ Date: Fri, 25 Dec 87 13:48:10 PST From: mackay@june.cs.washington.edu (Pierre MacKay) Subject: TeXhax Digest V87 #105 AM fonts were the result of font-designers' advice (pareticularly Herman Zapf's) about font design as applied to the original Computer Modern developed with old METAFONT-in-SAIL. They were much closer to the original flavor of Modern than their predecessors but, as good as old Metafont was, it did not have the sophistication about edge control that new Metafont has. The basic problem was that old METAFONT took the metaphor of a pen-stroke across white paper too seriously (it is still a great idea, especially for things like Arabic and Tamil) and paid too little attention to the fact that Latin-letter fonts are based on graver's techniques, rather than on calligrapher's techniques. To get the real character of a Modern (Most serifed book fonts nowadays are derived from Modern proportions) needed the attention to edges that new METAFONT gives. THe new Computer Modern is very faithful to its model in the Roman and Italic styles (there is a basic oxymoron in even the idea of a san-serif Modern). Look at the quotes (which are for the most part rather comically deprecatory) at the beginning of Computers and Typesetting, volume E, and you will get the essence of a good Modern. The quick overview of Bodoni's work in the ITC journal, U&lc (latest issue) shows Moderns at their most unreadable extreme. CM fonts are true Modern, AM was a very good approximation. (You might also look at Daniel Updike's Printing Types, available from Dover Books.) Pierre A. MacKay TUG Site Coordinator for Unix-flavored TeX ------------------------------ Date: Sat, 26 Dec 87 13:47:58 EST From: Lou Salkind Subject: DVIDMD, a previewer for DMD 5620 terminals I have written a DVI previewer for the DMD 5620 terminal that runs under System V and BSD UNIX. The previewer consists of two parts: a master program that runs on the host, a slave program that is downloaded to the terminal. The host code is adapted from Chris Torek's ctex package. Typically 118 DPI fonts are downloaded to the terminal program, although other resolutions may also be used (which will provide a correspondingly magnified image on the terminal). Other features: 1) PXL, PK, and GF format fonts are supported. 2) TPIC output is also supported. 3) Both the window (MPX) and standalone modes of the DMD terminal are supported. You may obtain the driver via anonymous ftp to NYU.EDU. The file to get is pub/dmd.tar.Z, a compressed tar file. Please drop me a note if you intend to use the driver. I also officially donate this driver to the UNIX TeX distribution. Lou ------------------------------ From: lamport@src.dec.com (Leslie Lamport) Date: 26 Dec 1987 1708-PST (Saturday) Subject: LaTeX Notes (Re: TeXhax Digest V87 #104) Rick McGeer writes: File (a) blows up into an infinite loop. File (b), which is file (a) less one line (there is a second \newtheorem in file (a)) works fine. The files are included here, (a) first. file (a): -------------------------------------------------------------------------- \newtheorem{theorem}{Theorem}[section] \newtheorem{corollary}{Corollary}[section] \documentstyle[11pt]{article} I don't have a copy of the LaTeX manual handy, but somewhere (I think in Chapter 2) it says that the input file should begin with a \documentstyle command. This file doesn't. To understand why one should not expect this input to work, consider what would happen if you replaced `article' with `letter'. Leslie Lamport ------------------------------ %%% %%% subscriptions, address changes to: texhax-request@score.stanford.edu %%% please send a valid arpanet address!! %%% %%% submissions to: texhax@score.stanford.edu %%% %%% BITNET redistribution: TEX-L@MARIST.BITNET (list server) %%% %%%\bye %%% ------------------------------ End of TeXhax Digest ************************** -------