1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2024-12-26 17:57:16 +00:00

Font size for headers

This commit is contained in:
M66B 2024-02-20 12:02:44 +01:00
parent 1eac366590
commit 7250ce175a

View file

@ -3730,8 +3730,14 @@ public class HtmlHelper {
case "h4":
case "h5":
case "h6":
// Font size is already set
setSpan(ssb, new StyleSpan(Typeface.BOLD), start, ssb.length());
int hsize = tag.charAt(1) - '0';
if (hsize == 1)
setSpan(ssb, new RelativeSizeSpan(FONT_XLARGE), start, ssb.length());
else if (hsize == 2)
setSpan(ssb, new RelativeSizeSpan(FONT_LARGE), start, ssb.length());
else if (hsize > 3)
setSpan(ssb, new RelativeSizeSpan(FONT_SMALL), start, ssb.length());
break;
case "hr":
// Suppress successive lines