[evolution/gnome-3-22] Bug 773494 - Composer doesn't respect dpi settings



commit 73ca4ed9571c3e156407b86a80464740b8dc4da8
Author: Tomas Popela <tpopela redhat com>
Date:   Wed Oct 26 08:09:24 2016 +0200

    Bug 773494 - Composer doesn't respect dpi settings
    
    Normalize the font size when setting the "default-monospace-font-size" and
    "minimum-font-size" properties of WebKitSettings (as we do for
    EWebView).

 modules/webkit-editor/e-webkit-editor.c |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/modules/webkit-editor/e-webkit-editor.c b/modules/webkit-editor/e-webkit-editor.c
index e231c4f..d72c8cb 100644
--- a/modules/webkit-editor/e-webkit-editor.c
+++ b/modules/webkit-editor/e-webkit-editor.c
@@ -1301,8 +1301,12 @@ webkit_editor_update_styles (EContentEditor *editor)
                pango_font_description_get_family (vw),
                "monospace-font-family",
                pango_font_description_get_family (ms),
-               "default-monospace-font-size", pango_font_description_get_size (ms) / PANGO_SCALE,
-               "minimum-font-size", pango_font_description_get_size (min_size) / PANGO_SCALE,
+               "default-monospace-font-size",
+               e_util_normalize_font_size (
+                       GTK_WIDGET (wk_editor), pango_font_description_get_size (ms) / PANGO_SCALE),
+               "minimum-font-size",
+               e_util_normalize_font_size (
+                       GTK_WIDGET (wk_editor), pango_font_description_get_size (min_size) / PANGO_SCALE),
                NULL);
 
        manager = webkit_web_view_get_user_content_manager (WEBKIT_WEB_VIEW (wk_editor));


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]