View Single Post
Posts: 16 | Thanked: 23 times | Joined on Jan 2016
#2539
@Markkyboy

I do prefer to increase the font size for text mail:

/usr/share/jolla-email/pages/PlainTextViewer.qml

from:
Code:
font.pixelSize: Screen.sizeCategory >= Screen.Large ? Theme.fontSizeSmall : Theme.fontSizeExtraSmall
to:
Code:
font.pixelSize: Screen.sizeCategory >= Screen.Large ? Theme.fontSizeMedium : Theme.fontSizeSmall



Some time before, there was one option more in silica webview to change:

/usr/lib/qt5/qml/Sailfish/Silica/SilicaWebView.qml

from:
Code:
color: webView.experimental.transparentBackground ? "transparent" : "white"
to:
Code:
color: webView.experimental.transparentBackground ? "transparent" : "transparent"
but since last update it may not necessary anymore.


I will try you're css file, because mine is very different. I'm exited. Thanks a lot for doing this job done!



I made also some changes on the htmlViewer component, because some emails got rendered totally unreadable, therefore I did the following changes:

/usr/share/jolla-email/pages/HtmlViewer.qml

from:
Code:
 // Respect viewport meta tag if exists
        if (!hasViewportMetaTag(htmlBody)) {
            // This affects only to layouts that do not have width defined in body content.
            // Smaller content layout gets scaled up to WebView's width. Basically meaning that
            // html text emails will get scaled up by factor (1.5*Theme.pixelRatio) rounded to nearest half.
            // With higher scale factor content layouts starts touching edges of WebView and that hinders
            // legibility. Thus, this 1.5 base factor.
            var scale = Math.round((1.5 * Theme.pixelRatio) / .5) * .5
            experimental.customLayoutWidth = width / scale
        } else {
            experimental.customLayoutWidth = width
        }
        // reload html
        loadHtml(htmlBody, "file:///usr/share/jolla-email")
    }

to:

Code:
// Respect viewport meta tag if exists
       //if (!hasViewportMetaTag(htmlBody)) {
            // This affects only to layouts that do not have width defined in body content.
            // Smaller content layout gets scaled up to WebView's width. Basically meaning that
            // html text emails will get scaled up by factor (1.5*Theme.pixelRatio) rounded to nearest half.
            // With higher scale factor content layouts starts touching edges of WebView and that hinders
            // legibility. Thus, this 1.5 base factor.
            //var scale = Math.round((1.5 * Theme.pixelRatio) / .5) * .5
            //experimental.customLayoutWidth = webView.width / scale
        //} else {
            experimental.customLayoutWidth = 350
        //}
        // reload html
        //loadHtml(htmlBody, "file:///usr/share/jolla-email")
        webView.loadHtml(htmlBody, "file:///usr/share/jolla-email")
        onScreen = true
    }

Last edited by kneeli; 2018-07-09 at 15:43. Reason: small changes
 

The Following User Says Thank You to kneeli For This Useful Post: