From fca426c17c858c473df482d5a279d6e5e0d141dc Mon Sep 17 00:00:00 2001 From: poire-z Date: Fri, 18 Sep 2020 12:45:19 +0200 Subject: [PATCH] Footnote popups: CSS: add more styles for FB2 elements Add styles for some more non-HTML FB2 tags, so MuPDF can render them as expected. --- frontend/ui/widget/footnotewidget.lua | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/frontend/ui/widget/footnotewidget.lua b/frontend/ui/widget/footnotewidget.lua index 33d2fae09..29e8ed36d 100644 --- a/frontend/ui/widget/footnotewidget.lua +++ b/frontend/ui/widget/footnotewidget.lua @@ -91,9 +91,19 @@ body > li { list-style-type: none; } .noprint { display: none; } /* Style some FB2 tags not known to MuPDF */ -emphasis { font-style: italic; } -strikethrough { text-decoration: line-through; } -underline { text-decoration: underline; } +strike, strikethrough { text-decoration: line-through; } +underline { text-decoration: underline; } +emphasis { font-style: italic; } +small { font-size: 80%; } +big { font-size: 130%; } +empty-line { display: block; padding: 0.5em; } +image { display: block; padding: 0.4em; border: 0.1em solid black; width: 0; } +date { display: block; font-style: italic; } +epigraph { display: block; font-style: italic; } +poem { display: block; } +stanza { display: block; font-style: italic; } +v { display: block; text-align: left; hyphenate: none; } +text-author { display: block; font-weight: bold; font-style: italic; } /* Attempt to display FB2 footnotes as expected (as crengine does, putting * the footnote number on the same line as the first paragraph via its