From 6c44ce86d2c280fd1027e669b27c55b6cb395da2 Mon Sep 17 00:00:00 2001 From: Rodrigo Torres Date: Sat, 10 Aug 2019 18:41:07 -0300 Subject: [PATCH 1/3] Update .travis.yml --- .travis.yml | 559 ++++++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 540 insertions(+), 19 deletions(-) diff --git a/.travis.yml b/.travis.yml index 39dedbc..f879261 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,27 +1,548 @@ -language: cpp +matrix: + include: + - env: Qt4.8.5_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: gcc + cache: ccache + addons: + apt: + packages: + - qt4-default + + script: + - qmake -r limereport.pro + - make + - make check -compiler: - - gcc + - env: Qt4.8.5_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: clang + cache: ccache + addons: + apt: + packages: + - qt4-default + + script: + - qmake -r limereport.pro + - make + - make check + + - env: Qt5.1.1_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: gcc + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt511-trusty' + packages: + - qt51base + - qt51script + - qt51tools + + script: + - source /opt/qt51/bin/qt51-env.sh + - /opt/qt51/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.1.1_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: clang + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt511-trusty' + packages: + - qt51base + - qt51script + - qt51tools + + script: + - source /opt/qt51/bin/qt51-env.sh + - /opt/qt51/bin/qmake -r limereport.pro + - make + - make check -sudo: required -dist: trusty + - env: Qt5.2.1_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: gcc + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt521-trusty' + packages: + - qt52base + - qt52script + - qt52tools + + script: + - source /opt/qt52/bin/qt52-env.sh + - /opt/qt52/bin/qmake -r limereport.pro + - make + - make check -env: - - QT_BASE=56 + - env: Qt5.2.1_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: clang + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt521-trusty' + packages: + - qt52base + - qt52script + - qt52tools + + script: + - source /opt/qt52/bin/qt52-env.sh + - /opt/qt52/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.3.2_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: gcc + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt532-trusty' + packages: + - qt53base + - qt53script + - qt53tools + + script: + - source /opt/qt53/bin/qt53-env.sh + - /opt/qt53/bin/qmake -r limereport.pro + - make + - make check -before_install: - - if [ "$QT_BASE" = "56" ]; then sudo add-apt-repository ppa:beineri/opt-qt562-trusty -y; fi - - sudo apt-get update -qq + - env: Qt5.3.2_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: clang + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt532-trusty' + packages: + - qt53base + - qt53script + - qt53tools + + script: + - source /opt/qt53/bin/qt53-env.sh + - /opt/qt53/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.4.2_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: gcc + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt542-trusty' + packages: + - qt54base + - qt54script + - qt54tools + + script: + - source /opt/qt54/bin/qt54-env.sh + - /opt/qt54/bin/qmake -r limereport.pro + - make + - make check -install: - - if [ "$QT_BASE" = "56" ]; then sudo apt-get install -qq qt56base qt56script qt56tools ; source /opt/qt56/bin/qt56-env.sh; fi - + - env: Qt5.4.2_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: clang + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt542-trusty' + packages: + - qt54base + - qt54script + - qt54tools + + script: + - source /opt/qt54/bin/qt54-env.sh + - /opt/qt54/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.5.1_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: gcc + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt551-trusty' + packages: + - qt55base + - qt55script + - qt55tools + + script: + - source /opt/qt55/bin/qt55-env.sh + - /opt/qt55/bin/qmake -r limereport.pro + - make + - make check -script: - - qmake -r limereport.pro - - make - - make check + - env: Qt5.5.1_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: clang + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt551-trusty' + packages: + - qt55base + - qt55script + - qt55tools + + script: + - source /opt/qt55/bin/qt55-env.sh + - /opt/qt55/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.6.3_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: gcc + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt563-trusty' + packages: + - qt56base + - qt56script + - qt56tools + + script: + - source /opt/qt56/bin/qt56-env.sh + - /opt/qt56/bin/qmake -r limereport.pro + - make + - make check + - env: Qt5.6.3_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: clang + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt563-trusty' + packages: + - qt56base + - qt56script + - qt56tools + + script: + - source /opt/qt56/bin/qt56-env.sh + - /opt/qt56/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.7.1_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: gcc + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt571-trusty' + packages: + - qt57base + - qt57script + - qt57tools + + script: + - source /opt/qt57/bin/qt57-env.sh + - /opt/qt57/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.7.1_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: clang + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt571-trusty' + packages: + - qt57base + - qt57script + - qt57tools + + script: + - source /opt/qt57/bin/qt57-env.sh + - /opt/qt57/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.8.0_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: gcc + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt58-trusty' + packages: + - qt58base + - qt58script + - qt58tools + + script: + - source /opt/qt58/bin/qt58-env.sh + - /opt/qt58/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.8.0_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: clang + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt58-trusty' + packages: + - qt58base + - qt58script + - qt58tools + + script: + - source /opt/qt58/bin/qt58-env.sh + - /opt/qt58/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.9.7_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: gcc + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt597-trusty' + packages: + - qt59base + - qt59script + - qt59tools + + script: + - source /opt/qt59/bin/qt59-env.sh + - /opt/qt59/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.9.7_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: clang + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt597-trusty' + packages: + - qt59base + - qt59script + - qt59tools + + script: + - source /opt/qt59/bin/qt59-env.sh + - /opt/qt59/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.10.1_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: gcc + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt-5.10.1-trusty' + packages: + - qt510base + - qt510script + - qt510tools + + script: + - source /opt/qt510/bin/qt510-env.sh + - /opt/qt510/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.10.1_Ubuntu_14.04 + os: linux + dist: trusty + language: cpp + compiler: clang + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt-5.10.1-trusty' + packages: + - qt510base + - qt510script + - qt510tools + + script: + - source /opt/qt510/bin/qt510-env.sh + - /opt/qt510/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.11.3_Ubuntu_18.04 + os: linux + dist: bionic + language: cpp + compiler: gcc + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt-5.11.3-bionic' + packages: + - qt511base + - qt511script + - qt511tools + - mesa-common-dev + - libgl1-mesa-dev + + script: + - source /opt/qt511/bin/qt511-env.sh + - /opt/qt511/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.11.3_Ubuntu_18.04 + os: linux + dist: bionic + language: cpp + compiler: clang + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt-5.11.3-bionic' + packages: + - qt511base + - qt511script + - qt511tools + - mesa-common-dev + - libgl1-mesa-dev + + script: + - source /opt/qt511/bin/qt511-env.sh + - /opt/qt511/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.12.3_Ubuntu_18.04 + os: linux + dist: bionic + language: cpp + compiler: gcc + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt-5.12.3-bionic' + packages: + - qt512base + - qt512script + - qt512tools + - mesa-common-dev + - libgl1-mesa-dev + + script: + - source /opt/qt512/bin/qt512-env.sh + - /opt/qt512/bin/qmake -r limereport.pro + - make + - make check + + - env: Qt5.12.3_Ubuntu_18.04 + os: linux + dist: bionic + language: cpp + compiler: clang + cache: ccache + addons: + apt: + sources: + - sourceline: 'ppa:beineri/opt-qt-5.12.3-bionic' + packages: + - qt512base + - qt512script + - qt512tools + - mesa-common-dev + - libgl1-mesa-dev + + script: + - source /opt/qt512/bin/qt512-env.sh + - /opt/qt512/bin/qmake -r limereport.pro + - make + - make check + notifications: - email: false - + email: false \ No newline at end of file From c549035c7638f844ab86b944d5d6d687022cee38 Mon Sep 17 00:00:00 2001 From: Rodrigo Torres Date: Sat, 10 Aug 2019 18:45:27 -0300 Subject: [PATCH 2/3] Fix compilation Qt4 still have one remaining compiler error --- limereport.pro | 7 ++++++- limereport/exporters/lrpdfexporter.h | 2 +- limereport/items/lrimageitemeditor.h | 2 +- limereport/lrbanddesignintf.cpp | 2 +- limereport/lrreportdesignwidget.h | 4 ++-- limereport/lrreportengine.cpp | 4 ++-- limereport/lrscriptenginemanager.cpp | 2 +- limereport/objectinspector/lrobjectpropitem.h | 5 ++++- 8 files changed, 18 insertions(+), 10 deletions(-) diff --git a/limereport.pro b/limereport.pro index 9e33bcc..9bc801f 100644 --- a/limereport.pro +++ b/limereport.pro @@ -16,9 +16,14 @@ SUBDIRS += \ limereport \ demo_r1 \ demo_r2 \ - console \ designer +greaterThan(QT_MAJOR_VERSION, 4){ +greaterThan(QT_MINOR_VERSION, 1){ + SUBDIRS += console + } +} + !contains(CONFIG, embedded_designer){ !contains(CONFIG, static_build){ SUBDIRS += designer_plugin diff --git a/limereport/exporters/lrpdfexporter.h b/limereport/exporters/lrpdfexporter.h index 225c80b..d758ff1 100644 --- a/limereport/exporters/lrpdfexporter.h +++ b/limereport/exporters/lrpdfexporter.h @@ -11,7 +11,7 @@ class PDFExporter : public QObject, public ReportExporterInterface { Q_OBJECT public: - explicit PDFExporter(ReportEnginePrivate *parent = nullptr); + explicit PDFExporter(ReportEnginePrivate *parent = NULL); // ReportExporterInterface interface bool exportPages(ReportPages pages, const QString &fileName, const QMap ¶ms); QString exporterName() diff --git a/limereport/items/lrimageitemeditor.h b/limereport/items/lrimageitemeditor.h index a8cc474..551baae 100644 --- a/limereport/items/lrimageitemeditor.h +++ b/limereport/items/lrimageitemeditor.h @@ -16,7 +16,7 @@ class ImageItemEditor : public QWidget Q_OBJECT public: - explicit ImageItemEditor(LimeReport::ImageItem* item, QWidget *parent = nullptr); + explicit ImageItemEditor(LimeReport::ImageItem* item, QWidget *parent = NULL); ~ImageItemEditor(); private: void updateImage(); diff --git a/limereport/lrbanddesignintf.cpp b/limereport/lrbanddesignintf.cpp index d8a6bbb..1690bbc 100644 --- a/limereport/lrbanddesignintf.cpp +++ b/limereport/lrbanddesignintf.cpp @@ -176,7 +176,7 @@ BandDesignIntf::BandDesignIntf(BandsType bandType, const QString &xmlTypeName, Q if (parentItem) setWidth(parentItem->width()); } - setBackgroundMode(BGMode::TransparentMode); + setBackgroundMode(BaseDesignIntf::TransparentMode); setFillTransparentInDesignMode(false); setHeight(100); setFixedPos(true); diff --git a/limereport/lrreportdesignwidget.h b/limereport/lrreportdesignwidget.h index 4b7248e..ef3b81b 100644 --- a/limereport/lrreportdesignwidget.h +++ b/limereport/lrreportdesignwidget.h @@ -82,12 +82,12 @@ private: class PageView: public QGraphicsView{ public: - PageView(QWidget *parent = nullptr): QGraphicsView(parent), + PageView(QWidget *parent = NULL): QGraphicsView(parent), m_horizontalRuller(0), m_verticalRuller(0) { setViewportMargins(20,20,0,0); } - PageView(QGraphicsScene *scene, QWidget *parent = nullptr): + PageView(QGraphicsScene *scene, QWidget *parent = NULL): QGraphicsView(scene, parent), m_horizontalRuller(0), m_verticalRuller(0) { diff --git a/limereport/lrreportengine.cpp b/limereport/lrreportengine.cpp index c07cff4..8a624e2 100644 --- a/limereport/lrreportengine.cpp +++ b/limereport/lrreportengine.cpp @@ -299,7 +299,7 @@ void ReportEnginePrivate::printReport(ItemsReaderIntf::Ptr reader, QPrinter& pri void ReportEnginePrivate::printReport(ReportPages pages, QPrinter &printer) { int currenPage = 1; - QMap> printProcessors; + QMap > printProcessors; printProcessors.insert("default",QSharedPointer(new PrintProcessor(&printer))); foreach(PageItemDesignIntf::Ptr page, pages){ if ( @@ -320,7 +320,7 @@ void ReportEnginePrivate::printReport(ReportPages pages, QMap> printProcessors; + QMap > printProcessors; for (int i = 0; i < printers.keys().count(); ++i) { printProcessors.insert(printers.keys()[i],QSharedPointer(new PrintProcessor(printers[printers.keys()[i]]))); } diff --git a/limereport/lrscriptenginemanager.cpp b/limereport/lrscriptenginemanager.cpp index cb6e219..f126a4c 100644 --- a/limereport/lrscriptenginemanager.cpp +++ b/limereport/lrscriptenginemanager.cpp @@ -1930,7 +1930,7 @@ bool DatasourceFunctions::isEOF(const QString &datasourceName) bool DatasourceFunctions::invalidate(const QString& datasourceName) { if (m_dataManager && m_dataManager->dataSource(datasourceName)){ - m_dataManager->dataSourceHolder(datasourceName)->invalidate(IDataSource::DatasourceMode::RENDER_MODE); + m_dataManager->dataSourceHolder(datasourceName)->invalidate(IDataSource::RENDER_MODE); return true; } return false; diff --git a/limereport/objectinspector/lrobjectpropitem.h b/limereport/objectinspector/lrobjectpropitem.h index 46392fc..f765213 100644 --- a/limereport/objectinspector/lrobjectpropitem.h +++ b/limereport/objectinspector/lrobjectpropitem.h @@ -99,7 +99,7 @@ namespace LimeReport{ #endif private: bool m_valid; - void invalidate(){m_object=0; m_objects=0; m_valid = false; m_name = ""; m_value=QVariant(), m_isClass=false;} + void invalidate(){m_object=0; m_objects=0; m_valid = false; m_name = ""; m_value=QVariant(); m_isClass=false;} protected: void beginChangeValue(){ m_changingValue = true; } @@ -140,4 +140,7 @@ namespace LimeReport{ }; } + +Q_DECLARE_METATYPE(LimeReport::ObjectPropItem*) + #endif // LROBJECTPROPITEM_H From fa795fe3ab922320b13b0a8bd11ba53106021b49 Mon Sep 17 00:00:00 2001 From: Arin Alexander Date: Sun, 11 Aug 2019 12:48:16 +0300 Subject: [PATCH 3/3] Qt4 build has been fixed --- common.pri | 2 +- limereport/lrbasedesignintf.h | 4 +++- limereport/lrpagedesignintf.cpp | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/common.pri b/common.pri index cbe3fc1..64fa9c2 100644 --- a/common.pri +++ b/common.pri @@ -127,7 +127,7 @@ RCC_DIR = $${ARCH_DIR}/$${BUILD_TYPE}/rcc LIMEREPORT_VERSION_MAJOR = 1 LIMEREPORT_VERSION_MINOR = 5 -LIMEREPORT_VERSION_RELEASE = 7 +LIMEREPORT_VERSION_RELEASE = 9 LIMEREPORT_VERSION = '$${LIMEREPORT_VERSION_MAJOR}.$${LIMEREPORT_VERSION_MINOR}.$${LIMEREPORT_VERSION_RELEASE}' DEFINES *= LIMEREPORT_VERSION_STR=\\\"$${LIMEREPORT_VERSION}\\\" diff --git a/limereport/lrbasedesignintf.h b/limereport/lrbasedesignintf.h index 40c4761..b7fbbbb 100644 --- a/limereport/lrbasedesignintf.h +++ b/limereport/lrbasedesignintf.h @@ -262,7 +262,7 @@ public: QString itemTypeName() const; void setItemTypeName(const QString &itemTypeName); - void emitObjectNamePropertyChanged(const QString& oldName, const QString& newName); + int borderLineSize() const; void setBorderLineSize(int value); void showEditorDialog(); @@ -303,7 +303,9 @@ public: bool fillTransparentInDesignMode() const; void setFillTransparentInDesignMode(bool fillTransparentInDesignMode); + void emitPosChanged(QPointF oldPos, QPointF newPos); + void emitObjectNamePropertyChanged(const QString& oldName, const QString& newName); bool isGeometryLocked() const; void setGeometryLocked(bool itemLocked); diff --git a/limereport/lrpagedesignintf.cpp b/limereport/lrpagedesignintf.cpp index bc81b94..89a18f4 100644 --- a/limereport/lrpagedesignintf.cpp +++ b/limereport/lrpagedesignintf.cpp @@ -2136,7 +2136,7 @@ bool PosChangedCommand::doIt() if (reportItem && (reportItem->pos() != m_newPos[i].pos)){ QPointF oldValue = reportItem->pos(); reportItem->setPos(m_newPos[i].pos); - emit reportItem->posChanged(reportItem, oldValue, reportItem->pos()); + reportItem->emitPosChanged(oldValue, reportItem->pos()); } }