]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk1/dcclient.cpp
WinCE fixes.
[wxWidgets.git] / src / gtk1 / dcclient.cpp
index ef602b5ea8c753f1ed4844e213a66892be6f261c..707f88fbc56a7c2f884b22fb5d4815a8e085fb96 100644 (file)
@@ -1736,8 +1736,10 @@ void wxWindowDC::DoGetTextExtent(const wxString &string,
         *height = (wxCoord) h;
     if (descent)
     {
-        // Do something about metrics here. TODO.
-        *descent = 0;
+        PangoLayoutIter *iter = pango_layout_get_iter(m_layout);
+        int baseline = pango_layout_iter_get_baseline(iter);
+        pango_layout_iter_free(iter);
+        *descent = h - PANGO_PIXELS(baseline);
     }
     if (externalLeading)
         *externalLeading = 0;  // ??