mirror of
https://github.com/M66B/FairEmail.git
synced 2026-04-06 00:53:26 +02:00
Added font/pre for external texts
This commit is contained in:
@@ -2099,7 +2099,9 @@ public class HtmlHelper {
|
||||
ssb.setSpan(new StyleSpan(Typeface.ITALIC), start, ssb.length(), Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||
break;
|
||||
case "font":
|
||||
// Do nothing
|
||||
String face = element.attr("face");
|
||||
if (!TextUtils.isEmpty(face))
|
||||
ssb.setSpan(new TypefaceSpan(face), start, ssb.length(), Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||
break;
|
||||
case "h1":
|
||||
case "h2":
|
||||
@@ -2193,6 +2195,9 @@ public class HtmlHelper {
|
||||
if (llevel > 0)
|
||||
ssb.setSpan(new LeadingMarginSpan.Standard(llevel * dp24), start, ssb.length(), Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||
break;
|
||||
case "pre":
|
||||
ssb.setSpan(new TypefaceSpan("monospace"), start, ssb.length(), Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||
break;
|
||||
case "small":
|
||||
ssb.setSpan(new RelativeSizeSpan(FONT_SMALL), start, ssb.length(), Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user