okular/generators
bob sayshilol 0bc8c76c3c Fix strikethrough rendering in markdown converter
Previously the `<del>` tag that Discount emits would be removed by Qt
since it's not in the subset of HTML that it understands. It does know
about `<s>` though, so replace `<del>` with `<s>` to render strikethroughs
correctly.

Note that I couldn't get Okular to build locally (PEBCAK issue) so I split out this file to debug it. I've tested against http://daringfireball.net/projects/downloads/MarkdownTest_1.0.zip and ff866f73d4/tests/data and the only difference is that trailing whitespace is now trimmed from the end of a line:
```diff
8c8
< <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Dashes:</p>
---
> <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Dashes: </p>
```
A quick search suggests this isn't a problem though https://stackoverflow.com/a/27026403:
> Within block tags (i.e. `<p>`, `<h1>`, `<div>`, ...) spaces as well as line breaks at the beginning or end of the tags should always be ignored (i.e. `<p>test</p>` should look the same as `<p> test </p>`).

I also tried https://doc.qt.io/qt-5/qtextdocument.html#setMarkdown which solves the strikethrough problem, though there are many visible differences with that approach. Most notably, everything is squashed together and code blocks lose their formatting.
2024-04-22 17:00:02 +00:00
..
comicbook A collection of cppcheck fixes 2024-04-15 19:59:42 +02:00
djvu djvu: Remove support for old djvu library version 2024-04-17 01:42:11 +02:00
dvi GIT_SILENT Update Appstream for new release 2024-04-08 18:04:20 +02:00
epub GIT_SILENT Update Appstream for new release 2024-04-08 18:04:20 +02:00
fax GIT_SILENT Update Appstream for new release 2024-04-08 18:04:20 +02:00
fictionbook A collection of cppcheck fixes 2024-04-15 19:59:42 +02:00
kimgio GIT_SILENT Update Appstream for new release 2024-04-08 18:04:20 +02:00
markdown Fix strikethrough rendering in markdown converter 2024-04-22 17:00:02 +00:00
mobipocket GIT_SILENT Update Appstream for new release 2024-04-08 18:04:20 +02:00
poppler Load certificates delayed 2024-04-20 13:44:54 +00:00
spectre GIT_SILENT Update Appstream for new release 2024-04-08 18:04:20 +02:00
tiff A collection of cppcheck fixes 2024-04-15 19:59:42 +02:00
txt GIT_SILENT Update Appstream for new release 2024-04-08 18:04:20 +02:00
xps Various minor fixes 2024-04-16 15:44:19 +02:00
CMakeLists.txt Remove CHM generator; disabled for 4 months 2024-04-20 15:58:58 +00:00