D7382: add markdown support

Albert Astals Cid noreply at phabricator.kde.org
Fri Aug 18 21:00:00 UTC 2017


aacid added a comment.


  Interesting work :)
  
  Some inline comments

INLINE COMMENTS

> FindDiscount.cmake:22
> +
> +  find_library (discount_LIBRARIES
> +    NAMES markdown libmarkdown

So the library is called discount but installs itself as libmarkdown?

Doesn't it have a pkg-config file?

> converter.cpp:41
> +{
> +    FILE *markdownFile = fopen( fileName.toStdString().c_str(), "rb" );
> +    mDir = QDir( fileName.left( fileName.lastIndexOf( '/' ) ) );

You probably want toLocal8Bit here

> converter.cpp:56
> +    FILE *tmpFile = fopen( tmpFileName.toStdString().c_str(), "w+" );
> +    markdown( markdownHandle, tmpFile, MKD_FENCEDCODE | MKD_GITHUBTAGS | MKD_AUTOLINK );
> +    fclose( tmpFile );

Have you tried mkd_document so we don't need a temp file?

> hi32-app-okular-md.svg:1
> +<?xml version="1.0" encoding="utf-8"?>
> +<svg xmlns="http://www.w3.org/2000/svg" version="1.1" width="208" height="128" viewBox="0 0 208 128">

Did you draw this SVG?

> okularMd.desktop:10
> +Name[ca at valencia]=Okular
> +Name[cs]=Okular
> +Name[da]=Okular

You need to drop all translations from these and the rest of the files.

REPOSITORY
  R223 Okular

REVISION DETAIL
  https://phabricator.kde.org/D7382

To: progwolff, #okular
Cc: aacid
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/okular-devel/attachments/20170818/9db0aadf/attachment.html>


More information about the Okular-devel mailing list