0
0
mirror of https://github.com/fralx/LimeReport.git synced 2024-12-23 16:22:58 +03:00

Merge branch 'develop' into feature/newScaleMethod

# Conflicts:
#	common.pri
#	limereport/lrbanddesignintf.cpp
#	limereport/lrbanddesignintf.h
#	limereport/lrbasedesignintf.cpp
#	limereport/lrbasedesignintf.h
#	limereport/lrpageitemdesignintf.h
This commit is contained in:
fralx 2021-01-20 14:56:42 +03:00
commit b18c2e4aa8
55 changed files with 2060 additions and 1195 deletions

View File

@ -18,6 +18,7 @@
#define BARCODERENDER_H
#include <QColor>
#include <QPainter>
#include <QPainterPath>
#include "qzint_global.h"
#include "zint.h"

View File

@ -1,5 +1,5 @@
# LimeReport v1.5.35 [![Build Status](https://api.travis-ci.org/fralx/LimeReport.svg?branch=master)](https://travis-ci.org/fralx/LimeReport) [![Codacy Badge](https://api.codacy.com/project/badge/Grade/bc31412ea4814f30825b5ed3723e9a70)](https://app.codacy.com/app/fralx/LimeReport?utm_source=github.com&utm_medium=referral&utm_content=fralx/LimeReport&utm_campaign=Badge_Grade_Dashboard)
# LimeReport v1.5.35 [![Build Status](https://api.travis-ci.org/fralx/LimeReport.svg?branch=master)](https://travis-ci.org/fralx/LimeReport) [![Build status](https://ci.appveyor.com/api/projects/status/wna5429pix7ilcmo/branch/master?svg=true)](https://ci.appveyor.com/project/fralx/limereport/branch/master) [![Codacy Badge](https://api.codacy.com/project/badge/Grade/bc31412ea4814f30825b5ed3723e9a70)](https://app.codacy.com/app/fralx/LimeReport?utm_source=github.com&utm_medium=referral&utm_content=fralx/LimeReport&utm_campaign=Badge_Grade_Dashboard)
## Official LimeReport web site [http://limereport.ru](http://limereport.ru)

View File

@ -134,7 +134,7 @@ RCC_DIR = $${ARCH_DIR}/$${BUILD_TYPE}/rcc
LIMEREPORT_VERSION_MAJOR = 1
LIMEREPORT_VERSION_MINOR = 5
LIMEREPORT_VERSION_RELEASE = 50
LIMEREPORT_VERSION_RELEASE = 78
LIMEREPORT_VERSION = '$${LIMEREPORT_VERSION_MAJOR}.$${LIMEREPORT_VERSION_MINOR}.$${LIMEREPORT_VERSION_RELEASE}'
DEFINES *= LIMEREPORT_VERSION_STR=\\\"$${LIMEREPORT_VERSION}\\\"

View File

