Enabled stuff for proper mMetrics.subscriptOffset mMetrics.superscriptOffset calculation
authorromashin
Sat, 19 Apr 2008 18:39:59 +0300
changeset 16825 9f77bf854180533001c27c800644b147a4cd2c14
parent 16824 dfa6c7ddbab2008617506b687ddedc00f4598019
child 16826 0d2273d6e58fa7b909d5d21374371f97747a1a9b
push id1298
push userpavlov@mozilla.com
push dateSun, 17 Aug 2008 05:03:09 +0000
treeherderautoland@4a506fa751d8 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
milestone2.0a1pre
Enabled stuff for proper mMetrics.subscriptOffset mMetrics.superscriptOffset calculation
gfx/thebes/src/gfxQtFonts.cpp
--- a/gfx/thebes/src/gfxQtFonts.cpp
+++ b/gfx/thebes/src/gfxQtFonts.cpp
@@ -444,17 +444,17 @@ gfxQtFont::GetMetrics()
 
     mMetrics.emAscent = lineHeight > 0.0 ?
         mMetrics.maxAscent * mMetrics.emHeight / lineHeight : 0.0;
     mMetrics.emDescent = mMetrics.emHeight - mMetrics.emAscent;
 
     mMetrics.spaceWidth = fontMetrics.width( QChar(' ') );
     mMetrics.xHeight = fontMetrics.xHeight();
 
-#if 0
+#if 1
     FT_Face face = mQFont->freetypeFace();
     if (face) {
         mMetrics.maxAdvance = face->size->metrics.max_advance / 64.0; // 26.6
         float val;
         TT_OS2 *os2 = (TT_OS2 *) FT_Get_Sfnt_Table(face, ft_sfnt_os2);
         if (os2 && os2->ySuperscriptYOffset) {
             val = CONVERT_DESIGN_UNITS_TO_PIXELS(os2->ySuperscriptYOffset,
                                                  face->size->metrics.y_scale);