Bug 388894 - Parse markdown in the changelog frame in UpdatesPage.qml
Summary: Parse markdown in the changelog frame in UpdatesPage.qml
Status: RESOLVED FIXED
Alias: None
Product: Discover
Classification: Applications
Component: PackageKit (other bugs)
Version First Reported In: unspecified
Platform: Other Linux
: NOR wishlist
Target Milestone: ---
Assignee: Aleix Pol
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-01-13 04:37 UTC by Nate Graham
Modified: 2018-10-31 14:02 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nate Graham 2018-01-13 04:37:18 UTC
The PackageKit folks deliberately provide the information in the updateText and updates fields in Markdown format. See https://github.com/hughsie/PackageKit/issues/227#issuecomment-350809040

The label that displays this information on UpdatesPage.qml already uses textFormat: Text.StyledText (line 21)), but that only parses HTML, not markdown, and the QQC2 label doesn't seem to support Markdown, unfortunately: https://doc.qt.io/qt-5/qml-qtquick-text.html#textFormat-prop

But maybe there's something we can do anyway? It would be a shame otherwise, since markdown formatting rendered in plaintext looks kind of ugly.
Comment 1 Aleix Pol 2018-01-16 16:40:12 UTC
This will have to wait until 5.13 as it needs us to add a dependency. At the moment okular uses DISCOUNT:
https://github.com/Orc/discount
Comment 2 Aleix Pol 2018-10-31 14:02:34 UTC
Git commit 76c4d24e508a10ab88c1cac5bc4fb44aa62a82fb by Aleix Pol.
Committed on 31/10/2018 at 13:59.
Pushed by apol into branch 'master'.

PK: Decode update information coded as markdown

M  +1    -0    CMakeLists.txt
M  +5    -1    libdiscover/backends/PackageKitBackend/CMakeLists.txt
M  +26   -1    libdiscover/backends/PackageKitBackend/PackageKitResource.cpp

https://commits.kde.org/discover/76c4d24e508a10ab88c1cac5bc4fb44aa62a82fb