Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

[REBOL] Re: another piece for pdf-dialect

From: dness:home at: 30-Jul-2001 15:26

Gabriele Santilli wrote:
> Hello Robert! > > On 30-Lug-01, you wrote: > > RM> Hi, AFAIK does TeX use such a multi-box approach. Each > RM> character uses a defined 2D space, depending on the font > RM> settings. TeX sums all those boxes and knows the size of the > RM> page, therefore it should be possible to calculate a page > > AFAIK TeX tries not to break paragraphs, avoids putting section > titles or spaces at the end of the page, etc. Ita has a lot of > nice euristics to create the best layout. > > RM> break. Do you have access to Donald Knuth's book about TeX? > > I don't, unfortunately. I've not been able to find Knuth's books > in local book stores or libraries... > > RM> The basic algorithm isn't that hard I have heard. And let's > > Indeed, as I said, a QAD solution wouldn't be difficult to add. > > Regards, > Gabriele. > --
PMFJI but I have a developing interest in REBOL and considerable past expertise with TeX. I have missed the discussion up to this point, but I will go back and see if I can re-construct it and perhaps add something about `how' TeX does `whatever' you are interested in. In the meantime, I would be happy to hear (and try to answer) specific questions. To discuss a point raised in this particular communication, (I hope I have the context right), TeX does `paragraph breaking' through a rather elaborate set of `penalties' which are evaluated using a dynamic programming algorithm. This allows the TeX writer to describe his/her `feelings' about the things in typesetting that are `not nice'. For example, a `title' line as the last line of a page is _very_ `not nice'. Similarly, paragraph spacing may be quite `strechable' but if you make it either way too big or way too small, you have high penalties. I hope this is relevant to your conversation...