Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!samsung!spool.mu.edu!munnari.oz.au!murtoa.cs.mu.oz.au!csv.viccol.edu.au!dougcc From: dougcc@csv.viccol.edu.au (Douglas Miller) Newsgroups: comp.text.tex Subject: Re: LaTeX: widow lines Message-ID: <1991Mar18.194506.6616@csv.viccol.edu.au> Date: 19 Mar 91 00:45:06 GMT References: <2302@borg.cs.unc.edu> <1991Mar14.212743.20145@csrd.uiuc.edu> <2312@borg.cs.unc.edu> Organization: Computer Services, Victoria College, Melbourne Lines: 42 In article <2312@borg.cs.unc.edu>, alexande@snuffy.cs.unc.edu (Geoffrey D. Alexander) writes: > In article <1991Mar14.212743.20145@csrd.uiuc.edu> eijkhout@s41.csrd.uiuc.edu (Victor Eijkhout) writes: > |alexande@grover.cs.unc.edu (Geoffrey D. Alexander) writes: > | > ||Is there a general way to avoid widow lines in LaTeX? In particular, I would > ||like to avoid a single line followed by display math at the top of a page. > ||Also, having the display math at the top the page is not vaiable soltion; I > ||would rather have two lines of text followed by the display math. > | > |Hm. This question once again shows that Lamport doesn't > |treat the TeX primitives in his book sufficiently. > |Comment in general for LaTeX users: > |buy the TeX book too, for more info on math and such. > | > |The above question can be answered as follows: > |the parameters \widowpenalty and \displaywidowpenalty > |control exactly the two phenomena described. > |Currently they are 150 and 50 respectively, > |try setting them to 1000 or so. If you set them > |to 10000 TeX will absolutely never break in these > |places, which may be a bit too rigorous. > | > |Victor. > > I was aware of these commands. The questions is can I use them in LaTeX? > If so, where and how do I specify them? Q1: Yes --- LaTeX is really just TeX after all :-) Q3: Like this: \widowpenalty=1000 Q2: Anywhere you like. Actually, in keeping with the Hosek/Miller principle of structuralism I would recommend putting them in a style file, e.g., you could make a style file called MYARTICLE.STY as follows: \input article.sty \widowpenalty=1000 \displaywidowpenalty=1000 and then start your document with \documentstyle{myarticle}