[webkit-dev] SVG Fonts in webkit

Nikolas Zimmermann zimmermann at physik.rwth-aachen.de
Wed May 25 02:27:13 PDT 2011


Am 25.05.2011 um 00:42 schrieb Saba Taseer:

> It executes the code in the following #if ENable but the if statement returns false. Thus I presume that SVG_FONTS is enabled. It is instead going to drawSimpleText. 
> #if ENABLE(SVG_FONTS)
>     if (primaryFont()->isSVGFont()) {
>         drawTextUsingSVGFont(context, run, point, from, to);
>         return;
>     }
> #endif
> 
>     if (codePath(run) != Complex)
>         return drawSimpleText(context, run, point, from, to);
> I am running a simple svg script 
> <?xml version="1.0" standalone="yes"?> 
> <svg width="400px" height="300px" version="1.1"  xmlns = 'http://www.w3.org/2000/svg'>   
> 	<text x="100" y="100"  style="font-family: impact, georgia, times, serif;   font-weight: normal; font-style: normal"> 	
> 	    Text using web safe font
> 	</text>
> </svg>

You're not using SVG Fonts at all, you're using "impact, georgia..." which are native platform fonts.
Google for existing examples using SVG Fonts :-)

Cheers,
Niko

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-dev/attachments/20110525/bc2e9ccb/attachment.html>


More information about the webkit-dev mailing list