diff --git a/3rdparty/zint-2.4.4/backend_qt4/Zint.pro b/3rdparty/zint-2.4.4/backend_qt4/Zint.pro index 7b54d67..2497f83 100644 --- a/3rdparty/zint-2.4.4/backend_qt4/Zint.pro +++ b/3rdparty/zint-2.4.4/backend_qt4/Zint.pro @@ -1,7 +1,15 @@ DEFINES += NO_PNG - TEMPLATE = lib + +contains(CONFIG, static_build){ + CONFIG += staticlib + DEFINES += HAVE_STATIC_BUILD +} + +!contains(CONFIG, staticlib){ CONFIG += dll + DEFINES += QZINT_LIBRARY +} include(../../../common.pri) @@ -18,8 +26,6 @@ unix{ INCLUDEPATH += $$PWD/../backend DEFINES += _CRT_SECURE_NO_WARNINGS _CRT_NONSTDC_NO_WARNINGS ZINT_VERSION=\\\"$$VERSION\\\" -DEFINES += QZINT_LIBRARY -#TARGET = QtZint CONFIG(debug, debug|release) { TARGET = QtZintd diff --git a/3rdparty/zint-2.4.4/backend_qt4/qzint_global.h b/3rdparty/zint-2.4.4/backend_qt4/qzint_global.h index 025b16e..ea46fe2 100644 --- a/3rdparty/zint-2.4.4/backend_qt4/qzint_global.h +++ b/3rdparty/zint-2.4.4/backend_qt4/qzint_global.h @@ -3,10 +3,14 @@ #include +#ifdef HAVE_STATIC_BUILD +# define QZINTSHARED_EXPORT /**/ +#else #if defined(QZINT_LIBRARY) # define QZINTSHARED_EXPORT Q_DECL_EXPORT #else # define QZINTSHARED_EXPORT Q_DECL_IMPORT #endif +#endif #endif // QZINT_GLOBAL_H diff --git a/common.pri b/common.pri index 0bb04eb..a99ca12 100644 --- a/common.pri +++ b/common.pri @@ -1,5 +1,13 @@ CONFIG += build_translations -CONFIG += zint + +!contains(CONFIG, no_zint){ + CONFIG += zint +} + +ZINT_PATH = $$PWD/3rdparty/zint-2.4.4 +contains(CONFIG,zint){ + DEFINES += HAVE_ZINT +} greaterThan(QT_MAJOR_VERSION, 4) { QT += uitools @@ -8,8 +16,6 @@ lessThan(QT_MAJOR_VERSION, 5){ CONFIG += uitools } -ZINT_PATH = $$PWD/3rdparty/zint-2.4.4 - CONFIG(release, debug|release){ message(Release) BUILD_TYPE = release @@ -56,7 +62,7 @@ RCC_DIR = $${ARCH_DIR}/$${BUILD_TYPE}/rcc LIMEREPORT_VERSION_MAJOR = 1 LIMEREPORT_VERSION_MINOR = 4 -LIMEREPORT_VERSION_RELEASE = 8 +LIMEREPORT_VERSION_RELEASE = 63 LIMEREPORT_VERSION = '\\"$${LIMEREPORT_VERSION_MAJOR}.$${LIMEREPORT_VERSION_MINOR}.$${LIMEREPORT_VERSION_RELEASE}\\"' DEFINES += LIMEREPORT_VERSION_STR=\"$${LIMEREPORT_VERSION}\" @@ -82,3 +88,5 @@ lessThan(QT_MAJOR_VERSION, 5){ DEFINES += HAVE_UI_LOADER } } + + diff --git a/demo_r1/demo_r1.pro b/demo_r1/demo_r1.pro index ecd57df..71c0821 100644 --- a/demo_r1/demo_r1.pro +++ b/demo_r1/demo_r1.pro @@ -33,27 +33,30 @@ unix:{ LIBS += -llimereport } - contains(CONFIG,zint){ - LIBS += -L$${DEST_LIBS} + !contains(CONFIG, static_build){ + contains(CONFIG,zint){ + LIBS += -L$${DEST_LIBS} - CONFIG(debug, debug|release) { - LIBS += -lQtZintd - } else { - LIBS += -lQtZint - } - } - DESTDIR = $$DEST_DIR -# QMAKE_POST_LINK += mkdir -p $$quote($$REPORTS_DIR) | - QMAKE_POST_LINK += $$QMAKE_COPY_DIR $$quote($$EXTRA_DIR) $$quote($$REPORTS_DIR) $$escape_expand(\n\t) -linux{ - #Link share lib to ../lib rpath - QMAKE_LFLAGS += -Wl,--rpath=\\\$\$ORIGIN - QMAKE_LFLAGS += -Wl,--rpath=\\\$\$ORIGIN/lib - QMAKE_LFLAGS += -Wl,--rpath=\\\$\$ORIGIN/../lib - QMAKE_LFLAGS_RPATH += #. .. ./libs -} - target.path = $${DEST_DIR} - INSTALLS = target + CONFIG(debug, debug|release) { + LIBS += -lQtZintd + } else { + LIBS += -lQtZint + } + } + } + DESTDIR = $$DEST_DIR + # QMAKE_POST_LINK += mkdir -p $$quote($$REPORTS_DIR) | + QMAKE_POST_LINK += $$QMAKE_COPY_DIR $$quote($$EXTRA_DIR) $$quote($$REPORTS_DIR) $$escape_expand(\n\t) + + linux{ + #Link share lib to ../lib rpath + QMAKE_LFLAGS += -Wl,--rpath=\\\$\$ORIGIN + QMAKE_LFLAGS += -Wl,--rpath=\\\$\$ORIGIN/lib + QMAKE_LFLAGS += -Wl,--rpath=\\\$\$ORIGIN/../lib + QMAKE_LFLAGS_RPATH += #. .. ./libs + } + target.path = $${DEST_DIR} + INSTALLS = target } win32 { @@ -65,20 +68,24 @@ win32 { RC_FILE += mainicon.rc QMAKE_POST_LINK += $$QMAKE_COPY_DIR $$quote($$EXTRA_DIR\\*) $$quote($$REPORTS_DIR\\demo_reports) $$escape_expand(\\n\\t) - contains(CONFIG,zint){ - LIBS += -L$${DEST_LIBS} - CONFIG(debug, debug|release) { - LIBS += -lQtZintd - } else { - LIBS += -lQtZint - } + !contains(CONFIG, static_build){ + + contains(CONFIG,zint){ + LIBS += -L$${DEST_LIBS} + CONFIG(debug, debug|release) { + LIBS += -lQtZintd + } else { + LIBS += -lQtZint + } + } } + LIBS += -L$${DEST_LIBS} - CONFIG(debug, debug|release) { - LIBS += -llimereportd - } else { - LIBS += -llimereport - } + CONFIG(debug, debug|release) { + LIBS += -llimereportd + } else { + LIBS += -llimereport + } } diff --git a/demo_r2/demo_r2.pro b/demo_r2/demo_r2.pro index 7a2ab07..8ff5356 100644 --- a/demo_r2/demo_r2.pro +++ b/demo_r2/demo_r2.pro @@ -32,23 +32,25 @@ unix:{ } else { LIBS += -llimereport } - contains(CONFIG,zint){ - LIBS += -L$${DEST_LIBS} - CONFIG(debug, debug|release) { - LIBS += -lQtZintd - } else { - LIBS += -lQtZint - } - } + !contains(CONFIG, static_build){ + contains(CONFIG,zint){ + LIBS += -L$${DEST_LIBS} + CONFIG(debug, debug|release) { + LIBS += -lQtZintd + } else { + LIBS += -lQtZint + } + } + } DESTDIR = $$DEST_DIR QMAKE_POST_LINK += $$QMAKE_COPY_DIR $$quote($$EXTRA_DIR) $$quote($$REPORTS_DIR) $$escape_expand(\n\t) -linux{ - #Link share lib to ../lib rpath - QMAKE_LFLAGS += -Wl,--rpath=\\\$\$ORIGIN - QMAKE_LFLAGS += -Wl,--rpath=\\\$\$ORIGIN/lib - QMAKE_LFLAGS += -Wl,--rpath=\\\$\$ORIGIN/../lib - QMAKE_LFLAGS_RPATH += #. .. ./libs -} + linux{ + #Link share lib to ../lib rpath + QMAKE_LFLAGS += -Wl,--rpath=\\\$\$ORIGIN + QMAKE_LFLAGS += -Wl,--rpath=\\\$\$ORIGIN/lib + QMAKE_LFLAGS += -Wl,--rpath=\\\$\$ORIGIN/../lib + QMAKE_LFLAGS_RPATH += #. .. ./libs + } target.path = $${DEST_DIR} INSTALLS = target } @@ -60,22 +62,24 @@ win32 { DESTDIR = $$DEST_DIR RC_FILE += mainicon.rc - - contains(CONFIG,zint){ - LIBS += -L$${DEST_LIBS} - CONFIG(debug, debug|release) { - LIBS += -lQtZintd - } else { - LIBS += -lQtZint - } - } + !contains(CONFIG, static_build){ + contains(CONFIG,zint){ + LIBS += -L$${DEST_LIBS} + CONFIG(debug, debug|release) { + LIBS += -lQtZintd + } else { + LIBS += -lQtZint + } + } + } LIBS += -L$${DEST_LIBS} - CONFIG(debug, debug|release) { + + CONFIG(debug, debug|release) { LIBS += -llimereportd } else { LIBS += -llimereport } - + QMAKE_POST_LINK += $$QMAKE_COPY_DIR \"$$EXTRA_DIR\" \"$$REPORTS_DIR\\demo_reports\" $$escape_expand(\\n\\t) } diff --git a/designer/designer.pro b/designer/designer.pro index 1f0b8ee..68bf6b6 100644 --- a/designer/designer.pro +++ b/designer/designer.pro @@ -23,14 +23,16 @@ unix:{ } else { LIBS += -llimereport } - contains(CONFIG,zint){ - LIBS += -L$${DEST_LIBS} - CONFIG(debug, debug|release) { - LIBS += -lQtZintd - } else { - LIBS += -lQtZint - } - } + !contains(CONFIG, static_build){ + contains(CONFIG,zint){ + LIBS += -L$${DEST_LIBS} + CONFIG(debug, debug|release) { + LIBS += -lQtZintd + } else { + LIBS += -lQtZint + } + } + } DESTDIR = $$DEST_DIR linux{ #Link share lib to ../lib rpath @@ -50,15 +52,17 @@ win32 { DESTDIR = $$DEST_DIR RC_FILE += mainicon.rc - - contains(CONFIG,zint){ - LIBS += -L$${DEST_LIBS} - CONFIG(debug, debug|release) { - LIBS += -lQtZintd - } else { - LIBS += -lQtZint - } + !contains(CONFIG, static_build){ + contains(CONFIG,zint){ + LIBS += -L$${DEST_LIBS} + CONFIG(debug, debug|release) { + LIBS += -lQtZintd + } else { + LIBS += -lQtZint + } + } } + LIBS += -L$${DEST_LIBS} CONFIG(debug, debug|release) { LIBS += -llimereportd diff --git a/designer/main.cpp b/designer/main.cpp index 6ecf8ef..9132b47 100644 --- a/designer/main.cpp +++ b/designer/main.cpp @@ -1,9 +1,21 @@ #include #include +#include int main(int argc, char *argv[]) { QApplication a(argc, argv); + + QTranslator limeReportTranslator; + QString translationPath = QApplication::applicationDirPath(); + translationPath.append("/languages"); + limeReportTranslator.load("limereport_"+QLocale::system().name(),translationPath); + a.installTranslator(&limeReportTranslator); + + QTranslator qtTranslator; + qtTranslator.load("qt_" + QLocale::system().name(),translationPath); + a.installTranslator(&qtTranslator); + LimeReport::ReportEngine report; if (a.arguments().count()>1){ report.loadFromFile(a.arguments().at(1)); diff --git a/include/lrglobal.h b/include/lrglobal.h index 3f11f78..f2c866f 100644 --- a/include/lrglobal.h +++ b/include/lrglobal.h @@ -27,8 +27,8 @@ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * * GNU General Public License for more details. * ****************************************************************************/ -#ifndef GLOBAL_H -#define GLOBAL_H +#ifndef LRGLOBAL_H +#define LRGLOBAL_H #include "qglobal.h" #include #include @@ -76,6 +76,7 @@ namespace Const{ const qreal SELECTION_OPACITY = 0.3; const QString FIELD_RX = "\\$D\\s*\\{\\s*([^{}]*)\\s*\\}"; const QString VARIABLE_RX = "\\$V\\s*\\{\\s*([^{}]*)\\s*\\}"; + const QString NAMED_VARIABLE_RX = "\\$V\\s*\\{\\s*(%1)\\s*\\}"; const QString SCRIPT_RX = "\\$S\\s*\\{(.*)\\}"; //const QString GROUP_FUNCTION_PARAM_RX = "\\(\\s*(((?:\\\"?\\$D\\s*\\{\\s*)|(?:\\\"?\\$V\\s*\\{\\s*)|(?:\\\"))(\\w+\\.?\\w+)((?:\\\")|(?:\\s*\\}\\\"?\\s*)))\\s*,\\s*\\\"(\\w+)\\\"\\s*\\)"; @@ -84,7 +85,8 @@ namespace Const{ //const QString GROUP_FUNCTION_PARAM_RX = "\\(\\s*(?:(?:((?:(?:\\\"?\\$D\\s*\\{\\s*)|(?:\\\"?\\$V\\s*\\{\\s*)|(?:\\\"?\\$S\\s*\\{\\s*)|(?:\\\"))((?:\\w+\\.?\\w+)|(?:\\w+))(?:(?:\\\")|(?:\\s*\\}\\\"?\\s*)))\\s*,)|(?:))\\s*\\\"(\\w+)\\\"\\s*\\)"; //const QString GROUP_FUNCTION_PARAM_RX = "\\((?:(.+),(.+))|(?:\\\"(\\w+)\\\")\\)"; - const QString GROUP_FUNCTION_PARAM_RX = "\\(\\s*(?:(?:(?:(?:\\\")|(?:))(\\w+)(?:(?:\\\")|(?:)))|(?:(?:(?:\\\")|(?:))(\\s*\\$\\w\\s*\\{.+\\}\\s*)(?:(?:\\\")|(?:))\\s*,\\s*(?:(?:\\\")|(?:))(\\w+)(?:(?:\\\")|(?:))))\\)"; + //const QString GROUP_FUNCTION_PARAM_RX = "\\(\\s*(?:(?:(?:(?:\\\")|(?:))(\\w+)(?:(?:\\\")|(?:)))|(?:(?:(?:\\\")|(?:))(\\s*\\$\\w\\s*\\{.+\\}\\s*)(?:(?:\\\")|(?:))\\s*,\\s*(?:(?:\\\")|(?:))(\\w+)(?:(?:\\\")|(?:))))\\)"; + const QString GROUP_FUNCTION_PARAM_RX = "\\(\\s*((?:(?:\\\")|(?:))(?:(?:\\$(?:(?:D\\{\\s*\\w*.\\w*\\s*\\})|(?:V\\{\\s*\\w*\\s*\\})|(?:S\\{.+\\})))|(?:\\w*))(?:(?:\\\")|(?:)))(?:(?:\\s*,\\s*(?:\\\"(\\w*)\\\"))|(?:))\\)"; const int DATASOURCE_INDEX = 3;//4; const int VALUE_INDEX = 2; //2; const int EXPRESSION_ARGUMENT_INDEX = 1;//3; diff --git a/include/lrreportengine.h b/include/lrreportengine.h index 564dabd..746712e 100644 --- a/include/lrreportengine.h +++ b/include/lrreportengine.h @@ -102,6 +102,8 @@ public: bool resultIsEditable(); bool isBusy(); void setPassPharse(QString& passPharse); + Qt::LayoutDirection previewLayoutDirection(); + void setPreviewLayoutDirection(const Qt::LayoutDirection& previewLayoutDirection); signals: void renderStarted(); void renderFinished(); diff --git a/limereport.pro b/limereport.pro index c03043d..84179ac 100644 --- a/limereport.pro +++ b/limereport.pro @@ -1,9 +1,15 @@ TEMPLATE = subdirs + +!contains(CONFIG, no_zint){ + CONFIG += zint +} + include(common.pri) contains(CONFIG, zint){ SUBDIRS += 3rdparty } +export($$CONFIG) SUBDIRS += \ limereport diff --git a/limereport/bands/lrgroupbands.cpp b/limereport/bands/lrgroupbands.cpp index 74b55eb..6865ce5 100644 --- a/limereport/bands/lrgroupbands.cpp +++ b/limereport/bands/lrgroupbands.cpp @@ -151,10 +151,11 @@ bool GroupBandHeader::isNeedToClose(DataSourceManager* dataManager) IDataSource* ds = dataManager->dataSource(datasourceName); if (ds){ if (ds->data(m_groupFiledName).isNull() && m_groupFieldValue.isNull()) return false; + if (!ds->data(m_groupFiledName).isValid()) return false; return ds->data(m_groupFiledName)!=m_groupFieldValue; } } else { - dataManager->putError(tr("Datasource \"%1\" not found !!!").arg(datasourceName)); + dataManager->putError(tr("Datasource \"%1\" not found!").arg(datasourceName)); } } diff --git a/limereport/bands/lrsubdetailband.h b/limereport/bands/lrsubdetailband.h index c9b4c76..72967b3 100644 --- a/limereport/bands/lrsubdetailband.h +++ b/limereport/bands/lrsubdetailband.h @@ -46,6 +46,7 @@ class SubDetailBand : public DataBandDesignIntf public: SubDetailBand(QObject* owner = 0, QGraphicsItem* parent=0); bool isUnique() const {return false;} + int bandNestingLevel(){ return 1;} bool isHasHeader() const; bool isHasFooter() const; private: @@ -63,6 +64,8 @@ class SubDetailHeaderBand : public BandDesignIntf public: SubDetailHeaderBand(QObject* owner = 0, QGraphicsItem* parent=0); bool isUnique() const; + bool isHeader() const {return true;} + int bandNestingLevel(){ return 1;} protected: QColor bandColor() const; private: @@ -79,6 +82,7 @@ public: SubDetailFooterBand(QObject* owner = 0, QGraphicsItem* parent=0); virtual bool isUnique() const; bool isFooter() const{return true;} + int bandNestingLevel(){ return 1;} protected: QColor bandColor() const; private: diff --git a/limereport/bands/lrtearoffband.h b/limereport/bands/lrtearoffband.h index e373a90..1366aa6 100644 --- a/limereport/bands/lrtearoffband.h +++ b/limereport/bands/lrtearoffband.h @@ -1,5 +1,5 @@ -#ifndef TEAROFFBAND_H -#define TEAROFFBAND_H +#ifndef LRTEAROFFBAND_H +#define LRTEAROFFBAND_H #include "lrbanddesignintf.h" namespace LimeReport { diff --git a/limereport/databrowser/lrconnectiondialog.cpp b/limereport/databrowser/lrconnectiondialog.cpp index b90545e..96204c4 100644 --- a/limereport/databrowser/lrconnectiondialog.cpp +++ b/limereport/databrowser/lrconnectiondialog.cpp @@ -95,7 +95,7 @@ void ConnectionDialog::checkFieldsFill() { if (ui->leConnectionName->text().isEmpty()){throw LimeReport::ReportError(tr("Connection Name is empty"));} if (!m_changeMode&&QSqlDatabase::connectionNames().contains(ui->leConnectionName->text())) { - throw LimeReport::ReportError(tr("Connection with name ")+ui->leConnectionName->text()+tr(" already exists ")); + throw LimeReport::ReportError(tr("Connection with name ")+ui->leConnectionName->text()+tr(" already exists! ")); } } @@ -117,6 +117,8 @@ ConnectionDesc *ConnectionDialog::uiToConnection(LimeReport::ConnectionDesc* con result = new LimeReport::ConnectionDesc(); result ->setName(ConnectionDesc::connectionNameForReport(ui->leConnectionName->text())); result ->setHost(ui->leServerName->text()); + if (!ui->lePort->text().isEmpty()) + result->setPort(ui->lePort->text().toInt()); result ->setDriver(ui->cbbDrivers->currentText()); result ->setUserName(ui->leUserName->text()); result ->setPassword(ui->lePassword->text()); @@ -139,6 +141,7 @@ void ConnectionDialog::connectionToUI() ui->cbbDrivers->setCurrentIndex(ui->cbbDrivers->findText(m_connection->driver())); ui->cbAutoConnect->setChecked(m_connection->autoconnect()); ui->cbbKeepCredentials->setChecked(!m_connection->keepDBCredentials()); + ui->lePort->setText(m_connection->port()!=-1?QString::number(m_connection->port()):""); } void ConnectionDialog::on_toolButton_clicked() diff --git a/limereport/databrowser/lrconnectiondialog.ui b/limereport/databrowser/lrconnectiondialog.ui index 60bf527..d76b765 100644 --- a/limereport/databrowser/lrconnectiondialog.ui +++ b/limereport/databrowser/lrconnectiondialog.ui @@ -7,7 +7,7 @@ 0 0 420 - 294 + 323 @@ -17,7 +17,7 @@ :/databrowser/images/database_disconnected:/databrowser/images/database_disconnected - + @@ -44,88 +44,106 @@ - - - - - Driver - - - - - - - - - - Server - - - - - - - - - - - - - - User - - - - - - - - - - - - - - Password - - - - - - - - - - QLineEdit::Password - - - - - - - Database - - - - - - - 2 - + + + - + + + Driver + + + + + + + Server + + + + + + + Port + + + + + + + User + + + + + + + Password + + + + + + + Database + + + + + + + + + + + + - + + + + - ... + + + + + + + + QLineEdit::Password + + + + + + + 2 + + + + + + + + + + + + ... + + + + + diff --git a/limereport/databrowser/lrdatabrowser.cpp b/limereport/databrowser/lrdatabrowser.cpp index b6db492..ef0e556 100644 --- a/limereport/databrowser/lrdatabrowser.cpp +++ b/limereport/databrowser/lrdatabrowser.cpp @@ -131,7 +131,7 @@ void DataBrowser::slotDeleteConnection() QMessageBox::critical( this, tr("Attention"), - tr("Do you really want to delete \"%1\" connection ?").arg(getConnectionName(NameForUser)), + tr("Do you really want to delete \"%1\" connection?").arg(getConnectionName(NameForUser)), QMessageBox::Ok|QMessageBox::No, QMessageBox::No ) == QMessageBox::Ok @@ -395,7 +395,7 @@ void DataBrowser::slotDeleteDatasource() QMessageBox::critical( this, tr("Attention"), - tr("Do you really want to delete \"%1\" datasource ?").arg(datasourceName), + tr("Do you really want to delete \"%1\" datasource?").arg(datasourceName), QMessageBox::Ok|QMessageBox::No, QMessageBox::No ) == QMessageBox::Ok @@ -702,7 +702,7 @@ void DataBrowser::on_dataTree_currentItemChanged(QTreeWidgetItem *current, QTree Q_UNUSED(previous) if (current&&(current->type() == DataBrowserTree::Connection)) { bool internalConnection = m_report->dataManager()->connectionByName(ConnectionDesc::connectionNameForReport(current->text(0))); - if (m_report->dataManager()->isConnectionConnected(current->text(0))){ + if (m_report->dataManager()->isConnectionConnected(ConnectionDesc::connectionNameForReport(current->text(0)))){ ui->pbConnect->setIcon(QIcon(":/databrowser/images/plug-connect.png")); } else { ui->pbConnect->setIcon(QIcon(":/databrowser/images/plug-disconnect.png")); @@ -766,7 +766,7 @@ void DataBrowser::on_deleteVariable_clicked() { QString varName = getVariable(); if (!varName.isEmpty()){ - if (QMessageBox::critical(this,tr("Attention"),QString(tr("Do you really want to delete variable \"%1\" ?")).arg(varName), + if (QMessageBox::critical(this,tr("Attention"),QString(tr("Do you really want to delete variable \"%1\"?")).arg(varName), QMessageBox::Ok|QMessageBox::Cancel, QMessageBox::Cancel )==QMessageBox::Ok){ m_report->dataManager()->deleteVariable(varName); diff --git a/limereport/databrowser/lrsqleditdialog.cpp b/limereport/databrowser/lrsqleditdialog.cpp index 31dd6f1..05e3267 100644 --- a/limereport/databrowser/lrsqleditdialog.cpp +++ b/limereport/databrowser/lrsqleditdialog.cpp @@ -147,11 +147,11 @@ void SQLEditDialog::hideEvent(QHideEvent *) void SQLEditDialog::check() { - if (ui->leDatasourceName->text().isEmpty()) throw LimeReport::ReportError(tr("Datasource Name is empty !")); - if (ui->textEditSQL->toPlainText().isEmpty() && (!ui->rbProxy) ) throw LimeReport::ReportError(tr("SQL is empty !")); + if (ui->leDatasourceName->text().isEmpty()) throw LimeReport::ReportError(tr("Datasource Name is empty!")); + if (ui->textEditSQL->toPlainText().isEmpty() && (!ui->rbProxy) ) throw LimeReport::ReportError(tr("SQL is empty!")); if (m_dialogMode==AddMode){ if (m_datasources->containsDatasource(ui->leDatasourceName->text())){ - throw LimeReport::ReportError(QString(tr("Datasource with name: \"%1\" already exists !")).arg(ui->leDatasourceName->text())); + throw LimeReport::ReportError(QString(tr("Datasource with name: \"%1\" already exists!")).arg(ui->leDatasourceName->text())); } } } diff --git a/limereport/items/lrhorizontallayout.cpp b/limereport/items/lrhorizontallayout.cpp index 9ca4b0a..d93e545 100644 --- a/limereport/items/lrhorizontallayout.cpp +++ b/limereport/items/lrhorizontallayout.cpp @@ -63,7 +63,7 @@ bool lessThen(BaseDesignIntf *c1, BaseDesignIntf* c2){ HorizontalLayout::HorizontalLayout(QObject *owner, QGraphicsItem *parent) : LayoutDesignIntf(xmlTag, owner, parent),m_isRelocating(false),m_layoutType(Layout) { - setPossibleResizeDirectionFlags(ResizeBottom); + setPossibleResizeDirectionFlags(AllDirections); m_layoutMarker = new LayoutMarker(this); m_layoutMarker->setParentItem(this); m_layoutMarker->setColor(Qt::red); @@ -86,6 +86,7 @@ BaseDesignIntf *HorizontalLayout::createSameTypeItem(QObject *owner, QGraphicsIt void HorizontalLayout::hoverEnterEvent(QGraphicsSceneHoverEvent *event) { Q_UNUSED(event) + LayoutDesignIntf::hoverEnterEvent(event); // if ((itemMode() & LayoutEditMode) || isSelected()){ // setChildVisibility(false); // } @@ -94,6 +95,7 @@ void HorizontalLayout::hoverEnterEvent(QGraphicsSceneHoverEvent *event) void HorizontalLayout::hoverLeaveEvent(QGraphicsSceneHoverEvent *event) { Q_UNUSED(event) + LayoutDesignIntf::hoverLeaveEvent(event); // setChildVisibility(true); } @@ -101,7 +103,7 @@ void HorizontalLayout::geometryChangedEvent(QRectF newRect, QRectF ) { m_layoutMarker->setHeight(newRect.height()); relocateChildren(); - if (m_layoutType == Table && !m_isRelocating){ + if (/*m_layoutType == Table && */!m_isRelocating){ divideSpace(); } } @@ -203,6 +205,36 @@ void HorizontalLayout::setBorderLinesFlags(BaseDesignIntf::BorderLines flags) relocateChildren(); } +QVariant HorizontalLayout::itemChange(QGraphicsItem::GraphicsItemChange change, const QVariant& value) +{ + if (change == QGraphicsItem::ItemSelectedHasChanged){ + m_isRelocating = true; + foreach(BaseDesignIntf* item, m_children){ + item->setVisible(!value.toBool()); + } + m_isRelocating = false; + } + return LayoutDesignIntf::itemChange(change, value); +} + +void HorizontalLayout::paint(QPainter* ppainter, const QStyleOptionGraphicsItem* option, QWidget* widget) +{ + if (isSelected()){ + foreach( BaseDesignIntf* item, m_children){ + ppainter->save(); + ppainter->setPen(Qt::red); + ppainter->drawRect( + QRectF(item->pos().x(),item->pos().y(), + item->rect().bottomRight().rx(), + item->rect().bottomRight().ry() + ) + ); + ppainter->restore(); + } + } + LayoutDesignIntf::paint(ppainter, option, widget); +} + void HorizontalLayout::restoreChild(BaseDesignIntf* item){ if (m_children.contains(item)) return; @@ -257,9 +289,22 @@ void HorizontalLayout::addChild(BaseDesignIntf *item, bool updateSize) item->setFixedPos(true); item->setPossibleResizeDirectionFlags(ResizeRight | ResizeBottom); - connect(item,SIGNAL(destroyed(QObject*)),this,SLOT(slotOnChildDestroy(QObject*))); - connect(item,SIGNAL(geometryChanged(QObject*,QRectF,QRectF)),this,SLOT(slotOnChildGeometryChanged(QObject*,QRectF,QRectF))); - connect(item, SIGNAL(itemVisibleHasChanged(BaseDesignIntf*)),this,SLOT(slotOnChildVisibleHasChanged(BaseDesignIntf*))); + connect( + item, SIGNAL(destroyed(QObject*)), + this, SLOT(slotOnChildDestroy(QObject*)) + ); + connect( + item,SIGNAL(geometryChanged(QObject*,QRectF,QRectF)), + this,SLOT(slotOnChildGeometryChanged(QObject*,QRectF,QRectF)) + ); + connect( + item, SIGNAL(itemVisibleHasChanged(BaseDesignIntf*)), + this,SLOT(slotOnChildVisibleHasChanged(BaseDesignIntf*)) + ); + connect( + item, SIGNAL(itemSelectedHasBeenChanged(BaseDesignIntf*,bool)), + this, SLOT(slotOnChildSelectionHasChanged(BaseDesignIntf*,bool)) + ); if (updateSize){ relocateChildren(); @@ -292,7 +337,8 @@ void HorizontalLayout::objectLoadFinished() void HorizontalLayout::updateLayoutSize() { - int w = ((borderLines() != 0) ? borderLineSize() : 0)*2; + int spaceBorder = (borderLines() != 0) ? borderLineSize() : 0; + int w = spaceBorder*2; qreal h = 0; foreach(BaseDesignIntf* item, m_children){ if (item->isVisible()){ @@ -300,7 +346,7 @@ void HorizontalLayout::updateLayoutSize() w+=item->width(); } } - if (h>0) setHeight(h); + if (h>0) setHeight(h+spaceBorder*2); setWidth(w); } @@ -317,7 +363,7 @@ void HorizontalLayout::relocateChildren() qreal curX = spaceBorder; m_isRelocating = true; foreach (BaseDesignIntf* item, m_children) { - if (item->isVisible()){ + if (item->isVisible() || itemMode() == DesignMode){ item->setPos(curX,spaceBorder); curX+=item->width(); item->setHeight(height()-(spaceBorder * 2)); @@ -418,14 +464,23 @@ BaseDesignIntf* HorizontalLayout::findPrior(BaseDesignIntf* item){ void HorizontalLayout::divideSpace(){ m_isRelocating = true; qreal itemsSumSize = 0; + int visibleItemsCount = 0; + int spaceBorder = (borderLines() != 0) ? borderLineSize() : 0; + foreach(BaseDesignIntf* item, m_children){ - itemsSumSize += item->width(); + if (item->isVisible() || itemMode() == DesignMode ){ + itemsSumSize += item->width(); + visibleItemsCount++; + } } - qreal delta = (width() - itemsSumSize)/m_children.size(); + qreal delta = (width() - (itemsSumSize+spaceBorder*2)) / (visibleItemsCount!=0 ? visibleItemsCount : 1); + for (int i=0; isetWidth(m_children[i]->width()+(delta)); + if (m_children[i]->isVisible() || itemMode() == DesignMode) + m_children[i]->setWidth(m_children[i]->width()+delta); if ((i+1)setPos(m_children[i+1]->pos().x()+delta*(i+1),m_children[i+1]->pos().y()); + if (m_children[i+1]->isVisible() || itemMode() == DesignMode) + m_children[i+1]->setPos(m_children[i+1]->pos().x()+delta*(i+1),m_children[i+1]->pos().y()); } m_isRelocating = false; } @@ -463,6 +518,11 @@ void HorizontalLayout::slotOnChildVisibleHasChanged(BaseDesignIntf *) } } +void HorizontalLayout::slotOnChildSelectionHasChanged(BaseDesignIntf* item, bool value) +{ + item->setZValue(value ? item->zValue()+1 : item->zValue()-1); +} + HorizontalLayout::LayoutType HorizontalLayout::layoutType() const { return m_layoutType; diff --git a/limereport/items/lrhorizontallayout.h b/limereport/items/lrhorizontallayout.h index 67cceef..5bfaddc 100644 --- a/limereport/items/lrhorizontallayout.h +++ b/limereport/items/lrhorizontallayout.h @@ -74,6 +74,7 @@ public: bool isEmpty() const; LayoutType layoutType() const; void setLayoutType(const LayoutType &layoutType); + bool isSplittable() const { return true;} protected: void collectionLoadFinished(const QString &collectionName); void objectLoadFinished(); @@ -95,11 +96,15 @@ protected: void setItemAlign(const ItemAlign &itemAlign); void setBorderLinesFlags(BorderLines flags); + + QVariant itemChange(GraphicsItemChange change, const QVariant &value); + void paint(QPainter* ppainter, const QStyleOptionGraphicsItem* option, QWidget* widget); private slots: void slotOnChildDestroy(QObject *child); void slotOnChildGeometryChanged(QObject*item, QRectF newGeometry, QRectF oldGeometry); void slotOnChildItemAlignChanged(BaseDesignIntf* item, const ItemAlign&, const ItemAlign&); void slotOnChildVisibleHasChanged(BaseDesignIntf*); + void slotOnChildSelectionHasChanged(BaseDesignIntf* item, bool value); //void slotOnPosChanged(QObject*, QPointF newPos, QPointF ); private: void divideSpace(); diff --git a/limereport/items/lrimageitem.cpp b/limereport/items/lrimageitem.cpp index ede6a1f..1233ac0 100644 --- a/limereport/items/lrimageitem.cpp +++ b/limereport/items/lrimageitem.cpp @@ -47,7 +47,7 @@ bool VARIABLE_IS_NOT_USED registred = LimeReport::DesignElementsFactory::instanc namespace LimeReport{ ImageItem::ImageItem(QObject* owner,QGraphicsItem* parent) - :ItemDesignIntf(xmlTag,owner,parent),m_autoSize(false), m_scale(true), m_keepAspectRatio(true), m_center(true){} + :ItemDesignIntf(xmlTag,owner,parent),m_autoSize(false), m_scale(true), m_keepAspectRatio(true), m_center(true), m_format(Binary){} BaseDesignIntf *ImageItem::createSameTypeItem(QObject *owner, QGraphicsItem *parent) { @@ -65,8 +65,21 @@ void ImageItem::updateItemSize(DataSourceManager* dataManager, RenderPass pass, if (data.isValid()){ if (data.type()==QVariant::Image){ m_picture = data.value(); - } else - m_picture.loadFromData(data.toByteArray()); + } else { + switch (m_format) { + default: + case Binary: + m_picture.loadFromData(data.toByteArray()); + break; + case Hex: + m_picture.loadFromData(QByteArray::fromHex(data.toByteArray())); + break; + case Base64: + m_picture.loadFromData(QByteArray::fromBase64(data.toByteArray())); + break; + } + } + } } } else if (!m_resourcePath.isEmpty()){ @@ -267,6 +280,19 @@ void ImageItem::setImage(QImage value) } } +ImageItem::Format ImageItem::format() const +{ + return m_format; +} +void ImageItem::setFormat(Format format) +{ + if (m_format!=format){ + Format oldValue = m_format; + m_format=format; + update(); + notify("format",oldValue,format); + } +} } diff --git a/limereport/items/lrimageitem.h b/limereport/items/lrimageitem.h index 631f292..18b236f 100644 --- a/limereport/items/lrimageitem.h +++ b/limereport/items/lrimageitem.h @@ -36,16 +36,24 @@ namespace LimeReport{ class ImageItem : public LimeReport::ItemDesignIntf { Q_OBJECT + Q_ENUMS(Format) Q_PROPERTY(QImage image READ image WRITE setImage) Q_PROPERTY(int opacity READ opacity WRITE setOpacity) Q_PROPERTY(QString datasource READ datasource WRITE setDatasource) Q_PROPERTY(QString field READ field WRITE setField) + Q_PROPERTY(Format format READ format WRITE setFormat) Q_PROPERTY(bool autoSize READ autoSize WRITE setAutoSize) Q_PROPERTY(bool scale READ scale WRITE setScale) Q_PROPERTY(bool keepAspectRatio READ keepAspectRatio WRITE setKeepAspectRatio) Q_PROPERTY(bool center READ center WRITE setCenter) Q_PROPERTY(QString resourcePath READ resourcePath WRITE setResourcePath) public: + enum Format { + Binary = 0, + Hex = 1, + Base64 = 2 + }; + ImageItem(QObject *owner, QGraphicsItem *parent); virtual void paint(QPainter *ppainter, const QStyleOptionGraphicsItem *option, QWidget *widget); void setImage(QImage value); @@ -65,6 +73,8 @@ public: void setKeepAspectRatio(bool keepAspectRatio); bool center() const; void setCenter(bool center); + Format format() const; + void setFormat(Format format); qreal minHeight() const; @@ -82,6 +92,7 @@ private: bool m_scale; bool m_keepAspectRatio; bool m_center; + Format m_format; }; } diff --git a/limereport/items/lrsubitemparentpropitem.cpp b/limereport/items/lrsubitemparentpropitem.cpp index 1b1380c..1587bc9 100644 --- a/limereport/items/lrsubitemparentpropitem.cpp +++ b/limereport/items/lrsubitemparentpropitem.cpp @@ -48,8 +48,8 @@ namespace{ LimeReport::ItemLocationPropItem::ItemLocationPropItem(QObject* object, ObjectsList* objects, const QString &name, const QString &displayName, const QVariant &value, ObjectPropItem* parent, bool readonly) :LimeReport::ObjectPropItem(object, objects, name, displayName, value, parent, readonly){ - m_locationMap.insert("Band",LimeReport::ItemDesignIntf::Band); - m_locationMap.insert("Page",LimeReport::ItemDesignIntf::Page); + m_locationMap.insert(tr("Band"),LimeReport::ItemDesignIntf::Band); + m_locationMap.insert(tr("Page"),LimeReport::ItemDesignIntf::Page); } diff --git a/limereport/items/lrtextitem.cpp b/limereport/items/lrtextitem.cpp index 64e9248..8c01e87 100644 --- a/limereport/items/lrtextitem.cpp +++ b/limereport/items/lrtextitem.cpp @@ -113,16 +113,16 @@ void TextItem::processPopUpAction(QAction *action) this->showEditorDialog(); } if (action->text().compare(tr("Auto height")) == 0){ - setProperty("autoHeight",action->isChecked()); + page()->setPropertyToSelectedItems("autoHeight",action->isChecked()); } if (action->text().compare(tr("Allow HTML")) == 0){ - setProperty("allowHTML",action->isChecked()); + page()->setPropertyToSelectedItems("allowHTML",action->isChecked()); } if (action->text().compare(tr("Allow HTML in fields")) == 0){ - setProperty("allowHTMLInFields",action->isChecked()); + page()->setPropertyToSelectedItems("allowHTMLInFields",action->isChecked()); } if (action->text().compare(tr("Stretch to max height")) == 0){ - setProperty("stretchToMaxHeight",action->isChecked()); + page()->setPropertyToSelectedItems("stretchToMaxHeight",action->isChecked()); } } @@ -576,7 +576,7 @@ void TextItem::setFollowTo(const QString &followTo) QMessageBox::critical( 0, tr("Error"), - tr("TextItem \" %1 \" not found !") + tr("TextItem \" %1 \" not found!") .arg(m_followTo) ); notify("followTo",followTo,""); @@ -777,46 +777,48 @@ bool TextItem::canBeSplitted(int height) const return height > m_firstLineSize; } -QString TextItem::getTextPart(int height, int skipHeight){ - int linesHeight = 0; +QString TextItem::extractText(QTextBlock& curBlock, int height){ int curLine = 0; - int textPos = 0; + int linesHeight = 0; + QString resultText; + for (;curBlock != curBlock.document()->end() || curLine<=curBlock.lineCount(); curBlock = curBlock.next(), curLine = 0, resultText += '\n' ){ + linesHeight+=curBlock.blockFormat().topMargin(); + for (;curLine < curBlock.layout()->lineCount(); curLine++){ + linesHeight += curBlock.layout()->lineAt(curLine).height() + lineSpacing(); + if (height > 0 && linesHeight > (height-borderLineSize() * 2)) {goto loop_exit;} + resultText += curBlock.text().mid(curBlock.layout()->lineAt(curLine).textStart(), + curBlock.layout()->lineAt(curLine).textLength()); + } + } + loop_exit: return resultText; +} - TextPtr text = textDocument(); +QString TextItem::getTextPart(int height, int skipHeight){ - QTextBlock curBlock = text->begin(); QString resultText = ""; + TextPtr text = textDocument(); + text->size().height(); + QTextBlock curBlock = text->begin(); + QTextCursor cursor(text.data()); + cursor.movePosition(QTextCursor::Start); if (skipHeight > 0){ - for (;curBlock != text->end(); curBlock=curBlock.next()){ - for (curLine = 0; curLine < curBlock.layout()->lineCount(); curLine++){ - linesHeight += curBlock.layout()->lineAt(curLine).height() + lineSpacing(); - if (linesHeight > (skipHeight-(/*fakeMarginSize()*2+*/borderLineSize() * 2))) {goto loop_exit;} - } - } - loop_exit:; + resultText = extractText(curBlock, skipHeight); + cursor.movePosition(QTextCursor::Right, QTextCursor::MoveAnchor, resultText.length()); } - linesHeight = 0; + resultText = extractText(curBlock, height); + cursor.movePosition(QTextCursor::Right, QTextCursor::KeepAnchor, resultText.length()); - for (;curBlock != text->end() || curLinelineCount(); curLine++){ - if (resultText == "") textPos= curBlock.layout()->lineAt(curLine).textStart(); - linesHeight += curBlock.layout()->lineAt(curLine).height() + lineSpacing(); - if ( (height>0) && (linesHeight>(height-(/*fakeMarginSize()*2+*/borderLineSize()*2))) ) { - linesHeight-=curBlock.layout()->lineAt(curLine).height(); - goto loop_exit1; - } - resultText+=curBlock.text().mid(curBlock.layout()->lineAt(curLine).textStart(), - curBlock.layout()->lineAt(curLine).textLength()); - } + if (allowHTML()){ + resultText = cursor.selection().toHtml(); + resultText.remove(""); + resultText.remove(""); + } else { + resultText = cursor.selection().toPlainText(); } - loop_exit1:; - resultText.chop(1); - - QScopedPointer context(new HtmlContext(m_strText)); - return context->extendTextByTags(resultText,textPos); + return resultText; } void TextItem::restoreLinksEvent() diff --git a/limereport/items/lrtextitem.h b/limereport/items/lrtextitem.h index 6dc735b..f743d3d 100644 --- a/limereport/items/lrtextitem.h +++ b/limereport/items/lrtextitem.h @@ -181,7 +181,7 @@ private: QString formatDateTime(const QDateTime &value); QString formatNumber(const double value); QString formatFieldValue(); - + QString extractText(QTextBlock& curBlock, int height); TextPtr textDocument() const; private: QString m_strText; @@ -208,6 +208,7 @@ private: TextItem* m_follower; qreal m_textIndent; Qt::LayoutDirection m_textLayoutDirection; + }; } diff --git a/limereport/limereport.pri b/limereport/limereport.pri index 605f96a..d20810d 100644 --- a/limereport/limereport.pri +++ b/limereport/limereport.pri @@ -91,6 +91,10 @@ SOURCES += \ $$REPORT_PATH/lrsettingdialog.cpp \ $$REPORT_PATH/scriptbrowser/lrscriptbrowser.cpp \ $$REPORT_PATH/lritemscontainerdesignitf.cpp + +contains(CONFIG, staticlib){ + SOURCES += $$REPORT_PATH/lrfactoryinitializer.cpp +} contains(CONFIG, zint){ SOURCES += $$REPORT_PATH/items/lrbarcodeitem.cpp @@ -159,6 +163,7 @@ HEADERS += \ $$REPORT_PATH/items/lrshapeitem.h \ $$REPORT_PATH/items/lrimageitem.h \ $$REPORT_PATH/items/lrsimpletagparser.h \ + $$REPORT_PATH/lrfactoryinitializer.h \ $$REPORT_PATH/lrbanddesignintf.h \ $$REPORT_PATH/lrpageitemdesignintf.h \ $$REPORT_PATH/lrbandsmanager.h \ @@ -191,7 +196,11 @@ HEADERS += \ $$REPORT_PATH/lrpreviewreportwidget_p.h \ $$REPORT_PATH/scriptbrowser/lrscriptbrowser.h \ $$REPORT_PATH/lritemscontainerdesignitf.h - + +contains(CONFIG, staticlib){ + HEADERS += $$REPORT_PATH/lrfactoryinitializer.h +} + contains(CONFIG,zint){ HEADERS += $$REPORT_PATH/items/lrbarcodeitem.h } @@ -209,8 +218,6 @@ FORMS += \ $$REPORT_PATH/lrsettingdialog.ui \ $$REPORT_PATH/scriptbrowser/lrscriptbrowser.ui \ - - RESOURCES += \ $$REPORT_PATH/objectinspector/lobjectinspector.qrc \ $$REPORT_PATH/databrowser/lrdatabrowser.qrc \ diff --git a/limereport/limereport.pro b/limereport/limereport.pro index 45f42c1..b05ac00 100644 --- a/limereport/limereport.pro +++ b/limereport/limereport.pro @@ -10,8 +10,15 @@ CONFIG(debug, debug|release) { TEMPLATE = lib -CONFIG += lib -CONFIG += dll +contains(CONFIG, static_build){ + CONFIG += staticlib +} + +!contains(CONFIG, staticlib){ + CONFIG += lib + CONFIG += dll +} + CONFIG += create_prl CONFIG += link_prl @@ -23,6 +30,12 @@ macx{ DEFINES += LIMEREPORT_EXPORTS +contains(CONFIG, staticlib){ + DEFINES += HAVE_STATIC_BUILD + message(STATIC_BUILD) + DEFINES -= LIMEREPORT_EXPORTS +} + EXTRA_FILES += \ $$PWD/lrglobal.cpp \ $$PWD/lrglobal.h \ @@ -83,7 +96,7 @@ contains(CONFIG,zint){ ####Automatically build required translation files (*.qm) contains(CONFIG,build_translations){ - LANGUAGES = ru es_ES ar + LANGUAGES = ru es_ES ar fr zh defineReplace(prependAll) { for(a,$$1):result += $$2$${a}$$3 diff --git a/limereport/lrbanddesignintf.cpp b/limereport/lrbanddesignintf.cpp index f4a1cf9..6ca39be 100644 --- a/limereport/lrbanddesignintf.cpp +++ b/limereport/lrbanddesignintf.cpp @@ -99,6 +99,11 @@ void BandMarker::mousePressEvent(QGraphicsSceneMouseEvent *event) } } +void BandMarker::contextMenuEvent(QGraphicsSceneContextMenuEvent *event) +{ + m_band->contextMenuEvent(event); +} + BandDesignIntf::BandDesignIntf(BandsType bandType, const QString &xmlTypeName, QObject* owner, QGraphicsItem *parent) : ItemsContainerDesignInft(xmlTypeName, owner,parent), m_bandType(bandType), @@ -122,7 +127,8 @@ BandDesignIntf::BandDesignIntf(BandsType bandType, const QString &xmlTypeName, Q m_startNewPage(false), m_startFromNewPage(false), m_printAlways(false), - m_repeatOnEachRow(false) + m_repeatOnEachRow(false), + m_bottomSpace() { setPossibleResizeDirectionFlags(ResizeBottom); setPossibleMoveFlags(TopBotom); @@ -145,6 +151,8 @@ BandDesignIntf::BandDesignIntf(BandsType bandType, const QString &xmlTypeName, Q m_bandNameLabel->setVisible(false); if (scene()) scene()->addItem(m_bandNameLabel); m_alternateBackgroundColor = backgroundColor(); + connect(this, SIGNAL(propertyObjectNameChanged(QString, QString)), + this, SLOT(slotPropertyObjectNameChanged(const QString&,const QString&))); } BandDesignIntf::~BandDesignIntf() @@ -159,6 +167,21 @@ BandDesignIntf::~BandDesignIntf() delete m_bandNameLabel; } +int extractItemIndex(const BaseDesignIntf* item){ + QString objectName = extractClassName(item->metaObject()->className()); + QString value = item->objectName().right(item->objectName().size() - objectName.size()); + return value.toInt(); +} + +QString BandDesignIntf::translateBandName(const BaseDesignIntf* item) const{ + QString defaultBandName = extractClassName(item->metaObject()->className()).toLatin1()+QString::number(extractItemIndex(item)); + if (item->objectName().compare(defaultBandName) == 0){ + return tr(extractClassName(item->metaObject()->className()).toLatin1())+QString::number(extractItemIndex(item)); + } else { + return item->objectName(); + } +} + void BandDesignIntf::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) { @@ -170,8 +193,7 @@ void BandDesignIntf::paint(QPainter *painter, const QStyleOptionGraphicsItem *op if (itemMode() & DesignMode){ painter->save(); - QString bandText = objectName(); - if (parentBand()) bandText+=QLatin1String(" connected to ")+parentBand()->objectName(); + QString bandText = bandTitle(); QFont font("Arial", 7 * Const::fontFACTOR, -1, true); QFontMetrics fontMetrics(font); @@ -202,6 +224,23 @@ void BandDesignIntf::paint(QPainter *painter, const QStyleOptionGraphicsItem *op BaseDesignIntf::paint(painter,option,widget); } +void BandDesignIntf::translateBandsName() +{ + tr("DataBand"); + tr("DataHeaderBand"); + tr("DataFooterBand"); + tr("ReportHeader"); + tr("ReportFooter"); + tr("PageHeader"); + tr("PageFooter"); + tr("SubDetailBand"); + tr("SubDetailHeaderBand"); + tr("SubDetailFooterBand"); + tr("GroupBandHeader"); + tr("GroupBandFooter"); + tr("TearOffBand"); +} + BandDesignIntf::BandsType BandDesignIntf::bandType() const { return m_bandType; @@ -209,8 +248,8 @@ BandDesignIntf::BandsType BandDesignIntf::bandType() const QString BandDesignIntf::bandTitle() const { - QString result = objectName(); - if (parentBand()) result +=tr(" connected to ")+parentBand()->objectName(); + QString result = translateBandName(this); + if (parentBand()) result +=tr(" connected to ") + translateBandName(parentBand()); return result; } @@ -229,9 +268,15 @@ void BandDesignIntf::setBandIndex(int value) m_bandIndex=value; } -void BandDesignIntf::changeBandIndex(int value) +void BandDesignIntf::changeBandIndex(int value, bool firstTime) { - int indexOffset = value - m_bandIndex; + int indexOffset; + + if (firstTime && bandHeader()) + value += 1; + + indexOffset = value - m_bandIndex; + foreach(BandDesignIntf* band, childBands()){ int newIndex = band->bandIndex()+indexOffset; band->changeBandIndex(newIndex); @@ -252,6 +297,14 @@ void BandDesignIntf::setDataSourceName(const QString &datasource){ m_dataSourceName=datasource; } +void BandDesignIntf::setKeepBottomSpaceOption(bool value){ + if (m_keepBottomSpace!=value){ + m_keepBottomSpace=value; + if (!isLoading()) + notify("keepBottomSpace",!value,value); + } +} + void BandDesignIntf::addChildBand(BandDesignIntf *band) { m_childBands.append(band); @@ -293,6 +346,16 @@ bool BandDesignIntf::isConnectedToBand(BandDesignIntf::BandsType bandType) const return false; } +int BandDesignIntf::maxChildIndex(BandDesignIntf::BandsType bandType) const{ + int curIndex = bandIndex(); + foreach(BandDesignIntf* childBand, childBands()){ + if ( (childBand->bandIndex() > bandIndex()) && (childBand->bandType() < bandType) ){ + curIndex = std::max(curIndex,childBand->maxChildIndex()); + } + } + return curIndex; +} + int BandDesignIntf::maxChildIndex(QSet ignoredBands) const{ int curIndex = bandIndex(); foreach(BandDesignIntf* childBand, childBands()){ @@ -416,13 +479,25 @@ void BandDesignIntf::preparePopUpMenu(QMenu &menu) } menu.addSeparator(); - QAction* autoHeightAction = menu.addAction(tr("Auto height")); - autoHeightAction->setCheckable(true); - autoHeightAction->setChecked(autoHeight()); + QAction* currAction = menu.addAction(tr("Auto height")); + currAction->setCheckable(true); + currAction->setChecked(autoHeight()); - QAction* autoSplittableAction = menu.addAction(tr("Splittable")); - autoSplittableAction->setCheckable(true); - autoSplittableAction->setChecked(isSplittable()); + currAction = menu.addAction(tr("Splittable")); + currAction->setCheckable(true); + currAction->setChecked(isSplittable()); + + currAction = menu.addAction(tr("Keep bottom space")); + currAction->setCheckable(true); + currAction->setChecked(keepBottomSpaceOption()); + + currAction = menu.addAction(tr("Start from new page")); + currAction->setCheckable(true); + currAction->setChecked(startFromNewPage()); + + currAction = menu.addAction(tr("Start new page")); + currAction->setCheckable(true); + currAction->setChecked(startNewPage()); } void BandDesignIntf::processPopUpAction(QAction *action) @@ -433,13 +508,23 @@ void BandDesignIntf::processPopUpAction(QAction *action) if (action->text().compare(tr("Splittable")) == 0){ setProperty("splittable",action->isChecked()); } + if (action->text().compare(tr("Keep bottom space")) == 0){ + setProperty("keepBottomSpace",action->isChecked()); + } + if (action->text().compare(tr("Start new page")) == 0){ + setProperty("startNewPage",action->isChecked()); + } + if (action->text().compare(tr("Start from new page")) == 0){ + setProperty("startFromNewPage",action->isChecked()); + } } BaseDesignIntf* BandDesignIntf::cloneUpperPart(int height, QObject *owner, QGraphicsItem *parent) { int maxBottom = 0; BandDesignIntf* upperPart = dynamic_cast(createSameTypeItem(owner,parent)); - BaseDesignIntf* upperItem; + upperPart->m_bottomSpace = this->bottomSpace(); + BaseDesignIntf* upperItem = 0; upperPart->initFromItem(this); @@ -485,6 +570,7 @@ bool itemLessThen(QGraphicsItem* i1, QGraphicsItem* i2){ BaseDesignIntf *BandDesignIntf::cloneBottomPart(int height, QObject *owner, QGraphicsItem *parent) { BandDesignIntf* bottomPart = dynamic_cast(createSameTypeItem(owner,parent)); + bottomPart->m_bottomSpace = this->bottomSpace(); bottomPart->initFromItem(this); QList bandItems; @@ -497,30 +583,28 @@ BaseDesignIntf *BandDesignIntf::cloneBottomPart(int height, QObject *owner, QGra if (item){ if (item->geometry().top()>height){ BaseDesignIntf* tmpItem = item->cloneItem(item->itemMode(),bottomPart,bottomPart); - tmpItem->setPos(tmpItem->pos().x(),tmpItem->pos().y()-height); + tmpItem->setPos(tmpItem->pos().x(), (tmpItem->pos().y()-height)+borderLineSize()); } else if ((item->geometry().top()geometry().bottom()>height)){ int sliceHeight = height-item->geometry().top(); - if (item->canBeSplitted(sliceHeight)) { + if (item->isSplittable() && item->canBeSplitted(sliceHeight)) { BaseDesignIntf* tmpItem=item->cloneBottomPart(sliceHeight,bottomPart,bottomPart); - tmpItem->setPos(tmpItem->pos().x(),0); - if (tmpItem->pos().y()<0) tmpItem->setPos(tmpItem->pos().x(),0); - qreal sizeOffset = (m_slicedItems.value(tmpItem->objectName())->height()+tmpItem->height()) - item->height(); - qreal bottomOffset = (height - m_slicedItems.value(tmpItem->objectName())->pos().y())-m_slicedItems.value(tmpItem->objectName())->height(); - moveItemsDown(item->pos().y()+item->height(), sizeOffset + bottomOffset); - } - else if (item->isSplittable()){ - BaseDesignIntf* tmpItem = item->cloneItem(item->itemMode(),bottomPart,bottomPart); - tmpItem->setPos(tmpItem->pos().x(),0); + tmpItem->setPos(tmpItem->pos().x(),borderLineSize()); + BaseDesignIntf* slicedItem = m_slicedItems.value(tmpItem->objectName()); + if (slicedItem){ + qreal sizeOffset = (slicedItem->height()+tmpItem->height()) - item->height(); + qreal bottomOffset = (height - slicedItem->pos().y())-m_slicedItems.value(tmpItem->objectName())->height(); + moveItemsDown(item->pos().y()+item->height(), sizeOffset + bottomOffset); + } } else { if ((item->geometry().bottom()-height)>height){ BaseDesignIntf* tmpItem = item->cloneItem(item->itemMode(),bottomPart,bottomPart); - tmpItem->setPos(tmpItem->pos().x(),0); + tmpItem->setPos(tmpItem->pos().x(),borderLineSize()); tmpItem->setHeight((this->height()-height)); } else { BaseDesignIntf* tmpItem = item->cloneEmpty((this->height()-height),bottomPart,bottomPart); if (tmpItem) - tmpItem->setPos(tmpItem->pos().x(),0); + tmpItem->setPos(tmpItem->pos().x(),borderLineSize()); } } } @@ -570,7 +654,7 @@ void BandDesignIntf::trimToMaxHeight(int maxHeight) void BandDesignIntf::setBandTypeText(const QString &value){ m_bandTypeText=value; - m_bandNameLabel->updateLabel(); + m_bandNameLabel->updateLabel(bandTitle()); } QSet BandDesignIntf::groupBands() @@ -628,7 +712,7 @@ QVariant BandDesignIntf::itemChange(QGraphicsItem::GraphicsItemChange change, co m_bandMarker->update(0,0, m_bandMarker->boundingRect().width(), m_bandMarker->boundingRect().width()); - m_bandNameLabel->updateLabel(); + m_bandNameLabel->updateLabel(bandTitle()); m_bandNameLabel->setVisible(value.toBool()); } @@ -682,6 +766,18 @@ void BandDesignIntf::setAlternateBackgroundColor(const QColor &alternateBackgrou m_alternateBackgroundColor = alternateBackgroundColor; } +qreal BandDesignIntf::bottomSpace() const +{ + return m_bottomSpace.isValid() ? m_bottomSpace.value() : height()-findMaxBottom(); +} + +void BandDesignIntf::slotPropertyObjectNameChanged(const QString &, const QString& newName) +{ + update(); + if (m_bandNameLabel) + m_bandNameLabel->updateLabel(newName); +} + bool BandDesignIntf::repeatOnEachRow() const { return m_repeatOnEachRow; @@ -709,7 +805,11 @@ bool BandDesignIntf::startFromNewPage() const void BandDesignIntf::setStartFromNewPage(bool startWithNewPage) { - m_startFromNewPage = startWithNewPage; + if (m_startFromNewPage != startWithNewPage){ + m_startFromNewPage = startWithNewPage; + if (!isLoading()) + notify("startFromNewPage", !startWithNewPage, startWithNewPage); + } } bool BandDesignIntf::startNewPage() const @@ -719,7 +819,11 @@ bool BandDesignIntf::startNewPage() const void BandDesignIntf::setStartNewPage(bool startNewPage) { - m_startNewPage = startNewPage; + if (m_startNewPage != startNewPage){ + m_startNewPage = startNewPage; + if (!isLoading()) + notify("startNewPage", !startNewPage, startNewPage); + } } void BandDesignIntf::setAutoHeight(bool value){ @@ -816,7 +920,8 @@ void BandDesignIntf::setKeepFooterTogether(bool value) void BandDesignIntf::updateItemSize(DataSourceManager* dataManager, RenderPass pass, int maxHeight) { qreal spaceBorder=0; - if (keepBottomSpaceOption()) spaceBorder=height()-findMaxBottom(); + if (keepBottomSpaceOption()) spaceBorder = bottomSpace(); + spaceBorder = spaceBorder>0 ? spaceBorder : 0; if (borderLines()!=0){ spaceBorder += borderLineSize(); } @@ -836,7 +941,7 @@ void BandDesignIntf::updateItemSize(DataSourceManager* dataManager, RenderPass p void BandDesignIntf::updateBandNameLabel() { - if (m_bandNameLabel) m_bandNameLabel->updateLabel(); + if (m_bandNameLabel) m_bandNameLabel->updateLabel(bandTitle()); } QColor BandDesignIntf::selectionColor() const @@ -879,7 +984,7 @@ QRectF BandNameLabel::boundingRect() const return m_rect; } -void BandNameLabel::updateLabel() +void BandNameLabel::updateLabel(const QString& bandName) { QFont font("Arial",7*Const::fontFACTOR,-1,true); QFontMetrics fontMetrics(font); @@ -887,7 +992,7 @@ void BandNameLabel::updateLabel() m_rect = QRectF( m_band->pos().x()+10, m_band->pos().y()-(fontMetrics.height()+10), - fontMetrics.width(m_band->bandTitle())+20,fontMetrics.height()+10 + fontMetrics.width(bandName)+20,fontMetrics.height()+10 ); update(); } diff --git a/limereport/lrbanddesignintf.h b/limereport/lrbanddesignintf.h index e588385..5f56beb 100644 --- a/limereport/lrbanddesignintf.h +++ b/limereport/lrbanddesignintf.h @@ -63,6 +63,7 @@ public: qreal height(){return m_rect.height();} protected: void mousePressEvent(QGraphicsSceneMouseEvent *event); + void contextMenuEvent(QGraphicsSceneContextMenuEvent *event); private: QRectF m_rect; QColor m_color; @@ -74,7 +75,7 @@ public: explicit BandNameLabel(BandDesignIntf* band, QGraphicsItem* parent=0); void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget); QRectF boundingRect() const; - void updateLabel(); + void updateLabel(const QString &bandName); void hoverEnterEvent(QGraphicsSceneHoverEvent *event); private: QRectF m_rect; @@ -82,6 +83,18 @@ private: BandDesignIntf* m_band; }; +class InitializedValue{ +public: + InitializedValue(): m_value(-1), m_isInitialized(false){} + InitializedValue(qreal value): m_value(value), m_isInitialized(true){} + qreal value() const { return m_value;} + void setValue( qreal value){ m_value = value; m_isInitialized = true;} + bool isValid() const{ return m_isInitialized;} +private: + qreal m_value; + bool m_isInitialized; +}; + class BandDesignIntf : public ItemsContainerDesignInft { Q_OBJECT @@ -121,6 +134,7 @@ public: ~BandDesignIntf(); void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget); + void translateBandsName(); virtual BandsType bandType() const; virtual QString bandTitle() const; virtual QIcon bandIcon() const; @@ -131,13 +145,13 @@ public: virtual QColor selectionColor() const; int bandIndex() const; void setBandIndex(int value); - void changeBandIndex(int value); + void changeBandIndex(int value, bool firstTime = false); void setBandType(BandsType value){m_bandType=value;} QString datasourceName(); void setDataSourceName(const QString& datasourceName); - void setKeepBottomSpaceOption(bool value){m_keepBottomSpace=value;} + void setKeepBottomSpaceOption(bool value); bool keepBottomSpaceOption() const {return m_keepBottomSpace;} void addChildBand(BandDesignIntf* band); @@ -151,8 +165,10 @@ public: bool isConnectedToBand(BandDesignIntf::BandsType bandType) const; int minChildIndex(BandsType bandType); + int maxChildIndex(BandDesignIntf::BandsType bandType) const; int maxChildIndex(QSet ignoredBands = QSet()) const; + BandDesignIntf* parentBand() const {return m_parentBand;} QList childBands() const{return m_childBands;} @@ -165,6 +181,7 @@ public: virtual bool isHeader() const {return false;} virtual bool isGroupHeader() const {return false;} virtual bool isData() const {return false;} + virtual int bandNestingLevel(){return 0;} bool isBand(){return true;} void setTryToKeepTogether(bool value); @@ -217,9 +234,9 @@ public: void setRepeatOnEachRow(bool repeatOnEachRow); QColor alternateBackgroundColor() const; void setAlternateBackgroundColor(const QColor &alternateBackgroundColor); - + qreal bottomSpace() const; signals: - void bandRendered(BandDesignIntf* band); + void bandRendered(BandDesignIntf* band); protected: void trimToMaxHeight(int maxHeight); void setBandTypeText(const QString& value); @@ -240,8 +257,10 @@ protected: void moveItemsDown(qreal startPos, qreal offset); void preparePopUpMenu(QMenu &menu); void processPopUpAction(QAction *action); + QString translateBandName(const BaseDesignIntf *item) const; private slots: void childBandDeleted(QObject* band); + void slotPropertyObjectNameChanged(const QString&,const QString&); private: QString m_bandTypeText; BandsType m_bandType; @@ -270,7 +289,8 @@ private: bool m_printAlways; bool m_repeatOnEachRow; QMap m_slicedItems; - QColor m_alternateBackgroundColor; + QColor m_alternateBackgroundColor; + InitializedValue m_bottomSpace; }; class DataBandDesignIntf : public BandDesignIntf{ diff --git a/limereport/lrbasedesignintf.cpp b/limereport/lrbasedesignintf.cpp index bdba630..e5591ed 100644 --- a/limereport/lrbasedesignintf.cpp +++ b/limereport/lrbasedesignintf.cpp @@ -628,10 +628,10 @@ QPointF BaseDesignIntf::modifyPosForAlignedItem(const QPointF& pos){ result.setX(leftBorder); break; case RightItemAlign: - result.setX(parent->width()-rightBorder); + result.setX(parent->width() - (rightBorder + width())); break; case CenterItemAlign: - result.setX((avaibleSpace-width())/2); + result.setX((avaibleSpace-width()) / 2 + leftBorder); break; case ParentWidthItemAlign: result.setX(leftBorder); @@ -1008,6 +1008,7 @@ QVariant BaseDesignIntf::itemChange(QGraphicsItem::GraphicsItemChange change, co } if (change == QGraphicsItem::ItemSelectedChange) { turnOnSelectionMarker(value.toBool()); + emit itemSelectedHasBeenChanged(this, value.toBool()); } if (change == QGraphicsItem::ItemParentHasChanged) { parentChangedEvent(dynamic_cast(value.value())); @@ -1152,6 +1153,7 @@ void BaseDesignIntf::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event) void BaseDesignIntf::contextMenuEvent(QGraphicsSceneContextMenuEvent *event) { + if (!(flags() & QGraphicsItem::ItemIsSelectable)) return; PageDesignIntf* page = dynamic_cast(scene()); if (!page->selectedItems().contains(this)){ page->clearSelection(); diff --git a/limereport/lrbasedesignintf.h b/limereport/lrbasedesignintf.h index e722598..ecced96 100644 --- a/limereport/lrbasedesignintf.h +++ b/limereport/lrbasedesignintf.h @@ -341,7 +341,6 @@ protected: virtual void preparePopUpMenu(QMenu& menu){Q_UNUSED(menu)} virtual void processPopUpAction(QAction* action){Q_UNUSED(action)} - private: void updateSelectionMarker(); int resizeDirectionFlags(QPointF position); @@ -401,6 +400,7 @@ signals: void geometryChanged(QObject* object, QRectF newGeometry, QRectF oldGeometry); void posChanged(QObject* object, QPointF newPos, QPointF oldPos); void itemSelected(LimeReport::BaseDesignIntf *item); + void itemSelectedHasBeenChanged(BaseDesignIntf *item, bool value); void loadCollectionFinished(const QString& collectionName); void objectLoaded(QObject* object); void objectChanged(QObject* object); diff --git a/limereport/lrdatadesignintf.cpp b/limereport/lrdatadesignintf.cpp index 37b3d4c..18e0d49 100644 --- a/limereport/lrdatadesignintf.cpp +++ b/limereport/lrdatadesignintf.cpp @@ -57,21 +57,21 @@ IDataSource * ModelHolder::dataSource(IDataSource::DatasourceMode mode) } QueryHolder::QueryHolder(QString queryText, QString connectionName, DataSourceManager *dataManager) - : m_query(0), m_queryText(queryText), m_connectionName(connectionName), + : m_queryText(queryText), m_connectionName(connectionName), m_mode(IDataSource::RENDER_MODE), m_dataManager(dataManager), m_prepared(true) { extractParams(); } -QueryHolder::~QueryHolder() -{ - if (m_query) delete m_query; -} +QueryHolder::~QueryHolder(){} bool QueryHolder::runQuery(IDataSource::DatasourceMode mode) { m_mode = mode; + QSqlDatabase db = QSqlDatabase::database(m_connectionName); + QSqlQuery query(db); + if (!db.isValid()) { setLastError(QObject::tr("Invalid connection! %1").arg(m_connectionName)); return false; @@ -82,16 +82,12 @@ bool QueryHolder::runQuery(IDataSource::DatasourceMode mode) if (!m_prepared) return false; } - if (!m_query){ - m_query = new QSqlQuery(db); - m_query->prepare(m_preparedSQL); - } - - fillParams(m_query); - m_query->exec(); + query.prepare(m_preparedSQL); + fillParams(&query); + query.exec(); QSqlQueryModel *model = new QSqlQueryModel; - model->setQuery(*m_query); + model->setQuery(query); while (model->canFetchMore()) model->fetchMore(); @@ -102,7 +98,7 @@ bool QueryHolder::runQuery(IDataSource::DatasourceMode mode) setLastError(model->lastError().text()); delete model; return false; - } else setLastError(""); + } else { setLastError("");} setDatasource(IDataSource::Ptr(new ModelToDataSource(model,true))); return true; @@ -118,11 +114,10 @@ void QueryHolder::setConnectionName(QString connectionName) m_connectionName=connectionName; } -void QueryHolder::invalidate(IDataSource::DatasourceMode mode){ +void QueryHolder::invalidate(IDataSource::DatasourceMode mode, bool dbWillBeClosed){ QSqlDatabase db = QSqlDatabase::database(m_connectionName); - if (!db.isValid()){ + if (!db.isValid() || dbWillBeClosed){ setLastError(QObject::tr("Invalid connection! %1").arg(m_connectionName)); - delete m_query; m_dataSource.clear(); } else { runQuery(mode); @@ -197,10 +192,6 @@ void QueryHolder::setQueryText(QString queryText) { m_queryText=queryText; m_prepared = false; - if (m_query) { - delete m_query; - m_query = 0; - } } IDataSource* QueryHolder::dataSource(IDataSource::DatasourceMode mode) @@ -350,13 +341,13 @@ void ModelToDataSource::slotModelDestroed() ConnectionDesc::ConnectionDesc(QSqlDatabase db, QObject *parent) : QObject(parent), m_connectionName(db.connectionName()), m_connectionHost(db.hostName()), m_connectionDriver(db.driverName()), - m_databaseName(db.databaseName()), m_user(db.userName()), m_password(db.password()), m_autoconnect(false), + m_databaseName(db.databaseName()), m_user(db.userName()), m_password(db.password()), m_port(-1), m_autoconnect(false), m_internal(false), m_keepDBCredentials(true) {} ConnectionDesc::ConnectionDesc(QObject *parent) - :QObject(parent),m_connectionName(""),m_connectionHost(""),m_connectionDriver(""), - m_databaseName(""), m_user(""), m_password(""), m_autoconnect(false), + :QObject(parent),m_connectionName(""),m_connectionHost(""), m_connectionDriver(""), + m_databaseName(""), m_user(""), m_password(""), m_port(-1), m_autoconnect(false), m_internal(false), m_keepDBCredentials(true) {} @@ -391,6 +382,16 @@ QString ConnectionDesc::connectionNameForReport(const QString &connectionName) return connectionName.compare(tr("defaultConnection")) == 0 ? QSqlDatabase::defaultConnection : connectionName; } +int ConnectionDesc::port() const +{ + return m_port; +} + +void ConnectionDesc::setPort(int port) +{ + m_port = port; +} + bool ConnectionDesc::keepDBCredentials() const { return m_keepDBCredentials; @@ -421,7 +422,7 @@ void SubQueryHolder::setMasterDatasource(const QString &value) void SubQueryHolder::extractParams() { if (!dataManager()->containsDatasource(m_masterDatasource)){ - setLastError(QObject::tr("Master datasource \"%1\" not found!!!").arg(m_masterDatasource)); + setLastError(QObject::tr("Master datasource \"%1\" not found!").arg(m_masterDatasource)); setPrepared(false); } else { m_preparedSQL = replaceFields(replaceVariables(queryText())); @@ -552,9 +553,10 @@ IDataSource *ProxyHolder::dataSource(IDataSource::DatasourceMode mode) return m_datasource.data(); } -void ProxyHolder::invalidate(IDataSource::DatasourceMode mode) +void ProxyHolder::invalidate(IDataSource::DatasourceMode mode, bool dbWillBeClosed) { Q_UNUSED(mode) + Q_UNUSED(dbWillBeClosed); if (m_model && m_model->isInvalid()){ m_invalid = true; m_lastError = tr("Datasource has been invalidated"); @@ -638,11 +640,26 @@ QVariant MasterDetailProxyModel::masterData(QString fieldName) const bool CallbackDatasource::next(){ if (!m_eof){ + bool nextRowExists = checkNextRecord(m_currentRow); + if (m_currentRow>-1){ + if (!m_getDataFromCache && nextRowExists){ + for (int i = 0; i < m_columnCount; ++i ){ + m_valuesCache[columnNameByIndex(i)] = data(columnNameByIndex(i)); + } + + } + } + if (!nextRowExists){ + m_eof = true; + return false; + } m_currentRow++; - bool result = false; - emit changePos(CallbackInfo::Next,result); + bool result = true; + if (!m_getDataFromCache) + emit changePos(CallbackInfo::Next,result); + m_getDataFromCache = false; if (m_rowCount != -1){ - if (m_rowCount>0 && m_currentRow 0 && m_currentRow < m_rowCount){ m_eof = false; } else { m_eof = true; @@ -655,6 +672,21 @@ bool CallbackDatasource::next(){ } else return false; } +bool CallbackDatasource::prior(){ + if (m_currentRow !=-1) { + if (!m_getDataFromCache && !m_valuesCache.isEmpty()){ + m_getDataFromCache = true; + m_currentRow--; + m_eof = false; + return true; + } else { + return false; + } + } else { + return false; + } +} + void CallbackDatasource::first(){ m_currentRow = 0; m_eof=checkIfEmpty(); @@ -673,12 +705,19 @@ void CallbackDatasource::first(){ QVariant CallbackDatasource::data(const QString& columnName) { - CallbackInfo info; - info.dataType = CallbackInfo::ColumnData; - info.columnName = columnName; - info.index = m_currentRow; QVariant result; - emit getCallbackData(info,result); + if (!bof()) + { + if (!m_getDataFromCache){ + CallbackInfo info; + info.dataType = CallbackInfo::ColumnData; + info.columnName = columnName; + info.index = m_currentRow; + emit getCallbackData(info,result); + } else { + result = m_valuesCache[columnName]; + } + } return result; } @@ -728,7 +767,7 @@ QString CallbackDatasource::columnNameByIndex(int columnIndex) int CallbackDatasource::columnIndexByName(QString name) { for (int i=0;i0 && m_currentRow 0) { + return (m_currentRow < (m_rowCount-1)); } else { QVariant result = false; CallbackInfo info; @@ -762,7 +802,10 @@ bool CallbackDatasource::checkIfEmpty(){ CallbackInfo info; info.dataType = CallbackInfo::RowCount; emit getCallbackData(info, recordCount); - if (recordCount.toInt()>0) return false; + if (recordCount.toInt()>0) { + m_rowCount = recordCount.toInt(); + return false; + } info.dataType = CallbackInfo::IsEmpty; emit getCallbackData(info,isEmpty); return isEmpty.toBool(); diff --git a/limereport/lrdatadesignintf.h b/limereport/lrdatadesignintf.h index e2f8134..0e77ae8 100644 --- a/limereport/lrdatadesignintf.h +++ b/limereport/lrdatadesignintf.h @@ -74,7 +74,7 @@ public: virtual bool isOwned() const = 0; virtual bool isEditable() const = 0; virtual bool isRemovable() const = 0; - virtual void invalidate(IDataSource::DatasourceMode mode) = 0; + virtual void invalidate(IDataSource::DatasourceMode mode, bool dbWillBeClosed = false) = 0; virtual void update() = 0; virtual void clearErrors() = 0; virtual ~IDataSourceHolder(){} @@ -91,7 +91,7 @@ public: QString lastError() const { return m_dataSource->lastError(); } bool isEditable() const { return false; } bool isRemovable() const { return false; } - void invalidate(IDataSource::DatasourceMode mode){Q_UNUSED(mode)} + void invalidate(IDataSource::DatasourceMode mode, bool dbWillBeClosed = false){Q_UNUSED(mode) Q_UNUSED(dbWillBeClosed)} void update(){} void clearErrors(){} signals: @@ -111,6 +111,7 @@ class ConnectionDesc : public QObject{ Q_PROPERTY(QString host READ host WRITE setHost) Q_PROPERTY(bool autoconnect READ autoconnect WRITE setAutoconnect) Q_PROPERTY(bool keepDBCredentials READ keepDBCredentials WRITE setKeepDBCredentials) + Q_PROPERTY(int port READ port WRITE setPort) public: typedef QSharedPointer Ptr; ConnectionDesc(QSqlDatabase db, QObject* parent=0); @@ -135,6 +136,8 @@ public: void setInternal(bool value) {m_internal = value;} bool keepDBCredentials() const; void setKeepDBCredentials(bool keepDBCredentials); + int port() const; + void setPort(int port); public: static QString connectionNameForUser(const QString& connectionName); static QString connectionNameForReport(const QString& connectionName); @@ -147,6 +150,7 @@ private: QString m_databaseName; QString m_user; QString m_password; + int m_port; bool m_autoconnect; bool m_internal; bool m_keepDBCredentials; @@ -199,8 +203,8 @@ public: bool isRemovable() const { return true; } bool isPrepared() const {return m_prepared;} QString lastError() const { return m_lastError; } - void setLastError(QString value){m_lastError=value; if (m_query) {delete m_query; m_query=0;}} - void invalidate(IDataSource::DatasourceMode mode); + void setLastError(QString value){m_lastError=value;} + void invalidate(IDataSource::DatasourceMode mode, bool dbWillBeClosed = false); void update(); void clearErrors(){setLastError("");} DataSourceManager* dataManager() const {return m_dataManager;} @@ -211,7 +215,6 @@ protected: virtual void extractParams(); QString replaceVariables(QString query); QMap m_aliasesToParam; - QSqlQuery* m_query; QString m_preparedSQL; private: QString m_queryText; @@ -330,7 +333,7 @@ public: bool isEditable() const { return true; } bool isRemovable() const { return true; } QString lastError() const { return m_lastError; } - void invalidate(IDataSource::DatasourceMode mode); + void invalidate(IDataSource::DatasourceMode mode, bool dbWillBeClosed = false); void update(){} void clearErrors(){m_lastError = "";} DataSourceManager* dataManager() const {return m_dataManger;} @@ -380,10 +383,11 @@ private: class CallbackDatasource :public ICallbackDatasource, public IDataSource { Q_OBJECT public: - CallbackDatasource(): m_currentRow(-1), m_eof(false), m_columnCount(-1), m_rowCount(-1){} + CallbackDatasource(): m_currentRow(-1), m_eof(false), m_columnCount(-1), + m_rowCount(-1), m_getDataFromCache(false){} bool next(); bool hasNext(){ if (!m_eof) return checkNextRecord(m_currentRow); else return false;} - bool prior(){ if (m_currentRow !=-1) {m_currentRow--; return true;} else return false;} + bool prior(); void first(); void last(){} bool bof(){return m_currentRow == -1;} @@ -404,6 +408,8 @@ private: bool m_eof; int m_columnCount; int m_rowCount; + QHash m_valuesCache; + bool m_getDataFromCache; }; class CallbackDatasourceHolder :public QObject, public IDataSourceHolder{ @@ -417,7 +423,7 @@ public: bool isOwned() const {return m_owned;} bool isEditable() const {return false;} bool isRemovable() const {return false;} - void invalidate(IDataSource::DatasourceMode mode){Q_UNUSED(mode)} + void invalidate(IDataSource::DatasourceMode mode, bool dbWillBeClosed = false){Q_UNUSED(mode) Q_UNUSED(dbWillBeClosed)} ~CallbackDatasourceHolder(){delete m_datasource;} void update(){} void clearErrors(){} diff --git a/limereport/lrdatasourcemanager.cpp b/limereport/lrdatasourcemanager.cpp index d35f670..c7950f2 100644 --- a/limereport/lrdatasourcemanager.cpp +++ b/limereport/lrdatasourcemanager.cpp @@ -226,6 +226,18 @@ DataSourceManager::DataSourceManager(QObject *parent) : m_groupFunctionFactory.registerFunctionCreator(QLatin1String("MAX"),new ConstructorGroupFunctionCreator); setSystemVariable(QLatin1String("#PAGE"),1,FirstPass); setSystemVariable(QLatin1String("#PAGE_COUNT"),0,SecondPass); + setSystemVariable(QLatin1String("#IS_LAST_PAGEFOOTER"),false,FirstPass); + setSystemVariable(QLatin1String("#IS_FIRST_PAGEFOOTER"),false,FirstPass); + + connect(&m_reportVariables, SIGNAL(variableHasBeenAdded(QString)), + this, SLOT(slotVariableHasBeenAdded(QString)) ); + connect(&m_reportVariables, SIGNAL(variableHasBeenChanged(QString)), + this, SLOT(slotVariableHasBeenChanged(QString))); + connect(&m_userVariables, SIGNAL(variableHasBeenAdded(QString)), + this, SLOT(slotVariableHasBeenAdded(QString)) ); + connect(&m_userVariables, SIGNAL(variableHasBeenChanged(QString)), + this, SLOT(slotVariableHasBeenChanged(QString))); + m_datasourcesModel.setDataSourceManager(this); } @@ -258,7 +270,11 @@ void DataSourceManager::clearGroupFuntionsExpressions() QString DataSourceManager::getExpression(QString index) { - return m_groupFunctionsExpressions.at(index.toInt()); + bool ok = false; + int i = index.toInt(&ok); + if (ok && m_groupFunctionsExpressions.size()>i) + return m_groupFunctionsExpressions.at(index.toInt()); + else return ""; } bool DataSourceManager::designTime() const @@ -580,7 +596,7 @@ QList& DataSourceManager::conections() bool DataSourceManager::dataSourceIsValid(const QString &name) { if (m_datasources.value(name.toLower())) return !m_datasources.value(name.toLower())->isInvalid(); - else throw ReportError(tr("Datasource \"%1\" not found !").arg(name)); + else throw ReportError(tr("Datasource \"%1\" not found!").arg(name)); } bool DataSourceManager::isQuery(const QString &dataSourceName) @@ -634,15 +650,18 @@ void DataSourceManager::removeConnection(const QString &connectionName) { QList::iterator cit = m_connections.begin(); while( cit != m_connections.end() ){ - if ( ((*cit)->name().compare(connectionName) == 0) && (*cit)->isInternal() ){ + if ( ((*cit)->name().compare(connectionName) == 0) ){ + if ((*cit)->isInternal()) { QSqlDatabase db = QSqlDatabase::database(connectionName); db.close(); } QSqlDatabase::removeDatabase(connectionName); + delete (*cit); + cit = m_connections.erase(cit); + } else { + cit++; } - delete (*cit); - cit = m_connections.erase(cit); } emit datasourcesChanged(); } @@ -660,7 +679,7 @@ void DataSourceManager::addConnectionDesc(ConnectionDesc * connection) } } } else { - throw ReportError(tr("connection with name \"%1\" already exists !").arg(connection->name())); + throw ReportError(tr("Connection with name \"%1\" already exists!").arg(connection->name())); } } @@ -685,7 +704,7 @@ void DataSourceManager::putHolder(const QString& name, IDataSourceHolder *dataSo name.toLower(), dataSource ); - } else throw ReportError(tr("datasource with name \"%1\" already exists !").arg(name)); + } else throw ReportError(tr("Datasource with name \"%1\" already exists!").arg(name)); } void DataSourceManager::putQueryDesc(QueryDesc* queryDesc) @@ -694,7 +713,7 @@ void DataSourceManager::putQueryDesc(QueryDesc* queryDesc) m_queries.append(queryDesc); connect(queryDesc, SIGNAL(queryTextChanged(QString,QString)), this, SLOT(slotQueryTextChanged(QString,QString))); - } else throw ReportError(tr("datasource with name \"%1\" already exists !").arg(queryDesc->queryName())); + } else throw ReportError(tr("Datasource with name \"%1\" already exists!").arg(queryDesc->queryName())); } void DataSourceManager::putSubQueryDesc(SubQueryDesc *subQueryDesc) @@ -703,14 +722,14 @@ void DataSourceManager::putSubQueryDesc(SubQueryDesc *subQueryDesc) m_subqueries.append(subQueryDesc); connect(subQueryDesc, SIGNAL(queryTextChanged(QString,QString)), this, SLOT(slotQueryTextChanged(QString,QString))); - } else throw ReportError(tr("datasource with name \"%1\" already exists !").arg(subQueryDesc->queryName())); + } else throw ReportError(tr("Datasource with name \"%1\" already exists!").arg(subQueryDesc->queryName())); } void DataSourceManager::putProxyDesc(ProxyDesc *proxyDesc) { if (!containsDatasource(proxyDesc->name())){ m_proxies.append(proxyDesc); - } else throw ReportError(tr("datasource with name \"%1\" already exists !").arg(proxyDesc->name())); + } else throw ReportError(tr("Datasource with name \"%1\" already exists!").arg(proxyDesc->name())); } bool DataSourceManager::initAndOpenDB(QSqlDatabase& db, ConnectionDesc& connectionDesc){ @@ -721,6 +740,8 @@ bool DataSourceManager::initAndOpenDB(QSqlDatabase& db, ConnectionDesc& connecti db.setHostName(replaceVariables(connectionDesc.host())); db.setUserName(replaceVariables(connectionDesc.userName())); db.setPassword(replaceVariables(connectionDesc.password())); + if (connectionDesc.port()!=-1) + db.setPort(connectionDesc.port()); if (!connectionDesc.keepDBCredentials() && m_dbCredentialsProvider){ if (!m_dbCredentialsProvider->getUserName(connectionDesc.name()).isEmpty()) @@ -942,7 +963,7 @@ IDataSource *DataSourceManager::dataSource(const QString &name) return holder->dataSource(designTime()?IDataSource::DESIGN_MODE:IDataSource::RENDER_MODE); } } else { - setLastError(tr("Datasource \"%1\" not found !").arg(name)); + setLastError(tr("Datasource \"%1\" not found!").arg(name)); return 0; } } @@ -1229,6 +1250,32 @@ void DataSourceManager::slotQueryTextChanged(const QString &queryName, const QSt } } +void DataSourceManager::invalidateQueriesContainsVariable(const QString& variableName) +{ + if (!variableIsSystem(variableName)){ + foreach (const QString& datasourceName, dataSourceNames()){ + QueryHolder* holder = dynamic_cast(m_datasources.value(datasourceName)); + if (holder){ + QRegExp rx(QString(Const::NAMED_VARIABLE_RX).arg(variableName)); + if (holder->queryText().contains(rx)) + holder->invalidate(designTime()?IDataSource::DESIGN_MODE:IDataSource::RENDER_MODE); + } + } + } +} + +void DataSourceManager::slotVariableHasBeenAdded(const QString& variableName) +{ + //qDebug()<< "variable has been added"<< variableName; + invalidateQueriesContainsVariable(variableName); +} + +void DataSourceManager::slotVariableHasBeenChanged(const QString& variableName) +{ + //qDebug()<< "variable has been changed"<< variableName; + invalidateQueriesContainsVariable(variableName); +} + void DataSourceManager::clear(ClearMethod method) { DataSourcesMap::iterator dit; diff --git a/limereport/lrdatasourcemanager.h b/limereport/lrdatasourcemanager.h index ea77064..fabb694 100644 --- a/limereport/lrdatasourcemanager.h +++ b/limereport/lrdatasourcemanager.h @@ -224,9 +224,12 @@ protected: void setLastError(const QString& value); void invalidateLinkedDatasources(QString datasourceName); bool checkConnection(QSqlDatabase db); + void invalidateQueriesContainsVariable(const QString& variableName); private slots: void slotConnectionRenamed(const QString& oldName,const QString& newName); void slotQueryTextChanged(const QString& queryName, const QString& queryText); + void slotVariableHasBeenAdded(const QString& variableName); + void slotVariableHasBeenChanged(const QString& variableName); private: explicit DataSourceManager(QObject *parent = 0); bool initAndOpenDB(QSqlDatabase &db, ConnectionDesc &connectionDesc); diff --git a/limereport/lrfactoryinitializer.cpp b/limereport/lrfactoryinitializer.cpp new file mode 100644 index 0000000..5aef43a --- /dev/null +++ b/limereport/lrfactoryinitializer.cpp @@ -0,0 +1,430 @@ +#include "bands/lrdataband.h" +#include "bands/lrgroupbands.h" +#include "bands/lrpagefooter.h" +#include "bands/lrpageheader.h" +#include "bands/lrreportheader.h" +#include "bands/lrreportfooter.h" +#include "bands/lrsubdetailband.h" +#include "bands/lrtearoffband.h" + + +#include "items/lrtextitem.h" +#ifdef HAVE_ZINT +#include "items/lrbarcodeitem.h" +#endif +#include "items/lrhorizontallayout.h" +#include "items/lrimageitem.h" +#include "items/lrshapeitem.h" +#include "lrdesignelementsfactory.h" + + +#include "objectinspector/lrobjectpropitem.h" +#include "objectinspector/propertyItems/lrboolpropitem.h" +#include "objectinspector/propertyItems/lrcolorpropitem.h" +#include "objectinspector/propertyItems/lrcontentpropitem.h" +#include "objectinspector/propertyItems/lrdatasourcepropitem.h" +#include "objectinspector/propertyItems/lrenumpropitem.h" +#include "objectinspector/propertyItems/lrflagspropitem.h" +#include "objectinspector/propertyItems/lrfontpropitem.h" +#include "objectinspector/propertyItems/lrgroupfieldpropitem.h" +#include "objectinspector/propertyItems/lrimagepropitem.h" +#include "objectinspector/propertyItems/lrintpropitem.h" +#include "objectinspector/propertyItems/lrqrealpropitem.h" +#include "objectinspector/propertyItems/lrrectproptem.h" +#include "objectinspector/propertyItems/lrstringpropitem.h" +#include "items/lralignpropitem.h" +#include "items/lrsubitemparentpropitem.h" + +#include "serializators/lrxmlbasetypesserializators.h" +#include "serializators/lrxmlqrectserializator.h" +#include "serializators/lrxmlserializatorsfactory.h" + +void initResources(){ + Q_INIT_RESOURCE(report); + Q_INIT_RESOURCE(lobjectinspector); + Q_INIT_RESOURCE(lrdatabrowser); + Q_INIT_RESOURCE(items); + Q_INIT_RESOURCE(lrscriptbrowser); +} + +namespace LimeReport{ + +BaseDesignIntf * createDataBand(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new LimeReport::DataBand(owner,parent); +} +BaseDesignIntf * createHeaderDataBand(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new LimeReport::DataHeaderBand(owner,parent); +} +BaseDesignIntf * createFooterDataBand(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new LimeReport::DataFooterBand(owner,parent); +} + +BaseDesignIntf* createGroupHeaderBand(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new LimeReport::GroupBandHeader(owner,parent); +} + +BaseDesignIntf * createGroupFooterBand(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new LimeReport::GroupBandFooter(owner,parent); +} + +BaseDesignIntf * createPageHeaderBand(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new LimeReport::PageHeader(owner,parent); +} + +BaseDesignIntf * createPageFooterBand(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new LimeReport::PageFooter(owner,parent); +} + +BaseDesignIntf * createSubDetailBand(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new LimeReport::SubDetailBand(owner,parent); +} + +BaseDesignIntf * createSubDetailHeaderBand(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new LimeReport::SubDetailHeaderBand(owner,parent); +} + +BaseDesignIntf * createSubDetailFooterBand(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new LimeReport::SubDetailFooterBand(owner,parent); +} + +BaseDesignIntf * createTearOffBand(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new LimeReport::TearOffBand(owner,parent); +} + +BaseDesignIntf * createTextItem(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new LimeReport::TextItem(owner,parent); +} + +#ifdef HAVE_ZINT +BaseDesignIntf * createBarcodeItem(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new BarcodeItem(owner,parent); +} +#endif + +BaseDesignIntf* createHLayout(QObject *owner, LimeReport::BaseDesignIntf *parent) +{ + return new HorizontalLayout(owner, parent); +} + +BaseDesignIntf * createImageItem(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new ImageItem(owner,parent); +} + +BaseDesignIntf * createShapeItem(QObject* owner, LimeReport::BaseDesignIntf* parent){ + return new ShapeItem(owner,parent); +} + +void initReportItems(){ + initResources(); + DesignElementsFactory::instance().registerCreator( + "TextItem", + LimeReport::ItemAttribs(QObject::tr("Text Item"),"TextItem"), + createTextItem + ); +#ifdef HAVE_ZINT + DesignElementsFactory::instance().registerCreator( + "BarcodeItem", + LimeReport::ItemAttribs(QObject::tr("Barcode Item"),"Item"), + createBarcodeItem + ); +#endif + DesignElementsFactory::instance().registerCreator( + "HLayout", + LimeReport::ItemAttribs(QObject::tr("HLayout"), LimeReport::Const::bandTAG), + createHLayout + ); + DesignElementsFactory::instance().registerCreator( + "ImageItem", LimeReport::ItemAttribs(QObject::tr("Image Item"),"Item"), createImageItem + ); + DesignElementsFactory::instance().registerCreator( + "ShapeItem", LimeReport::ItemAttribs(QObject::tr("Shape Item"),"Item"), createShapeItem + ); + DesignElementsFactory::instance().registerCreator( + "Data", + LimeReport::ItemAttribs(QObject::tr("Data"),LimeReport::Const::bandTAG), + createDataBand + ); + DesignElementsFactory::instance().registerCreator( + "DataHeader", + LimeReport::ItemAttribs(QObject::tr("DataHeader"),LimeReport::Const::bandTAG), + createHeaderDataBand + ); + DesignElementsFactory::instance().registerCreator( + "DataFooter", + LimeReport::ItemAttribs(QObject::tr("DataFooter"),LimeReport::Const::bandTAG), + createFooterDataBand + ); + DesignElementsFactory::instance().registerCreator( + "GroupHeader", + LimeReport::ItemAttribs(QObject::tr("GroupHeader"),LimeReport::Const::bandTAG), + createGroupHeaderBand + ); + DesignElementsFactory::instance().registerCreator( + "GroupFooter", + LimeReport::ItemAttribs(QObject::tr("GroupFooter"),LimeReport::Const::bandTAG), + createGroupFooterBand + ); + DesignElementsFactory::instance().registerCreator( + "PageFooter", + LimeReport::ItemAttribs(QObject::tr("Page Footer"),LimeReport::Const::bandTAG), + createPageFooterBand + ); + DesignElementsFactory::instance().registerCreator( + "PageHeader", + LimeReport::ItemAttribs(QObject::tr("Page Header"),LimeReport::Const::bandTAG), + createPageHeaderBand + ); + DesignElementsFactory::instance().registerCreator( + "SubDetail", + LimeReport::ItemAttribs(QObject::tr("SubDetail"),LimeReport::Const::bandTAG), + createSubDetailBand + ); + + DesignElementsFactory::instance().registerCreator( + "SubDetailHeader", + LimeReport::ItemAttribs(QObject::tr("SubDetailHeader"),LimeReport::Const::bandTAG), + createSubDetailHeaderBand + ); + DesignElementsFactory::instance().registerCreator( + "SubDetailFooter", + LimeReport::ItemAttribs(QObject::tr("SubDetailFooter"),LimeReport::Const::bandTAG), + createSubDetailFooterBand + ); + DesignElementsFactory::instance().registerCreator( + "TearOffBand", + LimeReport::ItemAttribs(QObject::tr("Tear-off Band"),LimeReport::Const::bandTAG), + createTearOffBand + ); + +} + +ObjectPropItem * createBoolPropItem( + QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly) +{ + return new LimeReport::BoolPropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem * createColorPropItem( + QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly) +{ + return new ColorPropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem * createContentPropItem( + QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly) +{ + return new ContentPropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem * createDatasourcePropItem( + QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly) +{ + return new LimeReport::DatasourcePropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem* createFieldPropItem(QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly){ + return new LimeReport::FieldPropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem * createEnumPropItem( + QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly) +{ + return new LimeReport::EnumPropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem * createFlagsPropItem( + QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly) +{ + return new LimeReport::FlagsPropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem * createFontPropItem( + QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly) +{ + return new LimeReport::FontPropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem* createGroupFieldPropItem(QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly){ + return new LimeReport::GroupFieldPropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem * createImagePropItem( + QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly) +{ + return new LimeReport::ImagePropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem * createIntPropItem( + QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly) +{ + return new LimeReport::IntPropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem * createQRealPropItem( + QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly) +{ + return new LimeReport::QRealPropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem * createReqtItem( + QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly +){ + return new LimeReport::RectPropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem * createReqtMMItem( + QObject*object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly +){ + return new LimeReport::RectMMPropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem * createStringPropItem( + QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly) +{ + return new LimeReport::StringPropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem * createAlignItem( + QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly +){ + return new LimeReport::AlignmentPropItem(object, objects, name, displayName, data, parent, readonly); +} + +ObjectPropItem * createLocationPropItem( + QObject *object, LimeReport::ObjectPropItem::ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& data, LimeReport::ObjectPropItem* parent, bool readonly) +{ + return new LimeReport::ItemLocationPropItem(object, objects, name, displayName, data, parent, readonly); +} + +void initObjectInspectorProperties() +{ + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("bool",""),QObject::tr("bool"),createBoolPropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("QColor",""),QObject::tr("QColor"),createColorPropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("content","LimeReport::TextItem"),QObject::tr("content"),createContentPropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("datasource","LimeReport::DataBandDesignIntf"),QObject::tr("datasource"),createDatasourcePropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("datasource","LimeReport::ImageItem"),QObject::tr("datasource"),createDatasourcePropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("field","LimeReport::ImageItem"),QObject::tr("field"),createFieldPropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("enum",""),QObject::tr("enum"),createEnumPropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("flags",""),QObject::tr("flags"),createFlagsPropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("QFont",""),QObject::tr("QFont"),createFontPropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("groupFieldName","LimeReport::GroupBandHeader"),QObject::tr("field"),createGroupFieldPropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("QImage",""),QObject::tr("QImage"),createImagePropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("int",""),QObject::tr("int"),createIntPropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("qreal",""),QObject::tr("qreal"),createQRealPropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("double",""),QObject::tr("qreal"),createQRealPropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("QRect",""),QObject::tr("QRect"),createReqtItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("QRectF",""),QObject::tr("QRectF"),createReqtItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("geometry","LimeReport::BaseDesignIntf"),QObject::tr("geometry"),createReqtMMItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("QString",""),QObject::tr("QString"),createStringPropItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("alignment","LimeReport::TextItem"),QObject::tr("alignment"),createAlignItem + ); + ObjectPropFactory::instance().registerCreator( + LimeReport::APropIdent("itemLocation","LimeReport::ItemDesignIntf"),QObject::tr("itemLocation"),createLocationPropItem + ); + +} + +SerializatorIntf * createIntSerializator(QDomDocument *doc, QDomElement *node){ + return new LimeReport::XmlIntSerializator(doc,node); +} + +SerializatorIntf * createQRealSerializator(QDomDocument *doc, QDomElement *node){ + return new LimeReport::XmlQRealSerializator(doc,node); +} + +SerializatorIntf * createQStringSerializator(QDomDocument *doc, QDomElement *node){ + return new LimeReport::XmlQStringSerializator(doc,node); +} + +SerializatorIntf * createEnumAndFlagsSerializator(QDomDocument *doc, QDomElement *node){ + return new LimeReport::XmlEnumAndFlagsSerializator(doc,node); +} + +SerializatorIntf * createBoolSerializator(QDomDocument *doc, QDomElement *node){ + return new LimeReport::XmlBoolSerializator(doc,node); +} + +SerializatorIntf * createFontSerializator(QDomDocument *doc, QDomElement *node){ + return new LimeReport::XmlFontSerializator(doc,node); +} + +SerializatorIntf * createQSizeFSerializator(QDomDocument *doc, QDomElement *node){ + return new LimeReport::XmlQSizeFSerializator(doc,node); +} + +SerializatorIntf * createQImageSerializator(QDomDocument *doc, QDomElement *node){ + return new LimeReport::XmlQImageSerializator(doc,node); +} + +SerializatorIntf * createQColorSerializator(QDomDocument *doc, QDomElement *node){ + return new LimeReport::XmlColorSerializator(doc,node); +} + +SerializatorIntf* createQByteArraySerializator(QDomDocument *doc, QDomElement *node){ + return new LimeReport::XmlQByteArraySerializator(doc,node); +} + +SerializatorIntf* createQVariantSerializator(QDomDocument *doc, QDomElement *node){ + return new LimeReport::XmlQVariantSerializator(doc,node); +} + +SerializatorIntf * createQRectSerializator(QDomDocument *doc, QDomElement *node){ + return new LimeReport::XMLQRectSerializator(doc,node); +} + +void initSerializators() +{ + XMLAbstractSerializatorFactory::instance().registerCreator("QString", createQStringSerializator); + XMLAbstractSerializatorFactory::instance().registerCreator("int", createIntSerializator); + XMLAbstractSerializatorFactory::instance().registerCreator("enumAndFlags",createEnumAndFlagsSerializator); + XMLAbstractSerializatorFactory::instance().registerCreator("bool", createBoolSerializator); + XMLAbstractSerializatorFactory::instance().registerCreator("QFont", createFontSerializator); + XMLAbstractSerializatorFactory::instance().registerCreator("QSizeF", createQSizeFSerializator); + XMLAbstractSerializatorFactory::instance().registerCreator("QImage", createQImageSerializator); + XMLAbstractSerializatorFactory::instance().registerCreator("qreal", createQRealSerializator); + XMLAbstractSerializatorFactory::instance().registerCreator("double", createQRealSerializator); + XMLAbstractSerializatorFactory::instance().registerCreator("QColor", createQColorSerializator); + XMLAbstractSerializatorFactory::instance().registerCreator("QByteArray", createQByteArraySerializator); + XMLAbstractSerializatorFactory::instance().registerCreator("QVariant", createQVariantSerializator); + XMLAbstractSerializatorFactory::instance().registerCreator("QRect", createQRectSerializator); + XMLAbstractSerializatorFactory::instance().registerCreator("QRectF", createQRectSerializator); +} + +} //namespace LimeReport diff --git a/limereport/lrfactoryinitializer.h b/limereport/lrfactoryinitializer.h new file mode 100644 index 0000000..679d657 --- /dev/null +++ b/limereport/lrfactoryinitializer.h @@ -0,0 +1,6 @@ +void initResources(); +namespace LimeReport{ + void initReportItems(); + void initObjectInspectorProperties(); + void initSerializators(); +} // namespace LimeReport diff --git a/limereport/lrglobal.h b/limereport/lrglobal.h index 3f11f78..f2c866f 100644 --- a/limereport/lrglobal.h +++ b/limereport/lrglobal.h @@ -27,8 +27,8 @@ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * * GNU General Public License for more details. * ****************************************************************************/ -#ifndef GLOBAL_H -#define GLOBAL_H +#ifndef LRGLOBAL_H +#define LRGLOBAL_H #include "qglobal.h" #include #include @@ -76,6 +76,7 @@ namespace Const{ const qreal SELECTION_OPACITY = 0.3; const QString FIELD_RX = "\\$D\\s*\\{\\s*([^{}]*)\\s*\\}"; const QString VARIABLE_RX = "\\$V\\s*\\{\\s*([^{}]*)\\s*\\}"; + const QString NAMED_VARIABLE_RX = "\\$V\\s*\\{\\s*(%1)\\s*\\}"; const QString SCRIPT_RX = "\\$S\\s*\\{(.*)\\}"; //const QString GROUP_FUNCTION_PARAM_RX = "\\(\\s*(((?:\\\"?\\$D\\s*\\{\\s*)|(?:\\\"?\\$V\\s*\\{\\s*)|(?:\\\"))(\\w+\\.?\\w+)((?:\\\")|(?:\\s*\\}\\\"?\\s*)))\\s*,\\s*\\\"(\\w+)\\\"\\s*\\)"; @@ -84,7 +85,8 @@ namespace Const{ //const QString GROUP_FUNCTION_PARAM_RX = "\\(\\s*(?:(?:((?:(?:\\\"?\\$D\\s*\\{\\s*)|(?:\\\"?\\$V\\s*\\{\\s*)|(?:\\\"?\\$S\\s*\\{\\s*)|(?:\\\"))((?:\\w+\\.?\\w+)|(?:\\w+))(?:(?:\\\")|(?:\\s*\\}\\\"?\\s*)))\\s*,)|(?:))\\s*\\\"(\\w+)\\\"\\s*\\)"; //const QString GROUP_FUNCTION_PARAM_RX = "\\((?:(.+),(.+))|(?:\\\"(\\w+)\\\")\\)"; - const QString GROUP_FUNCTION_PARAM_RX = "\\(\\s*(?:(?:(?:(?:\\\")|(?:))(\\w+)(?:(?:\\\")|(?:)))|(?:(?:(?:\\\")|(?:))(\\s*\\$\\w\\s*\\{.+\\}\\s*)(?:(?:\\\")|(?:))\\s*,\\s*(?:(?:\\\")|(?:))(\\w+)(?:(?:\\\")|(?:))))\\)"; + //const QString GROUP_FUNCTION_PARAM_RX = "\\(\\s*(?:(?:(?:(?:\\\")|(?:))(\\w+)(?:(?:\\\")|(?:)))|(?:(?:(?:\\\")|(?:))(\\s*\\$\\w\\s*\\{.+\\}\\s*)(?:(?:\\\")|(?:))\\s*,\\s*(?:(?:\\\")|(?:))(\\w+)(?:(?:\\\")|(?:))))\\)"; + const QString GROUP_FUNCTION_PARAM_RX = "\\(\\s*((?:(?:\\\")|(?:))(?:(?:\\$(?:(?:D\\{\\s*\\w*.\\w*\\s*\\})|(?:V\\{\\s*\\w*\\s*\\})|(?:S\\{.+\\})))|(?:\\w*))(?:(?:\\\")|(?:)))(?:(?:\\s*,\\s*(?:\\\"(\\w*)\\\"))|(?:))\\)"; const int DATASOURCE_INDEX = 3;//4; const int VALUE_INDEX = 2; //2; const int EXPRESSION_ARGUMENT_INDEX = 1;//3; diff --git a/limereport/lrgraphicsviewzoom.h b/limereport/lrgraphicsviewzoom.h index e1f6d49..7c7f014 100644 --- a/limereport/lrgraphicsviewzoom.h +++ b/limereport/lrgraphicsviewzoom.h @@ -1,5 +1,5 @@ -#ifndef GRAPHICSVIEWZOOM_H -#define GRAPHICSVIEWZOOM_H +#ifndef LRGRAPHICSVIEWZOOM_H +#define LRGRAPHICSVIEWZOOM_H #include #include diff --git a/limereport/lritemdesignintf.cpp b/limereport/lritemdesignintf.cpp index 5987086..167ac27 100644 --- a/limereport/lritemdesignintf.cpp +++ b/limereport/lritemdesignintf.cpp @@ -59,6 +59,7 @@ void ItemDesignIntf::setItemLocation(LocationType location) setParentItem(parentBand); setParent(dynamic_cast(parentBand)); setPos(parentPos); + emit itemLocationChanged(this, dynamic_cast(parentBand)); } else { m_itemLocation=Page; } @@ -69,6 +70,7 @@ void ItemDesignIntf::setItemLocation(LocationType location) setParentItem(page); setParent(page); setPos(parentPos); + emit itemLocationChanged(this, page); } } notify("locationType",oldValue,location); @@ -95,8 +97,8 @@ BaseDesignIntf *ItemDesignIntf::cloneEmpty(int height, QObject *owner, QGraphics QGraphicsItem * ItemDesignIntf::bandByPos() { - foreach(QGraphicsItem *item,collidingItems()){ - if (dynamic_cast(item)){ + foreach(QGraphicsItem *item, scene()->items()){ + if (dynamic_cast(item) && item->collidesWithItem(this)){ return item; } } diff --git a/limereport/lritemdesignintf.h b/limereport/lritemdesignintf.h index a9c8d7a..808666c 100644 --- a/limereport/lritemdesignintf.h +++ b/limereport/lritemdesignintf.h @@ -50,6 +50,8 @@ public: void setStretchToMaxHeight(bool value); bool stretchToMaxHeight(){return m_stretchToMaxHeight;} BaseDesignIntf* cloneEmpty(int height, QObject *owner, QGraphicsItem *parent); +signals: + void itemLocationChanged(BaseDesignIntf* item, BaseDesignIntf* parent); protected: QGraphicsItem* bandByPos(); virtual void initFlags(); diff --git a/limereport/lritemscontainerdesignitf.cpp b/limereport/lritemscontainerdesignitf.cpp index dcad6ee..0e31eb8 100644 --- a/limereport/lritemscontainerdesignitf.cpp +++ b/limereport/lritemscontainerdesignitf.cpp @@ -91,7 +91,7 @@ void ItemsContainerDesignInft::arrangeSubItems(RenderPass pass, DataSourceManage } } -qreal ItemsContainerDesignInft::findMaxBottom() +qreal ItemsContainerDesignInft::findMaxBottom() const { qreal maxBottom=0; foreach(QGraphicsItem* item,childItems()){ @@ -103,7 +103,7 @@ qreal ItemsContainerDesignInft::findMaxBottom() return maxBottom; } -qreal ItemsContainerDesignInft::findMaxHeight() +qreal ItemsContainerDesignInft::findMaxHeight() const { qreal maxHeight=0; foreach(QGraphicsItem* item,childItems()){ diff --git a/limereport/lritemscontainerdesignitf.h b/limereport/lritemscontainerdesignitf.h index 86b2509..1526ac7 100644 --- a/limereport/lritemscontainerdesignitf.h +++ b/limereport/lritemscontainerdesignitf.h @@ -1,5 +1,5 @@ -#ifndef ITEMSCONTAINERDESIGNITF_H -#define ITEMSCONTAINERDESIGNITF_H +#ifndef LRITEMSCONTAINERDESIGNITF_H +#define LRITEMSCONTAINERDESIGNITF_H #include "lrbasedesignintf.h" @@ -44,8 +44,8 @@ public: protected: void snapshotItemsLayout(); void arrangeSubItems(RenderPass pass, DataSourceManager *dataManager, ArrangeType type = AsNeeded); - qreal findMaxBottom(); - qreal findMaxHeight(); + qreal findMaxBottom() const; + qreal findMaxHeight() const; private: QVector m_containerItems; diff --git a/limereport/lrpagedesignintf.cpp b/limereport/lrpagedesignintf.cpp index 0928856..67d8408 100644 --- a/limereport/lrpagedesignintf.cpp +++ b/limereport/lrpagedesignintf.cpp @@ -125,7 +125,7 @@ void PageDesignIntf::updatePageRect() m_pageItem->setRightMargin(5); m_pageItem->setObjectName("ReportPage1"); connect(m_pageItem.data(), SIGNAL(itemSelected(LimeReport::BaseDesignIntf *)), this, SIGNAL(itemSelected(LimeReport::BaseDesignIntf *))); - connect(m_pageItem.data(), SIGNAL(geometryChanged(QObject *, QRectF, QRectF)), this, SLOT(slotPageGeomertyChanged(QObject *, QRectF, QRectF))); + connect(m_pageItem.data(), SIGNAL(geometryChanged(QObject *, QRectF, QRectF)), this, SLOT(slotPageGeometryChanged(QObject *, QRectF, QRectF))); connect(m_pageItem.data(), SIGNAL(objectLoaded(QObject *)), this, SLOT(slotPageItemLoaded(QObject *))); } this->setSceneRect(-Const::SCENE_MARGIN, -Const::SCENE_MARGIN, @@ -777,7 +777,7 @@ QStringList PageDesignIntf::possibleParentItems() return itemsList; } -void PageDesignIntf::slotPageGeomertyChanged(QObject *, QRectF /*newGeometry*/, QRectF) +void PageDesignIntf::slotPageGeometryChanged(QObject *, QRectF /*newGeometry*/, QRectF) { if (!m_isLoading){ pageItem()->relocateBands(); @@ -1071,6 +1071,14 @@ void PageDesignIntf::setReportSettings(ReportSettings *reportSettings) m_pageItem->setReportSettings(m_reportSettings); } +void PageDesignIntf::setPropertyToSelectedItems(const char* name, const QVariant& value) +{ + foreach(QGraphicsItem* gi, selectedItems()){ + BaseDesignIntf* item = dynamic_cast(gi); + if(item && item->metaObject()->indexOfProperty(name) != -1 ) item->setProperty(name,value); + } +} + bool PageDesignIntf::magneticMovement() const { return m_magneticMovement; diff --git a/limereport/lrpagedesignintf.h b/limereport/lrpagedesignintf.h index 5ddfdc0..684df0b 100644 --- a/limereport/lrpagedesignintf.h +++ b/limereport/lrpagedesignintf.h @@ -182,6 +182,8 @@ namespace LimeReport { ReportSettings *getReportSettings() const; void setReportSettings(ReportSettings *reportSettings); + void setPropertyToSelectedItems(const char *name, const QVariant &value); + protected: virtual void keyPressEvent(QKeyEvent *event); @@ -252,7 +254,7 @@ namespace LimeReport { void setTextAlign(const Qt::Alignment& alignment); void setBorders(const BaseDesignIntf::BorderLines& border); private slots: - void slotPageGeomertyChanged(QObject*, QRectF, QRectF ); + void slotPageGeometryChanged(QObject*, QRectF, QRectF ); void slotItemPropertyChanged(QString propertyName, const QVariant &oldValue, const QVariant &newValue); void slotItemPropertyObjectNameChanged(const QString& oldName, const QString& newName); void bandDeleted(QObject* band); diff --git a/limereport/lrpageitemdesignintf.cpp b/limereport/lrpageitemdesignintf.cpp index 150df06..2e8de0b 100644 --- a/limereport/lrpageitemdesignintf.cpp +++ b/limereport/lrpageitemdesignintf.cpp @@ -202,10 +202,16 @@ int PageItemDesignIntf::calcBandIndex(BandDesignIntf::BandsType bandType, BandDe int bandIndex=-1; qSort(m_bands.begin(),m_bands.end(),bandSortBandLessThenByIndex); foreach(BandDesignIntf* band,m_bands){ - if ((band->bandType()==BandDesignIntf::GroupHeader)&&(band->bandType()>bandType)) break; - if ((band->bandType()<=bandType)){ - if (bandIndex<=band->bandIndex()) bandIndex=band->maxChildIndex()+1; - } + if ((band->bandType() == BandDesignIntf::GroupHeader) && ( band->bandType() > bandType)) break; + if ((band->bandType() <= bandType)){ + if (bandIndex <= band->bandIndex()) { + if (bandType != BandDesignIntf::Data){ + bandIndex=band->maxChildIndex(bandType)+1; + } else { + bandIndex=band->maxChildIndex()+1; + } + } + } else { increaseBandIndex = true; break;} } if (bandIndex==-1) { @@ -222,7 +228,7 @@ int PageItemDesignIntf::calcBandIndex(BandDesignIntf::BandsType bandType, BandDe switch (bandType) { case BandDesignIntf::SubDetailBand: - bandIndex = parentBand->maxChildIndex() + 1; + bandIndex = parentBand->maxChildIndex(bandType) + 1; increaseBandIndex = true; break; case BandDesignIntf::SubDetailHeader: @@ -364,7 +370,8 @@ void PageItemDesignIntf::relocateBands() if (!(itemMode() & DesignMode)){ while ( (bandIndex < m_bands.count()) && ((m_bands[bandIndex]->bandType() == BandDesignIntf::TearOffBand) || - (m_bands[bandIndex]->bandType() == BandDesignIntf::PageFooter)) + (m_bands[bandIndex]->bandType() == BandDesignIntf::PageFooter) || + m_bands[bandIndex]->bandType() == BandDesignIntf::ReportFooter ) ){ bandIndex++; } @@ -588,8 +595,9 @@ void PageItemDesignIntf::bandGeometryChanged(QObject* object, QRectF newGeometry } } if (curIndex != band->bandIndex()){ - bandToSwap->changeBandIndex(band->bandIndex()); - band->changeBandIndex(curIndex); + int swapIndex = bandToSwap->maxChildIndex(); + bandToSwap->changeBandIndex(band->bandIndex(),true); + band->changeBandIndex(swapIndex,true); } relocateBands(); diff --git a/limereport/lrreportdesignwidget.cpp b/limereport/lrreportdesignwidget.cpp index 9e22238..b12ae6f 100644 --- a/limereport/lrreportdesignwidget.cpp +++ b/limereport/lrreportdesignwidget.cpp @@ -51,8 +51,16 @@ namespace LimeReport { ReportDesignWidget::ReportDesignWidget(ReportEnginePrivate *report, QMainWindow *mainWindow, QWidget *parent) : QWidget(parent), m_mainWindow(mainWindow), m_verticalGridStep(10), m_horizontalGridStep(10), m_useGrid(false) { +#ifdef HAVE_QT5 m_tabWidget = new QTabWidget(this); +#endif +#ifdef HAVE_QT4 + m_tabWidget = new LimeReportTabWidget(this); +#endif m_tabWidget->setTabPosition(QTabWidget::South); + m_tabWidget->setMovable(true); + connect(m_tabWidget->tabBar(), SIGNAL(tabMoved(int,int)), this, SLOT(slotTabMoved(int,int))); + QVBoxLayout* mainLayout = new QVBoxLayout(this); mainLayout->addWidget(m_tabWidget); setLayout(mainLayout); @@ -152,7 +160,9 @@ void ReportDesignWidget::createTabs(){ view->centerOn(0,0); view->scale(0.5,0.5); connectPage(m_report->pageAt(i)); - m_tabWidget->addTab(view,QIcon(),tr("Page")+QString::number(i+1)); + m_tabWidget->addTab(view,QIcon(),m_report->pageAt(i)->pageItem()->objectName()); + connect(m_report->pageAt(i)->pageItem(), SIGNAL(propertyObjectNameChanged(QString,QString)), + this, SLOT(slotPagePropertyObjectNameChanged(QString,QString))); } m_scriptEditor = new QTextEdit(this); m_tabWidget->addTab(m_scriptEditor,QIcon(),tr("Script")); @@ -257,7 +267,7 @@ void ReportDesignWidget::slotItemSelected(BaseDesignIntf *item){ } void ReportDesignWidget::saveToFile(const QString &fileName){ - m_report->scriptContext()->setInitScript(m_scriptEditor->toPlainText()); + prepareReport(); if (m_report->saveToFile(fileName)) { m_report->emitSaveFinished(); } @@ -265,7 +275,7 @@ void ReportDesignWidget::saveToFile(const QString &fileName){ bool ReportDesignWidget::save() { - m_report->scriptContext()->setInitScript(m_scriptEditor->toPlainText()); + prepareReport(); if (!m_report->reportFileName().isEmpty()){ if (m_report->saveToFile()){ m_report->emitSaveFinished(); @@ -454,15 +464,21 @@ void ReportDesignWidget::setBorders(const BaseDesignIntf::BorderLines& borders) activePage()->setBorders(borders); } +void ReportDesignWidget::prepareReport() +{ + m_report->scriptContext()->setInitScript(m_scriptEditor->toPlainText()); + report()->clearSelection(); +} + void ReportDesignWidget::previewReport() { - report()->scriptContext()->setInitScript(m_scriptEditor->toPlainText()); + prepareReport(); report()->previewReport(); } void ReportDesignWidget::printReport() { - report()->scriptContext()->setInitScript(m_scriptEditor->toPlainText()); + prepareReport(); setCursor(Qt::WaitCursor); report()->printReport(); setCursor(Qt::ArrowCursor); @@ -476,8 +492,10 @@ void ReportDesignWidget::addPage() PageDesignIntf* page = m_report->appendPage("page"+QString::number(m_report->pageCount()+1)); view->setScene(page); int index = m_report->pageCount()-1; - m_tabWidget->insertTab(index,view,QIcon(),tr("Page")+QString::number(m_report->pageCount())); + m_tabWidget->insertTab(index,view,QIcon(),page->pageItem()->objectName()); m_tabWidget->setCurrentIndex(index); + connect(page->pageItem(), SIGNAL(propertyObjectNameChanged(QString,QString)), + this, SLOT(slotPagePropertyObjectNameChanged(QString,QString))); connectPage(page); view->scale(0.5,0.5); view->centerOn(0,0); @@ -608,6 +626,41 @@ void ReportDesignWidget::slotCurrentTabChanged(int index) emit activePageChanged(); } +void ReportDesignWidget::slotPagePropertyObjectNameChanged(const QString &oldValue, const QString &newValue) +{ + for (int i = 0; i < m_tabWidget->count(); ++i ){ + if (m_tabWidget->tabText(i).compare(oldValue) == 0){ + QGraphicsView* view = dynamic_cast(m_tabWidget->widget(i)); + if (view){ + PageDesignIntf* page = dynamic_cast(view->scene()); + if (page->pageItem() == sender()) + m_tabWidget->setTabText(i, newValue); + } + } + } +} + +void ReportDesignWidget::slotTabMoved(int from, int to) +{ + Q_UNUSED(from) + Q_UNUSED(to) + + QList pages; + + for ( int i = 0; i < m_tabWidget->tabBar()->count(); ++i){ + QGraphicsView* view = dynamic_cast(m_tabWidget->widget(i)); + if (view){ + PageDesignIntf* page = dynamic_cast(view->scene()); + if (page){ + pages.append(page); + } + } + } + + m_report->reorderPages(pages); + +} + bool ReportDesignWidget::eventFilter(QObject *target, QEvent *event) { if (event->type() == QEvent::Wheel){ diff --git a/limereport/lrreportdesignwidget.h b/limereport/lrreportdesignwidget.h index 28a1998..407e2dc 100644 --- a/limereport/lrreportdesignwidget.h +++ b/limereport/lrreportdesignwidget.h @@ -42,6 +42,16 @@ #include "lrreportengine_p.h" #include "lrgraphicsviewzoom.h" +#ifdef HAVE_QT4 +QT_BEGIN_NAMESPACE +class LimeReportTabWidget: public QTabWidget{ + Q_OBJECT +public: + explicit LimeReportTabWidget(QWidget *parent = 0):QTabWidget(parent){} + QTabBar* tabBar() const{ return QTabWidget::tabBar();} +}; +QT_END_NAMESPACE +#endif namespace LimeReport { @@ -128,6 +138,8 @@ private slots: void slotDatasourceCollectionLoaded(const QString&); void slotSceneRectChanged(QRectF); void slotCurrentTabChanged(int index); + void slotPagePropertyObjectNameChanged(const QString& oldValue, const QString& newValue); + void slotTabMoved(int from, int to); signals: void insertModeStarted(); void itemInserted(LimeReport::PageDesignIntf*,QPointF,const QString&); @@ -156,7 +168,12 @@ private: QGraphicsView *m_view; QTextEdit* m_scriptEditor; QMainWindow *m_mainWindow; +#ifdef HAVE_QT5 QTabWidget* m_tabWidget; +#endif +#ifdef HAVE_QT4 + LimeReportTabWidget* m_tabWidget; +#endif GraphicsViewZoomer* m_zoomer; QFont m_defaultFont; int m_verticalGridStep; @@ -164,6 +181,7 @@ private: bool m_useGrid; bool m_useMagnet; // static ReportDesignWidget* m_instance; + void prepareReport(); }; } diff --git a/limereport/lrreportdesignwindow.cpp b/limereport/lrreportdesignwindow.cpp index 358aa6b..cffe165 100644 --- a/limereport/lrreportdesignwindow.cpp +++ b/limereport/lrreportdesignwindow.cpp @@ -217,16 +217,16 @@ void ReportDesignWindow::createActions() m_aboutAction->setIcon(QIcon(":/report/images/copyright")); connect(m_aboutAction,SIGNAL(triggered()),this,SLOT(slotShowAbout())); - m_hideLeftPanel = new QAction(tr("Hide left panel"),this); + m_hideLeftPanel = new QAction(tr("Hide left panel | Alt+L"),this); m_hideLeftPanel->setCheckable(true); -// m_hideLeftPanel->setChecked(true); m_hideLeftPanel->setIcon(QIcon(":/report/images/hideLeftPanel")); + m_hideLeftPanel->setShortcut(QKeySequence(Qt::ALT + Qt::Key_L)); connect(m_hideLeftPanel,SIGNAL(toggled(bool)), this, SLOT(slotHideLeftPanel(bool))); - m_hideRightPanel = new QAction(tr("Hide right panel"),this); + m_hideRightPanel = new QAction(tr("Hide right panel | Alt+R"),this); m_hideRightPanel->setCheckable(true); -// m_hideRightPanel->setChecked(true); m_hideRightPanel->setIcon(QIcon(":/report/images/hideRightPanel")); + m_hideRightPanel->setShortcut(QKeySequence(Qt::ALT + Qt::Key_R)); connect(m_hideRightPanel,SIGNAL(toggled(bool)), this, SLOT(slotHideRightPanel(bool))); } @@ -683,7 +683,7 @@ bool ReportDesignWindow::checkNeedToSave() { if (m_reportDesignWidget->isNeedToSave()){ QMessageBox::StandardButton button = QMessageBox::question( - this,"",tr("Report has been modified ! Do you want save the report ?"), + this,"",tr("Report has been modified! Do you want save the report?"), QMessageBox::Yes|QMessageBox::No|QMessageBox::Cancel, QMessageBox::Yes ); switch (button) { @@ -1058,8 +1058,10 @@ void ReportDesignWindow::slotBandAdded(PageDesignIntf *, BandDesignIntf * band) break; case BandDesignIntf::ReportFooter: m_newReportFooter->setDisabled(true); + break; case BandDesignIntf::TearOffBand: m_newTearOffBand->setDisabled(true); + break; default: break; } @@ -1267,7 +1269,7 @@ bool ObjectNameValidator::validate(const QString &propName, const QVariant &prop BaseDesignIntf* bd = dynamic_cast(object); if (bd){ if (bd->page()->reportItemByName(propValue.toString())){ - msg = QString(QObject::tr("Object with name %1 already exists").arg(propValue.toString())); + msg = QString(QObject::tr("Object with name %1 already exists!").arg(propValue.toString())); return false; } else (bd->emitObjectNamePropertyChanged(object->objectName(),propValue.toString())); } diff --git a/limereport/lrreportengine.cpp b/limereport/lrreportengine.cpp index 4d3aa3d..adb9e73 100644 --- a/limereport/lrreportengine.cpp +++ b/limereport/lrreportengine.cpp @@ -50,7 +50,9 @@ #include "lrpreviewreportwindow.h" #include "lrpreviewreportwidget.h" #include "lrpreviewreportwidget_p.h" - +#ifdef HAVE_STATIC_BUILD +#include "lrfactoryinitializer.h" +#endif namespace LimeReport{ QSettings* ReportEngine::m_settings = 0; @@ -63,8 +65,15 @@ ReportEnginePrivate::ReportEnginePrivate(QObject *parent) : m_reportRendering(false), m_resultIsEditable(true), m_passPhrase("HjccbzHjlbyfCkjy"), m_fileWatcher( new QFileSystemWatcher( this ) ) { +#ifdef HAVE_STATIC_BUILD + initResources(); + initReportItems(); + initObjectInspectorProperties(); + initSerializators(); +#endif m_datasources = new DataSourceManager(this); m_datasources->setReportSettings(&m_reportSettings); + scriptManager()->setDataManager(m_datasources); m_scriptEngineContext = new ScriptEngineContext(this); m_datasources->setObjectName("datasources"); connect(m_datasources,SIGNAL(loadCollectionFinished(QString)),this,SLOT(slotDataSourceCollectionLoaded(QString))); @@ -98,6 +107,7 @@ PageDesignIntf *ReportEnginePrivate::createPage(const QString &pageName) { PageDesignIntf* page =new PageDesignIntf(); page->setObjectName(pageName); + page->pageItem()->setObjectName("Report"+pageName); page->setReportEditor(this); page->setReportSettings(&m_reportSettings); return page; @@ -355,7 +365,7 @@ bool ReportEnginePrivate::printToPDF(const QString &fileName) void ReportEnginePrivate::previewReport(PreviewHints hints) { - QTime start = QTime::currentTime(); +// QTime start = QTime::currentTime(); try{ dataManager()->setDesignTime(false); ReportPages pages = renderToPages(); @@ -370,6 +380,7 @@ void ReportEnginePrivate::previewReport(PreviewHints hints) w->setWindowTitle(m_previewWindowTitle); w->setSettings(settings()); w->setPages(pages); + w->setLayoutDirection(m_previewLayoutDirection); if (!dataManager()->errorsList().isEmpty()){ w->setErrorMessages(dataManager()->errorsList()); } @@ -384,7 +395,6 @@ void ReportEnginePrivate::previewReport(PreviewHints hints) m_activePreview = w; connect(w,SIGNAL(destroyed(QObject*)), this, SLOT(slotPreviewWindowDestroyed(QObject*))); - qDebug()<<"render time ="<exec(); } } catch (ReportError &exception){ @@ -707,11 +717,38 @@ QString ReportEnginePrivate::renderToString() }else return QString(); } +Qt::LayoutDirection ReportEnginePrivate::previewLayoutDirection() +{ + return m_previewLayoutDirection; +} + +void ReportEnginePrivate::setPreviewLayoutDirection(const Qt::LayoutDirection& layoutDirection) +{ + m_previewLayoutDirection = layoutDirection; +} + void ReportEnginePrivate::setPassPhrase(const QString &passPhrase) { m_passPhrase = passPhrase; } +void ReportEnginePrivate::reorderPages(const QList& reorderedPages) +{ + m_pages.clear(); + foreach(PageDesignIntf* page, reorderedPages){ + m_pages.append(page); + } +} + +void ReportEnginePrivate::clearSelection() +{ + foreach (PageDesignIntf* page, m_pages) { + foreach(QGraphicsItem* item, page->selectedItems()){ + item->setSelected(false); + } + } +} + bool ReportEnginePrivate::resultIsEditable() const { return m_resultIsEditable; @@ -896,6 +933,18 @@ void ReportEngine::setPassPharse(QString &passPharse) d->setPassPhrase(passPharse); } +Qt::LayoutDirection ReportEngine::previewLayoutDirection() +{ + Q_D(ReportEngine); + return d->previewLayoutDirection(); +} + +void ReportEngine::setPreviewLayoutDirection(const Qt::LayoutDirection& layoutDirection) +{ + Q_D(ReportEngine); + return d->setPreviewLayoutDirection(layoutDirection); +} + void ReportEngine::setShowProgressDialog(bool value) { Q_D(ReportEngine); diff --git a/limereport/lrreportengine.h b/limereport/lrreportengine.h index 564dabd..746712e 100644 --- a/limereport/lrreportengine.h +++ b/limereport/lrreportengine.h @@ -102,6 +102,8 @@ public: bool resultIsEditable(); bool isBusy(); void setPassPharse(QString& passPharse); + Qt::LayoutDirection previewLayoutDirection(); + void setPreviewLayoutDirection(const Qt::LayoutDirection& previewLayoutDirection); signals: void renderStarted(); void renderFinished(); diff --git a/limereport/lrreportengine_p.h b/limereport/lrreportengine_p.h index ade298e..7d47e90 100644 --- a/limereport/lrreportengine_p.h +++ b/limereport/lrreportengine_p.h @@ -128,7 +128,10 @@ public: void setResultEditable(bool value); void setPassPhrase(const QString &passPhrase); - + void reorderPages(const QList &reorderedPages); + void clearSelection(); + Qt::LayoutDirection previewLayoutDirection(); + void setPreviewLayoutDirection(const Qt::LayoutDirection& previewLayoutDirection); signals: void pagesLoadFinished(); void datasourceCollectionLoadFinished(const QString& collectionName); @@ -181,8 +184,8 @@ private: bool m_reportRendering; bool m_resultIsEditable; QString m_passPhrase; - QFileSystemWatcher *m_fileWatcher; + Qt::LayoutDirection m_previewLayoutDirection; }; } diff --git a/limereport/lrreportrender.cpp b/limereport/lrreportrender.cpp index 9e6ea4c..5eb81e6 100644 --- a/limereport/lrreportrender.cpp +++ b/limereport/lrreportrender.cpp @@ -148,7 +148,7 @@ void ReportRender::renameChildItems(BaseDesignIntf *item){ ReportRender::ReportRender(QObject *parent) :QObject(parent), m_renderPageItem(0), m_pageCount(0), - m_lastDataBand(0), m_lastRenderedFooter(0), m_currentColumn(0) + m_lastDataBand(0), m_lastRenderedFooter(0), m_currentColumn(0), m_newPageStarted(false) { initColumns(); } @@ -247,8 +247,6 @@ void ReportRender::renderPage(PageDesignIntf* patternPage) clearPageMap(); startNewPage(); - - renderBand(m_patternPageItem->bandByType(BandDesignIntf::ReportHeader), 0, StartNewPageAsNeeded); BandDesignIntf* lastRenderedBand = 0; @@ -311,6 +309,8 @@ void ReportRender::initVariables() { m_datasources->setReportVariable("#PAGE",1); m_datasources->setReportVariable("#PAGE_COUNT",0); + m_datasources->setReportVariable("#IS_LAST_PAGEFOOTER",false); + m_datasources->setReportVariable("#IS_FIRST_PAGEFOOTER",false); } #ifdef HAVE_UI_LOADER @@ -330,68 +330,87 @@ void ReportRender::clearPageMap() m_renderedPages.clear(); } -void ReportRender::extractGroupsFunction(BandDesignIntf *band) -{ - foreach(BaseDesignIntf* item,band->childBaseItems()){ - ContentItemDesignIntf* contentItem = dynamic_cast(item); - if (contentItem&&(contentItem->content().contains(QRegExp("\\$S\\s*\\{.*\\}")))){ - foreach(const QString &functionName, m_datasources->groupFunctionNames()){ - QRegExp rx(QString(Const::GROUP_FUNCTION_RX).arg(functionName)); - QRegExp rxName(QString(Const::GROUP_FUNCTION_NAME_RX).arg(functionName)); - if (rx.indexIn(contentItem->content())>=0){ - int pos = 0; - while ( (pos = rx.indexIn(contentItem->content(),pos)) != -1){ - QVector captures = normalizeCaptures(rx); - if (captures.size()>=3){ - int dsIndex = captures.size() == 3 ? Const::DATASOURCE_INDEX - 1 : Const::DATASOURCE_INDEX; - BandDesignIntf* dataBand = m_patternPageItem->bandByName(captures.at(dsIndex)); - if (dataBand){ - GroupFunction* gf = datasources()->addGroupFunction(functionName,captures.at(Const::VALUE_INDEX),band->objectName(),dataBand->objectName()); - if (gf){ - connect(dataBand,SIGNAL(bandRendered(BandDesignIntf*)),gf,SLOT(slotBandRendered(BandDesignIntf*))); - } - } else { - GroupFunction* gf = datasources()->addGroupFunction(functionName,captures.at(Const::VALUE_INDEX),band->objectName(),captures.at(dsIndex)); - gf->setInvalid(tr("Databand \"%1\" not found").arg(captures.at(dsIndex))); +void ReportRender::extractGroupFuntionsFromItem(ContentItemDesignIntf* contentItem, BandDesignIntf* band){ + if ( contentItem && contentItem->content().contains(QRegExp("\\$S\\s*\\{.*\\}"))){ + foreach(const QString &functionName, m_datasources->groupFunctionNames()){ + QRegExp rx(QString(Const::GROUP_FUNCTION_RX).arg(functionName)); + QRegExp rxName(QString(Const::GROUP_FUNCTION_NAME_RX).arg(functionName)); + if (rx.indexIn(contentItem->content())>=0){ + int pos = 0; + while ( (pos = rx.indexIn(contentItem->content(),pos)) != -1){ + QVector captures = normalizeCaptures(rx); + if (captures.size()>=3){ + int dsIndex = captures.size() == 3 ? Const::DATASOURCE_INDEX - 1 : Const::DATASOURCE_INDEX; + BandDesignIntf* dataBand = m_patternPageItem->bandByName(captures.at(dsIndex)); + if (dataBand){ + GroupFunction* gf = datasources()->addGroupFunction(functionName,captures.at(Const::VALUE_INDEX),band->objectName(),dataBand->objectName()); + if (gf){ + connect(dataBand,SIGNAL(bandRendered(BandDesignIntf*)),gf,SLOT(slotBandRendered(BandDesignIntf*))); } + } else { + GroupFunction* gf = datasources()->addGroupFunction(functionName,captures.at(Const::VALUE_INDEX),band->objectName(),captures.at(dsIndex)); + gf->setInvalid(tr("Databand \"%1\" not found").arg(captures.at(dsIndex))); } - pos += rx.matchedLength(); } - } else if (rxName.indexIn(contentItem->content())>=0){ - GroupFunction* gf = datasources()->addGroupFunction(functionName,rxName.cap(1),band->objectName(),""); - gf->setInvalid(tr("Wrong using function %1").arg(functionName)); + pos += rx.matchedLength(); } + } else if (rxName.indexIn(contentItem->content())>=0){ + GroupFunction* gf = datasources()->addGroupFunction(functionName,rxName.cap(1),band->objectName(),""); + gf->setInvalid(tr("Wrong using function %1").arg(functionName)); } } } } - -void ReportRender::replaceGroupsFunction(BandDesignIntf *band) -{ - foreach(BaseDesignIntf* item,band->childBaseItems()){ +void ReportRender::extractGroupFunctionsFromContainer(BaseDesignIntf* baseItem, BandDesignIntf* band){ + foreach (BaseDesignIntf* item, baseItem->childBaseItems()) { ContentItemDesignIntf* contentItem = dynamic_cast(item); - if (contentItem){ - QString content = contentItem->content(); - foreach(const QString &functionName, m_datasources->groupFunctionNames()){ - QRegExp rx(QString(Const::GROUP_FUNCTION_RX).arg(functionName)); - if (rx.indexIn(content)>=0){ - int pos = 0; - while ( (pos = rx.indexIn(content,pos))!= -1 ){ - QVector captures = normalizeCaptures(rx); - if (captures.size() >= 3){ - QString expressionIndex = datasources()->putGroupFunctionsExpressions(captures.at(Const::VALUE_INDEX)); - content.replace(captures.at(0),QString("%1(%2,%3)").arg(functionName).arg('"'+expressionIndex+'"').arg('"'+band->objectName()+'"')); - } - pos += rx.matchedLength(); + if (contentItem) extractGroupFuntionsFromItem(contentItem, band); + else extractGroupFunctionsFromContainer(item, band); + } +} + +void ReportRender::extractGroupFunctions(BandDesignIntf *band) +{ + extractGroupFunctionsFromContainer(band, band); +} + + +void ReportRender::replaceGroupFunctionsInItem(ContentItemDesignIntf* contentItem, BandDesignIntf* band){ + if (contentItem){ + QString content = contentItem->content(); + foreach(const QString &functionName, m_datasources->groupFunctionNames()){ + QRegExp rx(QString(Const::GROUP_FUNCTION_RX).arg(functionName)); + if (rx.indexIn(content)>=0){ + int pos = 0; + while ( (pos = rx.indexIn(content,pos))!= -1 ){ + QVector captures = normalizeCaptures(rx); + if (captures.size() >= 3){ + QString expressionIndex = datasources()->putGroupFunctionsExpressions(captures.at(Const::VALUE_INDEX)); + content.replace(captures.at(0),QString("%1(%2,%3)").arg(functionName).arg('"'+expressionIndex+'"').arg('"'+band->objectName()+'"')); } - contentItem->setContent(content); + pos += rx.matchedLength(); } + contentItem->setContent(content); } } } } +void ReportRender::replaceGroupFunctionsInContainer(BaseDesignIntf* baseItem, BandDesignIntf* band) +{ + foreach(BaseDesignIntf* item, baseItem->childBaseItems()){ + ContentItemDesignIntf* contentItem = dynamic_cast(item); + if (contentItem) replaceGroupFunctionsInItem(contentItem, band); + else replaceGroupFunctionsInContainer(item, band); + } +} + +void ReportRender::replaceGroupsFunction(BandDesignIntf *band) +{ + replaceGroupFunctionsInContainer(band, band); +} + BandDesignIntf* ReportRender::renderBand(BandDesignIntf *patternBand, BandDesignIntf* bandData, ReportRender::DataRenderMode mode, bool isLast) { QApplication::processEvents(); @@ -413,7 +432,6 @@ BandDesignIntf* ReportRender::renderBand(BandDesignIntf *patternBand, BandDesign if (patternBand->isFooter()) m_lastRenderedFooter = patternBand; - bandClone->setBackgroundColor( (datasources()->variable(QLatin1String("line_")+patternBand->objectName().toLower()).toInt() %2 !=0 ? bandClone->backgroundColor(): @@ -431,6 +449,8 @@ BandDesignIntf* ReportRender::renderBand(BandDesignIntf *patternBand, BandDesign if (!bandClone->isEmpty() || patternBand->printIfEmpty()){ if (!registerBand(bandClone)){ + if (patternBand && patternBand->isHeader() && patternBand->reprintOnEachPage()) + m_reprintableBands.removeOne(patternBand); if (bandClone->canBeSplitted(m_maxHeightByColumn[m_currentColumn])){ bandClone = sliceBand(bandClone,patternBand,isLast); } else { @@ -488,6 +508,7 @@ void ReportRender::renderDataBand(BandDesignIntf *dataBand) IDataSource* bandDatasource = 0; m_lastRenderedFooter = 0; + if (!dataBand->datasourceName().isEmpty()) bandDatasource = datasources()->dataSource(dataBand->datasourceName()); @@ -507,7 +528,7 @@ void ReportRender::renderDataBand(BandDesignIntf *dataBand) if (dataBand->bandHeader() && dataBand->bandHeader()->reprintOnEachPage()) m_reprintableBands.append(dataBand->bandHeader()); - renderChildHeader(dataBand,PrintNotAlwaysPrintable); + //renderChildHeader(dataBand,PrintNotAlwaysPrintable); renderGroupHeader(dataBand, bandDatasource, true); bool firstTime = true; @@ -537,6 +558,7 @@ void ReportRender::renderDataBand(BandDesignIntf *dataBand) renderBand(header, 0, StartNewPageAsNeeded); renderBand(dataBand, rawData, StartNewPageAsNeeded, !bandDatasource->hasNext()); + m_newPageStarted = false; renderChildBands(dataBand); } @@ -557,7 +579,10 @@ void ReportRender::renderDataBand(BandDesignIntf *dataBand) m_reprintableBands.removeOne(dataBand->bandHeader()); - renderGroupFooter(dataBand); + if (bandDatasource->prior()){ + renderGroupFooter(dataBand); + bandDatasource->next(); + } if (footer && !footer->printAlways()) renderBand(footer, 0, StartNewPageAsNeeded); @@ -614,9 +639,9 @@ void ReportRender::renderPageItems(PageItemDesignIntf* patternPage) } m_renderPageItem->restoreLinks(); m_renderPageItem->updateSubItemsSize(FirstPass,m_datasources); -// foreach(BaseDesignIntf* item, pageItems){ -// item->updateItemSize(m_datasources); -// } + foreach(BaseDesignIntf* item, pageItems){ + item->setZValue(item->zValue()-100000); + } } qreal ReportRender::calcPageFooterHeight(PageItemDesignIntf *patternPage) @@ -638,7 +663,8 @@ void ReportRender::renderChildHeader(BandDesignIntf *parent, BandPrintMode print if (band->metaObject()->indexOfProperty("printAlways")>0){ printAlways=band->property("printAlways").toBool(); } - if (printAlways == (printMode==PrintAlwaysPrintable) ) renderBand(band, 0, StartNewPageAsNeeded); + if (printAlways == (printMode == PrintAlwaysPrintable)) + renderBand(band, 0, StartNewPageAsNeeded); } } @@ -662,9 +688,9 @@ void ReportRender::renderChildBands(BandDesignIntf *parentBand) if (!band->datasourceName().isEmpty()) ds = m_datasources->dataSource(band->datasourceName()); if (ds) ds->first(); - renderChildHeader(band,PrintAlwaysPrintable); + //renderChildHeader(band,PrintAlwaysPrintable); renderDataBand(band); - renderChildFooter(band,PrintAlwaysPrintable); + //renderChildFooter(band,PrintAlwaysPrintable); closeFooterGroup(band); } } @@ -675,7 +701,7 @@ void ReportRender::renderGroupHeader(BandDesignIntf *parentBand, IDataSource* da IGroupBand* gb = dynamic_cast(band); if (gb&&gb->isNeedToClose(m_datasources)){ if (band->childBands().count()>0){ - dataSource->prior(); + bool didGoBack = dataSource->prior(); foreach (BandDesignIntf* subBand, band->childrenByType(BandDesignIntf::GroupHeader)) { foreach(BandDesignIntf* footer, subBand->childrenByType(BandDesignIntf::GroupFooter)){ renderBand(footer, 0); @@ -687,7 +713,9 @@ void ReportRender::renderGroupHeader(BandDesignIntf *parentBand, IDataSource* da renderBand(footer, 0, StartNewPageAsNeeded); } - dataSource->next(); + if (didGoBack){ + dataSource->next(); + } } closeDataGroup(band); // if (gb->isNeedToStartNewPage()){ @@ -697,13 +725,19 @@ void ReportRender::renderGroupHeader(BandDesignIntf *parentBand, IDataSource* da } if (gb && !gb->isStarted()){ - if (band->reprintOnEachPage()) + if (band->reprintOnEachPage()){ m_reprintableBands.append(band); + } gb->startGroup(m_datasources); openDataGroup(band); - if (!firstTime && gb->startNewPage()){ + if (!firstTime && gb->startNewPage() && !m_newPageStarted){ if (gb->resetPageNumber()) resetPageNumber(BandReset); - renderBand(band, 0, ForcedStartPage); + if (band->reprintOnEachPage()){ + savePage(); + startNewPage(); + } else { + renderBand(band, 0, ForcedStartPage); + } } else { renderBand(band, 0, StartNewPageAsNeeded); } @@ -743,7 +777,7 @@ void ReportRender::initGroups() { m_datasources->clearGroupFunction(); foreach(BandDesignIntf* band, m_patternPageItem->childBands()){ - if (band->isFooter()) extractGroupsFunction(band); + if (band->isFooter()) extractGroupFunctions(band); if (band->isHeader()){ IGroupBand* gb = dynamic_cast(band); if (gb) gb->closeGroup(); @@ -818,6 +852,14 @@ void ReportRender::closeDataGroup(BandDesignIntf *band) if (groupBand){ groupBand->closeGroup(); if (band->reprintOnEachPage()) m_reprintableBands.removeOne(band); + + QList::Iterator it = m_reprintableBands.begin(); + while (it != m_reprintableBands.end()){ + if ((*it)->bandIndex()>band->bandIndex()) + it = m_reprintableBands.erase(it); + else + it++; + } } closeGroup(band); } @@ -857,7 +899,8 @@ bool ReportRender::registerBand(BandDesignIntf *band, bool registerInChildren) } } - if ( (band->columnsCount()>1) && !band->isHeader()){ + if ( (band->columnsCount()>1) && + (!band->isHeader() || (band->bandNestingLevel()>0 && band->columnsFillDirection() != BandDesignIntf::Horizontal ))){ if (m_maxHeightByColumn.size()!=band->columnsCount()){ for(int i=1;icolumnsCount();++i){ @@ -885,7 +928,8 @@ bool ReportRender::registerBand(BandDesignIntf *band, bool registerInChildren) m_maxHeightByColumn[m_currentColumn]-=band->height(); } - if (band->isHeader() && band->columnsCount()>1){ + if ( (band->columnsCount()>1) && + (band->isHeader() && (band->bandNestingLevel()==0 || band->columnsFillDirection()==BandDesignIntf::Horizontal))){ qreal bandPos = m_currentStartDataPos[m_currentColumn]; m_currentStartDataPos[m_currentColumn]+=band->height(); @@ -1042,8 +1086,9 @@ void ReportRender::startNewColumn(){ void ReportRender::startNewPage() { - m_renderPageItem=0; - m_currentColumn=0; + m_renderPageItem = 0; + m_currentColumn = 0; + m_newPageStarted = true; initColumns(); initRenderPage(); @@ -1065,14 +1110,13 @@ void ReportRender::startNewPage() m_dataAreaSize = m_maxHeightByColumn[m_currentColumn]; m_renderedDataBandCount = 0; - foreach (BandDesignIntf* band, m_reprintableBands) { renderBand(band, 0); } checkLostHeadersOnPrevPage(); pasteGroups(); - renderPageItems(m_patternPageItem); + } void ReportRender::resetPageNumber(ResetPageNuberType resetType) @@ -1205,6 +1249,11 @@ void ReportRender::moveTearOffBand(){ void ReportRender::savePage(bool isLast) { + + m_datasources->setReportVariable("#IS_LAST_PAGEFOOTER",isLast); + m_datasources->setReportVariable("#IS_FIRST_PAGEFOOTER",m_datasources->variable("#PAGE").toInt()==1); + + renderPageItems(m_patternPageItem); checkFooterGroup(m_lastDataBand); cutGroups(); rearrangeColumnsItems(); diff --git a/limereport/lrreportrender.h b/limereport/lrreportrender.h index 8e62b0b..3e9f26f 100644 --- a/limereport/lrreportrender.h +++ b/limereport/lrreportrender.h @@ -40,6 +40,7 @@ namespace LimeReport{ class PageDesignIntf; class BandDesignIntf; +class ContentItemDesignIntf; class GroupBandsHolder: public QList{ public: @@ -86,9 +87,7 @@ signals: public slots: void cancelRender(); private: - void baseDesignIntfToScript(BaseDesignIntf* item); - void renderPage(PageDesignIntf *patternPage); void initDatasources(); void initDatasource(const QString &name); @@ -112,9 +111,12 @@ private: void renderChildBands(BandDesignIntf* parentBand); void renderGroupHeader(BandDesignIntf* parentBand, IDataSource* dataSource, bool firstTime); void renderGroupFooter(BandDesignIntf* parentBand); - void initGroups(); - void extractGroupsFunction(BandDesignIntf* band); + void extractGroupFuntionsFromItem(ContentItemDesignIntf* contentItem, BandDesignIntf* band); + void extractGroupFunctionsFromContainer(BaseDesignIntf* baseItem, BandDesignIntf* band); + void extractGroupFunctions(BandDesignIntf* band); + void replaceGroupFunctionsInItem(ContentItemDesignIntf* contentItem, BandDesignIntf* band); + void replaceGroupFunctionsInContainer(BaseDesignIntf* baseItem, BandDesignIntf* band); void replaceGroupsFunction(BandDesignIntf* band); void popPageFooterGroupValues(BandDesignIntf* dataBand); @@ -183,6 +185,8 @@ private: QList m_ranges; QVector m_columnedBandItems; unsigned long long m_curentNameIndex; + bool m_newPageStarted; + }; } // namespace LimeReport diff --git a/limereport/lrscriptenginemanager.cpp b/limereport/lrscriptenginemanager.cpp index f8d157d..720df9d 100644 --- a/limereport/lrscriptenginemanager.cpp +++ b/limereport/lrscriptenginemanager.cpp @@ -216,7 +216,11 @@ QScriptValue setVariable(QScriptContext* pcontext, QScriptEngine* /*pengine*/){ ScriptEngineManager* sm = qscriptvalue_cast(pcontext->callee().data()); DataSourceManager* dm = sm->dataManager(); - dm->changeVariable(name,value); + if (dm->containsVariable(name)) + dm->changeVariable(name,value); + else + dm->addVariable(name, value); + return QScriptValue(); } @@ -268,6 +272,35 @@ QScriptValue currencyUSBasedFormat(QScriptContext* pcontext, QScriptEngine* peng return pengine->newVariant(vTempStr); } #endif +/* + * sectotimeFormat(int seconds, string format) + * - convert seconds to time format without day border! + * + * examples (base: 60 days 7 Minutes 2 Seconds = 5184422 seconds): + * (3600 * 24 * 60) + (7 * 60) + 2 seconds with format hh:mm:ss = 1440:07:02 + * (3600 * 24 * 60) + (7 * 60) + 2 seconds with format mm:s = 86407:2 + * (3600 * 24 * 60) + (7 * 60) + 2 seconds with format ss = 5184422 + */ +QScriptValue sectotimeFormat(QScriptContext* pcontext, QScriptEngine* pengine){ + // simplify values + QVariant value = pcontext->argument(0).toVariant(); + QString format = (pcontext->argumentCount()>1)?pcontext->argument(1).toString().toLatin1():"hh:mm:ss"; + + // algorithm adapted from: https://stackoverflow.com/a/25697134/4954370 + int seconds = value.toInt(); + int minutes = seconds / 60; + int hours = minutes / 60; + + // replace the following formats: hh, mm, ss, h, m, s + bool hasHour = format.contains("h"); + bool hasMinute = format.contains("m"); + for(int len = 2; len; len--) { + if(hasHour) format.replace(QString('h').repeated(len), QString::number(hours).rightJustified(len, '0')); + if(hasMinute) format.replace(QString('m').repeated(len), QString::number(hasHour ? minutes % 60 : minutes).rightJustified(len, '0')); + format.replace(QString('s').repeated(len), QString::number(hasMinute ? seconds % 60 : seconds).rightJustified(len, '0')); + } + return QScriptValue(format); +} QScriptValue dateFormat(QScriptContext* pcontext, QScriptEngine* pengine){ QVariant value = pcontext->argument(0).toVariant(); QString format = (pcontext->argumentCount()>1)?pcontext->argument(1).toString().toLatin1():"dd.MM.yyyy"; @@ -427,7 +460,7 @@ void ScriptEngineManager::setDataManager(DataSourceManager *dataManager){ if (m_dataManager){ foreach(QString func, m_dataManager->groupFunctionNames()){ if (isFunctionExists(func)) deleteFunction(func); - addFunction(func, groupFunction,"GROUP FUNCTIONS", func+"(\""+tr("Value")+"\",\""+tr("BandName")+"\")"); + addFunction(func, groupFunction,tr("GROUP FUNCTIONS"), func+"(\""+tr("Value")+"\",\""+tr("BandName")+"\")"); } foreach(ScriptFunctionDesc func, m_functions){ if (func.type==ScriptFunctionDesc::Native) @@ -551,9 +584,9 @@ QString ScriptEngineManager::expandScripts(QString context, QVariant& varValue, if (reportItem){ QScriptValue svThis = se->globalObject().property("THIS"); if (svThis.isValid()){ - se->newQObject(svThis, this); + se->newQObject(svThis, reportItem); } else { - svThis = se->newQObject(this); + svThis = se->newQObject(reportItem); se->globalObject().setProperty("THIS",svThis); } } @@ -612,22 +645,23 @@ ScriptEngineManager::ScriptEngineManager() m_scriptEngine = new QScriptEngine; //addFunction("dateToStr",dateToStr,"DATE", "dateToStr(\"value\",\"format\")"); - addFunction("line",line,"SYSTEM", "line(\""+tr("BandName")+"\")"); - addFunction("numberFormat",numberFormat,"NUMBER", "numberFormat(\""+tr("Value")+"\",\""+tr("Format")+"\",\""+ + addFunction("line",line,tr("SYSTEM"), "line(\""+tr("BandName")+"\")"); + addFunction("numberFormat",numberFormat,tr("NUMBER"), "numberFormat(\""+tr("Value")+"\",\""+tr("Format")+"\",\""+ tr("Precision")+"\",\""+ tr("Locale")+"\")"); - addFunction("dateFormat",dateFormat,"DATE&TIME", "dateFormat(\""+tr("Value")+"\",\""+tr("Format")+"\")"); - addFunction("timeFormat",timeFormat,"DATE&TIME", "dateFormat(\""+tr("Value")+"\",\""+tr("Format")+"\")"); - addFunction("dateTimeFormat", dateTimeFormat, "DATE&TIME", "dateTimeFormat(\""+tr("Value")+"\",\""+tr("Format")+"\")"); - addFunction("date",date,"DATE&TIME","date()"); - addFunction("now",now,"DATE&TIME","now()"); + addFunction("sectotimeFormat",sectotimeFormat,tr("DATE&TIME"), "sectotimeFormat(\""+tr("Seconds")+"\",\""+tr("Format")+"\")"); + addFunction("dateFormat",dateFormat,tr("DATE&TIME"), "dateFormat(\""+tr("Value")+"\",\""+tr("Format")+"\")"); + addFunction("timeFormat",timeFormat,tr("DATE&TIME"), "dateFormat(\""+tr("Value")+"\",\""+tr("Format")+"\")"); + addFunction("dateTimeFormat", dateTimeFormat, tr("DATE&TIME"), "dateTimeFormat(\""+tr("Value")+"\",\""+tr("Format")+"\")"); + addFunction("date",date,tr("DATE&TIME"),"date()"); + addFunction("now",now,tr("DATE&TIME"),"now()"); #if QT_VERSION>0x040800 - addFunction("currencyFormat",currencyFormat,"NUMBER","currencyFormat(\""+tr("Value")+"\",\""+tr("Locale")+"\")"); - addFunction("currencyUSBasedFormat",currencyUSBasedFormat,"NUMBER","currencyUSBasedFormat(\""+tr("Value")+",\""+tr("CurrencySymbol")+"\")"); + addFunction("currencyFormat",currencyFormat,tr("NUMBER"),"currencyFormat(\""+tr("Value")+"\",\""+tr("Locale")+"\")"); + addFunction("currencyUSBasedFormat",currencyUSBasedFormat,tr("NUMBER"),"currencyUSBasedFormat(\""+tr("Value")+",\""+tr("CurrencySymbol")+"\")"); #endif - addFunction("setVariable", setVariable, "GENERAL", "setVariable(\""+tr("Name")+"\",\""+tr("Value")+"\")"); - addFunction("getVariable", getVariable, "GENERAL", "getVariable(\""+tr("Name")+"\")"); - addFunction("getField", getField, "GENERAL", "getField(\""+tr("Name")+"\")"); + addFunction("setVariable", setVariable, tr("GENERAL"), "setVariable(\""+tr("Name")+"\",\""+tr("Value")+"\")"); + addFunction("getVariable", getVariable, tr("GENERAL"), "getVariable(\""+tr("Name")+"\")"); + addFunction("getField", getField, tr("GENERAL"), "getField(\""+tr("Name")+"\")"); QScriptValue colorCtor = m_scriptEngine->newFunction(constructColor); m_scriptEngine->globalObject().setProperty("QColor", colorCtor); diff --git a/limereport/lrvariablesholder.cpp b/limereport/lrvariablesholder.cpp index ed98f83..9cdf630 100644 --- a/limereport/lrvariablesholder.cpp +++ b/limereport/lrvariablesholder.cpp @@ -61,8 +61,9 @@ void VariablesHolder::addVariable(const QString& name, const QVariant& value, Va m_varNames.insert(name,varValue); if (type==VarDesc::Report) m_userVariables.append(varValue); + emit variableHasBeenAdded(name); } else { - throw ReportError(tr("variable with name ")+name+tr(" already exists !!")); + throw ReportError(tr("variable with name ")+name+tr(" already exists!")); } } @@ -77,7 +78,7 @@ VarDesc::VarType VariablesHolder::variableType(const QString &name) { if (m_varNames.contains(name)) return m_varNames.value(name)->varType(); - else throw ReportError(tr("variable with name ")+name+tr(" does not exists !!")); + else throw ReportError(tr("variable with name ")+name+tr(" does not exists!")); } void VariablesHolder::deleteVariable(const QString &name) @@ -86,6 +87,7 @@ void VariablesHolder::deleteVariable(const QString &name) m_userVariables.removeOne(m_varNames.value(name)); delete m_varNames.value(name); m_varNames.remove(name); + emit variableHasBennDeleted(name); } } @@ -93,8 +95,9 @@ void VariablesHolder::changeVariable(const QString &name, const QVariant &value) { if(m_varNames.contains(name)) { m_varNames.value(name)->setValue(value); + emit variableHasBeenChanged(name); } else - throw ReportError(tr("variable with name ")+name+tr(" does not exists !!")); + throw ReportError(tr("variable with name ")+name+tr(" does not exists!")); } void VariablesHolder::clearUserVariables() @@ -142,7 +145,7 @@ RenderPass VariablesHolder::variablePass(const QString &name) { if (m_varNames.contains(name)) return m_varNames.value(name)->renderPass(); - else throw ReportError(tr("variable with name ")+name+tr(" does not exists !!")); + else throw ReportError(tr("variable with name ")+name+tr(" does not exists!")); } }// namespace LimeReport diff --git a/limereport/lrvariablesholder.h b/limereport/lrvariablesholder.h index ede1ac6..5c97bbe 100644 --- a/limereport/lrvariablesholder.h +++ b/limereport/lrvariablesholder.h @@ -27,8 +27,8 @@ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * * GNU General Public License for more details. * ****************************************************************************/ -#ifndef VARIABLEHOLDER_H -#define VARIABLEHOLDER_H +#ifndef LRVARIABLEHOLDER_H +#define LRVARIABLEHOLDER_H #include #include @@ -92,6 +92,9 @@ public: int userVariablesCount(); VarDesc* userVariableAt(int index); signals: + void variableHasBeenAdded(const QString& variableName); + void variableHasBeenChanged(const QString& variableName); + void variableHasBennDeleted(const QString& variableName); private: QMap m_varNames; QList m_userVariables; diff --git a/limereport/objectinspector/editors/lrtextitempropertyeditor.h b/limereport/objectinspector/editors/lrtextitempropertyeditor.h index fec9afc..367941b 100644 --- a/limereport/objectinspector/editors/lrtextitempropertyeditor.h +++ b/limereport/objectinspector/editors/lrtextitempropertyeditor.h @@ -27,8 +27,8 @@ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * * GNU General Public License for more details. * ****************************************************************************/ -#ifndef ATEXTITEMPROPERTYEDITOR_H -#define ATEXTITEMPROPERTYEDITOR_H +#ifndef LRTEXTITEMPROPERTYEDITOR_H +#define LRTEXTITEMPROPERTYEDITOR_H #include #include diff --git a/limereport/objectinspector/lrobjectitemmodel.cpp b/limereport/objectinspector/lrobjectitemmodel.cpp index c79480a..080a7a2 100644 --- a/limereport/objectinspector/lrobjectitemmodel.cpp +++ b/limereport/objectinspector/lrobjectitemmodel.cpp @@ -83,6 +83,57 @@ void QObjectPropertyModel::translatePropertyName() tr("shape"); tr("shapeBrush"); tr("shapeBrushColor"); + tr("gridStep"); + tr("fullPage"); + tr("oldPrintMode"); + tr("borderColor"); + tr("resetPageNumber"); + tr("alternateBackgroundColor"); + tr("backgroundBrushStyle"); + tr("columnCount"); + tr("startFromNewPage"); + tr("startNewPage"); + tr("adaptFontToSize"); + tr("allowHTML"); + tr("allowHTMLInFields"); + tr("backgroundBrushStyle"); + tr("followTo"); + tr("format"); + tr("lineSpacing"); + tr("textIndent"); + tr("textLayoutDirection"); + tr("underlineLineSize"); + tr("underlines"); + tr("valueType"); + tr("securityLevel"); + tr("testValue"); + tr("whitespace"); + tr("resourcePath"); + tr("scale"); + tr("cornerRadius"); + tr("shapeColor"); + tr("layoutType"); + tr("barcodeType"); + tr("barcodeWidth"); + tr("foregroundColor"); + tr("inputMode"); + tr("pdf417CodeWords"); + tr("autoSize"); + tr("center"); + tr("field"); + tr("image"); + tr("keepAspectRatio"); + tr("columnsCount"); + tr("useAlternateBackgroundColor"); + tr("printBeforePageHeader"); + tr("maxScalePercent"); + tr("printOnFirstPage"); + tr("printOnLastPage"); + tr("printAlways"); + tr("repeatOnEachRow"); + tr("condition"); + tr("groupFieldName"); + tr("keepGroupTogether"); } void QObjectPropertyModel::clearObjectsList() diff --git a/limereport/objectinspector/lrpropertydelegate.cpp b/limereport/objectinspector/lrpropertydelegate.cpp index 3abfb32..170ccd3 100644 --- a/limereport/objectinspector/lrpropertydelegate.cpp +++ b/limereport/objectinspector/lrpropertydelegate.cpp @@ -74,7 +74,8 @@ void LimeReport::PropertyDelegate::paint(QPainter *painter, const QStyleOptionVi option.rect.y()+option.rect.height() ); painter->save(); - painter->setPen(option.palette.color(QPalette::Dark)); + QColor color = static_cast(QApplication::style()->styleHint(QStyle::SH_Table_GridLineColor, &option)); + painter->setPen(color); painter->drawLine(start,end); painter->restore(); } diff --git a/limereport/objectinspector/propertyItems/lrcontentpropitem.h b/limereport/objectinspector/propertyItems/lrcontentpropitem.h index ead771f..3c91b27 100644 --- a/limereport/objectinspector/propertyItems/lrcontentpropitem.h +++ b/limereport/objectinspector/propertyItems/lrcontentpropitem.h @@ -1,5 +1,5 @@ -#ifndef CONTENTPROPITEM_H -#define CONTENTPROPITEM_H +#ifndef LRCONTENTPROPITEM_H +#define LRCONTENTPROPITEM_H #include "lrstringpropitem.h" #include "objectinspector/editors/lrbuttonlineeditor.h" diff --git a/limereport/objectinspector/propertyItems/lrenumpropitem.cpp b/limereport/objectinspector/propertyItems/lrenumpropitem.cpp index dcd7937..36ebe26 100644 --- a/limereport/objectinspector/propertyItems/lrenumpropitem.cpp +++ b/limereport/objectinspector/propertyItems/lrenumpropitem.cpp @@ -54,10 +54,10 @@ QWidget *EnumPropItem::createProperyEditor(QWidget *parent) const QStringList enumValues; QMetaEnum propEnum = object()->metaObject()->property(object()->metaObject()->indexOfProperty(propertyName().toLatin1())).enumerator(); for (int i=0;imetaObject()->property(object()->metaObject()->indexOfProperty(propertyName().toLatin1())).enumerator(); + for (int i=0;i(propertyEditor); @@ -90,13 +149,13 @@ void EnumPropItem::setModelData(QWidget *propertyEditor, QAbstractItemModel *mod QString EnumPropItem::nameByType(int value) const { QMetaEnum propEnum = object()->metaObject()->property(object()->metaObject()->indexOfProperty(propertyName().toLatin1())).enumerator(); - return propEnum.valueToKey(value); + return tr(propEnum.valueToKey(value)); } int EnumPropItem::typeByName(const QString &value) const { QMetaEnum propEnum = object()->metaObject()->property(object()->metaObject()->indexOfProperty(propertyName().toLatin1())).enumerator(); - return propEnum.keyToValue(value.toLatin1()); + return propEnum.keyToValue(m_translation.value(value).toLatin1()); } QString EnumPropItem::displayValue() const diff --git a/limereport/objectinspector/propertyItems/lrenumpropitem.h b/limereport/objectinspector/propertyItems/lrenumpropitem.h index 268cc3d..4553d10 100644 --- a/limereport/objectinspector/propertyItems/lrenumpropitem.h +++ b/limereport/objectinspector/propertyItems/lrenumpropitem.h @@ -31,17 +31,18 @@ #define LRENUMPROPITEM_H #include "lrobjectpropitem.h" +#include namespace LimeReport{ class EnumPropItem : public ObjectPropItem { Q_OBJECT public: - EnumPropItem():ObjectPropItem(), m_settingValue(false){} + EnumPropItem():ObjectPropItem(), m_settingValue(false){initTranslation();} EnumPropItem(QObject* object, ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& value,ObjectPropItem* parent, bool readonly) - :ObjectPropItem(object, objects, name, displayName, value, parent, readonly),m_settingValue(false){} + :ObjectPropItem(object, objects, name, displayName, value, parent, readonly),m_settingValue(false){initTranslation();} EnumPropItem(QObject* object, ObjectsList* objects, const QString& name, const QString& displayName, const QVariant& value,ObjectPropItem* parent, bool readonly, QVector acceptableValues) - :ObjectPropItem(object, objects, name, displayName, value, parent, readonly),m_acceptableValues(acceptableValues),m_settingValue(false){} + :ObjectPropItem(object, objects, name, displayName, value, parent, readonly),m_acceptableValues(acceptableValues),m_settingValue(false){initTranslation();} QWidget* createProperyEditor(QWidget *parent) const; QString displayValue() const; void setPropertyEditorData(QWidget * propertyEditor, const QModelIndex &) const; @@ -52,9 +53,13 @@ protected: int typeByName(const QString& propertyValue) const; private slots: void slotEnumChanged(const QString& text); +private: + void initTranslation(); + void translateEnumItemName(); private: QVector m_acceptableValues; bool m_settingValue; + QMap m_translation; }; } #endif // LRENUMPROPITEM_H diff --git a/limereport/objectinspector/propertyItems/lrflagspropitem.cpp b/limereport/objectinspector/propertyItems/lrflagspropitem.cpp index 5b56e85..987ec94 100644 --- a/limereport/objectinspector/propertyItems/lrflagspropitem.cpp +++ b/limereport/objectinspector/propertyItems/lrflagspropitem.cpp @@ -59,12 +59,14 @@ void FlagsPropItem::createChildren() QMetaEnum propEnum = object()->metaObject()->property(object()->metaObject()->indexOfProperty(propertyName().toLatin1())).enumerator(); for (int i=0;iappendItem(new LimeReport::FlagPropItem( - object(), objects(), QString(propEnum.key(i)), QString(propEnum.key(i)), - bool((propertyValue().toInt() & propEnum.keyToValue(propEnum.key(i)))==propEnum.keyToValue(propEnum.key(i))), - this, false - ) - ); + if ( propEnum.keyToValue(propEnum.key(i)) !=0 ) { + this->appendItem(new LimeReport::FlagPropItem( + object(), objects(), QString(propEnum.key(i)), tr(propEnum.key(i)), + bool((propertyValue().toInt() & propEnum.keyToValue(propEnum.key(i)))==propEnum.keyToValue(propEnum.key(i))), + this, false + ) + ); + } } } @@ -94,10 +96,10 @@ QString FlagsPropItem::displayValue() const QMetaEnum propEnum = object()->metaObject()->property(object()->metaObject()->indexOfProperty(propertyName().toLatin1())).enumerator(); for (int i=0;i(propertyEditor)->isChecked(); model->setData(index,value); int flags = object()->property(parent()->propertyName().toLatin1()).toInt(); - if (value) flags=flags | valueByName(displayName()); - else if (flags&valueByName(displayName())) flags=flags ^ valueByName(displayName()); + if (value) flags = flags | valueByName(propertyName()); + else if (flags & valueByName(propertyName())) flags = flags ^ valueByName(propertyName()); setValueToObject(parent()->propertyName(),flags); parent()->setPropertyValue(flags); } diff --git a/limereport/objectinspector/propertyItems/lrflagspropitem.h b/limereport/objectinspector/propertyItems/lrflagspropitem.h index 7213d4d..1005a8b 100644 --- a/limereport/objectinspector/propertyItems/lrflagspropitem.h +++ b/limereport/objectinspector/propertyItems/lrflagspropitem.h @@ -46,6 +46,8 @@ public: virtual void setPropertyValue(QVariant propertyValue); private slots: void slotEnumChanged(QString); +private: + void translateFlagsItem(); private: QSet m_acceptableValues; QString nameByType(int propertyValue) const; diff --git a/limereport/objectsbrowser/lrobjectbrowser.cpp b/limereport/objectsbrowser/lrobjectbrowser.cpp index 5eff56d..e657a81 100644 --- a/limereport/objectsbrowser/lrobjectbrowser.cpp +++ b/limereport/objectsbrowser/lrobjectbrowser.cpp @@ -94,6 +94,11 @@ void ObjectBrowser::fillNode(QTreeWidgetItem* parentNode, BaseDesignIntf* report treeItem->setIcon(0,QIcon(":/items/"+extractClassName(item->metaObject()->className()))); connect(item, SIGNAL(propertyObjectNameChanged(QString,QString)), this, SLOT(slotPropertyObjectNameChanged(QString,QString))); + ItemDesignIntf* i = dynamic_cast(item); + if (i){ + connect(i, SIGNAL(itemLocationChanged(BaseDesignIntf*,BaseDesignIntf*)), + this, SLOT(slotItemParentChanged(BaseDesignIntf*,BaseDesignIntf*))); + } m_itemsMap.insert(item,treeItem); parentNode->addChild(treeItem); if (!item->childBaseItems().isEmpty()) @@ -278,6 +283,19 @@ void ObjectBrowser::slotActivePageUpdated(LimeReport::PageDesignIntf *) buildTree(); } +void ObjectBrowser::slotItemParentChanged(BaseDesignIntf* item, BaseDesignIntf* parent) +{ + if (m_itemsMap.contains(item) && m_itemsMap.contains(parent)){ + m_itemsMap.value(item)->parent()->removeChild(m_itemsMap.value(item)); + m_itemsMap.value(parent)->addChild(m_itemsMap.value(item)); + m_changingItemSelection = true; + m_itemsMap.value(item)->setSelected(true); + item->setSelected(true); + m_changingItemSelection = false; + } + +} + void ObjectBrowserNode::setObject(QObject *value) { m_object = value; diff --git a/limereport/objectsbrowser/lrobjectbrowser.h b/limereport/objectsbrowser/lrobjectbrowser.h index ceddbec..4bdcb52 100644 --- a/limereport/objectsbrowser/lrobjectbrowser.h +++ b/limereport/objectsbrowser/lrobjectbrowser.h @@ -75,6 +75,7 @@ private slots: void slotMultiItemSelected(); void slotItemDoubleClicked(QTreeWidgetItem* item,int); void slotActivePageUpdated(LimeReport::PageDesignIntf*); + void slotItemParentChanged(BaseDesignIntf* item, BaseDesignIntf* parent); private: ReportDesignWidget* m_report; QMainWindow* m_mainWindow; diff --git a/translations/limereport_ar.ts b/translations/limereport_ar.ts index a9354e5..10ebbf1 100644 --- a/translations/limereport_ar.ts +++ b/translations/limereport_ar.ts @@ -398,6 +398,70 @@ p, li { white-space: pre-wrap; } Splittable + + DataBand + + + + DataHeaderBand + + + + DataFooterBand + + + + ReportHeader + + + + ReportFooter + + + + PageHeader + + + + PageFooter + + + + SubDetailBand + + + + SubDetailHeaderBand + + + + SubDetailFooterBand + + + + GroupBandHeader + + + + GroupBandFooter + + + + TearOffBand + + + + Keep bottom space + + + + Start from new page + + + + Start new page + + LimeReport::BaseDesignIntf @@ -497,7 +561,7 @@ p, li { white-space: pre-wrap; } already exists - موجود مسبقاً + موجود مسبقاً ... @@ -519,6 +583,10 @@ p, li { white-space: pre-wrap; } defaultConnection + + already exists! + + LimeReport::ContentItemDesignIntf @@ -587,7 +655,7 @@ p, li { white-space: pre-wrap; } Do you really want to delete "%1" connection ? Do you really want delete "%1" connection ? - هل ترغب في حذف الإتصال "%1" ? + هل ترغب في حذف الإتصال "%1" ? User variables @@ -600,7 +668,7 @@ p, li { white-space: pre-wrap; } Do you really want to delete "%1" datasource ? Do you really want delete "%1" datasource ? - هل ترغب في حذف مصدر البيانات "%1" ? + هل ترغب في حذف مصدر البيانات "%1" ? Do you really want delete variable "%1" ? @@ -616,7 +684,7 @@ p, li { white-space: pre-wrap; } Do you really want to delete variable "%1" ? - هل ترغب في حذف المتغير "%1" ? + هل ترغب في حذف المتغير "%1" ? Grab variable @@ -630,6 +698,18 @@ p, li { white-space: pre-wrap; } External variables + + Do you really want to delete "%1" connection? + + + + Do you really want to delete "%1" datasource? + + + + Do you really want to delete variable "%1"? + + LimeReport::DataFooterBand @@ -653,16 +733,16 @@ p, li { white-space: pre-wrap; } Datasource "%1" not found ! - الإتصال "%1" غير موجود ! + الإتصال "%1" غير موجود ! connection with name "%1" already exists ! - الإتصال بأسم "%1" موجود مسبقاً ! + الإتصال بأسم "%1" موجود مسبقاً ! datasource with name "%1" already exists ! data source with name "%1" already exists !! - مصدر البيانات بأسم "%1" موجود مسبقاً ! + مصدر البيانات بأسم "%1" موجود مسبقاً ! invalid connection @@ -676,6 +756,18 @@ p, li { white-space: pre-wrap; } Database "%1" not found + + Datasource "%1" not found! + + + + Connection with name "%1" already exists! + + + + Datasource with name "%1" already exists! + + LimeReport::DataSourceModel @@ -692,6 +784,220 @@ p, li { white-space: pre-wrap; } + + LimeReport::EnumPropItem + + Default + + + + Portrait + + + + Landscape + + + + NoneAutoWidth + + + + MaxWordLength + + + + MaxStringLength + + + + TransparentMode + + + + OpaqueMode + + + + Angle0 + + + + Angle90 + + + + Angle180 + + + + Angle270 + + + + Angle45 + + + + Angle315 + + + + DateTime + + + + Double + + + + NoBrush + + + + SolidPattern + + + + Dense1Pattern + + + + Dense2Pattern + + + + Dense3Pattern + + + + Dense4Pattern + + + + Dense5Pattern + + + + Dense6Pattern + + + + Dense7Pattern + + + + HorPattern + + + + VerPattern + + + + CrossPattern + + + + BDiagPattern + + + + FDiagPattern + + + + LeftToRight + + + + RightToLeft + + + + LayoutDirectionAuto + + + + LeftItemAlign + + + + RightItemAlign + + + + CenterItemAlign + + + + ParentWidthItemAlign + + + + DesignedItemAlign + + + + HorizontalLine + + + + VerticalLine + + + + Ellipse + + + + Rectangle + + + + Page + + + + Band + + + + Horizontal + + + + Vertical + + + + VerticalUniform + + + + + LimeReport::FlagsPropItem + + NoLine + + + + TopLine + خط علوي + + + BottomLine + خط سفلي + + + LeftLine + خط أيسر + + + RightLine + خط أيمن + + LimeReport::FontEditorWidget @@ -748,7 +1054,7 @@ p, li { white-space: pre-wrap; } - Datasource "%1" not found !!! + Datasource "%1" not found! @@ -778,6 +1084,17 @@ p, li { white-space: pre-wrap; } صورة + + LimeReport::ItemLocationPropItem + + Band + + + + Page + + + LimeReport::ItemsAlignmentEditorWidget @@ -1252,6 +1569,202 @@ p, li { white-space: pre-wrap; } bottomMargin + + gridStep + + + + fullPage + + + + oldPrintMode + + + + borderColor + + + + resetPageNumber + + + + alternateBackgroundColor + + + + backgroundBrushStyle + + + + startFromNewPage + + + + startNewPage + + + + adaptFontToSize + + + + allowHTML + + + + allowHTMLInFields + + + + followTo + + + + format + + + + lineSpacing + + + + textIndent + + + + textLayoutDirection + + + + underlineLineSize + + + + underlines + + + + valueType + + + + securityLevel + + + + testValue + + + + whitespace + + + + resourcePath + + + + scale + + + + cornerRadius + + + + shapeColor + + + + layoutType + + + + barcodeType + + + + barcodeWidth + + + + foregroundColor + + + + inputMode + + + + pdf417CodeWords + + + + autoSize + + + + center + + + + field + الحقل + + + image + + + + keepAspectRatio + + + + columnsCount + + + + useAlternateBackgroundColor + + + + printBeforePageHeader + + + + maxScalePercent + + + + printOnFirstPage + + + + printOnLastPage + + + + printAlways + + + + repeatOnEachRow + + + + condition + + + + groupFieldName + + + + keepGroupTogether + + LimeReport::RectMMPropItem @@ -1281,10 +1794,6 @@ p, li { white-space: pre-wrap; } Report file name أسم التقرير - - Page - - Script @@ -1490,7 +1999,7 @@ p, li { white-space: pre-wrap; } Report has been modified ! Do you want save the report ? - تم تعديل التقرير ! هل تريد حفظ التعديلات ? + تم تعديل التقرير ! هل تريد حفظ التعديلات ? Report file name @@ -1552,6 +2061,10 @@ p, li { white-space: pre-wrap; } Script Browser + + Report has been modified! Do you want save the report? + + LimeReport::ReportEnginePrivate @@ -1667,15 +2180,15 @@ This preview is no longer valid. Datasource Name is empty ! - أسم مصدر البيانات فارغ ! + أسم مصدر البيانات فارغ ! SQL is empty ! - SQL فارغة ! + SQL فارغة ! Datasource with name: "%1" already exists ! - مصدر البيانات بأسم: "%1" موجود مسبقاً ! + مصدر البيانات بأسم: "%1" موجود مسبقاً ! Datasource with name %1 already exist @@ -1709,6 +2222,18 @@ This preview is no longer valid. defaultConnection + + Datasource Name is empty! + + + + SQL is empty! + + + + Datasource with name: "%1" already exists! + + LimeReport::ScriptBrowser @@ -1802,6 +2327,26 @@ This preview is no longer valid. Variable %1 not found المتغير %1 غير موجود + + GROUP FUNCTIONS + + + + SYSTEM + + + + NUMBER + + + + DATE&TIME + + + + GENERAL + + LimeReport::SettingDialog @@ -1917,7 +2462,7 @@ This preview is no longer valid. - TextItem " %1 " not found ! + TextItem " %1 " not found! @@ -1976,11 +2521,19 @@ This preview is no longer valid. already exists !! - موجود مسبقاً !! + موجود مسبقاً !! does not exists !! - غير موجود !! + غير موجود !! + + + already exists! + + + + does not exists! + @@ -2154,7 +2707,7 @@ This preview is no longer valid. Master datasource "%1" not found! - مصدر البيانات الرئيسي "%1" غير موجود! + مصدر البيانات الرئيسي "%1" غير موجود! Child @@ -2178,7 +2731,7 @@ This preview is no longer valid. Object with name %1 already exists - أسم الكائن %1 уже موجود مسبقاً + أسم الكائن %1 уже موجود مسبقاً Function %1 not found or have wrong arguments @@ -2232,10 +2785,6 @@ This preview is no longer valid. content المحتوى - - Master datasource "%1" not found!!! - - Master datasouce "%1" not found! @@ -2292,6 +2841,10 @@ This preview is no longer valid. Wrong file format + + Object with name %1 already exists! + + SQLEditDialog diff --git a/translations/limereport_es_ES.ts b/translations/limereport_es_ES.ts index bc96385..d5b0def 100644 --- a/translations/limereport_es_ES.ts +++ b/translations/limereport_es_ES.ts @@ -265,6 +265,70 @@ p, li { white-space: pre-wrap; } Splittable + + DataBand + + + + DataHeaderBand + + + + DataFooterBand + + + + ReportHeader + + + + ReportFooter + + + + PageHeader + + + + PageFooter + + + + SubDetailBand + + + + SubDetailHeaderBand + + + + SubDetailFooterBand + + + + GroupBandHeader + + + + GroupBandFooter + + + + TearOffBand + + + + Keep bottom space + + + + Start from new page + + + + Start new page + + LimeReport::BaseDesignIntf @@ -372,7 +436,7 @@ p, li { white-space: pre-wrap; } already exists - ya existe + ya existe Use default application connection @@ -386,6 +450,10 @@ p, li { white-space: pre-wrap; } defaultConnection + + already exists! + + LimeReport::ContentItemDesignIntf @@ -457,7 +525,7 @@ p, li { white-space: pre-wrap; } Do you really want to delete "%1" connection ? - Realmente quieres borrar la conexion "%1"? + Realmente quieres borrar la conexion "%1"? User variables @@ -467,14 +535,6 @@ p, li { white-space: pre-wrap; } System variables Variables del sistema - - Do you really want to delete "%1" datasource ? - - - - Do you really want to delete variable "%1" ? - - Error @@ -491,6 +551,18 @@ p, li { white-space: pre-wrap; } External variables + + Do you really want to delete "%1" connection? + + + + Do you really want to delete "%1" datasource? + + + + Do you really want to delete variable "%1"? + + LimeReport::DataFooterBand @@ -516,18 +588,6 @@ p, li { white-space: pre-wrap; } Variable "%1" not found! - - Datasource "%1" not found ! - - - - connection with name "%1" already exists ! - - - - datasource with name "%1" already exists ! - - invalid connection @@ -536,6 +596,18 @@ p, li { white-space: pre-wrap; } Database "%1" not found + + Datasource "%1" not found! + + + + Connection with name "%1" already exists! + + + + Datasource with name "%1" already exists! + + LimeReport::DataSourceModel @@ -552,6 +624,220 @@ p, li { white-space: pre-wrap; } + + LimeReport::EnumPropItem + + Default + + + + Portrait + + + + Landscape + + + + NoneAutoWidth + + + + MaxWordLength + + + + MaxStringLength + + + + TransparentMode + + + + OpaqueMode + + + + Angle0 + + + + Angle90 + + + + Angle180 + + + + Angle270 + + + + Angle45 + + + + Angle315 + + + + DateTime + + + + Double + + + + NoBrush + + + + SolidPattern + + + + Dense1Pattern + + + + Dense2Pattern + + + + Dense3Pattern + + + + Dense4Pattern + + + + Dense5Pattern + + + + Dense6Pattern + + + + Dense7Pattern + + + + HorPattern + + + + VerPattern + + + + CrossPattern + + + + BDiagPattern + + + + FDiagPattern + + + + LeftToRight + + + + RightToLeft + + + + LayoutDirectionAuto + + + + LeftItemAlign + + + + RightItemAlign + + + + CenterItemAlign + + + + ParentWidthItemAlign + + + + DesignedItemAlign + + + + HorizontalLine + + + + VerticalLine + + + + Ellipse + + + + Rectangle + + + + Page + + + + Band + + + + Horizontal + + + + Vertical + + + + VerticalUniform + + + + + LimeReport::FlagsPropItem + + NoLine + + + + TopLine + + + + BottomLine + + + + LeftLine + + + + RightLine + + + LimeReport::FontEditorWidget @@ -608,7 +894,7 @@ p, li { white-space: pre-wrap; } - Datasource "%1" not found !!! + Datasource "%1" not found! @@ -638,6 +924,17 @@ p, li { white-space: pre-wrap; } + + LimeReport::ItemLocationPropItem + + Band + + + + Page + + + LimeReport::ItemsAlignmentEditorWidget @@ -1089,6 +1386,202 @@ p, li { white-space: pre-wrap; } Warning + + gridStep + + + + fullPage + + + + oldPrintMode + + + + borderColor + + + + resetPageNumber + + + + alternateBackgroundColor + + + + backgroundBrushStyle + + + + startFromNewPage + + + + startNewPage + + + + adaptFontToSize + + + + allowHTML + + + + allowHTMLInFields + + + + followTo + + + + format + + + + lineSpacing + + + + textIndent + + + + textLayoutDirection + + + + underlineLineSize + + + + underlines + + + + valueType + + + + securityLevel + + + + testValue + + + + whitespace + + + + resourcePath + + + + scale + + + + cornerRadius + + + + shapeColor + + + + layoutType + + + + barcodeType + + + + barcodeWidth + + + + foregroundColor + + + + inputMode + + + + pdf417CodeWords + + + + autoSize + + + + center + + + + field + + + + image + + + + keepAspectRatio + + + + columnsCount + + + + useAlternateBackgroundColor + + + + printBeforePageHeader + + + + maxScalePercent + + + + printOnFirstPage + + + + printOnLastPage + + + + printAlways + + + + repeatOnEachRow + + + + condition + + + + groupFieldName + + + + keepGroupTogether + + LimeReport::RectMMPropItem @@ -1118,10 +1611,6 @@ p, li { white-space: pre-wrap; } Report file name - - Page - - Script @@ -1333,10 +1822,6 @@ p, li { white-space: pre-wrap; } Data Browser - - Report has been modified ! Do you want save the report ? - - Report file name @@ -1377,6 +1862,10 @@ p, li { white-space: pre-wrap; } Tear-off Band + + Report has been modified! Do you want save the report? + + LimeReport::ReportEnginePrivate @@ -1506,18 +1995,6 @@ This preview is no longer valid. Error - - Datasource Name is empty ! - - - - SQL is empty ! - - - - Datasource with name: "%1" already exists ! - - Datasource with name %1 already exist @@ -1534,6 +2011,18 @@ This preview is no longer valid. defaultConnection + + Datasource Name is empty! + + + + SQL is empty! + + + + Datasource with name: "%1" already exists! + + LimeReport::ScriptBrowser @@ -1623,6 +2112,26 @@ This preview is no longer valid. Name Nombre + + GROUP FUNCTIONS + + + + SYSTEM + + + + NUMBER + + + + DATE&TIME + + + + GENERAL + + LimeReport::SettingDialog @@ -1738,7 +2247,7 @@ This preview is no longer valid. - TextItem " %1 " not found ! + TextItem " %1 " not found! @@ -1797,11 +2306,19 @@ This preview is no longer valid. already exists !! - ya existe !! + ya existe !! does not exists !! - no existe !! + no existe !! + + + already exists! + + + + does not exists! + @@ -1886,10 +2403,6 @@ This preview is no longer valid. Invalid connection! %1 - - Master datasource "%1" not found!!! - - Master datasouce "%1" not found! @@ -1914,10 +2427,6 @@ This preview is no longer valid. Selected elements have different parent containers - - Object with name %1 already exists - - Function %1 not found or have wrong arguments @@ -2006,5 +2515,13 @@ This preview is no longer valid. Tear-off Band + + Master datasource "%1" not found! + + + + Object with name %1 already exists! + + diff --git a/translations/limereport_fr.ts b/translations/limereport_fr.ts new file mode 100644 index 0000000..f893b30 --- /dev/null +++ b/translations/limereport_fr.ts @@ -0,0 +1,3169 @@ + + + + + LRVariableDialog + + + Variable + Variable + + + + Name + Nom + + + + Value + Valeur + + + + Type + Type + + + + Attention + + + + + LimeReport::AboutDialog + + + About + A propos + + + + Lime Report + + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><img src=":/report/images/logo_100.png" height="100" style="float: left;" /><span style=" font-size:12pt; font-weight:600;">Report engine for </span><span style=" font-size:12pt; font-weight:600; color:#7faa18;">Qt</span><span style=" font-size:12pt; font-weight:600;"> framework</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">LimeReport - multi-platform C++ library written using Qt framework and intended for software developers that would like to add into their application capability to form report or print forms generated using templates.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">Official web site : </span><a href="www.limereport.ru"><span style=" font-size:11pt; text-decoration: underline; color:#0000ff;">www.limereport.ru</span></a></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt; text-decoration: underline; color:#0000ff;"><br /></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:10pt; font-weight:600;">This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:10pt; font-weight:600; color:#000000;"><br /></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:10pt;">Copyright 2015 Arin Alexander. All rights reserved.</span></p></body></html> + + + + + Author + Auteur + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Arin Alexander</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">arin_a@bk.ru</p></body></html> + + + + + License + Licence + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">(c) 2015 Arin Alexander arin_a@bk.ru</p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><br /></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="SEC1"></a><span style=" font-family:'sans-serif'; font-weight:600;">G</span><span style=" font-family:'sans-serif'; font-weight:600;">NU LESSER GENERAL PUBLIC LICENSE</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Version 2.1, February 1999</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Copyright (C) 1991, 1999 Free Software Foundation, Inc.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Everyone is permitted to copy and distribute verbatim copies</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">of this license document, but changing it is not allowed.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'monospace';"><br /></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">[This is the first released version of the Lesser GPL. It also counts</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';"> as the successor of the GNU Library Public License, version 2, hence</span></p> +<p style=" margin-top:0px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';"> the version number 2.1.]</span></p> +<p style=" margin-top:15px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="SEC2"></a><span style=" font-family:'sans-serif'; font-weight:600;">P</span><span style=" font-family:'sans-serif'; font-weight:600;">reamble</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public Licenses are intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">This license, the Lesser General Public License, applies to some specially designated software packages--typically libraries--of the Free Software Foundation and other authors who decide to use it. You can use it too, but we suggest you first think carefully about whether this license or the ordinary General Public License is the better strategy to use in any particular case, based on the explanations below.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">When we speak of free software, we are referring to freedom of use, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish); that you receive source code or can get it if you want it; that you can change the software and use pieces of it in new free programs; and that you are informed that you can do these things.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">To protect your rights, we need to make restrictions that forbid distributors to deny you these rights or to ask you to surrender these rights. These restrictions translate to certain responsibilities for you if you distribute copies of the library or if you modify it.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">For example, if you distribute copies of the library, whether gratis or for a fee, you must give the recipients all the rights that we gave you. You must make sure that they, too, receive or can get the source code. If you link other code with the library, you must provide complete object files to the recipients, so that they can relink them with the library after making changes to the library and recompiling it. And you must show them these terms so they know their rights.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">We protect your rights with a two-step method: (1) we copyright the library, and (2) we offer you this license, which gives you legal permission to copy, distribute and/or modify the library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">To protect each distributor, we want to make it very clear that there is no warranty for the free library. Also, if the library is modified by someone else and passed on, the recipients should know that what they have is not the original version, so that the original author's reputation will not be affected by problems that might be introduced by others.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Finally, software patents pose a constant threat to the existence of any free program. We wish to make sure that a company cannot effectively restrict the users of a free program by obtaining a restrictive license from a patent holder. Therefore, we insist that any patent license obtained for a version of the library must be consistent with the full freedom of use specified in this license.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Most GNU software, including some libraries, is covered by the ordinary GNU General Public License. This license, the GNU Lesser General Public License, applies to certain designated libraries, and is quite different from the ordinary General Public License. We use this license for certain libraries in order to permit linking those libraries into non-free programs.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">When a program is linked with a library, whether statically or using a shared library, the combination of the two is legally speaking a combined work, a derivative of the original library. The ordinary General Public License therefore permits such linking only if the entire combination fits its criteria of freedom. The Lesser General Public License permits more lax criteria for linking other code with the library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">We call this license the &quot;Lesser&quot; General Public License because it does Less to protect the user's freedom than the ordinary General Public License. It also provides other free software developers Less of an advantage over competing non-free programs. These disadvantages are the reason we use the ordinary General Public License for many libraries. However, the Lesser license provides advantages in certain special circumstances.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">For example, on rare occasions, there may be a special need to encourage the widest possible use of a certain library, so that it becomes a de-facto standard. To achieve this, non-free programs must be allowed to use the library. A more frequent case is that a free library does the same job as widely used non-free libraries. In this case, there is little to gain by limiting the free library to free software only, so we use the Lesser General Public License.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">In other cases, permission to use a particular library in non-free programs enables a greater number of people to use a large body of free software. For example, permission to use the GNU C Library in non-free programs enables many more people to use the whole GNU operating system, as well as its variant, the GNU/Linux operating system.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Although the Lesser General Public License is Less protective of the users' freedom, it does ensure that the user of a program that is linked with the Library has the freedom and the wherewithal to run that program using a modified version of the Library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">The precise terms and conditions for copying, distribution and modification follow. Pay close attention to the difference between a &quot;work based on the library&quot; and a &quot;work that uses the library&quot;. The former contains code derived from the library, whereas the latter must be combined with the library in order to run.</span></p> +<p style=" margin-top:15px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="SEC3"></a><span style=" font-family:'sans-serif'; font-weight:600; color:#333333;">T</span><span style=" font-family:'sans-serif'; font-weight:600; color:#333333;">ERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">0.</span><span style=" font-family:'sans-serif';"> This License Agreement applies to any software library or other program which contains a notice placed by the copyright holder or other authorized party saying it may be distributed under the terms of this Lesser General Public License (also called &quot;this License&quot;). Each licensee is addressed as &quot;you&quot;.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">A &quot;library&quot; means a collection of software functions and/or data prepared so as to be conveniently linked with application programs (which use some of those functions and data) to form executables.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">The &quot;Library&quot;, below, refers to any such software library or work which has been distributed under these terms. A &quot;work based on the Library&quot; means either the Library or any derivative work under copyright law: that is to say, a work containing the Library or a portion of it, either verbatim or with modifications and/or translated straightforwardly into another language. (Hereinafter, translation is included without limitation in the term &quot;modification&quot;.)</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">&quot;Source code&quot; for a work means the preferred form of the work for making modifications to it. For a library, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running a program using the Library is not restricted, and output from such a program is covered only if its contents constitute a work based on the Library (independent of the use of the Library in a tool for writing it). Whether that is true depends on what the Library does and what the program that uses the Library does.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">1.</span><span style=" font-family:'sans-serif';"> You may copy and distribute verbatim copies of the Library's complete source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and distribute a copy of this License along with the Library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">2.</span><span style=" font-family:'sans-serif';"> You may modify your copy or copies of the Library or any portion of it, thus forming a work based on the Library, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions:</span></p> +<ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" font-family:'sans-serif';" style=" margin-top:19px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">a)</span><span style=" font-size:16px;"> The modified work must itself be a software library.</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">b)</span><span style=" font-size:16px;"> You must cause the files modified to carry prominent notices stating that you changed the files and the date of any change.</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">c)</span><span style=" font-size:16px;"> You must cause the whole of the work to be licensed at no charge to all third parties under the terms of this License.</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:19px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">d)</span><span style=" font-size:16px;"> If a facility in the modified Library refers to a function or a table of data to be supplied by an application program that uses the facility, other than as an argument passed when the facility is invoked, then you must make a good faith effort to ensure that, in the event an application does not supply such function or table, the facility still operates, and performs whatever part of its purpose remains meaningful.</span></li></ul> +<p style=" margin-top:15px; margin-bottom:15px; margin-left:38px; margin-right:19px; -qt-block-indent:1; text-indent:0px;"><span style=" font-family:'sans-serif';">(For example, a function in a library to compute square roots has a purpose that is entirely well-defined independent of the application. Therefore, Subsection 2d requires that any application-supplied function or table used by this function must be optional: if the application does not supply it, the square root function must still compute square roots.)</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Library, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Library, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">In addition, mere aggregation of another work not based on the Library with the Library (or with a work based on the Library) on a volume of a storage or distribution medium does not bring the other work under the scope of this License.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">3.</span><span style=" font-family:'sans-serif';"> You may opt to apply the terms of the ordinary GNU General Public License instead of this License to a given copy of the Library. To do this, you must alter all the notices that refer to this License, so that they refer to the ordinary GNU General Public License, version 2, instead of to this License. (If a newer version than version 2 of the ordinary GNU General Public License has appeared, then you can specify that version instead if you wish.) Do not make any other change in these notices.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Once this change is made in a given copy, it is irreversible for that copy, so the ordinary GNU General Public License applies to all subsequent copies and derivative works made from that copy.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">This option is useful when you wish to copy part of the code of the Library into a program that is not a library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">4.</span><span style=" font-family:'sans-serif';"> You may copy and distribute the Library (or a portion or derivative of it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">If distribution of object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place satisfies the requirement to distribute the source code, even though third parties are not compelled to copy the source along with the object code.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">5.</span><span style=" font-family:'sans-serif';"> A program that contains no derivative of any portion of the Library, but is designed to work with the Library by being compiled or linked with it, is called a &quot;work that uses the Library&quot;. Such a work, in isolation, is not a derivative work of the Library, and therefore falls outside the scope of this License.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">However, linking a &quot;work that uses the Library&quot; with the Library creates an executable that is a derivative of the Library (because it contains portions of the Library), rather than a &quot;work that uses the library&quot;. The executable is therefore covered by this License. Section 6 states terms for distribution of such executables.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">When a &quot;work that uses the Library&quot; uses material from a header file that is part of the Library, the object code for the work may be a derivative work of the Library even though the source code is not. Whether this is true is especially significant if the work can be linked without the Library, or if the work is itself a library. The threshold for this to be true is not precisely defined by law.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">If such an object file uses only numerical parameters, data structure layouts and accessors, and small macros and small inline functions (ten lines or less in length), then the use of the object file is unrestricted, regardless of whether it is legally a derivative work. (Executables containing this object code plus portions of the Library will still fall under Section 6.)</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Otherwise, if the work is a derivative of the Library, you may distribute the object code for the work under the terms of Section 6. Any executables containing that work also fall under Section 6, whether or not they are linked directly with the Library itself.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">6.</span><span style=" font-family:'sans-serif';"> As an exception to the Sections above, you may also combine or link a &quot;work that uses the Library&quot; with the Library to produce a work containing portions of the Library, and distribute that work under terms of your choice, provided that the terms permit modification of the work for the customer's own use and reverse engineering for debugging such modifications.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">You must give prominent notice with each copy of the work that the Library is used in it and that the Library and its use are covered by this License. You must supply a copy of this License. If the work during execution displays copyright notices, you must include the copyright notice for the Library among them, as well as a reference directing the user to the copy of this License. Also, you must do one of these things:</span></p> +<ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" font-family:'sans-serif';" style=" margin-top:19px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">a)</span><span style=" font-size:16px;"> Accompany the work with the complete corresponding machine-readable source code for the Library including whatever changes were used in the work (which must be distributed under Sections 1 and 2 above); and, if the work is an executable linked with the Library, with the complete machine-readable &quot;work that uses the Library&quot;, as object code and/or source code, so that the user can modify the Library and then relink to produce a modified executable containing the modified Library. (It is understood that the user who changes the contents of definitions files in the Library will not necessarily be able to recompile the application to use the modified definitions.)</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">b)</span><span style=" font-size:16px;"> Use a suitable shared library mechanism for linking with the Library. A suitable mechanism is one that (1) uses at run time a copy of the library already present on the user's computer system, rather than copying library functions into the executable, and (2) will operate properly with a modified version of the library, if the user installs one, as long as the modified version is interface-compatible with the version that the work was made with.</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">c)</span><span style=" font-size:16px;"> Accompany the work with a written offer, valid for at least three years, to give the same user the materials specified in Subsection 6a, above, for a charge no more than the cost of performing this distribution.</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">d)</span><span style=" font-size:16px;"> If distribution of the work is made by offering access to copy from a designated place, offer equivalent access to copy the above specified materials from the same place.</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:19px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">e)</span><span style=" font-size:16px;"> Verify that the user has already received a copy of these materials or that you have already sent this user a copy.</span></li></ul> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">For an executable, the required form of the &quot;work that uses the Library&quot; must include any data and utility programs needed for reproducing the executable from it. However, as a special exception, the materials to be distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">It may happen that this requirement contradicts the license restrictions of other proprietary libraries that do not normally accompany the operating system. Such a contradiction means you cannot use both them and the Library together in an executable that you distribute.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">7.</span><span style=" font-family:'sans-serif';"> You may place library facilities that are a work based on the Library side-by-side in a single library together with other library facilities not covered by this License, and distribute such a combined library, provided that the separate distribution of the work based on the Library and of the other library facilities is otherwise permitted, and provided that you do these two things:</span></p> +<ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" font-family:'sans-serif';" style=" margin-top:19px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">a)</span><span style=" font-size:16px;"> Accompany the combined library with a copy of the same work based on the Library, uncombined with any other library facilities. This must be distributed under the terms of the Sections above.</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:19px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">b)</span><span style=" font-size:16px;"> Give prominent notice with the combined library of the fact that part of it is a work based on the Library, and explaining where to find the accompanying uncombined form of the same work.</span></li></ul> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">8.</span><span style=" font-family:'sans-serif';"> You may not copy, modify, sublicense, link with, or distribute the Library except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense, link with, or distribute the Library is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">9.</span><span style=" font-family:'sans-serif';"> You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Library or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Library (or any work based on the Library), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Library or works based on it.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">10.</span><span style=" font-family:'sans-serif';"> Each time you redistribute the Library (or any work based on the Library), the recipient automatically receives a license from the original licensor to copy, distribute, link with or modify the Library subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties with this License.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">11.</span><span style=" font-family:'sans-serif';"> If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Library at all. For example, if a patent license would not permit royalty-free redistribution of the Library by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply, and the section as a whole is intended to apply in other circumstances.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">12.</span><span style=" font-family:'sans-serif';"> If the distribution and/or use of the Library is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Library under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">13.</span><span style=" font-family:'sans-serif';"> The Free Software Foundation may publish revised and/or new versions of the Lesser General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Each version is given a distinguishing version number. If the Library specifies a version number of this License which applies to it and &quot;any later version&quot;, you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Library does not specify a license version number, you may choose any version ever published by the Free Software Foundation.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">14.</span><span style=" font-family:'sans-serif';"> If you wish to incorporate parts of the Library into other free programs whose distribution conditions are incompatible with these, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">NO WARRANTY</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">15.</span><span style=" font-family:'sans-serif';"> BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE LIBRARY &quot;AS IS&quot; WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">16.</span><span style=" font-family:'sans-serif';"> IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.</span></p> +<p style=" margin-top:15px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600; color:#333333;">END OF TERMS AND CONDITIONS</span></p> +<p style=" margin-top:15px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="SEC4"></a><span style=" font-family:'sans-serif'; font-weight:600; color:#333333;">H</span><span style=" font-family:'sans-serif'; font-weight:600; color:#333333;">ow to Apply These Terms to Your New Libraries</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">If you develop a new library, and you want it to be of the greatest possible use to the public, we recommend making it free software that everyone can redistribute and change. You can do so by permitting redistribution under these terms (or, alternatively, under the terms of the ordinary General Public License).</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">To apply these terms, attach the following notices to the library. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the &quot;copyright&quot; line and a pointer to where the full notice is found.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace'; font-style:italic;">one line to give the library's name and an idea of what it does.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Copyright (C) </span><span style=" font-family:'monospace'; font-style:italic;">year</span><span style=" font-family:'monospace';"> </span><span style=" font-family:'monospace'; font-style:italic;">name of author</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'monospace'; font-style:italic;"><br /></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">This library is free software; you can redistribute it and/or</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">modify it under the terms of the GNU Lesser General Public</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">License as published by the Free Software Foundation; either</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">version 2.1 of the License, or (at your option) any later version.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'monospace';"><br /></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">This library is distributed in the hope that it will be useful,</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">but WITHOUT ANY WARRANTY; without even the implied warranty of</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Lesser General Public License for more details.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'monospace';"><br /></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">You should have received a copy of the GNU Lesser General Public</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">License along with this library; if not, write to the Free Software</span></p> +<p style=" margin-top:0px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Also add information on how to contact you by electronic and paper mail.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">You should also get your employer (if you work as a programmer) or your school, if any, to sign a &quot;copyright disclaimer&quot; for the library, if necessary. Here is a sample; alter the names:</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Yoyodyne, Inc., hereby disclaims all copyright interest in</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">the library `Frob' (a library for tweaking knobs) written</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">by James Random Hacker.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'monospace';"><br /></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace'; font-style:italic;">signature of Ty Coon</span><span style=" font-family:'monospace';">, 1 April 1990</span></p> +<p style=" margin-top:0px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Ty Coon, President of Vice</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">That's all there is to it!</span></p></body></html> + + + + + Close + Fermer + + + + Version 1.1.1 + + + + + LimeReport::AlignmentPropItem + + + Left + Gauche + + + + Right + Droite + + + + + Center + Centré + + + + Justify + Justifié + + + + Top + Haut + + + + Botom + Bas + + + + horizontal + Horizontal + + + + vertical + Vertical + + + + LimeReport::BandDesignIntf + + + DataBand + bande de données + + + + DataHeaderBand + En-tête de données + + + + DataFooterBand + Bande de pied de données + + + + ReportHeader + En-tête du rapport + + + + ReportFooter + Pied du rapport + + + + PageHeader + En-tête de page + + + + PageFooter + Pied de page + + + + SubDetailBand + Bande de sous-détails + + + + SubDetailHeaderBand + En-tête de sous-détails + + + + SubDetailFooterBand + Pied de sous-détails + + + + GroupBandHeader + Bande de groupe d'en-tête + + + + GroupBandFooter + Bande de groupe de pieds + + + + TearOffBand + Bande détachable + + + + connected to + Connecté à + + + + Bring to top + Placer au premier-plan + + + + Send to back + Placer en arrière-plan + + + + + Auto height + Hauteur automatique + + + + + Splittable + Divisible + + + + + Keep bottom space + Garder l'espace inférieur + + + + + Start from new page + Démarrer depuis une nouvelle page + + + + + Start new page + Démarrer une nouvelle page + + + + LimeReport::BaseDesignIntf + + + Copy + Copier + + + + Cut + Couper + + + + Paste + Coller + + + + Bring to top + Placer au premier-plan + + + + Send to back + Placer en arrière-plan + + + + No borders + Aucune bordure + + + + All borders + Toutes les bordures + + + + LimeReport::ConnectionDesc + + + + defaultConnection + Connexion par défaut + + + + LimeReport::ConnectionDialog + + + + Connection + Connexion + + + + Connection Name + Nom de la connexion + + + + Use default application connection + Utiliser la connexion par défaut de l'application + + + + Driver + Pilote + + + + Server + Serveur + + + + User + Utilisateur + + + + Password + Mot de passe + + + + Database + Base de données + + + + ... + + + + + Auto connect + Connexion automatique + + + + Dont keep credentals in lrxml + Ne pas enregistrer les informations personnelles + + + + Check connection + Vérifier la connexion + + + + Cancel + Annuler + + + + Ok + + + + + + Error + Erreur + + + + Connection succsesfully established! + Connexion réussie! + + + + Connection Name is empty + Nom de la connexion vide + + + + Connection with name + + + + + already exists! + existe déja! + + + + defaultConnection + + + + + LimeReport::DataBand + + + Data + Données + + + + LimeReport::DataBrowser + + + + + Datasources + Source de données + + + + Add database connection + Ajouter une connexion à la base de données + + + + + + + + + + + + + + + + ... + + + + + Add new datasource + Ajouter une nouvelle source de données + + + + View data + Aperçu des données + + + + Change datasource + Modifier la source de données + + + + Delete datasource + Supprimer la source de données + + + + Show error + Afficher l'erreur + + + + Variables + + + + + Add new variable + Ajouter une variable + + + + Edit variable + Modifier une variable + + + + Delete variable + Supprimer une variable + + + + Grab variable + Saisir une variable + + + + + + + Attention + + + + + Do you really want to delete "%1" connection? + Voulez-vous vraiment supprimer la connexion "%1"? + + + + Report variables + Variables du rapport + + + + System variables + Variables système + + + + External variables + Variables externe + + + + Do you really want to delete "%1" datasource? + Vouz-vous vraiment supprimer la source de donnée "%1"? + + + + Do you really want to delete variable "%1"? + Vouz-vous vraiment supprimer la variable "%1"? + + + + Error + Erreur + + + + LimeReport::DataFooterBand + + + DataFooter + Pied de données + + + + LimeReport::DataHeaderBand + + + DataHeader + En-tête de données + + + + LimeReport::DataSourceManager + + + Connection "%1" is not open + La connexion "%1" n'est pas ouverte + + + + Variable "%1" not found! + Variable "%1" introuvable! + + + + + Datasource "%1" not found! + Source de donnée "%1" introuvable! + + + + Connection with name "%1" already exists! + La connexion avec le nom "%1" existe déja! + + + + + + + Datasource with name "%1" already exists! + La source de donnée avec le nom "%1" existe déja! + + + + Database "%1" not found + Base de données "%1 introuvable + + + + invalid connection + Connexion invalide + + + + LimeReport::DataSourceModel + + + Datasources + Source de données + + + + Variables + + + + + External variables + Variables externe + + + + LimeReport::EnumPropItem + + + Default + + + + + Portrait + + + + + Landscape + + + + + NoneAutoWidth + + + + + MaxWordLength + + + + + MaxStringLength + + + + + TransparentMode + + + + + OpaqueMode + + + + + Angle0 + + + + + Angle90 + + + + + Angle180 + + + + + Angle270 + + + + + Angle45 + + + + + Angle315 + + + + + DateTime + + + + + Double + + + + + NoBrush + + + + + SolidPattern + + + + + Dense1Pattern + + + + + Dense2Pattern + + + + + Dense3Pattern + + + + + Dense4Pattern + + + + + Dense5Pattern + + + + + Dense6Pattern + + + + + Dense7Pattern + + + + + HorPattern + + + + + VerPattern + + + + + CrossPattern + + + + + BDiagPattern + + + + + FDiagPattern + + + + + LeftToRight + + + + + RightToLeft + + + + + LayoutDirectionAuto + + + + + LeftItemAlign + + + + + RightItemAlign + + + + + CenterItemAlign + + + + + ParentWidthItemAlign + + + + + DesignedItemAlign + + + + + HorizontalLine + + + + + VerticalLine + + + + + Ellipse + + + + + Rectangle + + + + + Page + + + + + Band + + + + + Horizontal + + + + + Vertical + + + + + VerticalUniform + + + + + LimeReport::FlagsPropItem + + + NoLine + + + + + TopLine + Ligne supérieur + + + + BottomLine + Ligne inférieur + + + + LeftLine + Ligne gauche + + + + RightLine + Ligne droite + + + + LimeReport::FontEditorWidget + + + Font bold + Caractères en gras + + + + Font Italic + Caractères en italique + + + + Font Underline + Caractères Soulignées + + + + LimeReport::FontPropItem + + + bold + Gras + + + + italic + Italique + + + + underline + Souligné + + + + size + Taille + + + + family + Police + + + + LimeReport::GroupBandFooter + + + GroupFooter + Pied de groupe + + + + LimeReport::GroupBandHeader + + + GroupHeader + En-tête de groupe + + + + Group field not found + Champ de groupe non trouvé + + + + Datasource "%1" not found! + Source de donnée "%1" introuvable! + + + + LimeReport::GroupFunction + + + Field "%1" not found + Champ "%1 introuvable + + + + Variable "%1" not found + Variable "%1" introuvable + + + + Wrong script syntax "%1" + Syntaxe incorrecte du script "%1" + + + + Item "%1" not found + Elément "%1" introuvable + + + + LimeReport::ImageItem + + + Image + Image + + + + LimeReport::ItemLocationPropItem + + + Band + + + + + Page + + + + + LimeReport::ItemsAlignmentEditorWidget + + + Bring to top + Placer au premier-plan + + + + Send to back + Placer en arrière-plan + + + + Align to left + Aligner à gauche + + + + Align to right + Aligner à droite + + + + Align to vertical center + Aligner au centre vertical + + + + Align to top + Aligner en haut + + + + Align to bottom + Aligner en bas + + + + Align to horizontal center + Aligner au centre horizontal + + + + Set same height + Définir la même hauteur + + + + Set same width + Définir la même largeur + + + + LimeReport::ItemsBordersEditorWidget + + + Top line + ligne plus haut + + + + Bottom line + Ligne plus bas + + + + Left line + Ligne gauche + + + + Right line + Ligne droite + + + + No borders + Aucune bordure + + + + All borders + Toutes les bordures + + + + LimeReport::MasterDetailProxyModel + + + Field: "%1" not found in "%2" child datasource + Le champ: "%1"est introuvable dans la source de donnée enfant "%2" + + + + Field: "%1" not found in "%2" master datasource + Le champ: "%1"est introuvable dans la source de donnée principale "%2" + + + + LimeReport::ModelToDataSource + + + model is destroyed + Le modèle a été supprimé + + + + LimeReport::ObjectBrowser + + + Objects + Objets + + + + LimeReport::PageFooter + + + Page Footer + Pied de page + + + + LimeReport::PageHeader + + + Page Header + En-tête de page + + + + LimeReport::PageItemDesignIntf + + + Paste + Coller + + + + LimeReport::PreviewReportWidget + + + Form + Formulaire + + + + PDF file name + Nom du fichier PDF + + + + Report file name + Nom du fichier du rapport + + + + LimeReport::PreviewReportWindow + + + Preview + Aperçu avant impression + + + + View + Vue + + + + Report + Rapport + + + + toolBar + Barre d'outil + + + + Print + Imprimer + + + + Ctrl+P + + + + + Zoom In + Zoom avant + + + + Zoom Out + Zoom arrière + + + + + Prior Page + Page prioritaire + + + + + Next Page + Page suivante + + + + + Close Preview + Fermer l'aperçu + + + + Esc + Echap + + + + Edit Mode + Mode d'édition + + + + + Save to file + Enregistrer dans un fichier + + + + + Show errors + Afficher les erreurs + + + + First Page + Première page + + + + First page + Première page + + + + + Last Page + Dernièr page + + + + Print To PDF + Enregistrer en format PDF + + + + Fit page width + Ajuster la largeur de la page + + + + Fit page + Ajuster la page + + + + One to one + Page par Page + + + + Show Toolbar + Afficher la barre d'outil + + + + Show toolbar + Afficher la barre d'outil + + + + Page: + + + + + Font + Police + + + + Text align + Alignement de texte + + + + of %1 + de %1 + + + + LimeReport::ProxyHolder + + + Datasource has been invalidated + La source de donnée n'a pas été validée + + + + LimeReport::QObjectPropertyModel + + + leftMargin + Marge à gauche + + + + rightMargin + Marge à droite + + + + topMargin + Marge en haut + + + + bottomMargin + Marge en bas + + + + objectName + Nom de l'objet + + + + borders + Bordures + + + + geometry + Géométrie + + + + itemAlign + Alignement de l'élément + + + + pageOrientation + Orientation de la page + + + + pageSize + Taille de la page + + + + TopLine + Ligne supérieur + + + + BottomLine + Ligne inférieur + + + + LeftLine + Ligne gauche + + + + RightLine + Ligne droite + + + + reprintOnEachPage + Imprimer dans chaque page + + + + borderLineSize + Taille de la lignes de bordure + + + + autoHeight + Hauteur automatique + + + + backgroundColor + Couleur de fond + + + + + columnCount + Nombre de colonne + + + + columnsFillDirection + Direction de remplissage des colonnes + + + + datasource + Source de donnée + + + + keepBottomSpace + Garder l'espace inférieur + + + + keepFooterTogether + Joindre avec le pied de page + + + + keepSubdetailTogether + Joindre avec le sous-détail + + + + printIfEmpty + Imprimer si vide + + + + sliceLastRow + Couper la dernière rangée + + + + splittable + Divisible + + + + alignment + Alignement + + + + angle + Angle + + + + autoWidth + Largeur automatique + + + + backgroundMode + Motif de fond + + + + backgroundOpacity + Transparence de fond + + + + content + Contenu + + + + font + Police + + + + fontColor + Couleur de police + + + + foregroundOpacity + Transparence de premier-plan + + + + itemLocation + Emplacement de l'élément + + + + margin + Marge + + + + stretchToMaxHeight + Etirer à la hauteur maximale + + + + trimValue + Valeur d'ajustement + + + + lineWidth + Largeur de ligne + + + + opacity + Transparence + + + + penStyle + Style de pinceau + + + + shape + Forme + + + + shapeBrush + Brosse de forme + + + + shapeBrushColor + Couleur de brosse de forme + + + + gridStep + Grille + + + + fullPage + Page entière + + + + oldPrintMode + Mode d'impression classique + + + + borderColor + Couleur de bordure + + + + resetPageNumber + Réinitialiser le numéro de page + + + + alternateBackgroundColor + Couleurs de fond alternative + + + + + backgroundBrushStyle + Style de brosse de fond + + + + startFromNewPage + Démarrer depuis une nouvelle page + + + + startNewPage + Démarrer une nouvelle page + + + + adaptFontToSize + Adapter la police à lataille + + + + allowHTML + Interpréter HTML + + + + allowHTMLInFields + Interpréter HTML dans les champs + + + + followTo + Suivre pour + + + + format + Format + + + + lineSpacing + Interligne + + + + textIndent + Indentation de texte + + + + textLayoutDirection + Disposition du texte + + + + underlineLineSize + Taille de soulignement + + + + underlines + Soulignes + + + + valueType + Type de valeur + + + + securityLevel + Niveau de sécurité + + + + testValue + Valeur de test + + + + whitespace + Espace + + + + resourcePath + Chemin de ressources + + + + scale + Echelle + + + + cornerRadius + Rayon d'angle + + + + shapeColor + Couleur de forme + + + + layoutType + Type de mise en page + + + + barcodeType + Type de code barre + + + + barcodeWidth + Largeur de code barre + + + + foregroundColor + Couleur de premier-plan + + + + inputMode + Mode de saisie + + + + pdf417CodeWords + + + + + autoSize + Taille automatique + + + + center + Centrer + + + + field + Champ + + + + image + Image + + + + keepAspectRatio + Conserver les proportions + + + + columnsCount + Nombre de colonnes + + + + useAlternateBackgroundColor + Utiliser les couleurs de fond alternative + + + + printBeforePageHeader + Imprimer avant le pied de page + + + + maxScalePercent + Pourcentage d'échelle maximal + + + + printOnFirstPage + Imprimer dans la première page + + + + printOnLastPage + Imprimer dans la dernière page + + + + printAlways + Toujours imprimé + + + + repeatOnEachRow + Répéter dans chaque ligne + + + + condition + Condition + + + + groupFieldName + Nom du champ de groupe + + + + keepGroupTogether + Joindre avec le groupe + + + + Property Name + Nom de la propriété + + + + Property value + Valeur de la propriété + + + + Warning + Avertissement + + + + LimeReport::RectMMPropItem + + + + + width + Largeur + + + + + + height + Hauteur + + + + LimeReport::RectPropItem + + + width + Largeur + + + + height + Hauteur + + + + LimeReport::ReportDesignWidget + + + Script + Script + + + + Report file name + Nom du rapport + + + + Error + Erreur + + + + Wrong file format + Format de fichier incorrect + + + + LimeReport::ReportDesignWindow + + + New Report + Nouveau rapport + + + + New Report Page + Nouvelle page + + + + Delete Report Page + Supprimer une page + + + + Edit Mode + Mode d'édition + + + + Undo + Annuler + + + + Redo + Répéter + + + + Copy + Copier + + + + Paste + Coller + + + + Cut + Couper + + + + Settings + Paramètres + + + + Use grid + Utiliser la grille + + + + Use magnet + Utiliser l'aimant + + + + Text Item + Elément de texte + + + + Save Report + Enregistrer le rapport + + + + Save Report As + Enregistrer le rapport sous + + + + Load Report + Ouvrir un rapport + + + + Delete item + Supprimer élément + + + + Zoom In + Zoom avant + + + + Zoom Out + Zoom arrière + + + + Render Report + Afficher l'aperçu du rapport + + + + Edit layouts mode + Modifier le mode de mise en forme + + + + Horizontal layout + Mise en page horizontale + + + + About + A propos + + + + Hide left panel + Masquer le panneau de gauche + + + + Hide right panel + Masquer le panneau de droite + + + + Report Tools + Outils de rapport + + + + Main Tools + Outils principales + + + + Font + Police + + + + Text alignment + Alignement de texte + + + + Items alignment + Alignement des éléments + + + + Borders + Bordures + + + + Report bands + Bandesde rapport + + + + Report Header + En-tête du rapport + + + + Report Footer + Pied de rapport + + + + Page Header + En-tête de page + + + + Page Footer + Pied de page + + + + Data + Données + + + + Data Header + En-tête de données + + + + Data Footer + Pied de données + + + + SubDetail + Sous-détails + + + + SubDetailHeader + En-tête de sous-détails + + + + SubDetailFooter + Pied de sous-détails + + + + GroupHeader + En-tête de groupe + + + + GroupFooter + Pied de groupe + + + + Tear-off Band + Bande détachable + + + + File + Fichier + + + + Edit + Edition + + + + Info + + + + + Recent Files + Fichiers récents + + + + Object Inspector + Inspecteur d'objets + + + + Report structure + Structure du rapport + + + + Data Browser + Navigateur de données + + + + Script Browser + Navigateur de script + + + + Report has been modified! Do you want save the report? + Le rapport a été modifié! Voulez-vous l'enregistrer? + + + + + Report file name + Nom du fichier du rapport + + + + Rendering report + Afficher l'aperçu du rapport + + + + Abort + Quitter + + + + page rendered + du rendu de la page + + + + Warning + Avertissement + + + + File "%1" not found! + Fichier "%1" introuvable! + + + + LimeReport::ReportEnginePrivate + + + Preview + Aperçu avant impression + + + + Error + Erreur + + + + Report File Change + Nom du fichier changé + + + + The report file "%1" has changed names or been deleted. + +This preview is no longer valid. + Le fichier du rapport "%1" a changé de nom ou a été supprimé. + +Cet aperçu n'est plus valide. + + + + LimeReport::ReportFooter + + + Report Footer + Pied de rapport + + + + LimeReport::ReportHeader + + + Report Header + En-tête du rapport + + + + LimeReport::ReportRender + + + + + + Error + Erreur + + + + page index out of range + Indice de la page dépassé + + + + Databand "%1" not found + Bande de données "%1 introuvable + + + + Wrong using function %1 + Utilisation incorrecte de la fonction "%1" + + + + LimeReport::SQLEditDialog + + + Datasource + Source de donnée + + + + Connection + Connexion + + + + Datasource Name + Nom de source de donnée + + + + Subdetail + Sous-détails + + + + Master datasource + Banse de donnée principale + + + + Subquery mode + Mode de sous-requêtes + + + + Filter mode + Mode filtre + + + + SQL + + + + + + Preview + Aperçu + + + + Hide Preview + Masquer l'aperçu + + + + Child datasource + Source de donnée fille + + + + Fields map + Champs + + + + + ... + + + + + Data preview + Aperçu de données + + + + Cancel + Annuler + + + + Ok + + + + + Error + Erreur + + + + Datasource Name is empty! + Nom de source de donnée est vide! + + + + SQL is empty! + SQL est vide! + + + + Datasource with name: "%1" already exists! + La source de donnée avec le nom "%1" existe déja! + + + + defaultConnection + Connexion par défaut + + + + Datasource with name %1 already exist + La source de donnée avec le nom "%1" existe déja! + + + + + Attention + + + + + Connection is not specified + La connexion n'est pas spécifiée + + + + Refresh + Actualiser + + + + LimeReport::ScriptBrowser + + + Form + Formulaire + + + + Functions + Fonctions + + + + + + + + + ... + + + + + Dialogs + Dialogues + + + + Type + + + + + Name + Nom + + + + NO CATEGORY + AUCUNE CATEGORIE + + + + + + Error + Erreur + + + + Dialog with name: %1 already exists + Le dialogue avec le nom "%1" existe déja + + + + ui file must cointain QDialog instead QWidget or QMainWindow + Le fichier ui doit contenir un QDialog au lieu de QWidget ou QMainWindow + + + + wrong file format + Format de fichier incorrect + + + + LimeReport::ScriptEngineContext + + + Dialog with name: %1 can`t be created + Le dialogue avec le nom "%1" ne peut pas être crée + + + + LimeReport::ScriptEngineManager + + + GROUP FUNCTIONS + Fonctions de groupe + + + + + + + + + + + Value + Valeur + + + + + BandName + Nom de la bande + + + + Variable %1 not found + Variable "%1" introuvable + + + + SYSTEM + Système + + + + + + NUMBER + Nombre + + + + + + + Format + + + + + Precision + Précision + + + + + Locale + Local + + + + + + + + DATE&TIME + DATE&HEURE + + + + CurrencySymbol + Symbolde de la monnaie + + + + + + GENERAL + + + + + + + Name + Nom + + + + LimeReport::SettingDialog + + + Designer setting + Paramètres du Designer + + + + Designer Setting + Paramètres du Designer + + + + Default font + Police par défaut + + + + Grid + Grille + + + + Vertical grid step + Grille verticale + + + + Horizontal grid step + Grille horizontale + + + + Report Setting + Paramètres du rapport + + + + Suppress absent fields and variables warning + Effacer les messages d'absences de champs et d'avertissement de variables + + + + LimeReport::SubDetailBand + + + SubDetail + Sous-détails + + + + LimeReport::SubDetailHeaderBand + + + SubDetailHeader + En-tête de sous-détails + + + + LimeReport::TearOffBand + + + Tear-off Band + Bande détachable + + + + LimeReport::TextAlignmentEditorWidget + + + Text align left + Aligner le texte à gauche + + + + + Text align center + Aligner le texte au milieu + + + + Text align right + Aligner le texte à droite + + + + Text align justify + Justifier le texte + + + + Text align top + Aligner le texte en haut + + + + Text align bottom + Aligner le texte en bas + + + + LimeReport::TextItem + + + + Edit + Edition + + + + + Auto height + Hauteur automatique + + + + + Allow HTML + Interpréter HTML + + + + + Allow HTML in fields + Interpréter HTML dans les champs + + + + + Stretch to max height + Etirer à la hauteur maximale + + + + + Error + Erreur + + + + TextItem " %1 " already has folower " %2 " + L'élément texte " %1 " a toujours un copain " %2 " + + + + TextItem " %1 " not found! + Elément "%1" introuvable! + + + + LimeReport::TextItemEditor + + + Text Item Editor + Editeur d'élément de texte + + + + Content + Contenu + + + + Data + Données + + + + Functions + Fonctions + + + + Editor settings + Paramètres de l'éditeur + + + + Editor font + Police + + + + ... + + + + + Ok + + + + + Ctrl+Return + Ctrl+Arrière + + + + Cancel + Annuler + + + + Esc + Echap + + + + LimeReport::VariablesHolder + + + + + + variable with name + La variable avec le nom + + + + already exists! + existe déja! + + + + + + does not exists! + n'existe pas! + + + + QObject + + + + + Data + Données + + + + + DataHeader + En-tête de données + + + + + DataFooter + Pied de données + + + + + GroupHeader + En-tête de groupe + + + + + GroupFooter + Pied de groupe + + + + + + Page Footer + Pied de page + + + + + + Page Header + En-tête de page + + + + + Report Footer + Pied de rapport + + + + + Report Header + En-tête du rapport + + + + + + SubDetail + Sous-détails + + + + + SubDetailHeader + En-tête de sous-détails + + + + + SubDetailFooter + Pied de sous-détails + + + + + Tear-off Band + Bande détachable + + + + + alignment + Alignement + + + + + Barcode Item + Elément de code barre + + + + + HLayout + + + + + + Image Item + + + + + + Shape Item + + + + + + itemLocation + + + + + + Text Item + + + + + + Invalid connection! %1 + Connexion invalidé %1 + + + + Master datasource "%1" not found! + Source de donnée principale "%1" introuvable! + + + + Master datasouce "%1" not found! + Source de donnée principale "%1" introuvable! + + + + Child + Enfant + + + + and child + est enfant + + + + datasouce "%1" not found! + Source de donnée "%1" introuvable! + + + + + bool + + + + + + QColor + + + + + + content + Contenu + + + + + + + datasource + Source de donnée + + + + + + + field + Champ + + + + + enum + + + + + + flags + + + + + + QFont + + + + + + QImage + + + + + + int + + + + + + + + qreal + + + + + + QRect + + + + + + QRectF + + + + + + geometry + + + + + + QString + + + + + Attention! + + + + + Selected elements have different parent containers + Les éléments sélectionnés ont un parent différent + + + + Object with name %1 already exists! + L'objet avec le nom "%1" existe déja! + + + + Function %1 not found or have wrong arguments + La fonction %1 est introuvable ou contient des paramètres incorrects + + + + mm + + + + + Wrong file format + Format de fichier incorrect + + + + File %1 not opened + Fichier "%1" n'est pas ouvert + + + + Content string is empty + Contenu vide + + + + Content is empty + Contenu vide + + + diff --git a/translations/limereport_ru.qm b/translations/limereport_ru.qm index f21886b..6db7938 100644 Binary files a/translations/limereport_ru.qm and b/translations/limereport_ru.qm differ diff --git a/translations/limereport_ru.ts b/translations/limereport_ru.ts index 4adca96..d706b5f 100644 --- a/translations/limereport_ru.ts +++ b/translations/limereport_ru.ts @@ -57,7 +57,12 @@ p, li { white-space: pre-wrap; } </style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;"> <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Arin Alexander</span></p> <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">arin_a@bk.ru</p></body></html> - + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Александр Арин</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">arin_a@bk.ru</p></body></html> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> @@ -73,7 +78,7 @@ p, li { white-space: pre-wrap; } <p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:10pt; font-weight:600;">This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.</span></p> <p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:10pt; font-weight:600; color:#000000;"><br /></p> <p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:10pt;">Copyright 2015 Arin Alexander. All rights reserved.</span></p></body></html> - + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> @@ -190,7 +195,7 @@ p, li { white-space: pre-wrap; } <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace'; font-style:italic;">signature of Ty Coon</span><span style=" font-family:'monospace';">, 1 April 1990</span></p> <p style=" margin-top:0px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Ty Coon, President of Vice</span></p> <p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">That's all there is to it!</span></p></body></html> - + @@ -232,7 +237,7 @@ p, li { white-space: pre-wrap; } LimeReport::BandDesignIntf connected to - соединён с + соединён с Bring to top @@ -250,6 +255,86 @@ p, li { white-space: pre-wrap; } Splittable Разбивать содержимое на части + + DataBand + Данные + + + ReportHeader + Заголовок отчета + + + ReportFooter + Завершение отчета + + + PageHeader + Верхний колонтитул + + + PageFooter + Нижний колонтитул + + + Subdetail + Подчиненный + + + DataHeaderBand + Заголовок данных + + + DataFooterBand + Завершение данных + + + SubdetailBand + Подчиненные данные + + + SubdetailHeaderBand + Заголовок подчиненных данных + + + SubdetailFooterBand + Завершение подчиненных данных + + + GroupBandHeader + Заголовок группы + + + GroupBandFooter + Завершение группы + + + TearOffBand + Полоса для отрывания + + + SubDetailBand + Подчиненные данные + + + SubDetailHeaderBand + Заголовок подчиненных данных + + + SubDetailFooterBand + Завершение подчиненных данных + + + Keep bottom space + + + + Start from new page + + + + Start new page + + LimeReport::BaseDesignIntf @@ -286,7 +371,7 @@ p, li { white-space: pre-wrap; } LimeReport::ConnectionDesc defaultConnection - + Соединение по умолчанию @@ -309,7 +394,7 @@ p, li { white-space: pre-wrap; } Server - Сервер + Сервер User @@ -349,15 +434,11 @@ p, li { white-space: pre-wrap; } Connection with name - Соединение - - - already exists - уже существует + Соединение ... - + ... Ok @@ -365,11 +446,15 @@ p, li { white-space: pre-wrap; } Dont keep credentals in lrxml - + Не хранить логин с паролем в lrxml defaultConnection - + Соединение по умолчанию + + + already exists! + уже существует! @@ -385,6 +470,10 @@ p, li { white-space: pre-wrap; } Data Данные + + useAlternateBackgroundColor + Использовать альтернативный цвет фона + LimeReport::DataBrowser @@ -436,11 +525,6 @@ p, li { white-space: pre-wrap; } Attention Внимание - - Do you really want to delete "%1" connection ? - Do you really want delete "%1" connection ? - Вы действительно хотите удалить "%1" соединение ? - System variables Системные переменные @@ -449,11 +533,6 @@ p, li { white-space: pre-wrap; } User variables Пользовательские переменные - - Do you really want to delete "%1" datasource ? - Do you really want delete "%1" datasource ? - Вы действительно хотите удалить источник данных "%1" ? - Error Ошибка @@ -462,10 +541,6 @@ p, li { white-space: pre-wrap; } ... - - Do you really want to delete variable "%1" ? - Вы действительно хотите удалить переменную "%1" ? - Grab variable Захватить переменную @@ -478,6 +553,18 @@ p, li { white-space: pre-wrap; } External variables Внешние переменные + + Do you really want to delete "%1" connection? + Вы действительно хотите удалить "%1" соединение? + + + Do you really want to delete "%1" datasource? + Вы действительно хотите удалить источник данных "%1"? + + + Do you really want to delete variable "%1"? + Вы действительно хотите удалить переменную "%1"? + LimeReport::DataFooterBand @@ -499,19 +586,6 @@ p, li { white-space: pre-wrap; } Connection "%1" is not open Соединение "%1" не открыто - - Datasource "%1" not found ! - Источник данных "%1" не найден ! - - - connection with name "%1" already exists ! - соединение "%1" уже существует ! - - - datasource with name "%1" already exists ! - data source with name "%1" already exists !! - источник данных "%1" уже существует ! - invalid connection нет соединения @@ -522,7 +596,27 @@ p, li { white-space: pre-wrap; } Database "%1" not found - + База данных "%1" не найдена + + + Datasource "%1" not found! + Источник данных "%1" не найден! + + + connection with name "%1" already exists! + соединение "%1" уже существует! + + + datasource with name "%1" already exists! + источник данных "%1" уже существует! + + + Connection with name "%1" already exists! + Соединение "%1" уже существует! + + + Datasource with name "%1" already exists! + Источник данных с именем: "%1" уже существует! @@ -537,7 +631,252 @@ p, li { white-space: pre-wrap; } External variables - Внешние переменные + Внешние переменные + + + + LimeReport::DialogDesignerManager + + Edit Widgets + Редактировать виджеты + + + Widget Box + Панель виджетов + + + Object Inspector + Инспектор объектов + + + Property Editor + Редактор свойств + + + Signals && Slots Editor + Редактор сигналов и слотов + + + Resource Editor + Редактор ресурсов + + + Action Editor + Редактор действий + + + + LimeReport::EnumPropItem + + Default + По умолчанию + + + Portrait + Портретная + + + Landscape + Альбомная + + + NoneAutoWidth + Нет + + + MaxWordLength + По ширине слова + + + MaxStringLength + По ширине строки + + + TransparentMode + Прозрачный + + + OpaqueMode + Заливка + + + Angle0 + 0 + + + Angle90 + 90 + + + Angle180 + 180 + + + Angle270 + 270 + + + Angle45 + 45 + + + Angle315 + 315 + + + DateTime + Дата и время + + + Double + Число + + + NoBrush + Нет заливки + + + SolidPattern + Сплошная заливка + + + Dense1Pattern + + + + Dense2Pattern + + + + Dense3Pattern + + + + Dense4Pattern + + + + Dense5Pattern + + + + Dense6Pattern + + + + Dense7Pattern + + + + HorPattern + + + + VerPattern + + + + CrossPattern + + + + BDiagPattern + + + + FDiagPattern + + + + LeftToRight + Слева на право + + + RightToLeft + С права на лево + + + LayoutDirectionAuto + Авто + + + LeftItemAlign + Слева + + + RightItemAlign + Справа + + + CenterItemAlign + По центру + + + ParentWidthItemAlign + По ширине родителя + + + DesignedItemAlign + Заданное положение + + + HorizontalLine + Горизонтальная линия + + + VerticalLine + Вертикальная линия + + + Ellipse + Элипс + + + Rectangle + Прямоугольник + + + Page + Страница + + + Band + Раздел + + + Horizontal + Горизонтально + + + Vertical + Вертикально + + + VerticalUniform + Вертикально равномерно + + + + LimeReport::FlagsPropItem + + NoLine + Нет границ + + + TopLine + Верхняя граница + + + BottomLine + Нижняя граница + + + LeftLine + Левая граница + + + RightLine + Правая граница @@ -593,11 +932,11 @@ p, li { white-space: pre-wrap; } Group field not found - + Поле для группировки не найдено - Datasource "%1" not found !!! - + Datasource "%1" not found! + Источник данных "%1" не найден! @@ -616,7 +955,7 @@ p, li { white-space: pre-wrap; } Wrong script syntax "%1" - + Неправильный синтаксис скрипта "%1" @@ -626,6 +965,17 @@ p, li { white-space: pre-wrap; } Изображение + + LimeReport::ItemLocationPropItem + + Band + Раздел + + + Page + Страница + + LimeReport::ItemsAlignmentEditorWidget @@ -739,7 +1089,7 @@ p, li { white-space: pre-wrap; } LimeReport::PageItemDesignIntf Paste - Вставить + Вставить @@ -833,7 +1183,7 @@ p, li { white-space: pre-wrap; } Preview - Предосмотр + Предпросмотр Ctrl+P @@ -853,23 +1203,23 @@ p, li { white-space: pre-wrap; } Esc - + Esc Show Toolbar - + Показать панель инструментов Show toolbar - + Показать панель иструментов Font - Шрифт + Шрифт Text align - + Выравнивание текста @@ -891,43 +1241,43 @@ p, li { white-space: pre-wrap; } fullPage - Страница целиком + Страница целиком gridStep - Шаг сетки + Шаг сетки oldPrintMode - Старый режим печати + Старый режим печати resourcePath - Путь к ресурсам + Путь к ресурсам autoSize - Автоматический размер + Автоматический размер center - Центрировать + Центрировать field - Поле + Поле image - Изображение + Изображение keepAspectRatio - Сохранять соотношение сторон + Сохранять соотношение сторон scale - Масштабировать + Масштабировать leftMargin @@ -955,15 +1305,15 @@ p, li { white-space: pre-wrap; } condition - Условие + Условие keepGroupTogether - Сохранять группу вместе + Сохранять группу вместе groupFieldName - Столбец группы + Столбец группы geometry @@ -1027,43 +1377,43 @@ p, li { white-space: pre-wrap; } textIndent - Отступ текста + Отступ текста textLayoutDirection - Направление текста + Направление текста lineSpacing - Межстрочный интервал + Межстрочный интервал underlines - Подчеркивание + Подчеркивание underlineLineSize - Толщина подчеркивания + Толщина подчеркивания format - Формат + Формат valueType - Тип значения + Тип значения adaptFontToSize - Шрифт по размеру + Шрифт по размеру followTo - Следует за + Следует за backgroundBrushStyle - Стиль заполнения фона + Стиль заполнения фона autoHeight @@ -1075,11 +1425,11 @@ p, li { white-space: pre-wrap; } alternateBackgroundColor - Альтернативный цвет фона + Альтернативный цвет фона columnsCount - Количество столбцов + Количество столбцов columnsFillDirection @@ -1123,7 +1473,7 @@ p, li { white-space: pre-wrap; } backgroundOpacity - Заполненость фона + Непрозрачность фона font @@ -1135,7 +1485,7 @@ p, li { white-space: pre-wrap; } foregroundOpacity - Заполненость переднего плана + Непрозрачность переднего плана margin @@ -1155,7 +1505,7 @@ p, li { white-space: pre-wrap; } opacity - Заполненость + Непрозрачность penStyle @@ -1175,36 +1525,112 @@ p, li { white-space: pre-wrap; } allowHTML - Разрешить HTML + Разрешить HTML allowHTMLInFields - Разрешить HTML в полях + Разрешить HTML в полях printAlways - Печатать всегда + Печатать всегда borderColor - Цвет границ + Цвет границ startNewPage - Начинать новую страницу + Начинать новую страницу startFromNewPage - Начинать с новой страницы + Начинать с новой страницы resetPageNumber - Обнулять номер страницы + Обнулять номер страницы columnCount + Количество колонок + + + alternateBackgroundMode + Альтернативный цвет фона + + + textIdent + Параграф + + + securityLevel + Уровень безопасности + + + testValue + Тестовое значение + + + whitespace + Отступ + + + cornerRadius + Радиус закругления + + + shapeColor + Цвет фигуры + + + layoutType + Тип группировки + + + barcodeType + Тип штрихкода + + + barcodeWidth + + foregroundColor + Цвет переднего плана + + + inputMode + + + + pdf417CodeWords + + + + useAlternateBackgroundColor + Использовать альтернативный цвет фона + + + printBeforePageHeader + Печатать перед заголовком страницы + + + maxScalePercent + Максимальный процент уменьшения + + + printOnFirstPage + Печатать на первой странице + + + printOnLastPage + Печатать на последней странице + + + repeatOnEachRow + Печатать на каждой странице + LimeReport::RectMMPropItem @@ -1236,19 +1662,19 @@ p, li { white-space: pre-wrap; } Page - + Страница Script - + Скрипт Error - Ошибка + Ошибка Wrong file format - + Неправильный формат файла @@ -1263,7 +1689,7 @@ p, li { white-space: pre-wrap; } Undo - Отменить действие + Отменить действие Redo @@ -1307,7 +1733,7 @@ p, li { white-space: pre-wrap; } Save Report As - Сохранить отчет как + Сохранить отчет как Load Report @@ -1375,7 +1801,7 @@ p, li { white-space: pre-wrap; } Report bands - Банды + Разделы Report Header @@ -1427,7 +1853,7 @@ p, li { white-space: pre-wrap; } Tear-off Band - Отрыв данных + Полоса для отрывания File @@ -1457,10 +1883,6 @@ p, li { white-space: pre-wrap; } Script Browser Инспектор скриптов - - Report has been modified ! Do you want save the report ? - Отчет был изменен ! Хотите его сохранить ? - Report file name Файл отчета @@ -1493,6 +1915,42 @@ p, li { white-space: pre-wrap; } File "%1" not found! Файл "%1" не найден! + + Delete dialog + Удалить диалог + + + Add new dialog + Добавить диалог + + + Widget Box + Панель виджетов + + + Property Editor + Редактор свойств + + + Action Editor + Редактор действий + + + Resource Editor + Редактор ресурсов + + + SignalSlot Editor + Редактор сигналов и слотов + + + Dialog Designer Tools + Инструменты создания диалогов + + + Report has been modified! Do you want save the report? + Отчет был изменен! Хотите его сохранить? + LimeReport::ReportEnginePrivate @@ -1506,13 +1964,13 @@ p, li { white-space: pre-wrap; } Report File Change - + Монитор изменений файлов The report file "%1" has changed names or been deleted. This preview is no longer valid. - + Файл отчета "%1" изменил имя или был удален. @@ -1545,7 +2003,7 @@ This preview is no longer valid. page index out of range - + индекс страницы вышел за границы диапазона @@ -1606,18 +2064,6 @@ This preview is no longer valid. Error Ошибка - - Datasource Name is empty ! - Имя источника данных не заполнено ! - - - SQL is empty ! - SQL запрос пустой ! - - - Datasource with name: "%1" already exists ! - Источник данных с именем: "%1" уже существует ! - Datasource with name %1 already exist Источник данных с именем: "%1" уже существует @@ -1648,7 +2094,19 @@ This preview is no longer valid. defaultConnection - + Соединение по умолчанию + + + Datasource Name is empty! + Имя источника данных не заполнено! + + + SQL is empty! + SQL запрос пустой! + + + Datasource with name: "%1" already exists! + Источник данных с именем: "%1" уже существует! @@ -1663,46 +2121,50 @@ This preview is no longer valid. Form - Форма + Форма ... - + ... Type - Тип + Тип Name - Имя переменной + Имя переменной NO CATEGORY - + БЕЗ КАТЕГОРИИ Error - Ошибка + Ошибка Dialog with name: %1 already exists - + Диалог с именем %1 уже существует ui file must cointain QDialog instead QWidget or QMainWindow - + ui файл должен содержать QDialog вместо QWidget или QMainWindow wrong file format - + неправильный формат файла LimeReport::ScriptEngineContext Dialog with name: %1 can`t be created - + Диалог с именем: %1 не может быть создан + + + Error + Ошибка @@ -1737,11 +2199,31 @@ This preview is no longer valid. Variable %1 not found - Переменная %1 не найдена + Переменная %1 не найдена Name - Имя переменной + Имя переменной + + + GROUP FUNCTIONS + АГРЕГАТНЫЕ ФУНКЦИИ + + + SYSTEM + СИСТЕМНЫЕ + + + NUMBER + ЧИСЛОВЫЕ + + + DATE&TIME + ДАТА И ВРЕМЯ + + + GENERAL + ОБЩИЕ @@ -1768,15 +2250,15 @@ This preview is no longer valid. Designer Setting - + Настройки дизайнера Report Setting - + Настройки отчета Suppress absent fields and variables warning - + Не выводить сообщения об отсутствия полей или переменных @@ -1797,7 +2279,7 @@ This preview is no longer valid. LimeReport::TearOffBand Tear-off Band - Отрыв данных + Полоса для отрывания @@ -1855,12 +2337,16 @@ This preview is no longer valid. TextItem " %1 " already has folower " %2 " - Текстовый элемент "%1" уже следует за "%2" + Текстовый элемент "%1" уже следует за "%2" - TextItem " %1 " not found ! + TextItem " %1 " not found! Текстовый элемент "%1" не найден! + + Transparent + Прозрачный + LimeReport::TextItemEditor @@ -1913,15 +2399,15 @@ This preview is no longer valid. LimeReport::VariablesHolder variable with name - переменная + переменная - already exists !! - уже существует !! + already exists! + уже существует! - does not exists !! - не существует !! + does not exists! + не существует! @@ -2012,11 +2498,11 @@ This preview is no longer valid. and child - и подчиненный + и подчиненный datasouce "%1" not found! - источник данных "%1" не найден ! + источник данных "%1" не найден! Attention! @@ -2028,7 +2514,7 @@ This preview is no longer valid. Object with name %1 already exists - Объект с именем %1 уже существует + Объект с именем %1 уже существует Function %1 not found or have wrong arguments @@ -2068,7 +2554,7 @@ This preview is no longer valid. Master datasource "%1" not found!!! - Главный источник данных "%1" не найден! + Главный источник данных "%1" не найден! Master datasouce "%1" not found! @@ -2120,11 +2606,23 @@ This preview is no longer valid. Tear-off Band - Отрыв данных + Полоса для отрывания Wrong file format - + Неправильный формат файла + + + Datasource manager not found + Менеджер источников данных не найден + + + Master datasource "%1" not found! + Главный источник данных "%1" не найден! + + + Object with name %1 already exists! + Объект с именем %1 уже существует! diff --git a/translations/limereport_zh.ts b/translations/limereport_zh.ts new file mode 100644 index 0000000..dec023c --- /dev/null +++ b/translations/limereport_zh.ts @@ -0,0 +1,2507 @@ + + + + + LRVariableDialog + + Variable + 变量 + + + Name + 名称 + + + Value + + + + Type + 类型 + + + Attention + 注意 + + + + LimeReport::AboutDialog + + About + 关于 + + + Lime Report + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><img src=":/report/images/logo_100.png" height="100" style="float: left;" /><span style=" font-size:12pt; font-weight:600;">Report engine for </span><span style=" font-size:12pt; font-weight:600; color:#7faa18;">Qt</span><span style=" font-size:12pt; font-weight:600;"> framework</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">LimeReport - multi-platform C++ library written using Qt framework and intended for software developers that would like to add into their application capability to form report or print forms generated using templates.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">Official web site : </span><a href="www.limereport.ru"><span style=" font-size:11pt; text-decoration: underline; color:#0000ff;">www.limereport.ru</span></a></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt; text-decoration: underline; color:#0000ff;"><br /></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:10pt; font-weight:600;">This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:10pt; font-weight:600; color:#000000;"><br /></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:10pt;">Copyright 2015 Arin Alexander. All rights reserved.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><img src=":/report/images/logo_100.png" height="100" style="float: left;" /><span style=" font-size:12pt; font-weight:600; color:#7faa18;">Qt</span><span style=" font-size:12pt; font-weight:600;">报表引擎</span></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">LimeReport - QT框架多平台C++库,帮助开发者给应用增加基于模板生成报表及打印报表功能。</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">官方网站: </span><a href="www.limereport.ru"><span style=" font-size:11pt; text-decoration: underline; color:#0000ff;">www.limereport.ru</span></a></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt; text-decoration: underline; color:#0000ff;"><br /></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:10pt; font-weight:600;">该库基于提供帮助目的发布,但不提供任何担保,不以任何形式提供其适销性或适用于某一特定用途的默示保证。</span></p> +<p align="justify" style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:10pt; font-weight:600; color:#000000;"><br /></p> +<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:10pt;">版权 2015 Arin Alexander.所有权利保留.</span></p></body></html> + + + Author + 作者 + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Arin Alexander</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">arin_a@bk.ru</p></body></html> + + + + License + 许可 + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">(c) 2015 Arin Alexander arin_a@bk.ru</p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><br /></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="SEC1"></a><span style=" font-family:'sans-serif'; font-weight:600;">G</span><span style=" font-family:'sans-serif'; font-weight:600;">NU LESSER GENERAL PUBLIC LICENSE</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Version 2.1, February 1999</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Copyright (C) 1991, 1999 Free Software Foundation, Inc.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Everyone is permitted to copy and distribute verbatim copies</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">of this license document, but changing it is not allowed.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'monospace';"><br /></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">[This is the first released version of the Lesser GPL. It also counts</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';"> as the successor of the GNU Library Public License, version 2, hence</span></p> +<p style=" margin-top:0px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';"> the version number 2.1.]</span></p> +<p style=" margin-top:15px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="SEC2"></a><span style=" font-family:'sans-serif'; font-weight:600;">P</span><span style=" font-family:'sans-serif'; font-weight:600;">reamble</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public Licenses are intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">This license, the Lesser General Public License, applies to some specially designated software packages--typically libraries--of the Free Software Foundation and other authors who decide to use it. You can use it too, but we suggest you first think carefully about whether this license or the ordinary General Public License is the better strategy to use in any particular case, based on the explanations below.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">When we speak of free software, we are referring to freedom of use, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish); that you receive source code or can get it if you want it; that you can change the software and use pieces of it in new free programs; and that you are informed that you can do these things.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">To protect your rights, we need to make restrictions that forbid distributors to deny you these rights or to ask you to surrender these rights. These restrictions translate to certain responsibilities for you if you distribute copies of the library or if you modify it.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">For example, if you distribute copies of the library, whether gratis or for a fee, you must give the recipients all the rights that we gave you. You must make sure that they, too, receive or can get the source code. If you link other code with the library, you must provide complete object files to the recipients, so that they can relink them with the library after making changes to the library and recompiling it. And you must show them these terms so they know their rights.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">We protect your rights with a two-step method: (1) we copyright the library, and (2) we offer you this license, which gives you legal permission to copy, distribute and/or modify the library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">To protect each distributor, we want to make it very clear that there is no warranty for the free library. Also, if the library is modified by someone else and passed on, the recipients should know that what they have is not the original version, so that the original author's reputation will not be affected by problems that might be introduced by others.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Finally, software patents pose a constant threat to the existence of any free program. We wish to make sure that a company cannot effectively restrict the users of a free program by obtaining a restrictive license from a patent holder. Therefore, we insist that any patent license obtained for a version of the library must be consistent with the full freedom of use specified in this license.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Most GNU software, including some libraries, is covered by the ordinary GNU General Public License. This license, the GNU Lesser General Public License, applies to certain designated libraries, and is quite different from the ordinary General Public License. We use this license for certain libraries in order to permit linking those libraries into non-free programs.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">When a program is linked with a library, whether statically or using a shared library, the combination of the two is legally speaking a combined work, a derivative of the original library. The ordinary General Public License therefore permits such linking only if the entire combination fits its criteria of freedom. The Lesser General Public License permits more lax criteria for linking other code with the library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">We call this license the &quot;Lesser&quot; General Public License because it does Less to protect the user's freedom than the ordinary General Public License. It also provides other free software developers Less of an advantage over competing non-free programs. These disadvantages are the reason we use the ordinary General Public License for many libraries. However, the Lesser license provides advantages in certain special circumstances.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">For example, on rare occasions, there may be a special need to encourage the widest possible use of a certain library, so that it becomes a de-facto standard. To achieve this, non-free programs must be allowed to use the library. A more frequent case is that a free library does the same job as widely used non-free libraries. In this case, there is little to gain by limiting the free library to free software only, so we use the Lesser General Public License.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">In other cases, permission to use a particular library in non-free programs enables a greater number of people to use a large body of free software. For example, permission to use the GNU C Library in non-free programs enables many more people to use the whole GNU operating system, as well as its variant, the GNU/Linux operating system.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Although the Lesser General Public License is Less protective of the users' freedom, it does ensure that the user of a program that is linked with the Library has the freedom and the wherewithal to run that program using a modified version of the Library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">The precise terms and conditions for copying, distribution and modification follow. Pay close attention to the difference between a &quot;work based on the library&quot; and a &quot;work that uses the library&quot;. The former contains code derived from the library, whereas the latter must be combined with the library in order to run.</span></p> +<p style=" margin-top:15px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="SEC3"></a><span style=" font-family:'sans-serif'; font-weight:600; color:#333333;">T</span><span style=" font-family:'sans-serif'; font-weight:600; color:#333333;">ERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">0.</span><span style=" font-family:'sans-serif';"> This License Agreement applies to any software library or other program which contains a notice placed by the copyright holder or other authorized party saying it may be distributed under the terms of this Lesser General Public License (also called &quot;this License&quot;). Each licensee is addressed as &quot;you&quot;.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">A &quot;library&quot; means a collection of software functions and/or data prepared so as to be conveniently linked with application programs (which use some of those functions and data) to form executables.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">The &quot;Library&quot;, below, refers to any such software library or work which has been distributed under these terms. A &quot;work based on the Library&quot; means either the Library or any derivative work under copyright law: that is to say, a work containing the Library or a portion of it, either verbatim or with modifications and/or translated straightforwardly into another language. (Hereinafter, translation is included without limitation in the term &quot;modification&quot;.)</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">&quot;Source code&quot; for a work means the preferred form of the work for making modifications to it. For a library, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running a program using the Library is not restricted, and output from such a program is covered only if its contents constitute a work based on the Library (independent of the use of the Library in a tool for writing it). Whether that is true depends on what the Library does and what the program that uses the Library does.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">1.</span><span style=" font-family:'sans-serif';"> You may copy and distribute verbatim copies of the Library's complete source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and distribute a copy of this License along with the Library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">2.</span><span style=" font-family:'sans-serif';"> You may modify your copy or copies of the Library or any portion of it, thus forming a work based on the Library, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions:</span></p> +<ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" font-family:'sans-serif';" style=" margin-top:19px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">a)</span><span style=" font-size:16px;"> The modified work must itself be a software library.</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">b)</span><span style=" font-size:16px;"> You must cause the files modified to carry prominent notices stating that you changed the files and the date of any change.</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">c)</span><span style=" font-size:16px;"> You must cause the whole of the work to be licensed at no charge to all third parties under the terms of this License.</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:19px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">d)</span><span style=" font-size:16px;"> If a facility in the modified Library refers to a function or a table of data to be supplied by an application program that uses the facility, other than as an argument passed when the facility is invoked, then you must make a good faith effort to ensure that, in the event an application does not supply such function or table, the facility still operates, and performs whatever part of its purpose remains meaningful.</span></li></ul> +<p style=" margin-top:15px; margin-bottom:15px; margin-left:38px; margin-right:19px; -qt-block-indent:1; text-indent:0px;"><span style=" font-family:'sans-serif';">(For example, a function in a library to compute square roots has a purpose that is entirely well-defined independent of the application. Therefore, Subsection 2d requires that any application-supplied function or table used by this function must be optional: if the application does not supply it, the square root function must still compute square roots.)</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Library, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Library, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">In addition, mere aggregation of another work not based on the Library with the Library (or with a work based on the Library) on a volume of a storage or distribution medium does not bring the other work under the scope of this License.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">3.</span><span style=" font-family:'sans-serif';"> You may opt to apply the terms of the ordinary GNU General Public License instead of this License to a given copy of the Library. To do this, you must alter all the notices that refer to this License, so that they refer to the ordinary GNU General Public License, version 2, instead of to this License. (If a newer version than version 2 of the ordinary GNU General Public License has appeared, then you can specify that version instead if you wish.) Do not make any other change in these notices.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Once this change is made in a given copy, it is irreversible for that copy, so the ordinary GNU General Public License applies to all subsequent copies and derivative works made from that copy.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">This option is useful when you wish to copy part of the code of the Library into a program that is not a library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">4.</span><span style=" font-family:'sans-serif';"> You may copy and distribute the Library (or a portion or derivative of it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">If distribution of object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place satisfies the requirement to distribute the source code, even though third parties are not compelled to copy the source along with the object code.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">5.</span><span style=" font-family:'sans-serif';"> A program that contains no derivative of any portion of the Library, but is designed to work with the Library by being compiled or linked with it, is called a &quot;work that uses the Library&quot;. Such a work, in isolation, is not a derivative work of the Library, and therefore falls outside the scope of this License.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">However, linking a &quot;work that uses the Library&quot; with the Library creates an executable that is a derivative of the Library (because it contains portions of the Library), rather than a &quot;work that uses the library&quot;. The executable is therefore covered by this License. Section 6 states terms for distribution of such executables.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">When a &quot;work that uses the Library&quot; uses material from a header file that is part of the Library, the object code for the work may be a derivative work of the Library even though the source code is not. Whether this is true is especially significant if the work can be linked without the Library, or if the work is itself a library. The threshold for this to be true is not precisely defined by law.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">If such an object file uses only numerical parameters, data structure layouts and accessors, and small macros and small inline functions (ten lines or less in length), then the use of the object file is unrestricted, regardless of whether it is legally a derivative work. (Executables containing this object code plus portions of the Library will still fall under Section 6.)</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Otherwise, if the work is a derivative of the Library, you may distribute the object code for the work under the terms of Section 6. Any executables containing that work also fall under Section 6, whether or not they are linked directly with the Library itself.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">6.</span><span style=" font-family:'sans-serif';"> As an exception to the Sections above, you may also combine or link a &quot;work that uses the Library&quot; with the Library to produce a work containing portions of the Library, and distribute that work under terms of your choice, provided that the terms permit modification of the work for the customer's own use and reverse engineering for debugging such modifications.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">You must give prominent notice with each copy of the work that the Library is used in it and that the Library and its use are covered by this License. You must supply a copy of this License. If the work during execution displays copyright notices, you must include the copyright notice for the Library among them, as well as a reference directing the user to the copy of this License. Also, you must do one of these things:</span></p> +<ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" font-family:'sans-serif';" style=" margin-top:19px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">a)</span><span style=" font-size:16px;"> Accompany the work with the complete corresponding machine-readable source code for the Library including whatever changes were used in the work (which must be distributed under Sections 1 and 2 above); and, if the work is an executable linked with the Library, with the complete machine-readable &quot;work that uses the Library&quot;, as object code and/or source code, so that the user can modify the Library and then relink to produce a modified executable containing the modified Library. (It is understood that the user who changes the contents of definitions files in the Library will not necessarily be able to recompile the application to use the modified definitions.)</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">b)</span><span style=" font-size:16px;"> Use a suitable shared library mechanism for linking with the Library. A suitable mechanism is one that (1) uses at run time a copy of the library already present on the user's computer system, rather than copying library functions into the executable, and (2) will operate properly with a modified version of the library, if the user installs one, as long as the modified version is interface-compatible with the version that the work was made with.</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">c)</span><span style=" font-size:16px;"> Accompany the work with a written offer, valid for at least three years, to give the same user the materials specified in Subsection 6a, above, for a charge no more than the cost of performing this distribution.</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">d)</span><span style=" font-size:16px;"> If distribution of the work is made by offering access to copy from a designated place, offer equivalent access to copy the above specified materials from the same place.</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:19px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">e)</span><span style=" font-size:16px;"> Verify that the user has already received a copy of these materials or that you have already sent this user a copy.</span></li></ul> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">For an executable, the required form of the &quot;work that uses the Library&quot; must include any data and utility programs needed for reproducing the executable from it. However, as a special exception, the materials to be distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">It may happen that this requirement contradicts the license restrictions of other proprietary libraries that do not normally accompany the operating system. Such a contradiction means you cannot use both them and the Library together in an executable that you distribute.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">7.</span><span style=" font-family:'sans-serif';"> You may place library facilities that are a work based on the Library side-by-side in a single library together with other library facilities not covered by this License, and distribute such a combined library, provided that the separate distribution of the work based on the Library and of the other library facilities is otherwise permitted, and provided that you do these two things:</span></p> +<ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" font-family:'sans-serif';" style=" margin-top:19px; margin-bottom:0px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">a)</span><span style=" font-size:16px;"> Accompany the combined library with a copy of the same work based on the Library, uncombined with any other library facilities. This must be distributed under the terms of the Sections above.</span></li> +<li style=" font-family:'sans-serif';" style=" margin-top:0px; margin-bottom:19px; margin-left:38px; margin-right:19px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:16px; font-weight:600;">b)</span><span style=" font-size:16px;"> Give prominent notice with the combined library of the fact that part of it is a work based on the Library, and explaining where to find the accompanying uncombined form of the same work.</span></li></ul> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">8.</span><span style=" font-family:'sans-serif';"> You may not copy, modify, sublicense, link with, or distribute the Library except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense, link with, or distribute the Library is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">9.</span><span style=" font-family:'sans-serif';"> You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Library or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Library (or any work based on the Library), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Library or works based on it.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">10.</span><span style=" font-family:'sans-serif';"> Each time you redistribute the Library (or any work based on the Library), the recipient automatically receives a license from the original licensor to copy, distribute, link with or modify the Library subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties with this License.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">11.</span><span style=" font-family:'sans-serif';"> If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Library at all. For example, if a patent license would not permit royalty-free redistribution of the Library by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Library.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply, and the section as a whole is intended to apply in other circumstances.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">12.</span><span style=" font-family:'sans-serif';"> If the distribution and/or use of the Library is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Library under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">13.</span><span style=" font-family:'sans-serif';"> The Free Software Foundation may publish revised and/or new versions of the Lesser General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Each version is given a distinguishing version number. If the Library specifies a version number of this License which applies to it and &quot;any later version&quot;, you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Library does not specify a license version number, you may choose any version ever published by the Free Software Foundation.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">14.</span><span style=" font-family:'sans-serif';"> If you wish to incorporate parts of the Library into other free programs whose distribution conditions are incompatible with these, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">NO WARRANTY</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">15.</span><span style=" font-family:'sans-serif';"> BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE LIBRARY &quot;AS IS&quot; WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600;">16.</span><span style=" font-family:'sans-serif';"> IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.</span></p> +<p style=" margin-top:15px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif'; font-weight:600; color:#333333;">END OF TERMS AND CONDITIONS</span></p> +<p style=" margin-top:15px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="SEC4"></a><span style=" font-family:'sans-serif'; font-weight:600; color:#333333;">H</span><span style=" font-family:'sans-serif'; font-weight:600; color:#333333;">ow to Apply These Terms to Your New Libraries</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">If you develop a new library, and you want it to be of the greatest possible use to the public, we recommend making it free software that everyone can redistribute and change. You can do so by permitting redistribution under these terms (or, alternatively, under the terms of the ordinary General Public License).</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">To apply these terms, attach the following notices to the library. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the &quot;copyright&quot; line and a pointer to where the full notice is found.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace'; font-style:italic;">one line to give the library's name and an idea of what it does.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Copyright (C) </span><span style=" font-family:'monospace'; font-style:italic;">year</span><span style=" font-family:'monospace';"> </span><span style=" font-family:'monospace'; font-style:italic;">name of author</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'monospace'; font-style:italic;"><br /></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">This library is free software; you can redistribute it and/or</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">modify it under the terms of the GNU Lesser General Public</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">License as published by the Free Software Foundation; either</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">version 2.1 of the License, or (at your option) any later version.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'monospace';"><br /></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">This library is distributed in the hope that it will be useful,</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">but WITHOUT ANY WARRANTY; without even the implied warranty of</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Lesser General Public License for more details.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'monospace';"><br /></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">You should have received a copy of the GNU Lesser General Public</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">License along with this library; if not, write to the Free Software</span></p> +<p style=" margin-top:0px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">Also add information on how to contact you by electronic and paper mail.</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">You should also get your employer (if you work as a programmer) or your school, if any, to sign a &quot;copyright disclaimer&quot; for the library, if necessary. Here is a sample; alter the names:</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Yoyodyne, Inc., hereby disclaims all copyright interest in</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">the library `Frob' (a library for tweaking knobs) written</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">by James Random Hacker.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'monospace';"><br /></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace'; font-style:italic;">signature of Ty Coon</span><span style=" font-family:'monospace';">, 1 April 1990</span></p> +<p style=" margin-top:0px; margin-bottom:15px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'monospace';">Ty Coon, President of Vice</span></p> +<p style=" margin-top:19px; margin-bottom:19px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'sans-serif';">That's all there is to it!</span></p></body></html> + + + + Close + 关闭 + + + Version 1.1.1 + 版本 1.1.1 + + + + LimeReport::AlignmentPropItem + + Left + + + + Right + + + + Center + 居中 + + + Justify + 对齐 + + + Top + + + + Botom + + + + horizontal + 水平 + + + vertical + 垂直 + + + + LimeReport::BandDesignIntf + + DataBand + 数据带 + + + DataHeaderBand + 数据带头 + + + DataFooterBand + 数据带脚 + + + ReportHeader + 表头 + + + ReportFooter + 表脚 + + + PageHeader + 页眉 + + + PageFooter + 页脚 + + + SubDetailBand + 子细节带 + + + SubDetailHeaderBand + 子细节带头 + + + SubDetailFooterBand + 子细节带脚 + + + GroupBandHeader + 组带头 + + + GroupBandFooter + 组带脚 + + + TearOffBand + 分离带 + + + connected to + 连接到 + + + Bring to top + 置顶 + + + Send to back + 置底 + + + Auto height + 自动高度 + + + Splittable + 可拆分 + + + Keep bottom space + 保持底部距离 + + + Start from new page + 从新页开始 + + + Start new page + 开始新页 + + + + LimeReport::BaseDesignIntf + + Copy + 复制 + + + Cut + 剪切 + + + Paste + 粘贴 + + + Bring to top + 置顶 + + + Send to back + 置底 + + + No borders + 无边框 + + + All borders + 所有边框 + + + + LimeReport::ConnectionDesc + + defaultConnection + 默认连接 + + + + LimeReport::ConnectionDialog + + Connection + 数据连接 + + + Connection Name + 连接名称 + + + Use default application connection + 使用默认应用连接 + + + Driver + 驱动 + + + Server + 服务器 + + + Port + 端口 + + + User + 用户名 + + + Password + 密码 + + + Database + 数据库 + + + ... + + + + Auto connect + 自动连接 + + + Dont keep credentals in lrxml + 不在lrxml文件中保存凭证 + + + Check connection + 检查连接 + + + Cancel + 取消 + + + Ok + 确定 + + + Error + 错误 + + + Connection succsesfully established! + 连接成功建立! + + + Connection Name is empty + 连接名为空 + + + Connection with name + 连接 + + + already exists! + 已经存在! + + + defaultConnection + 默认连接 + + + + LimeReport::DataBand + + Data + 数据带 + + + + LimeReport::DataBrowser + + Datasources + 数据源 + + + Add database connection + 新建数据库连接 + + + ... + + + + Add new datasource + 新建数据源 + + + View data + 查看数据 + + + Change datasource + 编辑数据源 + + + Delete datasource + 删除数据源 + + + Show error + 显示错误 + + + Variables + 变量 + + + Add new variable + 新增变量 + + + Edit variable + 编辑变量 + + + Delete variable + 删除变量 + + + Grab variable + 取得变量 + + + Attention + 注意 + + + Do you really want to delete "%1" connection? + 是否确认删除"%1"连接? + + + Report variables + 报表变量 + + + System variables + 系统变量 + + + External variables + 外部变量 + + + Do you really want to delete "%1" datasource? + 是否确认删除"%1"数据源? + + + Do you really want to delete variable "%1"? + 是否确认删除变量"%1"? + + + Error + 错误 + + + + LimeReport::DataFooterBand + + DataFooter + 数据带脚 + + + + LimeReport::DataHeaderBand + + DataHeader + 数据带头 + + + + LimeReport::DataSourceManager + + Connection "%1" is not open + 连接"%1"没有打开 + + + Variable "%1" not found! + 未找到变量"%1"! + + + Datasource "%1" not found! + 未找到数据源"%1"! + + + Connection with name "%1" already exists! + 连接 "%1" 已存在! + + + Datasource with name "%1" already exists! + 数据源 "%1" 已存在! + + + Database "%1" not found + 未找到数据库 "%1" + + + invalid connection + 无效连接 + + + + LimeReport::DataSourceModel + + Datasources + 数据源 + + + Variables + 变量 + + + External variables + 外部变量 + + + + LimeReport::EnumPropItem + + Default + 默认 + + + Portrait + 纵向 + + + Landscape + 横向 + + + NoneAutoWidth + 无自动宽度 + + + MaxWordLength + 最大词长 + + + MaxStringLength + 最大字符串长 + + + TransparentMode + 透明模式 + + + OpaqueMode + 不透明模式 + + + Angle0 + 0度 + + + Angle90 + 90度 + + + Angle180 + 180度 + + + Angle270 + 270度 + + + Angle45 + 45度 + + + Angle315 + 315度 + + + DateTime + 日期时间 + + + Double + + + + NoBrush + + + + SolidPattern + 填充 + + + Dense1Pattern + 密集1 + + + Dense2Pattern + 密集2 + + + Dense3Pattern + 密集3 + + + Dense4Pattern + 密集4 + + + Dense5Pattern + 密集5 + + + Dense6Pattern + 密集6 + + + Dense7Pattern + 密集7 + + + HorPattern + 横条纹 + + + VerPattern + 竖条纹 + + + CrossPattern + 交叉条纹 + + + BDiagPattern + 斜条纹 + + + FDiagPattern + 反斜条纹 + + + LeftToRight + 从左到右 + + + RightToLeft + 从右到左 + + + LayoutDirectionAuto + 自动布局方向 + + + LeftItemAlign + 左对齐 + + + RightItemAlign + 右对齐 + + + CenterItemAlign + 居中对齐 + + + ParentWidthItemAlign + 上层宽度对齐 + + + DesignedItemAlign + 保持设计对齐 + + + HorizontalLine + 水平线 + + + VerticalLine + 垂直线 + + + Ellipse + 椭圆 + + + Rectangle + 矩形 + + + Page + + + + Band + + + + Horizontal + 水平 + + + Vertical + 垂直 + + + VerticalUniform + 均匀垂直 + + + + LimeReport::FlagsPropItem + + NoLine + 无边框 + + + TopLine + 顶边框 + + + BottomLine + 底边框 + + + LeftLine + 左边框 + + + RightLine + 右边框 + + + + LimeReport::FontEditorWidget + + Font bold + 粗体 + + + Font Italic + 斜体 + + + Font Underline + 下划线 + + + + LimeReport::FontPropItem + + bold + 粗体 + + + italic + 斜体 + + + underline + 下划线 + + + size + 字号 + + + family + 系列 + + + + LimeReport::GroupBandFooter + + GroupFooter + 组带脚 + + + + LimeReport::GroupBandHeader + + GroupHeader + 组带头 + + + Group field not found + 未找到组字段 + + + Datasource "%1" not found! + 未找到数据源 "%1"! + + + + LimeReport::GroupFunction + + Field "%1" not found + 未找到字段 "%1" + + + Variable "%1" not found + 未找到变量 "%1" + + + Wrong script syntax "%1" + 脚本语法错误 "%1" + + + Item "%1" not found + 未找到目标项 "%1" + + + + LimeReport::ImageItem + + Image + 图像 + + + + LimeReport::ItemLocationPropItem + + Band + + + + Page + + + + + LimeReport::ItemsAlignmentEditorWidget + + Bring to top + 置顶 + + + Send to back + 置底 + + + Align to left + 左对齐 + + + Align to right + 右对齐 + + + Align to vertical center + 居中对齐 + + + Align to top + 顶部对齐 + + + Align to bottom + 底部对齐 + + + Align to horizontal center + 水平居中 + + + Set same height + 相同高度 + + + Set same width + 相同宽度 + + + + LimeReport::ItemsBordersEditorWidget + + Top line + 顶边框 + + + Bottom line + 底边框 + + + Left line + 左边框 + + + Right line + 右边框 + + + No borders + 无边框 + + + All borders + 所有边框 + + + + LimeReport::MasterDetailProxyModel + + Field: "%1" not found in "%2" child datasource + 从数据源 "%2" 中未找到字段: "%1" + + + Field: "%1" not found in "%2" master datasource + 主数据源 "%2" 中未找到字段: "%1" + + + + LimeReport::ModelToDataSource + + model is destroyed + 数据模型已销毁 + + + + LimeReport::ObjectBrowser + + Objects + 对象 + + + + LimeReport::PageFooter + + Page Footer + 页脚 + + + + LimeReport::PageHeader + + Page Header + 页眉 + + + + LimeReport::PageItemDesignIntf + + Paste + 粘贴 + + + + LimeReport::PreviewReportWidget + + Form + 表格 + + + PDF file name + PDF 文件名 + + + Report file name + 报表文件名 + + + + LimeReport::PreviewReportWindow + + Preview + 预览 + + + View + 查看 + + + Report + 报表 + + + toolBar + 工具栏 + + + Print + 打印 + + + Ctrl+P + + + + Zoom In + 放大 + + + Zoom Out + 缩小 + + + Prior Page + 上一页 + + + Next Page + 下一页 + + + Close Preview + 关闭预览 + + + Esc + + + + Edit Mode + 编辑模式 + + + Save to file + 保存 + + + Show errors + 显示错误 + + + First Page + 首页 + + + First page + 首页 + + + Last Page + 末页 + + + Print To PDF + 打印到PDF文件 + + + Fit page width + 适合页宽 + + + Fit page + 适合页高 + + + One to one + 原始尺寸 + + + Show Toolbar + 显示工具栏 + + + Show toolbar + 显示工具栏 + + + Page: + 页数: + + + Font + 字体 + + + Text align + 文本对齐 + + + of %1 + / %1 + + + + LimeReport::ProxyHolder + + Datasource has been invalidated + 数据源已失效 + + + + LimeReport::QObjectPropertyModel + + leftMargin + 左边距 + + + rightMargin + 右边距 + + + topMargin + 顶边距 + + + bottomMargin + 底边距 + + + objectName + 对象名称 + + + borders + 边框 + + + geometry + 形状 + + + itemAlign + 对齐方式 + + + pageOrientation + 页面布局 + + + pageSize + 页面规格 + + + TopLine + 顶边框 + + + BottomLine + 底边框 + + + LeftLine + 左边框 + + + RightLine + 右边框 + + + reprintOnEachPage + 重新打印每页 + + + borderLineSize + 边框线宽 + + + autoHeight + 自动高度 + + + backgroundColor + 背景颜色 + + + columnCount + 列数 + + + columnsFillDirection + 列填充方向 + + + datasource + 数据源 + + + keepBottomSpace + 保持底部空间 + + + keepFooterTogether + 保持页脚 + + + keepSubdetailTogether + 保持子细节脚 + + + printIfEmpty + 为空时打印 + + + sliceLastRow + 分割末行 + + + splittable + 可拆分 + + + alignment + 对齐 + + + angle + 角度 + + + autoWidth + 自动宽度 + + + backgroundMode + 背景模式 + + + backgroundOpacity + 背景不透明度 + + + content + 内容 + + + font + 字体 + + + fontColor + 字体颜色 + + + foregroundOpacity + 背景不透明度 + + + itemLocation + 组件位置 + + + margin + 边距 + + + stretchToMaxHeight + 拉伸到最大高度 + + + trimValue + 裁剪值 + + + lineWidth + 线宽 + + + opacity + 不透明度 + + + penStyle + 画笔样式 + + + shape + 形状 + + + shapeBrush + 画刷 + + + shapeBrushColor + 画刷颜色 + + + gridStep + 栅格长 + + + fullPage + 全页 + + + oldPrintMode + 旧打印模式 + + + borderColor + 边框颜色 + + + resetPageNumber + 重置页号 + + + alternateBackgroundColor + 变更背景色 + + + backgroundBrushStyle + 背景画刷样式 + + + startFromNewPage + 从新页开始 + + + startNewPage + 开始新页 + + + adaptFontToSize + 字体适应字号 + + + allowHTML + 允许HTML + + + allowHTMLInFields + 允许字段HTML + + + followTo + 跟随 + + + format + 格式 + + + lineSpacing + 线距 + + + textIndent + 文本缩进 + + + textLayoutDirection + 文本布局方向 + + + underlineLineSize + 下划线宽 + + + underlines + 下划线 + + + valueType + 值类型 + + + securityLevel + 安全级别 + + + testValue + 测试值 + + + whitespace + 空格 + + + resourcePath + 资源路径 + + + scale + 比例 + + + cornerRadius + 圆角半径 + + + shapeColor + 颜色 + + + layoutType + 布局类型 + + + barcodeType + 条码类型 + + + barcodeWidth + 条码宽度 + + + foregroundColor + 颜色 + + + inputMode + 输入法 + + + pdf417CodeWords + PDF417码 + + + autoSize + 自动大小 + + + center + 居中 + + + field + 字段 + + + image + 图像 + + + keepAspectRatio + 保持比例 + + + columnsCount + 列数 + + + useAlternateBackgroundColor + 使用变更背景色 + + + printBeforePageHeader + 页眉前打印 + + + maxScalePercent + 最大百分比 + + + printOnFirstPage + 打印到首页 + + + printOnLastPage + 打印到尾页 + + + printAlways + 始终打印 + + + repeatOnEachRow + 每行重复 + + + condition + 条件 + + + groupFieldName + 组字段名 + + + keepGroupTogether + 保持组脚 + + + Property Name + 属性名 + + + Property value + 属性值 + + + Warning + 警告 + + + + LimeReport::RectMMPropItem + + width + + + + height + + + + + LimeReport::RectPropItem + + width + + + + height + + + + + LimeReport::ReportDesignWidget + + Script + 脚本 + + + Report file name + 报表文件名 + + + Error + 错误 + + + Wrong file format + 文件格式错误 + + + + LimeReport::ReportDesignWindow + + New Report + 新建报表 + + + New Report Page + 新建页 + + + Delete Report Page + 删除也 + + + Edit Mode + 编辑模式 + + + Undo + 撤销 + + + Redo + 重做 + + + Copy + 复制 + + + Paste + 粘贴 + + + Cut + 剪切 + + + Settings + 设置 + + + Use grid + 使用栅格 + + + Use magnet + 使用磁力 + + + Text Item + 文本组件 + + + Save Report + 保存报表 + + + Save Report As + 另存为 + + + Load Report + 读取报表 + + + Delete item + 删除组建 + + + Zoom In + 放大 + + + Zoom Out + 缩小 + + + Render Report + 生成报表 + + + Edit layouts mode + 编辑布局模式 + + + Horizontal layout + 水平布局 + + + About + 关于 + + + Hide left panel | Alt+L + 隐藏左面板 | Alt+L + + + Hide right panel | Alt+R + 隐藏右面板 | Alt+R + + + Report Tools + 报表工具 + + + Main Tools + 工具 + + + Font + 字体 + + + Text alignment + 文本对齐 + + + Items alignment + 组件对齐 + + + Borders + 边框 + + + Report bands + 报表带 + + + Report Header + 表头 + + + Report Footer + 表脚 + + + Page Header + 页眉 + + + Page Footer + 页脚 + + + Data + 数据带 + + + Data Header + 数据带头 + + + Data Footer + 数据带脚 + + + SubDetail + 子细节带 + + + SubDetailHeader + 子细节带头 + + + SubDetailFooter + 子细节带脚 + + + GroupHeader + 组带头 + + + GroupFooter + 组带脚 + + + Tear-off Band + 分离带 + + + File + 文件 + + + Edit + 编辑 + + + Info + 信息 + + + Recent Files + 最近打开文件 + + + Object Inspector + 对象观察器 + + + Report structure + 报表结构 + + + Data Browser + 数据浏览器 + + + Script Browser + 脚本浏览器 + + + Report has been modified! Do you want save the report? + 报表已修改! 是否保存? + + + Report file name + 报表文件名 + + + Rendering report + 生成报表 + + + Abort + 关于 + + + page rendered + 报表生成 + + + Warning + 警告 + + + File "%1" not found! + 未找到文件 "%1"! + + + + LimeReport::ReportEnginePrivate + + Preview + 预览 + + + Error + 错误 + + + Report File Change + 报表文件改变 + + + The report file "%1" has changed names or been deleted. + +This preview is no longer valid. + 报表文件 "%1" 重命名或删除。 + +预览已无效。 + + + + LimeReport::ReportFooter + + Report Footer + 表脚 + + + + LimeReport::ReportHeader + + Report Header + 表头 + + + + LimeReport::ReportRender + + Error + 错误 + + + page index out of range + 页索引越界 + + + Databand "%1" not found + 未找到数据带 "%1" + + + Wrong using function %1 + 函数 %1 使用错误 + + + + LimeReport::SQLEditDialog + + Datasource + 数据源 + + + Connection + 数据连接 + + + Datasource Name + 数据源名 + + + Subdetail + 子细节 + + + Master datasource + 主数据源 + + + Subquery mode + 子查询模式 + + + Filter mode + 筛选模式 + + + SQL + + + + Preview + 预览 + + + Hide Preview + 隐藏预览 + + + Child datasource + 子数据源 + + + Fields map + 字段映射 + + + ... + + + + Data preview + 数据预览 + + + Cancel + 取消 + + + Ok + 确定 + + + Error + 错误 + + + Datasource Name is empty! + 数据源名为空! + + + SQL is empty! + SQL语句为空! + + + Datasource with name: "%1" already exists! + 数据源 "%1" 已存在! + + + defaultConnection + 默认连接 + + + Datasource with name %1 already exist + 数据源 "%1" 已存在 + + + Attention + 注意 + + + Connection is not specified + 未指定连接 + + + Refresh + 刷新 + + + + LimeReport::ScriptBrowser + + Form + 表单 + + + Functions + 函数 + + + ... + + + + Dialogs + 对话框 + + + Type + 类型 + + + Name + 名称 + + + NO CATEGORY + 无类别 + + + Error + 错误 + + + Dialog with name: %1 already exists + 对话框 %1 已存在 + + + ui file must cointain QDialog instead QWidget or QMainWindow + ui 文件必须包含 QDialog 而不是 QWidget 或 QMainWindow + + + wrong file format + 文件格式错误 + + + + LimeReport::ScriptEngineContext + + Dialog with name: %1 can`t be created + 无法创建对话框 %1 + + + + LimeReport::ScriptEngineManager + + GROUP FUNCTIONS + 组函数 + + + Value + + + + BandName + 带名称 + + + Variable %1 not found + 未找到变量 %1 + + + SYSTEM + 系统 + + + NUMBER + 数字 + + + Format + 格式 + + + Precision + 精度 + + + Locale + 区域 + + + DATE&TIME + 日期时间 + + + Seconds + + + + CurrencySymbol + 货币符号 + + + GENERAL + 通用 + + + Name + 名称 + + + + LimeReport::SettingDialog + + Designer setting + 设计器设置 + + + Designer Setting + 设计器设置 + + + Default font + 默认字体 + + + Grid + 栅格 + + + Vertical grid step + 竖栅格 + + + Horizontal grid step + 横栅格 + + + Report Setting + 报表设置 + + + Suppress absent fields and variables warning + 抑制缺失字段及变量警告 + + + + LimeReport::SubDetailBand + + SubDetail + 子细节 + + + + LimeReport::SubDetailHeaderBand + + SubDetailHeader + 子细节头 + + + + LimeReport::TearOffBand + + Tear-off Band + 分离带 + + + + LimeReport::TextAlignmentEditorWidget + + Text align left + 文本左对齐 + + + Text align center + 文本居中对齐 + + + Text align right + 文本右对齐 + + + Text align justify + 文本行对齐 + + + Text align top + 文本顶部对齐 + + + Text align bottom + 文本底部对齐 + + + + LimeReport::TextItem + + Edit + 编辑 + + + Auto height + 自动高度 + + + Allow HTML + 允许HTML + + + Allow HTML in fields + 允许字段HTML + + + Stretch to max height + 拉伸至最大高度 + + + Error + 错误 + + + TextItem " %1 " already has folower " %2 " + 文本框 "%1 " 已有 "%2 " + + + TextItem " %1 " not found! + 未找到文本框 "%1"! + + + + LimeReport::TextItemEditor + + Text Item Editor + 文本编辑器 + + + Content + 内容 + + + Data + 数据 + + + Functions + 函数 + + + Editor settings + 编辑器设置 + + + Editor font + 编辑器字体 + + + ... + + + + Ok + 确定 + + + Ctrl+Return + + + + Cancel + 取消 + + + Esc + + + + + LimeReport::VariablesHolder + + variable with name + 变量 + + + already exists! + 已存在! + + + does not exists! + 不存在! + + + + QObject + + Data + 数据带 + + + DataHeader + 数据带头 + + + DataFooter + 数据带脚 + + + GroupHeader + 组带头 + + + GroupFooter + 组带脚 + + + Page Footer + 页脚 + + + Page Header + 页眉 + + + Report Footer + 表脚 + + + Report Header + 表头 + + + SubDetail + 子细节 + + + SubDetailHeader + 子细节头 + + + SubDetailFooter + 子细节带脚 + + + Tear-off Band + 分离带 + + + alignment + 对齐 + + + Barcode Item + 条码组件 + + + HLayout + 水平布局 + + + Image Item + 图像组件 + + + Shape Item + 图形组件 + + + itemLocation + 组件位置 + + + Text Item + 文本组件 + + + Invalid connection! %1 + 无效连接 %1 + + + Master datasource "%1" not found! + 未找到主数据源 "%1"! + + + Master datasouce "%1" not found! + 未找到主数据源 "%1"! + + + Child + + + + and child + 子数据源 + + + datasouce "%1" not found! + 未找到子数据源"%1"! + + + bool + + + + QColor + + + + content + 内容 + + + datasource + 数据源 + + + field + 字段映射 + + + enum + + + + flags + + + + QFont + + + + QImage + + + + int + + + + qreal + + + + QRect + + + + QRectF + + + + geometry + 形状 + + + QString + + + + Attention! + 注意! + + + Selected elements have different parent containers + 选中元素有不同的容器 + + + Object with name %1 already exists! + 对象 %1 已存在! + + + Function %1 not found or have wrong arguments + 未找到函数 %1 或参数错误 + + + mm + 毫米 + + + Wrong file format + 文件格式错误 + + + File %1 not opened + 无法打开文件 %1 + + + Content string is empty + 字符串为空 + + + Content is empty + 字符串为空 + + +