mirror of
https://github.com/M66B/FairEmail.git
synced 2024-12-27 18:27:43 +00:00
Added support for CSS font-style
This commit is contained in:
parent
53262f88cd
commit
7b285e8fa8
1 changed files with 10 additions and 0 deletions
|
@ -844,6 +844,12 @@ public class HtmlHelper {
|
||||||
sb.append(key).append(":").append(value).append(";");
|
sb.append(key).append(":").append(value).append(";");
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case "font-style":
|
||||||
|
// https://developer.mozilla.org/en-US/docs/Web/CSS/font-style
|
||||||
|
if (value.contains("italic") || value.contains("oblique"))
|
||||||
|
sb.append(key).append(":").append("italic").append(";");
|
||||||
|
break;
|
||||||
|
|
||||||
case "text-decoration":
|
case "text-decoration":
|
||||||
case "text-decoration-line":
|
case "text-decoration-line":
|
||||||
// https://developer.mozilla.org/en-US/docs/Web/CSS/text-decoration
|
// https://developer.mozilla.org/en-US/docs/Web/CSS/text-decoration
|
||||||
|
@ -3151,6 +3157,10 @@ public class HtmlHelper {
|
||||||
} else
|
} else
|
||||||
setSpan(ssb, StyleHelper.getTypefaceSpan(value, context), start, ssb.length());
|
setSpan(ssb, StyleHelper.getTypefaceSpan(value, context), start, ssb.length());
|
||||||
break;
|
break;
|
||||||
|
case "font-style":
|
||||||
|
if ("italic".equals(value))
|
||||||
|
setSpan(ssb, new StyleSpan(Typeface.ITALIC), start, ssb.length());
|
||||||
|
break;
|
||||||
case "text-decoration":
|
case "text-decoration":
|
||||||
if ("line-through".equals(value))
|
if ("line-through".equals(value))
|
||||||
setSpan(ssb, new StrikethroughSpan(), start, ssb.length());
|
setSpan(ssb, new StrikethroughSpan(), start, ssb.length());
|
||||||
|
|
Loading…
Reference in a new issue