From 19bd88c91a186b621fe145c372cd2b7d70b6af16 Mon Sep 17 00:00:00 2001 From: M66B Date: Tue, 5 Jan 2021 14:08:39 +0100 Subject: [PATCH] Fixed rem font sizes --- app/src/main/java/eu/faircode/email/HtmlHelper.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/eu/faircode/email/HtmlHelper.java b/app/src/main/java/eu/faircode/email/HtmlHelper.java index 5f7cfa8657..512f4e428c 100644 --- a/app/src/main/java/eu/faircode/email/HtmlHelper.java +++ b/app/src/main/java/eu/faircode/email/HtmlHelper.java @@ -1364,10 +1364,10 @@ public class HtmlHelper { try { if (value.endsWith("%")) return Float.parseFloat(value.substring(0, value.length() - 1).trim()) / 100 * current; - if (value.endsWith("em")) - return Float.parseFloat(value.substring(0, value.length() - 2).trim()) * current; if (value.endsWith("rem")) return Float.parseFloat(value.substring(0, value.length() - 3).trim()); + if (value.endsWith("em")) + return Float.parseFloat(value.substring(0, value.length() - 2).trim()) * current; if (value.endsWith("pt")) return Float.parseFloat(value.substring(0, value.length() - 2).trim()) / DEFAULT_FONT_SIZE_PT; if (value.endsWith("px"))