Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 6/24/83; site entropy.UUCP Path: utzoo!watmath!clyde!burl!ulysses!mhuxj!mhuxn!houxm!vax135!cornell!uw-beaver!uw-june!entropy!hubert From: hubert@entropy.UUCP (Steve Hubert) Newsgroups: net.text Subject: Re: Ditroff troubles Message-ID: <92@entropy.UUCP> Date: Thu, 6-Dec-84 17:37:55 EST Article-I.D.: entropy.92 Posted: Thu Dec 6 17:37:55 1984 Date-Received: Fri, 7-Dec-84 06:05:51 EST References: <334@ut-sally.UUCP> Organization: UW MathStat, Seattle Lines: 57 > > The main problem seems trivial but for certain applications simply can't be > > ignored: ditroff screws up square roots (as produced using the preprocessor > > deqn). Specifically, the horizontal bar which should appear over the > > expression to be sqrted is too low and is dashed rather than solid. It > > appears that the "root extender" character \(rn is somehow at fault. I've > > used rst2ch to browse around in the likely raster files, but I can't even > > find the \(rn character to check it. Any ideas where \(rn should be or how > > I could fix the problem? > > Apparently I'm not alone in having trouble with ditroff. Steve Hubert > (...ihnp4!uw-beaver!entropy!hubert) reports a similar problem, but with one > intriguing difference: his square roots are fine but the horizontal lines in > fractions (produced by deqn "over") are dashed! Does this suggest anything > to anyone? > > --- Prentiss Riddle ("Aprendiz de todo, maestro de nada.") > --- {ihnp4,harvard,seismo,gatech,ctvax}!ut-sally!riddle I have solved my deqn problem by changing deqn so it uses the new line drawing capabilities to draw the ``over'' line rather than the old \l line drawer. Here is a diff on eqn/over.c. 17a18,21 > /* > * Change over to use the new line drawing command instead > * of the old series of underrules. Hubert, 5 Dec 84 > */ 22c26 < printf("\\h'-\\n(%du-\\n(%du/2u+.1m'\\v'%du'\\l'\\n(%du-.2m'\\h'.1m'\\v'%du'\n", --- > printf("\\h'-\\n(%du-\\n(%du/2u+.1m'\\v'%du-.1m'\\D't.005i'\\D'l\\n(%du-.2m 0u'\\D't.015i'\\h'.1m'\\v'%du+.1m'\n", Perhaps the line drawer could be used to draw the root extender, too. What changed is \l is replaced by \D l. There are a couple other nasty things. The default linewidth for \D on the Versatec is .015i. That is too wide for ``over''. So I change the linewidth to .005i, draw the line, then change it to .015i. That means the linewidth is set to .015i after an over regardless of what it was before. I couldn't think of any way to find out what the width was on entry to the over() routine. I also made the vertical movement right before the line go down 1/10th em less than before, and 1/10th em more after the line. That is so the line lined up where it was supposed to go. Another side effect that just occurred to me is that there is no way to get a bold over with this change. Two questions: Is there any way to determine the linewidth so I can save it and restore it after drawing the line? Is there any way to determine whether the over line is supposed to be bold? Hmmm, maybe I ought to just fix the rule character in my fonts instead :-). Steve Hubert Dept. of Stat., U. of Wash, Seattle {allegra,decvax,ihnp4,ucbvax!lbl-csam}!uw-beaver!entropy!hubert hubert%entropy@uw-beaver