Bug 388894

Summary: Parse markdown in the changelog frame in UpdatesPage.qml
Product: [Applications] Discover Reporter: Nate Graham <nate>
Component: PackageKitAssignee: Aleix Pol <aleixpol>
Status: RESOLVED FIXED    
Severity: wishlist    
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

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