And why not adjust the spacing within the user specified min/max for START and END alignment?
[Luca]
Should the user desire adjusted spaces, wouldn't it be better for him to specify justified alignment? :-) Seriously, the recommendation (at 7.16.2 "letter-spacing" and 7.16.8 "word-spacing") states that these spaces "may also be influenced by justification", but says nothing about start and end alignments.
I tend to read that to mean that word spacing may be pushed beyond the specified range by justification. And I would think that unjustified alignment still has the option of using the word-spacing range but ofcourse has to stay within the range.
I'm still not sure why it would be ok to ignore any user specified min and max values of 'word-spacing' during START and END alignment. If a user specifies a length range, what would the reason be for not using it? Perhaps with additional DEFAULT_SPACE_WIDTH.
When alignment is start or end, each space has always its .optimum width, so there is no need to look at the .minimum and .maximum: the user most preferred value is already used.
Is there anything that prevents using a non .optimum value within the range if the result is judged to be better (with a lower demerit).
Ok, performance is indeed a fine reason, but IMHO such quality vs. speed tradeoffs should eventually be made by the user rather than us.
Simon told the same:
# Note that in TeX such thresholds are user-adjustable parameters. I # think they should eventually be so in FOP too, for those of us who # have the most exquisite taste of line layout.
and I think it's a good idea; the algorithm should:
1 find breaking points without hyphenation 2 hyphenate 3 find breaking points with hyphenation 4 decide which ones are "better"
and point #4 uses the user-definable threshold; where should this constant be stored? Inside the code of LineLM or in a configuration file?
An extension attribute?
<fo:block fox:knuth-threshold="5"> ... </fo:block>
I suspect that the other knuth parameters should be specified the same way. But it is not a high priority IMO.
regards, finn