"J.Pietschmann" <[EMAIL PROTECTED] Para: [EMAIL PROTECTED], e> [EMAIL PROTECTED] cc: 17/09/2002 17:36 Assunto: Re: Fix for paragraph breaking. Favor responder a fop-dev
[EMAIL PROTECTED] wrote: > I fixed a problem that FOP had with breaking loooooong words. If these > words were too long to fit on one line, and no hyphenation was selected, > the word would go beyond the right side of the page. Sorry, commit denied for a variety of reasons: 1. It is not clear whether the problem you attempt to fix is a problem at all. Actually, it can be argued FOPs behaviour is correct, annoying as it may be sometimes. This is the main showstopper. Although I concur that FOP should never break words while hyphenation is off, I sympathise with Mr. Baals. I had a similar problem with URLs, which can become quite long and do not fit in the hyphenation rules for any language. If they grow beyond the line width there is no way of getting it right without inserting spaces manually <yech/> . While using discretionary hyphens can solve the problem localy (I do not remember FOP taking them into account while hyphenating; it is most handy when a word has irregular hyphenation), it would be counterproductive. I suggest we write a special language hyphenation file for URLs -- it is not a natural language, but it is one nevertheless, with its own lexical rules. (Can someone provide me with a pointer to the pertinent spec?) Stylesheets like DocBook's can take advantage of this by specifying the new language code, something like x-url. This approach can also be used with programming languages or other similar stuff, and it has already been proven to work with languages that can produce very long words (Herr Pietschmann und die xml:lang='de' Leute soll mit mir einstimmig sein ;-). However, the hyphen would not be a good choice as the character to use in the breaking point: a better choice would be to use ellipses (...) in the preceeding AND in the following line. Can this be achieved? I can write such an hyphenation file if you people agree this is a sensible solution. ============================================= Marcelo Jaccoud Amaral Petrobrás (http://www.petrobras.com.br) mailto:[EMAIL PROTECTED] voice: +55 21 2534-3485 fax: +55 21 2534-1809 ============================================= If brute force doesn't work, maybe you're not using enough brute force. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]