@ -33,7 +33,7 @@ macx{
unix:{
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)
QMAKE_POST_LINK += $$QMAKE_COPY_DIR \"$$EXTRA_DIR\" \"$$REPORTS_DIR\" $$escape_expand(\n\t)
linux{
#Link share lib to ../lib rpath
@ -49,7 +49,7 @@ unix:{
win32 {
DESTDIR = $$DEST_DIR
contains(QMAKE_HOST.os, Linux){
QMAKE_POST_LINK += $$QMAKE_COPY_DIR $$quote($$EXTRA_DIR) $$quote($$REPORTS_DIR) $$escape_expand(\n\t)
QMAKE_POST_LINK += $$QMAKE_COPY_DIR \"$$EXTRA_DIR\" \"$$REPORTS_DIR\" $$escape_expand(\n\t)
} else {
EXTRA_DIR ~= s,/,\\,g
DEST_DIR ~= s,/,\\,g

View File

@ -33,7 +33,7 @@ macx{
unix:{
DESTDIR = $$DEST_DIR
QMAKE_POST_LINK += $$QMAKE_COPY_DIR $$quote($$EXTRA_DIR) $$quote($$REPORTS_DIR) $$escape_expand(\n\t)
QMAKE_POST_LINK += $$QMAKE_COPY_DIR \"$$EXTRA_DIR\" \"$$REPORTS_DIR\" $$escape_expand(\n\t)
linux{
#Link share lib to ../lib rpath
QMAKE_LFLAGS += -Wl,--rpath=\\\$\$ORIGIN
@ -48,7 +48,7 @@ unix:{
win32 {
DESTDIR = $$DEST_DIR
contains(QMAKE_HOST.os, Linux){
QMAKE_POST_LINK += $$QMAKE_COPY_DIR $$quote($$EXTRA_DIR) $$quote($$REPORTS_DIR) $$escape_expand(\n\t)
QMAKE_POST_LINK += $$QMAKE_COPY_DIR \"$$EXTRA_DIR\" \"$$REPORTS_DIR\" $$escape_expand(\n\t)
} else {
EXTRA_DIR ~= s,/,\\,g
DEST_DIR ~= s,/,\\,g

View File

@ -87,6 +87,7 @@ class DataFooterBand : public BandDesignIntf
{
Q_OBJECT
Q_PROPERTY(int columnsCount READ columnsCount WRITE setColumnsCount)
Q_PROPERTY(bool splittable READ isSplittable WRITE setSplittable)
Q_PROPERTY(BandColumnsLayoutType columnsFillDirection READ columnsFillDirection WRITE setColumnsFillDirection)
Q_PROPERTY(bool printAlways READ printAlways WRITE setPrintAlways)
public:

View File

@ -77,6 +77,7 @@ class SubDetailFooterBand : public BandDesignIntf
{
Q_OBJECT
Q_PROPERTY(int columnsCount READ columnsCount WRITE setColumnsCount)
Q_PROPERTY(bool splittable READ isSplittable WRITE setSplittable)
Q_PROPERTY(BandColumnsLayoutType columnsFillDirection READ columnsFillDirection WRITE setColumnsFillDirection)
Q_PROPERTY(bool printAlways READ printAlways() WRITE setPrintAlways())
public:

Binary file not shown.

After

Width:  |  Height:  |  Size: 232 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 429 B

View File

@ -118,7 +118,7 @@ ConnectionDesc *ConnectionDialog::uiToConnection(LimeReport::ConnectionDesc* con
result ->setName(ConnectionDesc::connectionNameForReport(ui->leConnectionName->text()));
result ->setHost(ui->leServerName->text());
if (!ui->lePort->text().isEmpty())
result->setPort(ui->lePort->text().toInt());
result->setPort(ui->lePort->text());
result ->setDriver(ui->cbbDrivers->currentText());
result ->setUserName(ui->leUserName->text());
result ->setPassword(ui->lePassword->text());
@ -141,7 +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()):"");
ui->lePort->setText(m_connection->port());
}
void ConnectionDialog::on_toolButton_clicked()
@ -160,6 +160,10 @@ void ConnectionDialog::on_cbbUseDefaultConnection_toggled(bool checked)
ui->leConnectionName->setEnabled(true);
}
}
void ConnectionDialog::on_toolButton_2_toggled(bool checked)
{
ui->lePassword->setEchoMode(checked ? QLineEdit::Normal : QLineEdit::Password);
}
} // namespace LimeReport
@ -167,3 +171,5 @@ void ConnectionDialog::on_cbbUseDefaultConnection_toggled(bool checked)

View File

@ -60,6 +60,8 @@ private slots:
void on_toolButton_clicked();
void on_cbbUseDefaultConnection_toggled(bool checked);
void on_toolButton_2_toggled(bool checked);
private:
Ui::ConnectionDialog *ui;
ConnectionDesc* m_connection;

View File

@ -7,7 +7,7 @@
<x>0</x>
<y>0</y>
<width>420</width>
<height>323</height>
<height>365</height>
</rect>
</property>
<property name="windowTitle">
@ -44,7 +44,7 @@
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_4">
<layout class="QHBoxLayout" name="horizontalLayout_5">
<item>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
@ -114,14 +114,39 @@
</widget>
</item>
<item>
<widget class="QLineEdit" name="lePassword">
<property name="text">
<string/>
<layout class="QHBoxLayout" name="horizontalLayout_4">
<property name="spacing">
<number>2</number>
</property>
<property name="echoMode">
<enum>QLineEdit::Password</enum>
</property>
</widget>
<item>
<widget class="QLineEdit" name="lePassword">
<property name="text">
<string/>
</property>
<property name="echoMode">
<enum>QLineEdit::Password</enum>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="toolButton_2">
<property name="focusPolicy">
<enum>Qt::ClickFocus</enum>
</property>
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="lrdatabrowser.qrc">
<normaloff>:/databrowser/images/closed_eye.png</normaloff>
<normalon>:/databrowser/images/eye.png</normalon>:/databrowser/images/closed_eye.png</iconset>
</property>
<property name="checkable">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_3">
@ -137,6 +162,9 @@
</item>
<item>
<widget class="QToolButton" name="toolButton">
<property name="focusPolicy">
<enum>Qt::ClickFocus</enum>
</property>
<property name="text">
<string>...</string>
</property>
@ -158,7 +186,7 @@
<item>
<widget class="QCheckBox" name="cbbKeepCredentials">
<property name="text">
<string>Dont keep credentals in lrxml</string>
<string>Don't keep credentials in lrxml</string>
</property>
</widget>
</item>
@ -221,8 +249,24 @@
</item>
</layout>
</widget>
<tabstops>
<tabstop>leConnectionName</tabstop>
<tabstop>cbbUseDefaultConnection</tabstop>
<tabstop>cbbDrivers</tabstop>
<tabstop>leServerName</tabstop>
<tabstop>lePort</tabstop>
<tabstop>leUserName</tabstop>
<tabstop>lePassword</tabstop>
<tabstop>leDataBase</tabstop>
<tabstop>cbAutoConnect</tabstop>
<tabstop>cbbKeepCredentials</tabstop>
<tabstop>pbCheckConnection</tabstop>
<tabstop>pbCancel</tabstop>
<tabstop>pbOk</tabstop>
</tabstops>
<resources>
<include location="lrdatabrowser.qrc"/>
<include location="lrdatabrowser.qrc"/>
</resources>
<connections>
<connection>

View File

@ -677,7 +677,7 @@ SQLEditResult::ResultMode DataBrowser::currentDatasourceType(const QString& data
void DataBrowser::applyChanges(SQLEditResult result)
{
if (result.resultMode == currentDatasourceType(result.datasourceName)){
if (result.resultMode == currentDatasourceType(result.oldDatasourceName)){
switch(result.resultMode){
case SQLEditResult::Query:
changeQuery(result);
@ -694,7 +694,7 @@ void DataBrowser::applyChanges(SQLEditResult result)
default: break;
}
} else {
removeDatasource(result.datasourceName);
removeDatasource(result.oldDatasourceName);
addDatasource(result);
}
activateItem(result.datasourceName, DataBrowserTree::Table);

View File

@ -44,5 +44,7 @@
<file alias="/images/value_edit">images/value_edit2.png</file>
<file alias="/images/value">images/value1.png</file>
<file alias="/images/varToReport">images/varToReport.png</file>
<file>images/eye.png</file>
<file>images/closed_eye.png</file>
</qresource>
</RCC>

View File

@ -28,6 +28,8 @@ void HorizontalBarChart::paintChart(QPainter *painter, QRectF chartRect)
void HorizontalBarChart::paintHorizontalBars(QPainter *painter, QRectF barsRect)
{
if (seriesCount() == 0) return;
painter->save();
painter->setRenderHint(QPainter::Antialiasing,false);
int delta = int(maxValue()-minValue());

View File

@ -65,6 +65,8 @@ void LinesChart::drawDesignMode(QPainter* painter, qreal hStep, qreal vStep, qre
void LinesChart::paintSerialLines(QPainter* painter, QRectF barsRect)
{
if (valuesCount() == 0) return;
painter->save();
painter->setRenderHint(QPainter::Antialiasing,true);
int delta = int(maxValue() - minValue());

View File

@ -70,7 +70,7 @@ void PieChart::paintChart(QPainter *painter, QRectF chartRect)
drawPercent(painter, chartRect, currentDegree, sectorDegree);
currentDegree += sectorDegree;
}
} else {
} else if (m_chartItem->itemMode() == DesignMode){
painter->setBrush(color_map[0]);
painter->drawPie(chartRect,0,260*16);
drawPercent(painter, chartRect, 0, 260);
@ -122,7 +122,7 @@ void PieChart::paintChartLegend(QPainter *painter, QRectF legendRect)
);
cw += painter->fontMetrics().height();
}
} else {
} else if (m_chartItem->itemMode() == DesignMode){
qreal cw = 0;
for (int i=0;i<m_designLabels.size();++i){
QString label = m_designLabels.at(i);

View File

@ -47,6 +47,8 @@ void VerticalBarChart::paintChart(QPainter *painter, QRectF chartRect)
void VerticalBarChart::paintVerticalBars(QPainter *painter, QRectF barsRect)
{
if (valuesCount() == 0) return;
int delta = int(maxValue() - minValue());
delta = genNextValue(delta);
@ -64,6 +66,8 @@ void VerticalBarChart::paintVerticalBars(QPainter *painter, QRectF barsRect)
qreal hStep = (barsRect.width() / valuesCount()) / (barSeriesCount == 0 ? 1 : barSeriesCount);
qreal topShift = (delta - (maxValue() - minValue())) * vStep + barsRect.top();
qDebug() << "vStep" << vStep << "hStep" << hStep;
if (!m_chartItem->series().isEmpty() && (m_chartItem->itemMode() != DesignMode)){
int curSeries = 0;
foreach (SeriesItem* series, m_chartItem->series()) {
@ -93,6 +97,8 @@ void VerticalBarChart::paintVerticalBars(QPainter *painter, QRectF barsRect)
void VerticalBarChart::paintSerialLines(QPainter* painter, QRectF barsRect)
{
if (valuesCount() == 0 ) return;
painter->save();
painter->setRenderHint(QPainter::Antialiasing,true);
int delta = int(maxValue() - minValue());

View File

@ -160,7 +160,10 @@ QString AlignmentItemEditor::displayValue() const
void AlignmentItemEditor::setPropertyValue(QVariant value)
{
ObjectPropItem::setPropertyValue(extractAcceptableValue(value.toInt())[0]);
QVector<int> _accpepttableValueList= extractAcceptableValue(value.toInt());
if(_accpepttableValueList.isEmpty()) return;
ObjectPropItem::setPropertyValue(_accpepttableValueList[0]);
}
}

View File

@ -333,6 +333,13 @@ bool BarcodeItem::isEmpty() const
return m_content.isEmpty();
}
void BarcodeItem::expandContent(QString data, DataSourceManager* dataManager, RenderPass pass)
{
setContent(expandUserVariables(data, pass, NoEscapeSymbols, dataManager));
setContent(expandScripts(content(), dataManager));
setContent(expandDataFields(content(), NoEscapeSymbols, dataManager));
}
void BarcodeItem::updateItemSize(DataSourceManager* dataManager, RenderPass pass, int maxHeight)
{
if (content().isEmpty())
@ -346,21 +353,19 @@ void BarcodeItem::updateItemSize(DataSourceManager* dataManager, RenderPass pass
if (data.isValid())
{
switch(pass)
{
case FirstPass:
setContent(expandUserVariables(data.toString(),pass,NoEscapeSymbols, dataManager));
setContent(expandDataFields(data.toString(), NoEscapeSymbols, dataManager));
break;
default:;
}
{
case FirstPass:
expandContent(data.toString(), dataManager, pass);
break;
default:;
}
}
}
}
} else {
switch(pass){
case FirstPass:
setContent(expandUserVariables(content(),pass,NoEscapeSymbols, dataManager));
setContent(expandDataFields(content(), NoEscapeSymbols, dataManager));
expandContent(content(), dataManager, pass);
break;
default:;
}

View File

@ -191,20 +191,19 @@ public:
void setSecurityLevel(int securityLevel);
int pdf417CodeWords() const;
void setPdf417CodeWords(int pdf417CodeWords);
InputMode inputMode() const;
void setInputMode(const InputMode &inputMode);
bool hideText() const;
void setHideText(bool hideText);
int option3() const;
void setOption3(int option3);
bool hideIfEmpty() const;
void setHideIfEmpty(bool hideIfEmpty);
bool isEmpty() const;
private:
void expandContent(QString data, DataSourceManager *dataManager, RenderPass pass);
private:
QString m_content;
QString m_datasource;

View File

@ -584,7 +584,10 @@ QSizeF AbstractSeriesChart::calcChartLegendSize(const QFont &font)
return QSizeF(maxWidth+fm.height()*2,cw);
}
bool AbstractSeriesChart::verticalLabels(QPainter* painter, QRectF labelsRect){
bool AbstractSeriesChart::verticalLabels(QPainter* painter, QRectF labelsRect)
{
if (valuesCount() == 0) return false;
qreal hStep = (labelsRect.width() / valuesCount());
QFontMetrics fm = painter->fontMetrics();
foreach(QString label, m_chartItem->labels()){
@ -597,6 +600,8 @@ bool AbstractSeriesChart::verticalLabels(QPainter* painter, QRectF labelsRect){
void AbstractSeriesChart::paintHorizontalLabels(QPainter *painter, QRectF labelsRect)
{
if (valuesCount() == 0) return;
painter->save();
qreal hStep = (labelsRect.width() / valuesCount());
if (!m_chartItem->labels().isEmpty()){
@ -623,6 +628,8 @@ void AbstractSeriesChart::paintHorizontalLabels(QPainter *painter, QRectF labels
void AbstractSeriesChart::paintVerticalLabels(QPainter *painter, QRectF labelsRect)
{
if (valuesCount() == 0) return;
painter->save();
painter->setFont(adaptLabelsFont(labelsRect.adjusted(0, 0, -hPadding(m_chartItem->rect()), 0),
painter->font()));
@ -771,7 +778,7 @@ void AbstractBarChart::paintChartLegend(QPainter *painter, QRectF legendRect)
);
cw += painter->fontMetrics().height();
}
} else {
} else if (m_chartItem->itemMode() == DesignMode){
qreal cw = 0;
for (int i=0;i<m_designLabels.size();++i){
QString label = m_designLabels.at(i);

View File

@ -116,20 +116,14 @@ BaseDesignIntf* VerticalLayout::cloneBottomPart(int height, QObject* owner, QGra
bottomPart->initFromItem(this);
foreach(BaseDesignIntf* item,childBaseItems()){
if ((item->geometry().top() < height) && ( item->geometry().bottom() > height )){
if (item->geometry().bottom() > height){
int sliceHeight = height - item->geometry().top();
if (item->canBeSplitted(sliceHeight)){
if ((item->geometry().top() < height) && (item->canBeSplitted(sliceHeight))){
BaseDesignIntf* tmpItem = item->cloneBottomPart(sliceHeight, bottomPart, bottomPart);
tmpItem->setPos(tmpItem->pos().x(),0);
tmpItem->setHeight(sliceHeight);
bottomPart->addChild(tmpItem);
} else {
item->cloneItem(item->itemMode(), bottomPart, bottomPart);
item->setPos(item->pos().x(), 0);
}
} else {
if (item->geometry().top() >= height){
BaseDesignIntf* tmpItem = item->cloneItem(item->itemMode(), bottomPart, bottomPart);
tmpItem->setPos(item->pos().x(), item->pos().y() - height);
bottomPart->addChild(item->cloneItem(item->itemMode(), bottomPart, bottomPart));
}
}
}

View File

@ -47,28 +47,28 @@ include(limereport.pri)
unix:{
DESTDIR = $${DEST_LIBS}
linux{
QMAKE_POST_LINK += mkdir -p $$quote($${DEST_INCLUDE_DIR}) $$escape_expand(\\n\\t) # qmake need make mkdir -p on subdirs more than root/
QMAKE_POST_LINK += mkdir -p \"$${DEST_INCLUDE_DIR}\" $$escape_expand(\\n\\t) # qmake need make mkdir -p on subdirs more than root/
for(FILE,EXTRA_FILES){
QMAKE_POST_LINK += $$QMAKE_COPY $$quote($$FILE) $$quote($${DEST_INCLUDE_DIR}) $$escape_expand(\\n\\t) # inside of libs make /include/files
QMAKE_POST_LINK += $$QMAKE_COPY \"$$FILE\" \"$${DEST_INCLUDE_DIR}\" $$escape_expand(\\n\\t) # inside of libs make /include/files
}
}
macx{
for(FILE,EXTRA_FILES){
QMAKE_POST_LINK += $$QMAKE_COPY $$quote($$FILE) $$quote($${DEST_INCLUDE_DIR}) $$escape_expand(\\n\\t)
QMAKE_POST_LINK += $$QMAKE_COPY \"$$FILE\" \"$${DEST_INCLUDE_DIR}\" $$escape_expand(\\n\\t)
}
QMAKE_POST_LINK += mkdir -p $$quote($${DESTDIR}/include) $$escape_expand(\\n\\t)
QMAKE_POST_LINK += mkdir -p \"$${DESTDIR}/include\" $$escape_expand(\\n\\t)
}
QMAKE_POST_LINK += $$QMAKE_COPY_DIR $$quote($${DEST_INCLUDE_DIR}) $$quote($${DESTDIR})
QMAKE_POST_LINK += $$QMAKE_COPY_DIR \"$${DEST_INCLUDE_DIR}\" \"$${DESTDIR}\"
}
win32 {
DESTDIR = $${DEST_LIBS}
contains(QMAKE_HOST.os, Linux){
QMAKE_POST_LINK += mkdir -p $$quote($${DEST_INCLUDE_DIR}) $$escape_expand(\\n\\t) # qmake need make mkdir -p on subdirs more than root/
QMAKE_POST_LINK += mkdir -p \"$${DEST_INCLUDE_DIR}\" $$escape_expand(\\n\\t) # qmake need make mkdir -p on subdirs more than root/
for(FILE,EXTRA_FILES){
QMAKE_POST_LINK += $$QMAKE_COPY $$quote($$FILE) $$quote($${DEST_INCLUDE_DIR}) $$escape_expand(\\n\\t) # inside of libs make /include/files
QMAKE_POST_LINK += $$QMAKE_COPY \"$$FILE\" \"$${DEST_INCLUDE_DIR}\" $$escape_expand(\\n\\t) # inside of libs make /include/files
}
QMAKE_POST_LINK += $$QMAKE_COPY_DIR $$quote($${DEST_INCLUDE_DIR}) $$quote($${DESTDIR})
QMAKE_POST_LINK += $$QMAKE_COPY_DIR \"$${DEST_INCLUDE_DIR}\" \"$${DESTDIR}\"
} else {
EXTRA_FILES ~= s,/,\\,g
BUILD_DIR ~= s,/,\\,g
@ -121,20 +121,13 @@ contains(CONFIG,build_translations){
TRANSLATIONS = $$prependAll(LANGUAGES, \"$$TRANSLATIONS_PATH/limereport_,.ts\")
qtPrepareTool(LUPDATE, lupdate)
greaterThan(QT_MAJOR_VERSION, 4) {
ts.commands = $$LUPDATE $$shell_quote($$PWD) -noobsolete -ts $$TRANSLATIONS
}
lessThan(QT_MAJOR_VERSION, 5){
ts.commands = $$LUPDATE $$quote($$PWD) -noobsolete -ts $$TRANSLATIONS
}
ts.commands = $$LUPDATE \"$$PWD\" -noobsolete -ts $$TRANSLATIONS
TRANSLATIONS_FILES =
qtPrepareTool(LRELEASE, lrelease)
for(tsfile, TRANSLATIONS) {
qmfile = $$tsfile
qmfile ~= s,".ts\"$",".qm\"",
qm.commands += $$LRELEASE -removeidentical $$tsfile -qm $$qmfile $$escape_expand(\\n\\t)
tmp_command = $$LRELEASE -removeidentical $$tsfile -qm $$qmfile $$escape_expand(\\n\\t)
TRANSLATIONS_FILES += $$qmfile
}
qm.depends = ts

View File

@ -273,6 +273,12 @@ void BandDesignIntf::setPpm(int ppm)
updateBandMarkerGeometry(QRectF(pos(),size()));
}
void BandDesignIntf::copyBandAttributes(BandDesignIntf *source)
{
this->copyBookmarks(source);
this->setBackgroundColor(source->backgroundColor());
}
void BandDesignIntf::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget)
{
prepareRect(painter, option, widget);
@ -776,6 +782,11 @@ void BandDesignIntf::emitBandRendered(BandDesignIntf* band)
emit bandRendered(band);
}
void BandDesignIntf::emitBandReRendered(BandDesignIntf *oldBand, BandDesignIntf *newBand)
{
emit bandReRendered(oldBand, newBand);
}
void BandDesignIntf::setSplittable(bool value){
if (m_splitable!=value){
bool oldValue = m_splitable;

View File

@ -219,6 +219,7 @@ public:
void parentObjectLoadFinished();
void finishLoading();
void emitBandRendered(BandDesignIntf *band);
void emitBandReRendered(BandDesignIntf* oldBand, BandDesignIntf* newBand);
bool isSplittable() const {return m_splitable;}
void setSplittable(bool value);
@ -255,6 +256,7 @@ public:
bool startFromNewPage() const;
void setStartFromNewPage(bool startFromNewPage);
bool canContainChildren() const{ return true;}
bool canAcceptPaste() const{ return true;}
bool printAlways() const;
void setPrintAlways(bool printAlways);
bool repeatOnEachRow() const;
@ -281,8 +283,10 @@ public:
void setPaddingBottom(int paddingBottom);
QRectF boundingRect() const;
void copyBandAttributes(BandDesignIntf* source);
signals:
void bandRendered(BandDesignIntf* band);
void bandReRendered(BandDesignIntf* oldBand, BandDesignIntf* newBand);
void preparedForRender();
void bandRegistred();
protected:

View File

@ -87,6 +87,8 @@ BaseDesignIntf::BaseDesignIntf(const QString &storageTypeName, QObject *owner, Q
m_itemGeometryLocked(false),
m_isChangingPos(false),
m_ppm(Const::STORAGE_MM_FACTOR)
m_isMoveable(false)
{
setGeometry(QRectF(0, 0, m_width, m_height));
if (BaseDesignIntf *item = dynamic_cast<BaseDesignIntf *>(parent)) {
@ -390,6 +392,10 @@ void BaseDesignIntf::setFixedPos(bool fixedPos)
m_fixedPos = fixedPos;
}
void BaseDesignIntf::onChangeGeometryTimeOut(){
m_isMoveable = true;
}
void BaseDesignIntf::mousePressEvent(QGraphicsSceneMouseEvent *event)
{
if (event->button() == Qt::LeftButton) {
@ -398,7 +404,9 @@ void BaseDesignIntf::mousePressEvent(QGraphicsSceneMouseEvent *event)
m_startPos = pos();
m_oldGeometry = geometry();
QGraphicsItem::mousePressEvent(event);
emit(itemSelected(this));
emit itemSelected(this);
m_isMoveable = false;
QTimer::singleShot(200, this, SLOT(onChangeGeometryTimeOut()));
}
else QGraphicsItem::mousePressEvent(event);
}
@ -527,6 +535,7 @@ void BaseDesignIntf::hoverEnterEvent(QGraphicsSceneHoverEvent* /*event*/)
void BaseDesignIntf::mouseMoveEvent(QGraphicsSceneMouseEvent *event)
{
if (!m_isMoveable) return;
if (!isSelected()){
QGraphicsItem::mouseMoveEvent(event);
return;

View File

@ -324,6 +324,7 @@ public:
void setBorderColor(const QColor &borderColor);
void setItemVisible(const bool& value);
virtual bool canContainChildren() const { return false;}
virtual bool canAcceptPaste() const{ return false;}
ReportSettings* reportSettings() const;
void setReportSettings(ReportSettings *reportSettings);
void setZValueProperty(qreal value);
@ -338,6 +339,15 @@ public:
virtual void setWatermark(bool watermark);
void updateSelectionMarker();
void turnOnSelectionMarker(bool value);
bool fillTransparentInDesignMode() const;
void setFillTransparentInDesignMode(bool fillTransparentInDesignMode);
void emitPosChanged(QPointF oldPos, QPointF newPos);
void emitObjectNamePropertyChanged(const QString& oldName, const QString& newName);
bool isGeometryLocked() const;
void setGeometryLocked(bool itemLocked);
bool isChangingPos() const;
void setIsChangingPos(bool isChangingPos);
Q_INVOKABLE QString setItemWidth(qreal width);
Q_INVOKABLE QString setItemHeight(qreal height);
Q_INVOKABLE qreal getItemWidth();
@ -434,6 +444,10 @@ private:
void moveSelectedItems(QPointF delta);
Qt::CursorShape getPossibleCursor(int cursorFlags);
void updatePossibleDirectionFlags();
private slots:
void onChangeGeometryTimeOut();
private:
QPointF m_startPos;
int m_resizeHandleSize;
@ -495,19 +509,21 @@ private:
bool m_itemGeometryLocked;
bool m_isChangingPos;
int m_ppm;
bool m_isMoveable;
signals:
void geometryChanged(QObject* object, QRectF newGeometry, QRectF oldGeometry);
void posChanging(QObject* object, QPointF newPos, QPointF oldPos);
void posChanged(QObject* object, QPointF newPos, QPointF oldPos);
void itemSelected(LimeReport::BaseDesignIntf *item);
void itemSelectedHasBeenChanged(BaseDesignIntf *item, bool value);
void itemSelectedHasBeenChanged(LimeReport::BaseDesignIntf *item, bool value);
void loadCollectionFinished(const QString& collectionName);
void objectLoaded(QObject* object);
void objectChanged(QObject* object);
void propertyChanged(const QString& propertName, const QVariant& oldValue,const QVariant& newValue);
void propertyObjectNameChanged(const QString& oldValue, const QString& newValue);
void propertyesChanged(QVector<QString> propertyNames);
void itemAlignChanged(BaseDesignIntf* item, const ItemAlign& oldValue, const ItemAlign& newValue);
void itemAlignChanged(BaseDesignIntf* item, const BaseDesignIntf::ItemAlign& oldValue, const BaseDesignIntf::ItemAlign& newValue);
void itemVisibleHasChanged(BaseDesignIntf* item);
void beforeRender();
void afterData();

View File

@ -336,13 +336,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_port(-1), m_autoconnect(false),
m_databaseName(db.databaseName()), m_user(db.userName()), m_password(db.password()), m_port(""), 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_port(-1), m_autoconnect(false),
m_databaseName(""), m_user(""), m_password(""), m_port(""), m_autoconnect(false),
m_internal(false), m_keepDBCredentials(true)
{}
@ -377,12 +377,12 @@ QString ConnectionDesc::connectionNameForReport(const QString &connectionName)
return connectionName.compare(tr("defaultConnection")) == 0 ? QSqlDatabase::defaultConnection : connectionName;
}
int ConnectionDesc::port() const
QString ConnectionDesc::port() const
{
return m_port;
}
void ConnectionDesc::setPort(int port)
void ConnectionDesc::setPort(QString port)
{
m_port = port;
}

View File

@ -78,7 +78,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)
Q_PROPERTY(QString port READ port WRITE setPort)
public:
typedef QSharedPointer<ConnectionDesc> Ptr;
ConnectionDesc(QSqlDatabase db, QObject* parent=0);
@ -103,8 +103,8 @@ public:
void setInternal(bool value) {m_internal = value;}
bool keepDBCredentials() const;
void setKeepDBCredentials(bool keepDBCredentials);
int port() const;
void setPort(int port);
QString port() const;
void setPort(QString port);
public:
static QString connectionNameForUser(const QString& connectionName);
static QString connectionNameForReport(const QString& connectionName);
@ -117,7 +117,7 @@ private:
QString m_databaseName;
QString m_user;
QString m_password;
int m_port;
QString m_port;
bool m_autoconnect;
bool m_internal;
bool m_keepDBCredentials;

View File

@ -675,8 +675,6 @@ CSVDesc *DataSourceManager::csvByName(const QString &datasourceName)
void DataSourceManager::removeDatasource(const QString &name)
{
invalidateLinkedDatasources(name);
if (m_datasources.contains(name)){
IDataSourceHolder *holder;
holder=m_datasources.value(name);
@ -703,6 +701,7 @@ void DataSourceManager::removeDatasource(const QString &name)
delete m_csvs.at(csvIndex);
m_csvs.removeAt(csvIndex);
}
invalidateLinkedDatasources(name);
m_hasChanges = true;
emit datasourcesChanged();
}
@ -808,12 +807,12 @@ bool DataSourceManager::initAndOpenDB(QSqlDatabase& db, ConnectionDesc& connecti
bool connected = false;
db.setHostName(replaceVariables(connectionDesc.host()));
db.setUserName(replaceVariables(connectionDesc.userName()));
db.setPassword(replaceVariables(connectionDesc.password()));
if (connectionDesc.port()!=-1)
db.setPort(connectionDesc.port());
db.setDatabaseName(replaceVariables(connectionDesc.databaseName()));
if (connectionDesc.port()!="")
db.setPort(replaceVariables(connectionDesc.port()).toInt());
if (!connectionDesc.keepDBCredentials() && m_dbCredentialsProvider){
if (!m_dbCredentialsProvider->getUserName(connectionDesc.name()).isEmpty())
@ -1011,14 +1010,15 @@ void DataSourceManager::disconnectConnection(const QString& connectionName)
foreach(QString datasourceName, dataSourceNames()){
if (isQuery(datasourceName) || isSubQuery(datasourceName)){
QueryHolder* qh = dynamic_cast<QueryHolder*>(dataSourceHolder(datasourceName));
if (qh && qh->connectionName().compare(connectionName,Qt::CaseInsensitive)==0){
qh->invalidate(designTime()?IDataSource::DESIGN_MODE:IDataSource::RENDER_MODE);
if (qh && qh->connectionName().compare(connectionName, Qt::CaseInsensitive) == 0){
qh->invalidate(designTime() ? IDataSource::DESIGN_MODE : IDataSource::RENDER_MODE, true);
qh->setLastError(tr("invalid connection"));
}
}
}
ConnectionDesc* connectionDesc = connectionByName(connectionName);
if (connectionDesc->isInternal()){
{
QSqlDatabase db = QSqlDatabase::database(connectionName);
@ -1347,12 +1347,12 @@ void DataSourceManager::invalidateLinkedDatasources(QString datasourceName)
{
foreach(QString name, dataSourceNames()){
if (isSubQuery(name)){
if (subQueryByName(name)->master() == datasourceName)
if (subQueryByName(name)->master().compare(datasourceName) == 0)
dataSourceHolder(name)->invalidate(designTime()?IDataSource::DESIGN_MODE:IDataSource::RENDER_MODE);
}
if (isProxy(name)){
ProxyDesc* proxy = proxyByName(name);
if ((proxy->master() == datasourceName) || (proxy->child() == datasourceName))
if ((proxy->master().compare(datasourceName) == 0) || (proxy->child().compare(datasourceName) == 0))
dataSourceHolder(name)->invalidate(designTime()?IDataSource::DESIGN_MODE:IDataSource::RENDER_MODE);
}
@ -1437,13 +1437,13 @@ void DataSourceManager::clear(ClearMethod method)
case All:
invalidateLinkedDatasources(dit.key());
delete dit.value();
m_datasources.erase(dit++);
dit = m_datasources.erase(dit);
break;
default:
if (owned){
invalidateLinkedDatasources(dit.key());
delete dit.value();
m_datasources.erase(dit++);
dit = m_datasources.erase(dit);
} else {
++dit;
}

View File

@ -97,6 +97,14 @@ void GroupFunction::slotBandRendered(BandDesignIntf *band)
}
}
void GroupFunction::slotBandReRendered(BandDesignIntf *oldBand, BandDesignIntf *newBand)
{
if (m_valuesByBand.contains(oldBand)){
m_valuesByBand.insert(newBand, m_valuesByBand.value(oldBand));
m_valuesByBand.remove(oldBand);
}
}
QVariant GroupFunction::addition(QVariant value1, QVariant value2)
{
return value1.toDouble()+value2.toDouble();

View File

@ -56,6 +56,7 @@ public:
virtual QVariant calculate(PageItemDesignIntf* page = 0)=0;
public slots:
void slotBandRendered(BandDesignIntf* band);
void slotBandReRendered(BandDesignIntf* oldBand, BandDesignIntf* newBand);
protected:
void setName(const QString& value){m_name=value;}
QVariant addition(QVariant value1, QVariant value2);

View File

@ -1,5 +1,6 @@
#include "lritemscontainerdesignitf.h"
#include "lritemdesignintf.h"
#include "lrbanddesignintf.h"
namespace LimeReport {
@ -37,11 +38,15 @@ bool itemSortContainerLessThen(const PItemSortContainer c1, const PItemSortConta
else return c1->m_rect.y()<c2->m_rect.y();
}
void ItemsContainerDesignInft::snapshotItemsLayout()
void ItemsContainerDesignInft::snapshotItemsLayout(SnapshotType type)
{
m_containerItems.clear();
foreach(BaseDesignIntf *childItem,childBaseItems()){
m_containerItems.append(PItemSortContainer(new ItemSortContainer(childItem)));
foreach(BaseDesignIntf *childItem, childBaseItems()){
if (type == IgnoreBands){
if (!dynamic_cast<BandDesignIntf*>(childItem))
m_containerItems.append(PItemSortContainer(new ItemSortContainer(childItem)));
} else
m_containerItems.append(PItemSortContainer(new ItemSortContainer(childItem)));
}
qSort(m_containerItems.begin(),m_containerItems.end(),itemSortContainerLessThen);
}

View File

@ -42,8 +42,9 @@ class ItemsContainerDesignInft : public BookmarkContainerDesignIntf{
public:
ItemsContainerDesignInft(const QString& xmlTypeName, QObject* owner = 0, QGraphicsItem* parent=0):
BookmarkContainerDesignIntf(xmlTypeName, owner, parent){}
enum SnapshotType{Full, IgnoreBands};
protected:
void snapshotItemsLayout();
void snapshotItemsLayout(SnapshotType type = Full);
void arrangeSubItems(RenderPass pass, DataSourceManager *dataManager, ArrangeType type = AsNeeded);
qreal findMaxBottom() const;
qreal findMaxHeight() const;

View File

@ -132,23 +132,6 @@ void PageDesignIntf::updatePageRect()
emit sceneRectChanged(sceneRect());
}
//PageDesignIntf::Orientation PageDesignIntf::getOrientation()
//{
// return m_orientation;
//}
//void PageDesignIntf::setPageSize(PageDesignIntf::PageSize sizeType, QSizeF sizeValue)
//{
// m_pageSize = sizeType;
// m_pageSizeValue = sizeValue;
// updatePageRect();
//}
//PageDesignIntf::PageSize PageDesignIntf::pageSize() const
//{
// return m_pageSize;
//}
void PageDesignIntf::keyPressEvent(QKeyEvent *event)
{
if (event->modifiers() == Qt::NoModifier ||
@ -1385,9 +1368,9 @@ void PageDesignIntf::copy()
}
BaseDesignIntf* PageDesignIntf::findDestObject(BaseDesignIntf* item){
if (item && item->canContainChildren()) return item;
if (item && item->canAcceptPaste()) return item;
BaseDesignIntf * curItem = item;
while (curItem && !curItem->canContainChildren()){
while (curItem && !curItem->canAcceptPaste()){
curItem = dynamic_cast<BaseDesignIntf*>(curItem->parentItem());
}
return curItem;
@ -2150,6 +2133,9 @@ bool PasteCommand::insertItem(ItemsReaderIntf::Ptr reader)
if (page()->reportItemsByName(item->objectName()).size()>1){
item->setObjectName(objectName);
}
foreach (BaseDesignIntf* child, item->childBaseItems()){
changeName(page(), child);
};
m_itemNames.push_back(item->objectName());
}
return true;
@ -2157,6 +2143,14 @@ bool PasteCommand::insertItem(ItemsReaderIntf::Ptr reader)
return false;
}
void PasteCommand::changeName(PageDesignIntf *page, BaseDesignIntf* item)
{
item->setObjectName(page->genObjectName(*item));
foreach(BaseDesignIntf* child, item->childBaseItems()){
changeName(page, child);
};
}
CommandIf::Ptr CutCommand::create(PageDesignIntf *page)
{
CutCommand *command = new CutCommand();

View File

@ -430,6 +430,7 @@ namespace LimeReport {
void setItemsXML(const QString& itemsXML);
void setParent(BaseDesignIntf* parent){m_parentItemName = parent->objectName();}
bool insertItem(ItemsReaderIntf::Ptr reader);
void changeName(PageDesignIntf* page, BaseDesignIntf *item);
private:
QString m_itemsXML;
QString m_parentItemName;

View File

@ -50,8 +50,9 @@ PageItemDesignIntf::PageItemDesignIntf(QObject *owner, QGraphicsItem *parent) :
m_topMargin(0), m_bottomMargin(0), m_leftMargin(0), m_rightMargin(0),
m_pageOrientaion(Portrait), m_pageSize(A4), m_sizeChainging(false),
m_fullPage(false), m_oldPrintMode(false), m_resetPageNumber(false),
m_isExtendedInDesignMode(false), m_extendedHeight(1000), m_isTOC(false), m_setPageSizeToPrinter(false),
m_endlessHeight(false), m_printable(true), m_pageFooter(0), m_printBehavior(Split)
m_isExtendedInDesignMode(false), m_extendedHeight(1000), m_isTOC(false),
m_setPageSizeToPrinter(false), m_endlessHeight(false), m_printable(true),
m_pageFooter(0), m_printBehavior(Split), m_dropPrinterMargins(false)
{
setFixedPos(true);
setPossibleResizeDirectionFlags(Fixed);
@ -64,8 +65,9 @@ PageItemDesignIntf::PageItemDesignIntf(const PageSize pageSize, const QRectF &re
m_topMargin(0), m_bottomMargin(0), m_leftMargin(0), m_rightMargin(0),
m_pageOrientaion(Portrait), m_pageSize(pageSize), m_sizeChainging(false),
m_fullPage(false), m_oldPrintMode(false), m_resetPageNumber(false),
m_isExtendedInDesignMode(false), m_extendedHeight(1000), m_isTOC(false), m_setPageSizeToPrinter(false),
m_endlessHeight(false), m_printable(true), m_pageFooter(0), m_printBehavior(Split)
m_isExtendedInDesignMode(false), m_extendedHeight(1000), m_isTOC(false),
m_setPageSizeToPrinter(false), m_endlessHeight(false), m_printable(true),
m_pageFooter(0), m_printBehavior(Split), m_dropPrinterMargins(false)
{
setFixedPos(true);
setPossibleResizeDirectionFlags(Fixed);
@ -129,7 +131,8 @@ BaseDesignIntf *PageItemDesignIntf::createSameTypeItem(QObject *owner, QGraphics
void PageItemDesignIntf::geometryChangedEvent(QRectF newRect, QRectF)
{
Q_UNUSED(newRect)
updateMarginRect();
if (itemMode() == DesignMode || !endlessHeight())
updateMarginRect();
PageSize oldSize = m_pageSize;
if (!m_sizeChainging && !isLoading())
m_pageSize = Custom;
@ -241,8 +244,7 @@ int PageItemDesignIntf::calcBandIndex(BandDesignIntf::BandsType bandType, BandDe
} else {
int maxChildIndex = 0;
foreach(BandDesignIntf* band, m_bands){
if (band->bandType() == BandDesignIntf::Data)
maxChildIndex = std::max(maxChildIndex, band->maxChildIndex());
maxChildIndex = std::max(maxChildIndex, band->maxChildIndex());
}
bandIndex = std::max(bandIndex, maxChildIndex + 1);
}
@ -345,6 +347,16 @@ void PageItemDesignIntf::initColumnsPos(QVector<qreal> &posByColumns, qreal pos,
}
}
bool PageItemDesignIntf::dropPrinterMargins() const
{
return m_dropPrinterMargins;
}
void PageItemDesignIntf::setDropPrinterMargins(bool dropPrinterMargins)
{
m_dropPrinterMargins = dropPrinterMargins;
}
void PageItemDesignIntf::setPrintBehavior(const PrintBehavior &printBehavior)
{
m_printBehavior = printBehavior;
@ -518,8 +530,10 @@ void PageItemDesignIntf::setResetPageNumber(bool resetPageNumber)
void PageItemDesignIntf::updateSubItemsSize(RenderPass pass, DataSourceManager *dataManager)
{
snapshotItemsLayout();
arrangeSubItems(pass, dataManager);
if (!endlessHeight()){
snapshotItemsLayout(IgnoreBands);
arrangeSubItems(pass, dataManager);
}
}
bool PageItemDesignIntf::oldPrintMode() const

View File

@ -61,6 +61,7 @@ class PageItemDesignIntf : public ItemsContainerDesignInft
Q_PROPERTY(QString printerName READ printerName WRITE setPrinterName)
Q_PROPERTY(UnitType units READ unitType WRITE setUnitTypeProperty)
Q_PROPERTY(PrintBehavior printBehavior READ printBehavior WRITE setPrintBehavior)
Q_PROPERTY(bool dropPrinterMargins READ dropPrinterMargins WRITE setDropPrinterMargins)
friend class ReportRender;
public:
enum Orientation { Portrait = QPrinter::Portrait, Landscape = QPrinter::Landscape };
@ -143,6 +144,7 @@ public:
bool oldPrintMode() const;
void setOldPrintMode(bool oldPrintMode);
bool canContainChildren() const{ return true;}
bool canAcceptPaste() const{ return true;}
bool resetPageNumber() const;
void setResetPageNumber(bool resetPageNumber);
void updateSubItemsSize(RenderPass pass, DataSourceManager *dataManager);
@ -181,6 +183,10 @@ public:
QRectF transformFromStorageToScenePpm(const QRectF& rect);
void zoomIn();
void zoomOut();
bool dropPrinterMargins() const;
void setDropPrinterMargins(bool dropPrinterMargins);
signals:
void beforeFirstPageRendered();
void afterLastPageRendered();
@ -225,6 +231,7 @@ private:
QString m_printerName;
BandDesignIntf* m_pageFooter;
PrintBehavior m_printBehavior;
bool m_dropPrinterMargins;
};

View File

@ -60,6 +60,7 @@ void PreparedPages::clear()
bool PreparedPages::readPages(ItemsReaderIntf::Ptr reader)
{
clear();
if (reader->first()){
PageItemDesignIntf::Ptr page = PageItemDesignIntf::create(0);
if (!reader->readItem(page.data()))

View File

@ -135,6 +135,7 @@ ReportDesignWindow::ReportDesignWindow(ReportEnginePrivateInterface* report, QWi
m_hideLeftPanel->setChecked(isDockAreaVisible(Qt::LeftDockWidgetArea));
m_hideRightPanel->setChecked(isDockAreaVisible(Qt::RightDockWidgetArea));
createProgressBar();
m_deletePageAction->setEnabled(report->pageCount()>1);
}
ReportDesignWindow::~ReportDesignWindow()
@ -1126,6 +1127,7 @@ void ReportDesignWindow::slotSaveReport()
QString filename = m_reportDesignWidget->reportFileName();
m_lblReportName->setText(filename);
if(!filename.isEmpty()) addRecentFile(filename);
setWindowTitle(m_reportDesignWidget->report()->reportName() + " - Lime Report Designer");
}
void ReportDesignWindow::slotSaveReportAs()
@ -1137,6 +1139,7 @@ void ReportDesignWindow::slotSaveReportAs()
m_reportDesignWidget->saveToFile(fileName);
m_lblReportName->setText(m_reportDesignWidget->reportFileName());
addRecentFile(fileName);
setWindowTitle(m_reportDesignWidget->report()->reportName() + " - Lime Report Designer");
}
}

View File

@ -206,7 +206,7 @@ void ReportEnginePrivate::collectionLoadFinished(const QString &)
page->setReportSettings(&m_reportSettings);
page->setSceneRect(-Const::SCENE_MARGIN,-Const::SCENE_MARGIN,
page->pageItem()->width()+Const::SCENE_MARGIN*2,
page->pageItem()->height()+Const::SCENE_MARGIN*2);
page->pageItem()->boundingRect().height()+Const::SCENE_MARGIN*2);
}
emit pagesLoadFinished();
}
@ -878,6 +878,7 @@ bool ReportEnginePrivate::saveToFile(const QString &fileName)
}
}
dropChanges();
this->setReportName(fi.baseName());
return saved;
}
@ -1801,9 +1802,6 @@ bool PrintProcessor::printPage(PageItemDesignIntf::Ptr page)
if (!m_firstPage && !m_painter->isActive()) return false;
PageDesignIntf* backupPage = dynamic_cast<PageDesignIntf*>(page->scene());
//LimeReport::PageDesignIntf m_renderPage;
//m_renderPage.setItemMode(PrintMode);
QPointF backupPagePos = page->pos();
page->setPos(0,0);
int currentPpm = page->ppm();
@ -1852,7 +1850,14 @@ bool PrintProcessor::printPage(PageItemDesignIntf::Ptr page)
}
} else {
m_renderPage.render(m_painter);
if (page->getSetPageSizeToPrinter()){
QRectF source = page->geometry();
QSizeF inchSize = source.size() / (100 * 2.54);
QRectF target = QRectF(QPoint(0,0), inchSize * m_printer->resolution());
m_renderPage.render(m_painter, target, source);
} else {
m_renderPage.render(m_painter);
}
}
page->setPos(backupPagePos);
page->setPpm(currentPpm);
@ -1876,13 +1881,15 @@ void PrintProcessor::initPrinter(PageItemDesignIntf* page)
m_printer->setPaperSize(pageSize,QPrinter::Millimeter);
} else {
m_printer->setFullPage(page->fullPage());
if (page->dropPrinterMargins())
m_printer->setPageMargins(0, 0, 0, 0, QPrinter::Point);
m_printer->setOrientation(static_cast<QPrinter::Orientation>(page->pageOrientation()));
if (page->pageSize()==PageItemDesignIntf::Custom){
QSizeF pageSize = (page->pageOrientation()==PageItemDesignIntf::Landscape)?
QSizeF(page->sizeMM().height(),page->sizeMM().width()):
page->sizeMM();
if (page->getSetPageSizeToPrinter() || m_printer->outputFormat() == QPrinter::PdfFormat)
m_printer->setPaperSize(pageSize,QPrinter::Millimeter);
m_printer->setPaperSize(pageSize, QPrinter::Millimeter);
} else {
if (page->getSetPageSizeToPrinter() || m_printer->outputFormat() == QPrinter::PdfFormat)
m_printer->setPaperSize(static_cast<QPrinter::PageSize>(page->pageSize()));

View File

@ -386,7 +386,10 @@ void ReportRender::extractGroupFuntionsFromItem(ContentItemDesignIntf* contentIt
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*)));
connect(dataBand, SIGNAL(bandRendered(BandDesignIntf*)),
gf, SLOT(slotBandRendered(BandDesignIntf*)));
connect(dataBand, SIGNAL(bandReRendered(BandDesignIntf*, BandDesignIntf*)),
gf, SLOT(slotBandReRendered(BandDesignIntf*, BandDesignIntf*)));
}
} else {
GroupFunction* gf = datasources()->addGroupFunction(functionName,captures.at(Const::VALUE_INDEX),band->objectName(),captures.at(dsIndex));
@ -463,6 +466,15 @@ void ReportRender::replaceGroupsFunction(BandDesignIntf *band)
replaceGroupFunctionsInContainer(band, band);
}
QColor ReportRender::makeBackgroundColor(BandDesignIntf* band){
if (band->useAlternateBackgroundColor()){
return datasources()->variable(QLatin1String("line_") + band->objectName().toLower()).toInt() %2 == 0 ?
band->backgroundColor() :
band->alternateBackgroundColor();
}
return band->backgroundColor();
}
BandDesignIntf* ReportRender::renderBand(BandDesignIntf *patternBand, BandDesignIntf* bandData, ReportRender::DataRenderMode mode, bool isLast)
{
QCoreApplication::processEvents();
@ -490,18 +502,9 @@ BandDesignIntf* ReportRender::renderBand(BandDesignIntf *patternBand, BandDesign
if (patternBand->isFooter())
m_lastRenderedFooter = patternBand;
if (bandClone->useAlternateBackgroundColor()){
bandClone->setBackgroundColor(
(datasources()->variable(QLatin1String("line_")+patternBand->objectName().toLower()).toInt() %2 == 0 ?
bandClone->backgroundColor() :
bandClone->alternateBackgroundColor()
)
);
}
bandClone->setBackgroundColor(makeBackgroundColor(patternBand));
patternBand->emitBandRendered(bandClone);
m_scriptEngineContext->setCurrentBand(bandClone);
emit(patternBand->afterRender());
if ( isLast && bandClone->keepFooterTogether() && bandClone->sliceLastRow() ){
if (m_maxHeightByColumn[m_currentColumn] < (bandClone->height()+m_reportFooterHeight))
@ -545,8 +548,9 @@ BandDesignIntf* ReportRender::renderBand(BandDesignIntf *patternBand, BandDesign
savePage();
startNewPage();
if (!bandIsSliced){
BandDesignIntf* t = renderData(patternBand);
t->copyBookmarks(bandClone);
BandDesignIntf* t = renderData(patternBand, false);
t->copyBandAttributes(bandClone);
patternBand->emitBandReRendered(bandClone, t);
delete bandClone;
bandClone = t;
}
@ -554,6 +558,7 @@ BandDesignIntf* ReportRender::renderBand(BandDesignIntf *patternBand, BandDesign
if (!registerBand(bandClone)) {
BandDesignIntf* upperPart = dynamic_cast<BandDesignIntf*>(bandClone->cloneUpperPart(m_maxHeightByColumn[m_currentColumn]));
registerBand(upperPart);
patternBand->emitBandReRendered(bandClone, upperPart);
delete bandClone;
bandClone = NULL;
};
@ -571,6 +576,7 @@ BandDesignIntf* ReportRender::renderBand(BandDesignIntf *patternBand, BandDesign
if (patternBand->isFooter())
datasources()->clearGroupFunctionValues(patternBand->objectName());
emit(patternBand->afterRender());
return bandClone;
}
return 0;
@ -832,7 +838,7 @@ void ReportRender::recalcIfNeeded(BandDesignIntf* band){
void ReportRender::renderDataHeader(BandDesignIntf *header)
{
recalcIfNeeded(header);
BandDesignIntf* renderedHeader = renderBand(header, 0);
BandDesignIntf* renderedHeader = renderBand(header, 0, StartNewPageAsNeeded);
if (containsGroupFunctions(header))
m_recalcBands.append(renderedHeader);
}
@ -1253,13 +1259,14 @@ BandDesignIntf *ReportRender::saveUppperPartReturnBottom(BandDesignIntf *band, i
return bottomBandPart;
}
BandDesignIntf *ReportRender::renderData(BandDesignIntf *patternBand)
BandDesignIntf *ReportRender::renderData(BandDesignIntf *patternBand, bool emitBeforeRender)
{
BandDesignIntf* bandClone = dynamic_cast<BandDesignIntf*>(patternBand->cloneItem(PreviewMode));
m_scriptEngineContext->baseDesignIntfToScript(patternBand->parent()->objectName(), bandClone);
m_scriptEngineContext->setCurrentBand(bandClone);
emit(patternBand->beforeRender());
if (emitBeforeRender)
emit(patternBand->beforeRender());
if (patternBand->isFooter()){
replaceGroupsFunction(bandClone);

View File

@ -169,12 +169,10 @@ private:
BandDesignIntf *sliceBand(BandDesignIntf* band, BandDesignIntf *patternBand, bool isLast);
BandDesignIntf* saveUppperPartReturnBottom(BandDesignIntf *band, int height, BandDesignIntf *patternBand);
BandDesignIntf* renderData(BandDesignIntf* patternBand);
BandDesignIntf* renderData(BandDesignIntf* patternBand, bool emitBeforeRender = true);
void startNewColumn();
void startNewPage(bool isFirst = false);
void resetPageNumber(ResetPageNuberType resetType);
//int findLastPageNumber(int currentPage);
//int findPageNumber(int currentPage);
void savePage(bool isLast = false);
QString toString();
void initColumns();
@ -187,8 +185,8 @@ private:
void renameChildItems(BaseDesignIntf *item);
void renderGroupFooterByHeader(BandDesignIntf *groupHeader);
void updateTOC(BaseDesignIntf* item, int pageNumber);
//PagesRange& currentRange(bool isTOC = false){ return (isTOC) ? m_ranges.first(): m_ranges.last();}
void placeBandOnPage(BandDesignIntf *band, int columnIndex);
QColor makeBackgroundColor(BandDesignIntf *band);
private:
DataSourceManager* m_datasources;
ScriptEngineContext* m_scriptEngineContext;
@ -223,7 +221,6 @@ private:
bool m_newPageStarted;
bool m_lostHeadersMoved;
};
} // namespace LimeReport
#endif // LRREPORTRENDER_H

View File

@ -1937,7 +1937,10 @@ bool DatasourceFunctions::invalidate(const QString& datasourceName)
QObject* DatasourceFunctions::createTableBuilder(QObject* horizontalLayout)
{
return new TableBuilder(dynamic_cast<LimeReport::HorizontalLayout*>(horizontalLayout), dynamic_cast<DataSourceManager*>(m_dataManager));
LimeReport::HorizontalLayout* l = dynamic_cast<LimeReport::HorizontalLayout*>(horizontalLayout);
if (l)
return new TableBuilder(l, m_dataManager);
return 0;
}
TableBuilder::TableBuilder(HorizontalLayout* layout, DataSourceManager* dataManager)
@ -1987,16 +1990,19 @@ void TableBuilder::fillInRowData(QObject* row)
void TableBuilder::buildTable(const QString& datasourceName)
{
checkBaseLayout();
m_dataManager->dataSourceHolder(datasourceName)->invalidate(IDataSource::RENDER_MODE);
IDataSource* ds = m_dataManager->dataSource(datasourceName);
if (ds){
bool firstTime = true;
QObject* row = m_horizontalLayout;
while(!ds->eof()){
if (!firstTime) row = addRow();
else firstTime = false;
fillInRowData(row);
ds->next();
IDataSourceHolder* dh = m_dataManager->dataSourceHolder(datasourceName);
if (dh) {
dh->invalidate(IDataSource::RENDER_MODE);
IDataSource* ds = m_dataManager->dataSource(datasourceName);
if (ds){
bool firstTime = true;
QObject* row = m_horizontalLayout;
while(!ds->eof()){
if (!firstTime) row = addRow();
else firstTime = false;
fillInRowData(row);
ds->next();
}
}
}
}

View File

@ -332,7 +332,7 @@ class DatasourceFunctions : public QObject{
Q_OBJECT
public:
explicit DatasourceFunctions(IDataSourceManager* dataManager)
: m_dataManager(dataManager){}
: m_dataManager(dynamic_cast<DataSourceManager*>(dataManager)){}
Q_INVOKABLE bool first(const QString& datasourceName);
Q_INVOKABLE bool next(const QString& datasourceName);
Q_INVOKABLE bool prior(const QString& datasourceName);
@ -340,7 +340,7 @@ public:
Q_INVOKABLE bool invalidate(const QString& datasourceName);
Q_INVOKABLE QObject *createTableBuilder(QObject *horizontalLayout);
private:
IDataSourceManager* m_dataManager;
DataSourceManager* m_dataManager;
};
class ScriptFunctionsManager : public QObject{

View File

@ -29,6 +29,8 @@
****************************************************************************/
#include "lrsimplecrypt.h"
namespace LimeReport {
#if defined(LP64) || defined(_LP64) || defined(__LP64__)
typedef unsigned int WORD; /* Should be 32-bit = 4 bytes */
#else
@ -62,8 +64,6 @@ void initPt(WTB& pt, QByteArray::Iterator* it, QByteArray::Iterator end){
}
}
namespace LimeReport {
class ChipperPrivate{
friend class Chipper;
public:
@ -117,7 +117,7 @@ QByteArray Chipper::cryptString(QString value)
{
QByteArray buff;
QByteArray result;
buff += value;
buff += value.toUtf8();
WTB pt, ct, prior;
if (!d->isPrepared())

View File

@ -175,15 +175,15 @@ void ScriptHighlighter::highlightBlock(const QString& text)
bool ScriptHighlighter::isKeyWord(const QString& word)
{
for (int i = 0; i < KEYWORDS_COUNT-1; ++i){
if (QLatin1String(keywords[i]) == word) return true;
}
return false;
return m_keywords.contains(word);
}
ScriptHighlighter::ScriptHighlighter(QTextDocument* parent):
QSyntaxHighlighter(parent)
{
for(int i=0; i<KEYWORDS_COUNT; ++i){
m_keywords.insert(keywords[i]);
}
if ( isColorDark(QPalette().background().color())){
m_formats[NumberFormat].setForeground(Qt::darkBlue);

View File

@ -2,6 +2,7 @@
#define LRSCRIPTHIGHLIGHTER_H
#include <QSyntaxHighlighter>
#include <QSet>
namespace LimeReport{
@ -43,6 +44,8 @@ protected:
QTextCharFormat m_formats[FormatsCount];
bool isKeyWord(const QString& word);
void createParentheisisInfo(const char& literal, TextBlockData *data, const QString& text);
private:
QSet<QString> m_keywords;
};

View File

@ -55,6 +55,29 @@
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>ImageItemEditor</name>
<message>
<source>Image Item Editor</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Image</source>
<translation type="unfinished">صورة</translation>
</message>
<message>
<source>...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Resource path</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Select image file</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LRVariableDialog</name>
<message>
@ -375,18 +398,22 @@ p, li { white-space: pre-wrap; }
<source>Keep bottom space</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Start from new page</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Start new page</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Keep top space</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Cut</source>
<translation type="unfinished">قص</translation>
</message>
<message>
<source>Copy</source>
<translation type="unfinished">نسخ</translation>
</message>
<message>
<source>Print if empty</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::BaseDesignIntf</name>
@ -422,6 +449,14 @@ p, li { white-space: pre-wrap; }
<source>Create Horizontal Layout</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Lock item geometry</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Create Vertical Layout</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::ConnectionDesc</name>
@ -500,10 +535,6 @@ p, li { white-space: pre-wrap; }
<source>Use default application connection</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Dont keep credentals in lrxml</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>defaultConnection</source>
<translation type="unfinished"></translation>
@ -516,6 +547,10 @@ p, li { white-space: pre-wrap; }
<source>Port</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Don&apos;t keep credentials in lrxml</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::DataBand</name>
@ -527,6 +562,26 @@ p, li { white-space: pre-wrap; }
<source>Use alternate background color</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Keep footer together</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Keep subdetail together</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Slice last row</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Start from new page</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Start new page</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::DataBrowser</name>
@ -621,6 +676,10 @@ p, li { white-space: pre-wrap; }
<source>DataFooter</source>
<translation>ذيل جدول البيانات</translation>
</message>
<message>
<source>Print always</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::DataHeaderBand</name>
@ -628,6 +687,18 @@ p, li { white-space: pre-wrap; }
<source>DataHeader</source>
<translation>رأس جدول البيانات</translation>
</message>
<message>
<source>Reprint on each page</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Repeat on each row</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Print always</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::DataSourceManager</name>
@ -659,6 +730,10 @@ p, li { white-space: pre-wrap; }
<source>Datasource with name &quot;%1&quot; already exists!</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Unknown parameter &quot;%1&quot; for variable &quot;%2&quot; found!</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::DataSourceModel</name>
@ -932,6 +1007,30 @@ p, li { white-space: pre-wrap; }
<source>TitleAlignCenter</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Layout</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Table</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Millimeters</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Inches</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Scale</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Split</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::FlagsPropItem</name>
@ -1049,6 +1148,18 @@ p, li { white-space: pre-wrap; }
<source>Watermark</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Edit</source>
<translation type="unfinished">تحرير</translation>
</message>
<message>
<source>Images (*.gif *.icns *.ico *.jpeg *.tga *.tiff *.wbmp *.webp *.png *.jpg *.bmp);;All(*.*)</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Ext.</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::ItemLocationPropItem</name>
@ -1156,6 +1267,28 @@ p, li { white-space: pre-wrap; }
<translation>الكائن</translation>
</message>
</context>
<context>
<name>LimeReport::ObjectInspectorWidget</name>
<message>
<source>Clear</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Filter</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Translate properties</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::PDFExporter</name>
<message>
<source>Export to PDF</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::PageFooter</name>
<message>
@ -1207,14 +1340,14 @@ p, li { white-space: pre-wrap; }
<source>Form</source>
<translation type="unfinished">نموذج</translation>
</message>
<message>
<source>PDF file name</source>
<translation type="unfinished">أسم ملف PDF</translation>
</message>
<message>
<source>Report file name</source>
<translation type="unfinished">أسم التقرير</translation>
</message>
<message>
<source>%1 file name</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::PreviewReportWindow</name>
@ -1226,10 +1359,6 @@ p, li { white-space: pre-wrap; }
<source>Report</source>
<translation type="unfinished">تقرير</translation>
</message>
<message>
<source>toolBar</source>
<translation type="unfinished">شريط الأدوات</translation>
</message>
<message>
<source>Print</source>
<translation type="unfinished">طباعة</translation>
@ -1330,6 +1459,46 @@ p, li { white-space: pre-wrap; }
<source>Text align</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>MainToolBar</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>EditModeTools</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>InsertTextItem</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Add new TextItem</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Selection Mode</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Delete Item</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Del</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Printing</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Attention</source>
<translation type="unfinished">Attention</translation>
</message>
<message>
<source>The printing is in process</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::ProxyHolder</name>
@ -1800,16 +1969,65 @@ p, li { white-space: pre-wrap; }
<source>variable</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::RectMMPropItem</name>
<message>
<source>width</source>
<translation>العرض</translation>
<source>replaceCRwithBR</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>height</source>
<translation>الأرتفاع</translation>
<source>hideIfEmpty</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>hideEmptyItems</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>useExternalPainter</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>layoutSpacing</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>printerName</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>fontLetterSpacing</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>hideText</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>option3</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>units</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>geometryLocked</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>printBehavior</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>shiftItems</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>showLegend</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>removeGap</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
@ -1823,6 +2041,17 @@ p, li { white-space: pre-wrap; }
<translation>الأرتفاع</translation>
</message>
</context>
<context>
<name>LimeReport::RectUnitPropItem</name>
<message>
<source>width</source>
<translation type="unfinished">العرض</translation>
</message>
<message>
<source>height</source>
<translation type="unfinished">الأرتفاع</translation>
</message>
</context>
<context>
<name>LimeReport::ReportDesignWidget</name>
<message>
@ -2020,18 +2249,6 @@ p, li { white-space: pre-wrap; }
<source>Report file name</source>
<translation>أسم التقرير</translation>
</message>
<message>
<source>Rendering report</source>
<translation>جاري قراءة التقرير</translation>
</message>
<message>
<source>Abort</source>
<translation>إجهاض</translation>
</message>
<message>
<source> page rendered</source>
<translation>تم إنشاء الصفحة</translation>
</message>
<message>
<source>Warning</source>
<translation type="unfinished">تحذير</translation>
@ -2120,6 +2337,38 @@ p, li { white-space: pre-wrap; }
<source>Hide right panel | Alt+R</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rendered %1 pages</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Cancel report rendering</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Vertical layout</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Lock selected items</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Unlock selected items</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Select one level items</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Attention</source>
<translation type="unfinished">Attention</translation>
</message>
<message>
<source>The rendering is in process</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::ReportEnginePrivate</name>
@ -2149,6 +2398,10 @@ This preview is no longer valid.</source>
<source>Designer not found!</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>%1 file name</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::ReportFooter</name>
@ -2285,6 +2538,41 @@ This preview is no longer valid.</source>
<source>Datasource with name: &quot;%1&quot; already exists!</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>CSV</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Separator</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>;</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Use first row as header</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::SVGItem</name>
<message>
<source>SVG Image</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SVG (*.svg)</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Edit</source>
<translation type="unfinished">تحرير</translation>
</message>
<message>
<source>Watermark</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::ScriptBrowser</name>
@ -2457,6 +2745,10 @@ This preview is no longer valid.</source>
<source>Function manager with name &quot;%1&quot; already exists!</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>RowIndex</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::SettingDialog</name>
@ -2480,24 +2772,40 @@ This preview is no longer valid.</source>
<source>Horizontal grid step</source>
<translation type="unfinished">تباعد الشبكة الأفقي</translation>
</message>
<message>
<source>Designer Setting</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Report Setting</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Suppress absent fields and variables warning</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Use dark theme</source>
<source>Language</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Language</source>
<source>Designer settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Theme</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Report units</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Script editor settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Font</source>
<translation type="unfinished">خط</translation>
</message>
<message>
<source>Indent size</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Report settings</source>
<translation type="unfinished"></translation>
</message>
</context>
@ -2515,6 +2823,13 @@ This preview is no longer valid.</source>
<translation>رأس البيانات الفرعية</translation>
</message>
</context>
<context>
<name>LimeReport::SvgEditor</name>
<message>
<source>Select image file</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::TearOffBand</name>
<message>
@ -2591,6 +2906,10 @@ This preview is no longer valid.</source>
<source>Watermark</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Hide if empty</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::TextItemEditor</name>
@ -2602,22 +2921,10 @@ This preview is no longer valid.</source>
<source>Content</source>
<translation type="unfinished">المحتوى</translation>
</message>
<message>
<source>Editor settings</source>
<translation type="unfinished">إعدادات المحرر</translation>
</message>
<message>
<source>Editor font</source>
<translation type="unfinished">خطوط المحرر</translation>
</message>
<message>
<source>Cancel</source>
<translation type="unfinished">إلغاء الأمر</translation>
</message>
<message>
<source>...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Ok</source>
<translation type="unfinished">موافق</translation>
@ -2915,5 +3222,57 @@ This preview is no longer valid.</source>
<source>Datasource manager not found</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Export to PDF</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SVG Item</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>VLayout</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>image</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Dark</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Light</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Default</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Millimeters</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Inches</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>margin</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>&apos;&apos;</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>series</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Series</source>
<translation type="unfinished"></translation>
</message>
</context>
</TS>

View File

@ -55,6 +55,29 @@
<translation>Nombre de la Serie</translation>
</message>
</context>
<context>
<name>ImageItemEditor</name>
<message>
<source>Image Item Editor</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Image</source>
<translation type="unfinished">Imagen</translation>
</message>
<message>
<source>...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Resource path</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Select image file</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LRVariableDialog</name>
<message>
@ -515,6 +538,10 @@ p, li { white-space: pre-wrap; }
<source>Print if empty</source>
<translation>Imprimir si está vacío</translation>
</message>
<message>
<source>Keep top space</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::BaseDesignIntf</name>
@ -554,6 +581,10 @@ p, li { white-space: pre-wrap; }
<source>Create Vertical Layout</source>
<translation>Crear diseño vertical</translation>
</message>
<message>
<source>Lock item geometry</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::ConnectionDesc</name>
@ -632,10 +663,6 @@ p, li { white-space: pre-wrap; }
<source>Use default application connection</source>
<translation>Utilice la conexión de aplicación predeterminada</translation>
</message>
<message>
<source>Dont keep credentals in lrxml</source>
<translation>No mantener credentals en el lrxml</translation>
</message>
<message>
<source>defaultConnection</source>
<translation>Conexión por defecto</translation>
@ -648,6 +675,10 @@ p, li { white-space: pre-wrap; }
<source>Port</source>
<translation>Puerto</translation>
</message>
<message>
<source>Don&apos;t keep credentials in lrxml</source>
<translation>No mantener credentals en el lrxml</translation>
</message>
</context>
<context>
<name>LimeReport::DataBand</name>
@ -1112,6 +1143,22 @@ p, li { white-space: pre-wrap; }
<source>Table</source>
<translation>Tabla</translation>
</message>
<message>
<source>Millimeters</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Inches</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Scale</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Split</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::FlagsPropItem</name>
@ -1233,6 +1280,14 @@ p, li { white-space: pre-wrap; }
<source>Ext.</source>
<translation>Ext.</translation>
</message>
<message>
<source>Edit</source>
<translation type="unfinished">Editar</translation>
</message>
<message>
<source>Images (*.gif *.icns *.ico *.jpeg *.tga *.tiff *.wbmp *.webp *.png *.jpg *.bmp);;All(*.*)</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::ItemLocationPropItem</name>
@ -1350,6 +1405,10 @@ p, li { white-space: pre-wrap; }
<source>Filter</source>
<translation>Filtrar</translation>
</message>
<message>
<source>Translate properties</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::PDFExporter</name>
@ -1432,10 +1491,6 @@ p, li { white-space: pre-wrap; }
<source>Report</source>
<translation>Reporte</translation>
</message>
<message>
<source>toolBar</source>
<translation>Barra herramientas</translation>
</message>
<message>
<source>Print</source>
<translation>Imprimir</translation>
@ -1532,10 +1587,6 @@ p, li { white-space: pre-wrap; }
<source>Show toolbar</source>
<translation>Mostrar barra herramientas</translation>
</message>
<message>
<source>toolBar_2</source>
<translation>barra herramientas_2</translation>
</message>
<message>
<source>InsertTextItem</source>
<translation>Insertar objeto de texto</translation>
@ -1556,6 +1607,26 @@ p, li { white-space: pre-wrap; }
<source>Del</source>
<translation>Supr</translation>
</message>
<message>
<source>MainToolBar</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>EditModeTools</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Printing</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Attention</source>
<translation type="unfinished">Atención</translation>
</message>
<message>
<source>The printing is in process</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::ProxyHolder</name>
@ -2062,16 +2133,29 @@ p, li { white-space: pre-wrap; }
<source>option3</source>
<translation>Opción3</translation>
</message>
</context>
<context>
<name>LimeReport::RectMMPropItem</name>
<message>
<source>width</source>
<translation>ancho</translation>
<source>units</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>height</source>
<translation>alto</translation>
<source>geometryLocked</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>printBehavior</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>shiftItems</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>showLegend</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>removeGap</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
@ -2085,6 +2169,17 @@ p, li { white-space: pre-wrap; }
<translation>alto</translation>
</message>
</context>
<context>
<name>LimeReport::RectUnitPropItem</name>
<message>
<source>width</source>
<translation type="unfinished">ancho</translation>
</message>
<message>
<source>height</source>
<translation type="unfinished">alto</translation>
</message>
</context>
<context>
<name>LimeReport::ReportDesignWidget</name>
<message>
@ -2302,18 +2397,6 @@ p, li { white-space: pre-wrap; }
<source>Report file name</source>
<translation>Nombre de archivo del reporte</translation>
</message>
<message>
<source>Rendering report</source>
<translation>Generando reporte</translation>
</message>
<message>
<source>Abort</source>
<translation>Abortar</translation>
</message>
<message>
<source> page rendered</source>
<translation> página generada</translation>
</message>
<message>
<source>Warning</source>
<translation>Advertencia</translation>
@ -2386,6 +2469,34 @@ p, li { white-space: pre-wrap; }
<source>Vertical layout</source>
<translation>Diseño vertical</translation>
</message>
<message>
<source>Rendered %1 pages</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Cancel report rendering</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Lock selected items</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Unlock selected items</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Select one level items</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Attention</source>
<translation type="unfinished">Atención</translation>
</message>
<message>
<source>The rendering is in process</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::ReportEnginePrivate</name>
@ -2574,6 +2685,25 @@ Esta vista previa ya no es válida.</translation>
<translation>Usa la primera fila como encabezado</translation>
</message>
</context>
<context>
<name>LimeReport::SVGItem</name>
<message>
<source>SVG Image</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SVG (*.svg)</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Edit</source>
<translation type="unfinished">Editar</translation>
</message>
<message>
<source>Watermark</source>
<translation type="unfinished">Marca de agua</translation>
</message>
</context>
<context>
<name>LimeReport::ScriptBrowser</name>
<message>
@ -2776,10 +2906,6 @@ Esta vista previa ya no es válida.</translation>
<source>Suppress absent fields and variables warning</source>
<translation>Suprimir campos ausentes y variables de advertencia.</translation>
</message>
<message>
<source>Use dark theme</source>
<translation type="vanished">Usar tema oscuro</translation>
</message>
<message>
<source>Language</source>
<translation>Idioma</translation>
@ -2808,6 +2934,10 @@ Esta vista previa ya no es válida.</translation>
<source>Theme</source>
<translation>Tema</translation>
</message>
<message>
<source>Report units</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::SubDetailBand</name>
@ -2823,6 +2953,13 @@ Esta vista previa ya no es válida.</translation>
<translation>Encabezado sub-detalle</translation>
</message>
</context>
<context>
<name>LimeReport::SvgEditor</name>
<message>
<source>Select image file</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::TearOffBand</name>
<message>
@ -3227,5 +3364,45 @@ Esta vista previa ya no es válida.</translation>
<source>Default</source>
<translation>Por defecto</translation>
</message>
<message>
<source>SVG Item</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>image</source>
<translation type="unfinished">imagen</translation>
</message>
<message>
<source>Dark</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Light</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Millimeters</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Inches</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>margin</source>
<translation type="unfinished">margen</translation>
</message>
<message>
<source>&apos;&apos;</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>series</source>
<translation type="unfinished">series</translation>
</message>
<message>
<source>Series</source>
<translation type="unfinished"></translation>
</message>
</context>
</TS>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -540,10 +540,6 @@ p, li { white-space: pre-wrap; }
<source>Ok</source>
<translation>Ок</translation>
</message>
<message>
<source>Dont keep credentals in lrxml</source>
<translation>Не хранить учетные данные в lrxml</translation>
</message>
<message>
<source>defaultConnection</source>
<translation>Соединение по умолчанию</translation>
@ -556,6 +552,10 @@ p, li { white-space: pre-wrap; }
<source>Port</source>
<translation>Порт</translation>
</message>
<message>
<source>Don&apos;t keep credentials in lrxml</source>
<translation>Не хранить учетные данные в lrxml</translation>
</message>
</context>
<context>
<name>LimeReport::DataBand</name>

View File

@ -523,10 +523,6 @@ p, li { white-space: pre-wrap; }
<source>Auto connect</source>
<translation></translation>
</message>
<message>
<source>Dont keep credentals in lrxml</source>
<translation>lrxml文件中保存凭证</translation>
</message>
<message>
<source>Check connection</source>
<translation></translation>
@ -563,6 +559,10 @@ p, li { white-space: pre-wrap; }
<source>defaultConnection</source>
<translation></translation>
</message>
<message>
<source>Don&apos;t keep credentials in lrxml</source>
<translation>lrxml文件中保存凭证</translation>
</message>
</context>
<context>
<name>LimeReport::DataBand</name>
@ -1168,6 +1168,10 @@ p, li { white-space: pre-wrap; }
<source>Edit</source>
<translation></translation>
</message>
<message>
<source>Images (*.gif *.icns *.ico *.jpeg *.tga *.tiff *.wbmp *.webp *.png *.jpg *.bmp);;All(*.*)</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::ItemLocationPropItem</name>
@ -2029,6 +2033,14 @@ p, li { white-space: pre-wrap; }
<source>shiftItems</source>
<translation></translation>
</message>
<message>
<source>showLegend</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>removeGap</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::RectPropItem</name>
@ -2557,6 +2569,25 @@ This preview is no longer valid.</source>
<translation></translation>
</message>
</context>
<context>
<name>LimeReport::SVGItem</name>
<message>
<source>SVG Image</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SVG (*.svg)</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Edit</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Watermark</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::ScriptBrowser</name>
<message>
@ -2806,6 +2837,13 @@ This preview is no longer valid.</source>
<translation></translation>
</message>
</context>
<context>
<name>LimeReport::SvgEditor</name>
<message>
<source>Select image file</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>LimeReport::TearOffBand</name>
<message>
@ -3234,5 +3272,21 @@ This preview is no longer valid.</source>
<source>&apos;&apos;</source>
<translation>&apos;&apos;</translation>
</message>
<message>
<source>SVG Item</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>image</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>series</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Series</source>
<translation type="unfinished"></translation>
</message>
</context>
</TS>