working build of new podofo pdf system
This commit is contained in:
parent
02f2d70ad3
commit
6a8266f1f1
4 changed files with 27 additions and 1 deletions
|
@ -32,7 +32,24 @@ find_package(KF5 ${KF_MIN_VERSION} REQUIRED COMPONENTS Kirigami2 I18n CoreAddons
|
|||
find_package(Libmpv)
|
||||
set_package_properties(Libmpv PROPERTIES TYPE REQUIRED)
|
||||
|
||||
find_package(PoDoFo)
|
||||
FIND_PACKAGE(LIBPODOFO)
|
||||
IF(NOT LIBPODOFO_FOUND)
|
||||
MESSAGE("+++PoDoFo not found... building private copy")
|
||||
SET(PODOFO_BUILD_STATIC 1)
|
||||
SET(PODOFO_BUILD_SHARED 0)
|
||||
SET(PODOFO_BUILD_LIB_ONLY 1)
|
||||
ADD_SUBDIRECTORY(externals/required_libpodofo)
|
||||
SET(LIBPODOFO_H ${CMAKE_CURRENT_SOURCE_DIR}/externals/required_libpodofo)
|
||||
SET(LIBPODOFO_CONFIG_H ${CMAKE_CURRENT_BINARY_DIR}/externals/required_libpodofo)
|
||||
SET(LIBPODOFO_LIB podofo_static)
|
||||
MESSAGE("+++Done setting up private PoDoFo copy")
|
||||
ENDIF(NOT LIBPODOFO_FOUND)
|
||||
|
||||
|
||||
INCLUDE_DIRECTORIES(
|
||||
${LIBPODOFO_H}
|
||||
${LIBPODOFO_CONFIG_H}
|
||||
)
|
||||
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||
|
|
|
@ -24,6 +24,7 @@ target_link_libraries(presenter
|
|||
Qt5::X11Extras
|
||||
KF5::Kirigami2
|
||||
KF5::I18n
|
||||
podofo
|
||||
mpv
|
||||
)
|
||||
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
#include <podofo/podofo.h>
|
||||
#include <QDebug>
|
||||
|
||||
using namespace PoDoFo;
|
||||
Slide::Slide(QObject *parent)
|
||||
: QObject{parent}
|
||||
{
|
||||
|
@ -197,6 +198,13 @@ void Slide::changeSlide(QVariantMap item)
|
|||
setImageBackground("");
|
||||
}
|
||||
|
||||
if (type() == "pres") {
|
||||
qDebug() << "#$#$#$#$ THIS PDF $#$#$#$#";
|
||||
PdfMemDocument pdf = PdfMemDocument();
|
||||
// const char doc = imageBackground();
|
||||
// pdf.Load(doc);
|
||||
}
|
||||
|
||||
QStringList text = m_serviceItem.value("text").toStringList();
|
||||
if (text.isEmpty()) {
|
||||
setText("");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue