Patch for text-overflow:ellipsis
Leo Savernik
l.savernik at aon.at
Mon Nov 13 17:56:25 GMT 2006
Am Montag, 13. November 2006 00:08 schrieb Allan Sandfeld Jensen:
> On Sunday 12 November 2006 23:50, Leo Savernik wrote:
> > Well, offsetForPoint is optimised for vertical caret navigation, so by
> > about 50% it returns the next character. Subtracting one offset will at
> > least ensure that characters never spill into the ellipsis.
>
> Ah. Maybe I should use the selection functions instead then.
Selection... This reminds me of Simon Hausmann's patch introducing clipping
for ligature-rich scripts (arabic, hebrew etc.) which must be clipped instead
of repainted. OTOH ellipsis doesn't support ligature-rich scripts anyways,
does it?
>
> > Btw, have you tested ellipsis with caret navigation? It needn't work
> > flawlessly, but it shouldn't crash either.
>
> Yes, it doesn't crash. Though it seems carets can navigate the hidden part
> of the text and even select it. This however is also true for normal
> overflow:hidden.
Not by design but cool ;-)
mfg
Leo
More information about the kfm-devel
mailing list