[PATCH] improved text-decoration

Leo Savernik l.savernik at aon.at
Mon Dec 15 15:04:47 GMT 2003


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Am Sonntag, 14. Dezember 2003 14:01 schrieb Luciano Montanaro:
> The attached patch modifies the Font::drawDecoration() function
> to use font metrics data to calculate the thickness and the position of the
> underline etc.
>
> Luciano

When I outsourced the decoration drawing, I thought about taking care of the 
thickness, too. I didn't do it because I fear that fillRect is much slower 
than drawLine (Is there any X11 expert to confirm or disprove this 
statement?)

Given that most decorations are only 1px thick, they should be always drawn 
the fastest way possible.

I'm sure the original author had some reason not to use the fm.xxxPos() 
functions, probably to be able to comply better with CSS.

Btw, if you change the decoration drawings here, you must also change them in 
InlineFlowBox::paintDecorations (in render_line.cpp), as this is the standard 
mode implementation.

mfg
	Leo
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE/3c2Uj5jssenUYTsRAkUSAKCpxsO2pHW5DgMLslzdeyzTf8mRMACfY3gZ
aTPUv3mGTBE5HoT72d9cpUo=
=9Go9
-----END PGP SIGNATURE-----





More information about the kfm-devel mailing list