RE: two thoughts on lengthAdjust="" modes

The text length adjustment should be honored in either case. The author is specifying a specific thing, and that thing may well matter.

For technical diagrams, such as, say a wiring diagram, we have cases where a label is placed on a wire, and the label needs to be evenly spaced in the gap drawn in the wire:

------------   W1234-567   --------

It is important that the extent of that text "W1234-567" is exactly what it should be so the beginning and end of the text  are where the author intended them to be, regardless of what font the rendering system chooses.  If the font would end up less than the textLength attribute, the text would have to be stretched, otherwise we end up with this, where the gap on the end of the text is too large.

-----------    W1234-567      ----------


In our technical documents, we are using the font size to scale things up-and-down, perpendicular to the text baseline vector, and textLength should scale things left-to-right along the text baseline axis.

So the textLength and font size effects should work the same way if the text is oriented where the baseline isn't 0 degrees (horizontal).  It may be 90 deg (vertical text) where textLength is effectively in the y dimension of the page, but the text may be at a 45 deg angle.


Thomas


-----Original Message-----
From: Cameron McCormack [mailto:cam@mcc.id.au] 
Sent: Monday, July 08, 2013 9:15 PM
To: www-svg@w3.org
Subject: two thoughts on lengthAdjust="" modes

I had two thoughts on text length adjustment while working on Firefox's implementation.

The first is that it might be worth having the ability to scale the text in both dimensions rather than just horizontally (for horizontal text). 
  That could help make the text look nicer when it is shrunk to fit a given length.

The second is being able to say that the adjustment should only be performed when the actual text length is greater than the author's specified length.  If the text is shorter, in many cases I think the author would prefer to have the text shown as is, rather than expanded out to fit textLength="".

Received on Thursday, 11 July 2013 21:59:59 UTC