RK> In FreeType font rasterizer the sign of the XLFD property
RK> UNDERLINE_POSITION has changed between 4.2.1 and 4.3.0.  Because of
RK> this, Type1 and TrueType fonts now have UNDERLINE_POSITION negative,
RK> which makes gtk1 builds of mozilla loose underlining.

Yep, this is right.  UNDERLINE_POSITION counts downwards, which is not
stated explicitly by the XLFD, but clearly implied by the formula in
3.2.30:

  UNDERLINE_POSITION = ROUND(maximum_descent / 2)

David, please apply and attribute to Roman Kagan.

                                        Juliusz

--- xc/lib/font/FreeType/ftfuncs.c~     2003-02-13 06:01:45.000000000 +0300
+++ xc/lib/font/FreeType/ftfuncs.c      2003-03-04 20:27:16.000000000 +0300
@@ -959,11 +959,11 @@
         int underlinePosition, underlineThickness;
 
         if(post) {
-            underlinePosition = TRANSFORM_FUNITS_Y(post->underlinePosition);
+            underlinePosition = TRANSFORM_FUNITS_Y(-post->underlinePosition);
             underlineThickness = TRANSFORM_FUNITS_Y(post->underlineThickness);
         } else {
             underlinePosition = 
-                TRANSFORM_FUNITS_Y(t1info->underline_position);
+                TRANSFORM_FUNITS_Y(-t1info->underline_position);
             underlineThickness = 
                 TRANSFORM_FUNITS_Y(t1info->underline_thickness);
         }
_______________________________________________
Fonts mailing list
[EMAIL PROTECTED]
http://XFree86.Org/mailman/listinfo/fonts

Reply via email to