mirror of
https://github.com/python-LimeReport/LimeReport.git
synced 2024-12-23 20:22:58 +03:00
plugin extracted
This commit is contained in:
parent
9e4025f886
commit
0fb1ba1bd8
105
demo_r1/demo_reports/change_alignment.lrxml
Normal file
105
demo_r1/demo_reports/change_alignment.lrxml
Normal file
@ -0,0 +1,105 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF8"?>
|
||||||
|
<Report>
|
||||||
|
<object ClassName="LimeReport::ReportEnginePrivate" Type="Object">
|
||||||
|
<objectName Type="QString"></objectName>
|
||||||
|
<pages Type="Collection">
|
||||||
|
<item ClassName="LimeReport::PageDesignIntf" Type="Object">
|
||||||
|
<objectName Type="QString">page1</objectName>
|
||||||
|
<sceneRect y="-50" x="-50" width="2200" height="3070" Type="QRect"/>
|
||||||
|
<bspTreeDepth Value="5" Type="int"/>
|
||||||
|
<font pointSize="9" italic="0" family="Noto Sans" weight="50" underline="0" stylename="" Type="QFont"/>
|
||||||
|
<sortCacheEnabled Value="0" Type="bool"/>
|
||||||
|
<stickyFocus Value="0" Type="bool"/>
|
||||||
|
<minimumRenderSize Value="0" Type="qreal"/>
|
||||||
|
<pageItem ClassName="PageItem" Type="Object">
|
||||||
|
<objectName Type="QString">Reportpage1</objectName>
|
||||||
|
<geometry y="0" x="0" width="2100" height="2970" Type="QRect"/>
|
||||||
|
<children Type="Collection">
|
||||||
|
<item ClassName="TextItem" Type="Object">
|
||||||
|
<objectName Type="QString">TextItem1</objectName>
|
||||||
|
<geometry y="176" x="156" width="420" height="326" Type="QRect"/>
|
||||||
|
<children Type="Collection"/>
|
||||||
|
<zOrder Value="0" Type="qreal"/>
|
||||||
|
<borders Value="15" Type="enumAndFlags"/>
|
||||||
|
<parentName Type="QString">Reportpage1</parentName>
|
||||||
|
<borderLineSize Value="1" Type="int"/>
|
||||||
|
<isVisible Value="1" Type="bool"/>
|
||||||
|
<borderColor Value="#000000" Type="QColor"/>
|
||||||
|
<itemLocation Value="1" Type="enumAndFlags"/>
|
||||||
|
<stretchToMaxHeight Value="0" Type="bool"/>
|
||||||
|
<itemAlign Value="4" Type="enumAndFlags"/>
|
||||||
|
<content Type="QString">$S{
|
||||||
|
const Alignment = {
|
||||||
|
Left : 1,
|
||||||
|
Right: 2,
|
||||||
|
HCenter: 4,
|
||||||
|
Justify: 8,
|
||||||
|
Top: 32,
|
||||||
|
Bottom: 64,
|
||||||
|
VCenter: 128
|
||||||
|
}
|
||||||
|
|
||||||
|
THIS.alignment = (Alignment.Right | Alignment.Bottom);
|
||||||
|
"Test"
|
||||||
|
}</content>
|
||||||
|
<margin Value="4" Type="int"/>
|
||||||
|
<alignment Value="33" Type="enumAndFlags"/>
|
||||||
|
<autoWidth Value="0" Type="enumAndFlags"/>
|
||||||
|
<autoHeight Value="0" Type="bool"/>
|
||||||
|
<font pointSize="9" italic="0" family="DejaVu Sans" weight="50" underline="0" stylename="" Type="QFont"/>
|
||||||
|
<backgroundOpacity Value="100" Type="int"/>
|
||||||
|
<backgroundMode Value="1" Type="enumAndFlags"/>
|
||||||
|
<backgroundColor Value="#ffffff" Type="QColor"/>
|
||||||
|
<fontColor Value="#000000" Type="QColor"/>
|
||||||
|
<angle Value="0" Type="enumAndFlags"/>
|
||||||
|
<foregroundOpacity Value="100" Type="int"/>
|
||||||
|
<underlines Value="0" Type="bool"/>
|
||||||
|
<adaptFontToSize Value="0" Type="bool"/>
|
||||||
|
<trimValue Value="1" Type="bool"/>
|
||||||
|
<lineSpacing Value="1" Type="int"/>
|
||||||
|
<underlineLineSize Value="1" Type="int"/>
|
||||||
|
<allowHTML Value="0" Type="bool"/>
|
||||||
|
<allowHTMLInFields Value="0" Type="bool"/>
|
||||||
|
<format Type="QString"></format>
|
||||||
|
<valueType Value="0" Type="enumAndFlags"/>
|
||||||
|
<followTo Type="QString"></followTo>
|
||||||
|
<backgroundBrushStyle Value="1" Type="enumAndFlags"/>
|
||||||
|
<textIndent Value="0" Type="qreal"/>
|
||||||
|
<textLayoutDirection Value="2" Type="enumAndFlags"/>
|
||||||
|
</item>
|
||||||
|
</children>
|
||||||
|
<zOrder Value="0" Type="qreal"/>
|
||||||
|
<borders Value="0" Type="enumAndFlags"/>
|
||||||
|
<parentName Type="QString"></parentName>
|
||||||
|
<borderLineSize Value="1" Type="int"/>
|
||||||
|
<isVisible Value="1" Type="bool"/>
|
||||||
|
<borderColor Value="#000000" Type="QColor"/>
|
||||||
|
<topMargin Value="5" Type="int"/>
|
||||||
|
<bottomMargin Value="5" Type="int"/>
|
||||||
|
<rightMargin Value="5" Type="int"/>
|
||||||
|
<leftMargin Value="5" Type="int"/>
|
||||||
|
<pageOrientation Value="0" Type="enumAndFlags"/>
|
||||||
|
<pageSize Value="0" Type="enumAndFlags"/>
|
||||||
|
<gridStep Value="2" Type="int"/>
|
||||||
|
<fullPage Value="0" Type="bool"/>
|
||||||
|
<oldPrintMode Value="0" Type="bool"/>
|
||||||
|
<resetPageNumber Value="0" Type="bool"/>
|
||||||
|
</pageItem>
|
||||||
|
</item>
|
||||||
|
</pages>
|
||||||
|
<datasourcesManager ClassName="LimeReport::DataSourceManager" Type="Object">
|
||||||
|
<objectName Type="QString">datasources</objectName>
|
||||||
|
<connections Type="Collection"/>
|
||||||
|
<queries Type="Collection"/>
|
||||||
|
<subqueries Type="Collection"/>
|
||||||
|
<subproxies Type="Collection"/>
|
||||||
|
<variables Type="Collection"/>
|
||||||
|
</datasourcesManager>
|
||||||
|
<scriptContext ClassName="LimeReport::ScriptEngineContext" Type="Object">
|
||||||
|
<objectName Type="QString"></objectName>
|
||||||
|
<dialogs Type="Collection"/>
|
||||||
|
<initScript Type="QString"></initScript>
|
||||||
|
</scriptContext>
|
||||||
|
<suppressFieldAndVarError Value="0" Type="bool"/>
|
||||||
|
</object>
|
||||||
|
</Report>
|
@ -5,23 +5,23 @@
|
|||||||
<pages Type="Collection">
|
<pages Type="Collection">
|
||||||
<item Type="Object" ClassName="LimeReport::PageDesignIntf">
|
<item Type="Object" ClassName="LimeReport::PageDesignIntf">
|
||||||
<objectName Type="QString">page2</objectName>
|
<objectName Type="QString">page2</objectName>
|
||||||
<sceneRect y="-50" Type="QRect" width="2200" x="-50" height="3070"/>
|
<sceneRect Type="QRect" x="-50" height="3070" width="2200" y="-50"/>
|
||||||
<bspTreeDepth Type="int" Value="5"/>
|
<bspTreeDepth Type="int" Value="5"/>
|
||||||
<font pointSize="9" stylename="" Type="QFont" family="Noto Sans" italic="0" weight="50" underline="0"/>
|
<font pointSize="9" Type="QFont" stylename="" weight="50" italic="0" underline="0" family="Noto Sans"/>
|
||||||
<sortCacheEnabled Type="bool" Value="0"/>
|
<sortCacheEnabled Type="bool" Value="0"/>
|
||||||
<stickyFocus Type="bool" Value="0"/>
|
<stickyFocus Type="bool" Value="0"/>
|
||||||
<minimumRenderSize Type="qreal" Value="0"/>
|
<minimumRenderSize Type="qreal" Value="0"/>
|
||||||
<pageItem Type="Object" ClassName="PageItem">
|
<pageItem Type="Object" ClassName="PageItem">
|
||||||
<objectName Type="QString">TOC</objectName>
|
<objectName Type="QString">TOC</objectName>
|
||||||
<geometry y="0" Type="QRect" width="2100" x="0" height="2970"/>
|
<geometry Type="QRect" x="0" height="2970" width="2100" y="0"/>
|
||||||
<children Type="Collection">
|
<children Type="Collection">
|
||||||
<item Type="Object" ClassName="Data">
|
<item Type="Object" ClassName="Data">
|
||||||
<objectName Type="QString">DataBand1</objectName>
|
<objectName Type="QString">DataBand1</objectName>
|
||||||
<geometry y="50" Type="QRect" width="2000" x="50" height="94"/>
|
<geometry Type="QRect" x="50" height="94" width="2000" y="50"/>
|
||||||
<children Type="Collection">
|
<children Type="Collection">
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem1</objectName>
|
<objectName Type="QString">TextItem1</objectName>
|
||||||
<geometry y="26" Type="QRect" width="1612" x="18" height="50"/>
|
<geometry Type="QRect" x="18" height="50" width="1612" y="26"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -32,12 +32,12 @@
|
|||||||
<itemLocation Type="enumAndFlags" Value="0"/>
|
<itemLocation Type="enumAndFlags" Value="0"/>
|
||||||
<stretchToMaxHeight Type="bool" Value="0"/>
|
<stretchToMaxHeight Type="bool" Value="0"/>
|
||||||
<itemAlign Type="enumAndFlags" Value="4"/>
|
<itemAlign Type="enumAndFlags" Value="4"/>
|
||||||
<content Type="QString">$D{tableofcontens.Content}</content>
|
<content Type="QString">$D{tableofcontents.Content}</content>
|
||||||
<margin Type="int" Value="4"/>
|
<margin Type="int" Value="4"/>
|
||||||
<alignment Type="enumAndFlags" Value="33"/>
|
<alignment Type="enumAndFlags" Value="33"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="50" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="50" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="1"/>
|
<backgroundMode Type="enumAndFlags" Value="1"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -61,7 +61,7 @@
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem2</objectName>
|
<objectName Type="QString">TextItem2</objectName>
|
||||||
<geometry y="28" Type="QRect" width="244" x="1640" height="48"/>
|
<geometry Type="QRect" x="1640" height="48" width="244" y="28"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -74,17 +74,17 @@
|
|||||||
<itemAlign Type="enumAndFlags" Value="4"/>
|
<itemAlign Type="enumAndFlags" Value="4"/>
|
||||||
<content Type="QString">$S{
|
<content Type="QString">$S{
|
||||||
getFieldByKeyField(
|
getFieldByKeyField(
|
||||||
"tableofcontens",
|
"tableofcontents",
|
||||||
"Page number",
|
"Page number",
|
||||||
"Content Key",
|
"Content Key",
|
||||||
"$D{tableofcontens.Content Key}"
|
"$D{tableofcontents.Content Key}"
|
||||||
)
|
)
|
||||||
}</content>
|
}</content>
|
||||||
<margin Type="int" Value="4"/>
|
<margin Type="int" Value="4"/>
|
||||||
<alignment Type="enumAndFlags" Value="33"/>
|
<alignment Type="enumAndFlags" Value="33"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="50" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="50" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="1"/>
|
<backgroundMode Type="enumAndFlags" Value="1"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -120,7 +120,7 @@ getFieldByKeyField(
|
|||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
<backgroundBrushStyle Type="enumAndFlags" Value="1"/>
|
<backgroundBrushStyle Type="enumAndFlags" Value="1"/>
|
||||||
<printIfEmpty Type="bool" Value="0"/>
|
<printIfEmpty Type="bool" Value="0"/>
|
||||||
<datasource Type="QString">tableofcontens</datasource>
|
<datasource Type="QString">tableofcontents</datasource>
|
||||||
<keepSubdetailTogether Type="bool" Value="0"/>
|
<keepSubdetailTogether Type="bool" Value="0"/>
|
||||||
<splittable Type="bool" Value="0"/>
|
<splittable Type="bool" Value="0"/>
|
||||||
<keepFooterTogether Type="bool" Value="0"/>
|
<keepFooterTogether Type="bool" Value="0"/>
|
||||||
@ -152,27 +152,29 @@ getFieldByKeyField(
|
|||||||
<isExtendedInDesignMode Type="bool" Value="0"/>
|
<isExtendedInDesignMode Type="bool" Value="0"/>
|
||||||
<extendedHeight Type="int" Value="1000"/>
|
<extendedHeight Type="int" Value="1000"/>
|
||||||
<pageIsTOC Type="bool" Value="1"/>
|
<pageIsTOC Type="bool" Value="1"/>
|
||||||
|
<setPageSizeToPrinter Type="bool" Value="0"/>
|
||||||
|
<endlessHeight Type="bool" Value="0"/>
|
||||||
</pageItem>
|
</pageItem>
|
||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="LimeReport::PageDesignIntf">
|
<item Type="Object" ClassName="LimeReport::PageDesignIntf">
|
||||||
<objectName Type="QString">page1</objectName>
|
<objectName Type="QString">page1</objectName>
|
||||||
<sceneRect y="-50" Type="QRect" width="2200" x="-50" height="3070"/>
|
<sceneRect Type="QRect" x="-50" height="3070" width="2200" y="-50"/>
|
||||||
<bspTreeDepth Type="int" Value="5"/>
|
<bspTreeDepth Type="int" Value="5"/>
|
||||||
<font pointSize="9" stylename="" Type="QFont" family="Sans Serif" italic="0" weight="50" underline="0"/>
|
<font pointSize="9" Type="QFont" stylename="" weight="50" italic="0" underline="0" family="Sans Serif"/>
|
||||||
<sortCacheEnabled Type="bool" Value="0"/>
|
<sortCacheEnabled Type="bool" Value="0"/>
|
||||||
<stickyFocus Type="bool" Value="0"/>
|
<stickyFocus Type="bool" Value="0"/>
|
||||||
<minimumRenderSize Type="qreal" Value="0"/>
|
<minimumRenderSize Type="qreal" Value="0"/>
|
||||||
<pageItem Type="Object" ClassName="PageItem">
|
<pageItem Type="Object" ClassName="PageItem">
|
||||||
<objectName Type="QString">ReportPage1</objectName>
|
<objectName Type="QString">ReportPage1</objectName>
|
||||||
<geometry y="0" Type="QRect" width="2100" x="0" height="2970"/>
|
<geometry Type="QRect" x="0" height="2970" width="2100" y="0"/>
|
||||||
<children Type="Collection">
|
<children Type="Collection">
|
||||||
<item Type="Object" ClassName="ReportHeader">
|
<item Type="Object" ClassName="ReportHeader">
|
||||||
<objectName Type="QString">ReportHeader1</objectName>
|
<objectName Type="QString">ReportHeader1</objectName>
|
||||||
<geometry y="154" Type="QRect" width="2000" x="50" height="164"/>
|
<geometry Type="QRect" x="50" height="164" width="2000" y="154"/>
|
||||||
<children Type="Collection">
|
<children Type="Collection">
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem1</objectName>
|
<objectName Type="QString">TextItem1</objectName>
|
||||||
<geometry y="22" Type="QRect" width="1024" x="230" height="142"/>
|
<geometry Type="QRect" x="230" height="142" width="1024" y="22"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -189,7 +191,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="33"/>
|
<alignment Type="enumAndFlags" Value="33"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="16" stylename="" Type="QFont" family="Arial" italic="0" weight="75" underline="0"/>
|
<font pointSize="16" Type="QFont" stylename="" weight="75" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="0"/>
|
<backgroundMode Type="enumAndFlags" Value="0"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -213,7 +215,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="ImageItem">
|
<item Type="Object" ClassName="ImageItem">
|
||||||
<objectName Type="QString">ImageItem1</objectName>
|
<objectName Type="QString">ImageItem1</objectName>
|
||||||
<geometry y="6" Type="QRect" width="158" x="68" height="156"/>
|
<geometry Type="QRect" x="68" height="156" width="158" y="6"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -228,6 +230,7 @@ Report</content>
|
|||||||
<opacity Type="int" Value="100"/>
|
<opacity Type="int" Value="100"/>
|
||||||
<datasource Type="QString"></datasource>
|
<datasource Type="QString"></datasource>
|
||||||
<field Type="QString"></field>
|
<field Type="QString"></field>
|
||||||
|
<format Type="enumAndFlags" Value="0"/>
|
||||||
<autoSize Type="bool" Value="0"/>
|
<autoSize Type="bool" Value="0"/>
|
||||||
<scale Type="bool" Value="1"/>
|
<scale Type="bool" Value="1"/>
|
||||||
<keepAspectRatio Type="bool" Value="1"/>
|
<keepAspectRatio Type="bool" Value="1"/>
|
||||||
@ -236,7 +239,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="ShapeItem">
|
<item Type="Object" ClassName="ShapeItem">
|
||||||
<objectName Type="QString">ShapeItem1</objectName>
|
<objectName Type="QString">ShapeItem1</objectName>
|
||||||
<geometry y="86" Type="QRect" width="2000" x="0" height="78"/>
|
<geometry Type="QRect" x="0" height="78" width="2000" y="86"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="-0.1"/>
|
<zOrder Type="qreal" Value="-0.1"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -258,7 +261,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="ShapeItem">
|
<item Type="Object" ClassName="ShapeItem">
|
||||||
<objectName Type="QString">ShapeItem2</objectName>
|
<objectName Type="QString">ShapeItem2</objectName>
|
||||||
<geometry y="60" Type="QRect" width="2006" x="-6" height="50"/>
|
<geometry Type="QRect" x="-6" height="50" width="2006" y="60"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0.1"/>
|
<zOrder Type="qreal" Value="0.1"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -280,7 +283,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem9</objectName>
|
<objectName Type="QString">TextItem9</objectName>
|
||||||
<geometry y="18" Type="QRect" width="200" x="1782" height="50"/>
|
<geometry Type="QRect" x="1782" height="50" width="200" y="18"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -296,7 +299,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="130"/>
|
<alignment Type="enumAndFlags" Value="130"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="75" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="75" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="50"/>
|
<backgroundOpacity Type="int" Value="50"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="1"/>
|
<backgroundMode Type="enumAndFlags" Value="1"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -320,7 +323,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem10</objectName>
|
<objectName Type="QString">TextItem10</objectName>
|
||||||
<geometry y="98" Type="QRect" width="200" x="1782" height="50"/>
|
<geometry Type="QRect" x="1782" height="50" width="200" y="98"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -336,7 +339,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="130"/>
|
<alignment Type="enumAndFlags" Value="130"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="75" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="75" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="50"/>
|
<backgroundOpacity Type="int" Value="50"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="1"/>
|
<backgroundMode Type="enumAndFlags" Value="1"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -377,11 +380,11 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="Data">
|
<item Type="Object" ClassName="Data">
|
||||||
<objectName Type="QString">DataBand1</objectName>
|
<objectName Type="QString">DataBand1</objectName>
|
||||||
<geometry y="414" Type="QRect" width="2000" x="50" height="64"/>
|
<geometry Type="QRect" x="50" height="64" width="2000" y="414"/>
|
||||||
<children Type="Collection">
|
<children Type="Collection">
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem3</objectName>
|
<objectName Type="QString">TextItem3</objectName>
|
||||||
<geometry y="6" Type="QRect" width="250" x="648" height="50"/>
|
<geometry Type="QRect" x="648" height="50" width="250" y="6"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -397,7 +400,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="33"/>
|
<alignment Type="enumAndFlags" Value="33"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="50" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="50" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="0"/>
|
<backgroundMode Type="enumAndFlags" Value="0"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -421,7 +424,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem4</objectName>
|
<objectName Type="QString">TextItem4</objectName>
|
||||||
<geometry y="6" Type="QRect" width="250" x="178" height="50"/>
|
<geometry Type="QRect" x="178" height="50" width="250" y="6"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -437,7 +440,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="33"/>
|
<alignment Type="enumAndFlags" Value="33"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="50" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="50" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="0"/>
|
<backgroundMode Type="enumAndFlags" Value="0"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -461,7 +464,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem12</objectName>
|
<objectName Type="QString">TextItem12</objectName>
|
||||||
<geometry y="12" Type="QRect" width="340" x="1642" height="38"/>
|
<geometry Type="QRect" x="1642" height="38" width="340" y="12"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -477,7 +480,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="34"/>
|
<alignment Type="enumAndFlags" Value="34"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="75" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="75" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="1"/>
|
<backgroundMode Type="enumAndFlags" Value="1"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -501,7 +504,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem16</objectName>
|
<objectName Type="QString">TextItem16</objectName>
|
||||||
<geometry y="6" Type="QRect" width="162" x="10" height="50"/>
|
<geometry Type="QRect" x="10" height="50" width="162" y="6"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -517,7 +520,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="33"/>
|
<alignment Type="enumAndFlags" Value="33"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="75" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="75" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="0"/>
|
<backgroundMode Type="enumAndFlags" Value="0"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -541,7 +544,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem17</objectName>
|
<objectName Type="QString">TextItem17</objectName>
|
||||||
<geometry y="6" Type="QRect" width="208" x="434" height="50"/>
|
<geometry Type="QRect" x="434" height="50" width="208" y="6"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -557,7 +560,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="33"/>
|
<alignment Type="enumAndFlags" Value="33"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="75" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="75" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="0"/>
|
<backgroundMode Type="enumAndFlags" Value="0"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -607,11 +610,11 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="GroupHeader">
|
<item Type="Object" ClassName="GroupHeader">
|
||||||
<objectName Type="QString">GroupBandHeader1</objectName>
|
<objectName Type="QString">GroupBandHeader1</objectName>
|
||||||
<geometry y="322" Type="QRect" width="2000" x="50" height="88"/>
|
<geometry Type="QRect" x="50" height="88" width="2000" y="322"/>
|
||||||
<children Type="Collection">
|
<children Type="Collection">
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem2</objectName>
|
<objectName Type="QString">TextItem2</objectName>
|
||||||
<geometry y="22" Type="QRect" width="580" x="10" height="50"/>
|
<geometry Type="QRect" x="10" height="50" width="580" y="22"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -627,7 +630,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="33"/>
|
<alignment Type="enumAndFlags" Value="33"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="50" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="50" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="0"/>
|
<backgroundMode Type="enumAndFlags" Value="0"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -651,7 +654,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="ShapeItem">
|
<item Type="Object" ClassName="ShapeItem">
|
||||||
<objectName Type="QString">ShapeItem3</objectName>
|
<objectName Type="QString">ShapeItem3</objectName>
|
||||||
<geometry y="2" Type="QRect" width="2000" x="0" height="8"/>
|
<geometry Type="QRect" x="0" height="8" width="2000" y="2"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="-0.1"/>
|
<zOrder Type="qreal" Value="-0.1"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -673,7 +676,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem11</objectName>
|
<objectName Type="QString">TextItem11</objectName>
|
||||||
<geometry y="24" Type="QRect" width="326" x="1656" height="38"/>
|
<geometry Type="QRect" x="1656" height="38" width="326" y="24"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -689,7 +692,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="34"/>
|
<alignment Type="enumAndFlags" Value="34"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="75" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="75" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="50"/>
|
<backgroundOpacity Type="int" Value="50"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="1"/>
|
<backgroundMode Type="enumAndFlags" Value="1"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -735,11 +738,11 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="SubDetail">
|
<item Type="Object" ClassName="SubDetail">
|
||||||
<objectName Type="QString">SubDetailBand1</objectName>
|
<objectName Type="QString">SubDetailBand1</objectName>
|
||||||
<geometry y="482" Type="QRect" width="2000" x="50" height="64"/>
|
<geometry Type="QRect" x="50" height="64" width="2000" y="482"/>
|
||||||
<children Type="Collection">
|
<children Type="Collection">
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem5</objectName>
|
<objectName Type="QString">TextItem5</objectName>
|
||||||
<geometry y="6" Type="QRect" width="626" x="104" height="50"/>
|
<geometry Type="QRect" x="104" height="50" width="626" y="6"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -755,7 +758,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="33"/>
|
<alignment Type="enumAndFlags" Value="33"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="1"/>
|
<autoHeight Type="bool" Value="1"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="50" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="50" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="0"/>
|
<backgroundMode Type="enumAndFlags" Value="0"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -779,7 +782,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem6</objectName>
|
<objectName Type="QString">TextItem6</objectName>
|
||||||
<geometry y="6" Type="QRect" width="250" x="738" height="50"/>
|
<geometry Type="QRect" x="738" height="50" width="250" y="6"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -795,7 +798,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="34"/>
|
<alignment Type="enumAndFlags" Value="34"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="50" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="50" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="0"/>
|
<backgroundMode Type="enumAndFlags" Value="0"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -819,7 +822,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem7</objectName>
|
<objectName Type="QString">TextItem7</objectName>
|
||||||
<geometry y="6" Type="QRect" width="86" x="8" height="50"/>
|
<geometry Type="QRect" x="8" height="50" width="86" y="6"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -835,7 +838,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="33"/>
|
<alignment Type="enumAndFlags" Value="33"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="50" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="50" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="0"/>
|
<backgroundMode Type="enumAndFlags" Value="0"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -859,7 +862,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem13</objectName>
|
<objectName Type="QString">TextItem13</objectName>
|
||||||
<geometry y="12" Type="QRect" width="354" x="1628" height="42"/>
|
<geometry Type="QRect" x="1628" height="42" width="354" y="12"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -875,7 +878,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="34"/>
|
<alignment Type="enumAndFlags" Value="34"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="75" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="75" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="50"/>
|
<backgroundOpacity Type="int" Value="50"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="1"/>
|
<backgroundMode Type="enumAndFlags" Value="1"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -921,11 +924,11 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="SubDetailFooter">
|
<item Type="Object" ClassName="SubDetailFooter">
|
||||||
<objectName Type="QString">SubDetailFooterBand1</objectName>
|
<objectName Type="QString">SubDetailFooterBand1</objectName>
|
||||||
<geometry y="550" Type="QRect" width="2000" x="50" height="70"/>
|
<geometry Type="QRect" x="50" height="70" width="2000" y="550"/>
|
||||||
<children Type="Collection">
|
<children Type="Collection">
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem8</objectName>
|
<objectName Type="QString">TextItem8</objectName>
|
||||||
<geometry y="10" Type="QRect" width="248" x="738" height="50"/>
|
<geometry Type="QRect" x="738" height="50" width="248" y="10"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="1"/>
|
<borders Type="enumAndFlags" Value="1"/>
|
||||||
@ -941,7 +944,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="130"/>
|
<alignment Type="enumAndFlags" Value="130"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="50" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="50" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="1"/>
|
<backgroundMode Type="enumAndFlags" Value="1"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -965,7 +968,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem14</objectName>
|
<objectName Type="QString">TextItem14</objectName>
|
||||||
<geometry y="16" Type="QRect" width="380" x="1602" height="42"/>
|
<geometry Type="QRect" x="1602" height="42" width="380" y="16"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -981,7 +984,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="34"/>
|
<alignment Type="enumAndFlags" Value="34"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="75" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="75" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="1"/>
|
<backgroundMode Type="enumAndFlags" Value="1"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -1005,7 +1008,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem15</objectName>
|
<objectName Type="QString">TextItem15</objectName>
|
||||||
<geometry y="10" Type="QRect" width="200" x="528" height="50"/>
|
<geometry Type="QRect" x="528" height="50" width="200" y="10"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -1021,7 +1024,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="130"/>
|
<alignment Type="enumAndFlags" Value="130"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="10" stylename="" Type="QFont" family="Arial" italic="0" weight="50" underline="0"/>
|
<font pointSize="10" Type="QFont" stylename="" weight="50" italic="0" underline="0" family="Arial"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="1"/>
|
<backgroundMode Type="enumAndFlags" Value="1"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -1045,7 +1048,7 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="ShapeItem">
|
<item Type="Object" ClassName="ShapeItem">
|
||||||
<objectName Type="QString">ShapeItem4</objectName>
|
<objectName Type="QString">ShapeItem4</objectName>
|
||||||
<geometry y="40" Type="QRect" width="1994" x="6" height="50"/>
|
<geometry Type="QRect" x="6" height="50" width="1994" y="40"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -1085,11 +1088,11 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="PageFooter">
|
<item Type="Object" ClassName="PageFooter">
|
||||||
<objectName Type="QString">PageFooter1</objectName>
|
<objectName Type="QString">PageFooter1</objectName>
|
||||||
<geometry y="624" Type="QRect" width="2000" x="50" height="100"/>
|
<geometry Type="QRect" x="50" height="100" width="2000" y="624"/>
|
||||||
<children Type="Collection">
|
<children Type="Collection">
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem18</objectName>
|
<objectName Type="QString">TextItem18</objectName>
|
||||||
<geometry y="22" Type="QRect" width="696" x="1258" height="50"/>
|
<geometry Type="QRect" x="1258" height="50" width="696" y="22"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -1105,7 +1108,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="34"/>
|
<alignment Type="enumAndFlags" Value="34"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="9" stylename="" Type="QFont" family="DejaVu Sans" italic="0" weight="50" underline="0"/>
|
<font pointSize="9" Type="QFont" stylename="" weight="50" italic="0" underline="0" family="DejaVu Sans"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="1"/>
|
<backgroundMode Type="enumAndFlags" Value="1"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -1146,11 +1149,11 @@ Report</content>
|
|||||||
</item>
|
</item>
|
||||||
<item Type="Object" ClassName="PageHeader">
|
<item Type="Object" ClassName="PageHeader">
|
||||||
<objectName Type="QString">PageHeader18</objectName>
|
<objectName Type="QString">PageHeader18</objectName>
|
||||||
<geometry y="50" Type="QRect" width="2000" x="50" height="100"/>
|
<geometry Type="QRect" x="50" height="100" width="2000" y="50"/>
|
||||||
<children Type="Collection">
|
<children Type="Collection">
|
||||||
<item Type="Object" ClassName="TextItem">
|
<item Type="Object" ClassName="TextItem">
|
||||||
<objectName Type="QString">TextItem19</objectName>
|
<objectName Type="QString">TextItem19</objectName>
|
||||||
<geometry y="22" Type="QRect" width="696" x="1258" height="50"/>
|
<geometry Type="QRect" x="1258" height="50" width="696" y="22"/>
|
||||||
<children Type="Collection"/>
|
<children Type="Collection"/>
|
||||||
<zOrder Type="qreal" Value="0"/>
|
<zOrder Type="qreal" Value="0"/>
|
||||||
<borders Type="enumAndFlags" Value="0"/>
|
<borders Type="enumAndFlags" Value="0"/>
|
||||||
@ -1166,7 +1169,7 @@ Report</content>
|
|||||||
<alignment Type="enumAndFlags" Value="34"/>
|
<alignment Type="enumAndFlags" Value="34"/>
|
||||||
<autoWidth Type="enumAndFlags" Value="0"/>
|
<autoWidth Type="enumAndFlags" Value="0"/>
|
||||||
<autoHeight Type="bool" Value="0"/>
|
<autoHeight Type="bool" Value="0"/>
|
||||||
<font pointSize="9" stylename="" Type="QFont" family="DejaVu Sans" italic="0" weight="50" underline="0"/>
|
<font pointSize="9" Type="QFont" stylename="" weight="50" italic="0" underline="0" family="DejaVu Sans"/>
|
||||||
<backgroundOpacity Type="int" Value="100"/>
|
<backgroundOpacity Type="int" Value="100"/>
|
||||||
<backgroundMode Type="enumAndFlags" Value="1"/>
|
<backgroundMode Type="enumAndFlags" Value="1"/>
|
||||||
<backgroundColor Type="QColor" Value="#ffffff"/>
|
<backgroundColor Type="QColor" Value="#ffffff"/>
|
||||||
@ -1225,6 +1228,8 @@ Report</content>
|
|||||||
<isExtendedInDesignMode Type="bool" Value="0"/>
|
<isExtendedInDesignMode Type="bool" Value="0"/>
|
||||||
<extendedHeight Type="int" Value="1000"/>
|
<extendedHeight Type="int" Value="1000"/>
|
||||||
<pageIsTOC Type="bool" Value="0"/>
|
<pageIsTOC Type="bool" Value="0"/>
|
||||||
|
<setPageSizeToPrinter Type="bool" Value="0"/>
|
||||||
|
<endlessHeight Type="bool" Value="0"/>
|
||||||
</pageItem>
|
</pageItem>
|
||||||
</item>
|
</item>
|
||||||
</pages>
|
</pages>
|
||||||
@ -1278,15 +1283,15 @@ var firstLevel = "&nbsp;&nbsp;&nbsp;&nbsp;";
|
|||||||
var secondLevel = "&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
|
var secondLevel = "&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
|
||||||
|
|
||||||
function SB1AfterData(){
|
function SB1AfterData(){
|
||||||
addTableOfContensItem(getField("orders.OrderID"),firstLevel+getField("orders.OrderID"));
|
addTableOfContentsItem(getField("orders.OrderID"),firstLevel+getField("orders.OrderID"));
|
||||||
}
|
}
|
||||||
|
|
||||||
function SB2AfterData(){
|
function SB2AfterData(){
|
||||||
addTableOfContensItem(getField("orders.OrderID")+getField("orderItems.ProductName"), secondLevel+"<i>"+getField("orderItems.ProductName")+"</i>");
|
addTableOfContentsItem(getField("orders.OrderID")+getField("orderItems.ProductName"), secondLevel+"<i>"+getField("orderItems.ProductName")+"</i>");
|
||||||
}
|
}
|
||||||
|
|
||||||
function SB3AfterData(){
|
function SB3AfterData(){
|
||||||
addTableOfContensItem(getField("orders.CompanyName"), "<b>"+getField("orders.CompanyName")+"</b>");
|
addTableOfContentsItem(getField("orders.CompanyName"), "<b>"+getField("orders.CompanyName")+"</b>");
|
||||||
}</initScript>
|
}</initScript>
|
||||||
</scriptContext>
|
</scriptContext>
|
||||||
<suppressFieldAndVarError Type="bool" Value="0"/>
|
<suppressFieldAndVarError Type="bool" Value="0"/>
|
||||||
|
44
designer_plugin/designer_plugin.pro
Normal file
44
designer_plugin/designer_plugin.pro
Normal file
@ -0,0 +1,44 @@
|
|||||||
|
include(../common.pri)
|
||||||
|
include(limereport.pri)
|
||||||
|
QT += core gui
|
||||||
|
|
||||||
|
contains(CONFIG,release) {
|
||||||
|
TARGET = LRDesigner_plugin
|
||||||
|
} else {
|
||||||
|
TARGET = LRDesigner_plugind
|
||||||
|
}
|
||||||
|
|
||||||
|
TEMPLATE = lib
|
||||||
|
CONFIG += plugin
|
||||||
|
|
||||||
|
HEADERS += \
|
||||||
|
lrdesignerplugin.h
|
||||||
|
SOURCES += \
|
||||||
|
lrdesignerplugin.cpp
|
||||||
|
|
||||||
|
INCLUDEPATH += $$PWD/../include
|
||||||
|
DEPENDPATH += $$PWD/../include
|
||||||
|
|
||||||
|
macx{
|
||||||
|
CONFIG += lib_bundle
|
||||||
|
CONFIG += -dll
|
||||||
|
}
|
||||||
|
|
||||||
|
DESTDIR = $${DEST_LIBS}
|
||||||
|
unix {
|
||||||
|
target.path = $${DESTDIR}
|
||||||
|
INSTALLS = target
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
contains(CONFIG,zint){
|
||||||
|
message(zint)
|
||||||
|
INCLUDEPATH += $$ZINT_PATH/backend $$ZINT_PATH/backend_qt
|
||||||
|
DEPENDPATH += $$ZINT_PATH/backend $$ZINT_PATH/backend_qt
|
||||||
|
LIBS += -L$${DEST_LIBS}
|
||||||
|
contains(CONFIG,release) {
|
||||||
|
LIBS += -lQtZint
|
||||||
|
} else {
|
||||||
|
LIBS += -lQtZintd
|
||||||
|
}
|
||||||
|
}
|
257
designer_plugin/limereport.pri
Normal file
257
designer_plugin/limereport.pri
Normal file
@ -0,0 +1,257 @@
|
|||||||
|
include(../common.pri)
|
||||||
|
|
||||||
|
DEFINES += IS_REPORT_DESIGNER
|
||||||
|
|
||||||
|
contains(CONFIG,dialogdesigner){
|
||||||
|
include($$REPORT_PATH/dialogdesigner/dialogdesigner.pri)
|
||||||
|
}
|
||||||
|
|
||||||
|
DEFINES += INSPECT_BASEDESIGN
|
||||||
|
|
||||||
|
INCLUDEPATH += \
|
||||||
|
$$REPORT_PATH/ \
|
||||||
|
$$REPORT_PATH/items \
|
||||||
|
$$REPORT_PATH/bands \
|
||||||
|
$$REPORT_PATH/base \
|
||||||
|
$$REPORT_PATH/objectinspector \
|
||||||
|
$$REPORT_PATH/databrowser \
|
||||||
|
$$REPORT_PATH/scripteditor \
|
||||||
|
$$REPORT_PATH/../designer_plugin
|
||||||
|
|
||||||
|
SOURCES += \
|
||||||
|
$$REPORT_PATH/bands/lrpageheader.cpp \
|
||||||
|
$$REPORT_PATH/bands/lrpagefooter.cpp \
|
||||||
|
$$REPORT_PATH/bands/lrreportheader.cpp \
|
||||||
|
$$REPORT_PATH/bands/lrreportfooter.cpp \
|
||||||
|
$$REPORT_PATH/bands/lrdataband.cpp \
|
||||||
|
$$REPORT_PATH/bands/lrgroupbands.cpp \
|
||||||
|
$$REPORT_PATH/bands/lrsubdetailband.cpp \
|
||||||
|
$$REPORT_PATH/bands/lrtearoffband.cpp \
|
||||||
|
$$REPORT_PATH/databrowser/lrdatabrowser.cpp \
|
||||||
|
$$REPORT_PATH/databrowser/lrsqleditdialog.cpp \
|
||||||
|
$$REPORT_PATH/databrowser/lrconnectiondialog.cpp \
|
||||||
|
$$REPORT_PATH/databrowser/lrvariabledialog.cpp \
|
||||||
|
$$REPORT_PATH/databrowser/lrdatabrowsertree.cpp \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlqrectserializator.cpp \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlbasetypesserializators.cpp \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlreader.cpp \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlwriter.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrstringpropitem.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrrectproptem.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrintpropitem.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrenumpropitem.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrboolpropitem.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrflagspropitem.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrfontpropitem.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrimagepropitem.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrqrealpropitem.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrcolorpropitem.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrdatasourcepropitem.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrgroupfieldpropitem.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrcontentpropitem.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/lrtextitempropertyeditor.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/lrcomboboxeditor.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/lrcheckboxeditor.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/lrbuttonlineeditor.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/lrfonteditor.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/lrimageeditor.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/lrcoloreditor.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/lrbasedesignobjectmodel.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/lrobjectinspectorwidget.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/lrobjectitemmodel.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/lrobjectpropitem.cpp \
|
||||||
|
$$REPORT_PATH/objectinspector/lrpropertydelegate.cpp \
|
||||||
|
$$REPORT_PATH/objectsbrowser/lrobjectbrowser.cpp \
|
||||||
|
$$REPORT_PATH/scriptbrowser/lrscriptbrowser.cpp \
|
||||||
|
$$REPORT_PATH/scripteditor/lrscripteditor.cpp \
|
||||||
|
$$REPORT_PATH/scripteditor/lrcodeeditor.cpp \
|
||||||
|
$$REPORT_PATH/scripteditor/lrscripthighlighter.cpp \
|
||||||
|
$$REPORT_PATH/items/lrsubitemparentpropitem.cpp \
|
||||||
|
$$REPORT_PATH/items/lralignpropitem.cpp \
|
||||||
|
$$REPORT_PATH/items/lrhorizontallayout.cpp \
|
||||||
|
$$REPORT_PATH/items/editors/lritemeditorwidget.cpp \
|
||||||
|
$$REPORT_PATH/items/editors/lrfonteditorwidget.cpp \
|
||||||
|
$$REPORT_PATH/items/editors/lrtextalignmenteditorwidget.cpp \
|
||||||
|
$$REPORT_PATH/items/editors/lritemsaligneditorwidget.cpp \
|
||||||
|
$$REPORT_PATH/items/editors/lritemsborderseditorwidget.cpp \
|
||||||
|
$$REPORT_PATH/items/lrsimpletagparser.cpp \
|
||||||
|
$$REPORT_PATH/items/lrimageitem.cpp \
|
||||||
|
$$REPORT_PATH/items/lrtextitemeditor.cpp \
|
||||||
|
$$REPORT_PATH/items/lrshapeitem.cpp \
|
||||||
|
$$REPORT_PATH/items/lrtextitem.cpp \
|
||||||
|
$$REPORT_PATH/translationeditor/translationeditor.cpp \
|
||||||
|
$$REPORT_PATH/lrbanddesignintf.cpp \
|
||||||
|
$$REPORT_PATH/lrpageitemdesignintf.cpp \
|
||||||
|
$$REPORT_PATH/lrpagedesignintf.cpp \
|
||||||
|
$$REPORT_PATH/lrbandsmanager.cpp \
|
||||||
|
$$REPORT_PATH/lrglobal.cpp \
|
||||||
|
$$REPORT_PATH/lritemdesignintf.cpp \
|
||||||
|
$$REPORT_PATH/lrdatadesignintf.cpp \
|
||||||
|
$$REPORT_PATH/lrreportdesignwidget.cpp \
|
||||||
|
$$REPORT_PATH/lrbasedesignintf.cpp \
|
||||||
|
$$REPORT_PATH/lrreportengine.cpp \
|
||||||
|
$$REPORT_PATH/lrdatasourcemanager.cpp \
|
||||||
|
$$REPORT_PATH/lrreportdesignwindow.cpp \
|
||||||
|
# $$REPORT_PATH/lrreportrender.cpp \
|
||||||
|
$$REPORT_PATH/lrscriptenginemanager.cpp \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwindow.cpp \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwidget.cpp \
|
||||||
|
$$REPORT_PATH/lrgraphicsviewzoom.cpp \
|
||||||
|
$$REPORT_PATH/lrvariablesholder.cpp \
|
||||||
|
$$REPORT_PATH/lrgroupfunctions.cpp \
|
||||||
|
$$REPORT_PATH/lrsimplecrypt.cpp \
|
||||||
|
$$REPORT_PATH/lraboutdialog.cpp \
|
||||||
|
$$REPORT_PATH/lrsettingdialog.cpp \
|
||||||
|
$$REPORT_PATH/lritemscontainerdesignitf.cpp \
|
||||||
|
$$REPORT_PATH/lrcolorindicator.cpp \
|
||||||
|
$$REPORT_PATH/items/lrchartitem.cpp \
|
||||||
|
$$REPORT_PATH/items/lrchartitemeditor.cpp \
|
||||||
|
$$REPORT_PATH/lrreporttranslation.cpp \
|
||||||
|
$$REPORT_PATH/translationeditor/languageselectdialog.cpp
|
||||||
|
|
||||||
|
contains(CONFIG, staticlib){
|
||||||
|
SOURCES += $$REPORT_PATH/lrfactoryinitializer.cpp
|
||||||
|
}
|
||||||
|
|
||||||
|
contains(CONFIG, zint){
|
||||||
|
SOURCES += $$REPORT_PATH/items/lrbarcodeitem.cpp
|
||||||
|
}
|
||||||
|
|
||||||
|
HEADERS += \
|
||||||
|
$$REPORT_PATH/base/lrsingleton.h \
|
||||||
|
$$REPORT_PATH/base/lrsimpleabstractfactory.h \
|
||||||
|
$$REPORT_PATH/base/lrattribsabstractfactory.h \
|
||||||
|
$$REPORT_PATH/bands/lrpageheader.h \
|
||||||
|
$$REPORT_PATH/bands/lrpagefooter.h \
|
||||||
|
$$REPORT_PATH/bands/lrreportheader.h \
|
||||||
|
$$REPORT_PATH/bands/lrreportfooter.h \
|
||||||
|
$$REPORT_PATH/bands/lrdataband.h \
|
||||||
|
$$REPORT_PATH/bands/lrtearoffband.h \
|
||||||
|
$$REPORT_PATH/bands/lrsubdetailband.h \
|
||||||
|
$$REPORT_PATH/bands/lrgroupbands.h \
|
||||||
|
$$REPORT_PATH/databrowser/lrdatabrowser.h \
|
||||||
|
$$REPORT_PATH/databrowser/lrsqleditdialog.h \
|
||||||
|
$$REPORT_PATH/databrowser/lrconnectiondialog.h \
|
||||||
|
$$REPORT_PATH/databrowser/lrvariabledialog.h \
|
||||||
|
$$REPORT_PATH/databrowser/lrdatabrowsertree.h \
|
||||||
|
$$REPORT_PATH/serializators/lrserializatorintf.h \
|
||||||
|
$$REPORT_PATH/serializators/lrstorageintf.h \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlqrectserializator.h \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlserializatorsfactory.h \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlbasetypesserializators.h \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlreader.h \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlwriter.h \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrstringpropitem.h \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrrectproptem.h \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrdatasourcepropitem.h \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrfontpropitem.h \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrimagepropitem.h \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrintpropitem.h \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrenumpropitem.h \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrboolpropitem.h \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrflagspropitem.h \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrgroupfieldpropitem.h \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrcontentpropitem.h \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrqrealpropitem.h \
|
||||||
|
$$REPORT_PATH/objectinspector/propertyItems/lrcolorpropitem.h \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/lrtextitempropertyeditor.h \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/lrcomboboxeditor.h \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/lrcheckboxeditor.h \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/lrbuttonlineeditor.h \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/lrimageeditor.h \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/lrcoloreditor.h \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/lrfonteditor.h \
|
||||||
|
$$REPORT_PATH/objectinspector/lrbasedesignobjectmodel.h \
|
||||||
|
$$REPORT_PATH/objectinspector/lrobjectinspectorwidget.h \
|
||||||
|
$$REPORT_PATH/objectinspector/lrobjectitemmodel.h \
|
||||||
|
$$REPORT_PATH/objectinspector/lrobjectpropitem.h \
|
||||||
|
$$REPORT_PATH/objectinspector/lrpropertydelegate.h \
|
||||||
|
$$REPORT_PATH/objectsbrowser/lrobjectbrowser.h \
|
||||||
|
$$REPORT_PATH/scriptbrowser/lrscriptbrowser.h \
|
||||||
|
$$REPORT_PATH/scripteditor/lrscripteditor.h \
|
||||||
|
$$REPORT_PATH/scripteditor/lrcodeeditor.h \
|
||||||
|
$$REPORT_PATH/scripteditor/lrscripthighlighter.h \
|
||||||
|
$$REPORT_PATH/items/editors/lritemeditorwidget.h \
|
||||||
|
$$REPORT_PATH/items/editors/lrfonteditorwidget.h \
|
||||||
|
$$REPORT_PATH/items/editors/lrtextalignmenteditorwidget.h \
|
||||||
|
$$REPORT_PATH/items/editors/lritemsaligneditorwidget.h \
|
||||||
|
$$REPORT_PATH/items/editors/lritemsborderseditorwidget.h \
|
||||||
|
$$REPORT_PATH/items/lrtextitem.h \
|
||||||
|
$$REPORT_PATH/items/lrsubitemparentpropitem.h \
|
||||||
|
$$REPORT_PATH/items/lralignpropitem.h \
|
||||||
|
$$REPORT_PATH/items/lrhorizontallayout.h \
|
||||||
|
$$REPORT_PATH/items/lrtextitemeditor.h \
|
||||||
|
$$REPORT_PATH/items/lrshapeitem.h \
|
||||||
|
$$REPORT_PATH/items/lrimageitem.h \
|
||||||
|
$$REPORT_PATH/items/lrsimpletagparser.h \
|
||||||
|
$$REPORT_PATH/translationeditor/translationeditor.h \
|
||||||
|
$$REPORT_PATH/lrfactoryinitializer.h \
|
||||||
|
$$REPORT_PATH/lrbanddesignintf.h \
|
||||||
|
$$REPORT_PATH/lrpageitemdesignintf.h \
|
||||||
|
$$REPORT_PATH/lrbandsmanager.h \
|
||||||
|
$$REPORT_PATH/lrglobal.h \
|
||||||
|
$$REPORT_PATH/lrdatadesignintf.h \
|
||||||
|
$$REPORT_PATH/lrcollection.h \
|
||||||
|
$$REPORT_PATH/lrpagedesignintf.h \
|
||||||
|
$$REPORT_PATH/lrreportdesignwidget.h \
|
||||||
|
$$REPORT_PATH/lrreportengine_p.h \
|
||||||
|
$$REPORT_PATH/lrdatasourcemanager.h \
|
||||||
|
$$REPORT_PATH/lrreportdesignwindow.h \
|
||||||
|
# $$REPORT_PATH/lrreportrender.h \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwindow.h \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwidget.h \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwidget_p.h \
|
||||||
|
$$REPORT_PATH/lrgraphicsviewzoom.h \
|
||||||
|
$$REPORT_PATH/lrbasedesignintf.h \
|
||||||
|
$$REPORT_PATH/lritemdesignintf.h \
|
||||||
|
$$REPORT_PATH/lrdesignelementsfactory.h \
|
||||||
|
$$REPORT_PATH/lrscriptenginemanager.h \
|
||||||
|
$$REPORT_PATH/lrvariablesholder.h \
|
||||||
|
$$REPORT_PATH/lrgroupfunctions.h \
|
||||||
|
$$REPORT_PATH/lrreportengine.h \
|
||||||
|
$$REPORT_PATH/lrdatasourcemanagerintf.h \
|
||||||
|
$$REPORT_PATH/lrscriptenginemanagerintf.h \
|
||||||
|
$$REPORT_PATH/lrsimplecrypt.h \
|
||||||
|
$$REPORT_PATH/lraboutdialog.h \
|
||||||
|
$$REPORT_PATH/lrcallbackdatasourceintf.h \
|
||||||
|
$$REPORT_PATH/lrsettingdialog.h \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwidget_p.h \
|
||||||
|
$$REPORT_PATH/lritemscontainerdesignitf.h \
|
||||||
|
$$REPORT_PATH/lrcolorindicator.h \
|
||||||
|
$$REPORT_PATH/items/lrchartitem.h \
|
||||||
|
$$REPORT_PATH/items/lrchartitemeditor.h \
|
||||||
|
$$REPORT_PATH/lrreporttranslation.h \
|
||||||
|
$$REPORT_PATH/translationeditor/languageselectdialog.h
|
||||||
|
|
||||||
|
contains(CONFIG, staticlib){
|
||||||
|
HEADERS += $$REPORT_PATH/lrfactoryinitializer.h
|
||||||
|
}
|
||||||
|
|
||||||
|
contains(CONFIG,zint){
|
||||||
|
HEADERS += $$REPORT_PATH/items/lrbarcodeitem.h
|
||||||
|
}
|
||||||
|
|
||||||
|
FORMS += \
|
||||||
|
$$REPORT_PATH/databrowser/lrsqleditdialog.ui \
|
||||||
|
$$REPORT_PATH/databrowser/lrconnectiondialog.ui \
|
||||||
|
$$REPORT_PATH/databrowser/lrdatabrowser.ui \
|
||||||
|
$$REPORT_PATH/databrowser/lrvariabledialog.ui \
|
||||||
|
$$REPORT_PATH/objectinspector/editors/ltextitempropertyeditor.ui \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwindow.ui \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwidget.ui \
|
||||||
|
$$REPORT_PATH/items/lrtextitemeditor.ui \
|
||||||
|
$$REPORT_PATH/lraboutdialog.ui \
|
||||||
|
$$REPORT_PATH/lrsettingdialog.ui \
|
||||||
|
$$REPORT_PATH/scriptbrowser/lrscriptbrowser.ui \
|
||||||
|
$$REPORT_PATH/items/lrchartitemeditor.ui \
|
||||||
|
$$REPORT_PATH/translationeditor/translationeditor.ui \
|
||||||
|
$$REPORT_PATH/translationeditor/languageselectdialog.ui \
|
||||||
|
$$REPORT_PATH/scripteditor/lrscripteditor.ui
|
||||||
|
|
||||||
|
RESOURCES += \
|
||||||
|
$$REPORT_PATH/objectinspector/lobjectinspector.qrc \
|
||||||
|
$$REPORT_PATH/databrowser/lrdatabrowser.qrc \
|
||||||
|
$$REPORT_PATH/report.qrc \
|
||||||
|
$$REPORT_PATH/items/items.qrc \
|
||||||
|
$$REPORT_PATH/scriptbrowser/lrscriptbrowser.qrc \
|
||||||
|
$$REPORT_PATH/translationeditor/translationeditor.qrc
|
31
designer_plugin/lrdesignerplugin.cpp
Normal file
31
designer_plugin/lrdesignerplugin.cpp
Normal file
@ -0,0 +1,31 @@
|
|||||||
|
#include "lrdesignerplugin.h"
|
||||||
|
|
||||||
|
#include <QRect>
|
||||||
|
#include "lrreportdesignwindow.h"
|
||||||
|
|
||||||
|
DesignerFactoryPlugin::~DesignerFactoryPlugin() {
|
||||||
|
}
|
||||||
|
|
||||||
|
QString DesignerFactoryPlugin::getString() const {
|
||||||
|
return "Hello, Plugin!";
|
||||||
|
}
|
||||||
|
|
||||||
|
QVariant DesignerFactoryPlugin::getVar() const {
|
||||||
|
return QRect( 10, 10, 500, 500 );
|
||||||
|
}
|
||||||
|
|
||||||
|
QMainWindow* DesignerFactoryPlugin::getDesignerWindow(LimeReport::ReportEnginePrivateInterface* report, QWidget* parent, QSettings* settings)
|
||||||
|
{
|
||||||
|
LimeReport::ReportDesignWindow* designerWindow = new LimeReport::ReportDesignWindow(report, parent, settings);
|
||||||
|
|
||||||
|
settings->beginGroup("DesignerWindow");
|
||||||
|
designerWindow->setAttribute(Qt::WA_DeleteOnClose,true);
|
||||||
|
designerWindow->setWindowIcon(QIcon(":report/images/logo32"));
|
||||||
|
designerWindow->setShowProgressDialog(settings->value("showProgressDialog").toBool());
|
||||||
|
settings->endGroup();
|
||||||
|
|
||||||
|
return designerWindow;
|
||||||
|
}
|
||||||
|
|
||||||
|
//Q_EXPORT_PLUGIN2( LimeReportPluginInterface, DesignerFactoryPlugin )
|
||||||
|
|
20
designer_plugin/lrdesignerplugin.h
Normal file
20
designer_plugin/lrdesignerplugin.h
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
#ifndef LRDESIGNERPLUGIN_H
|
||||||
|
#define LRDESIGNERPLUGIN_H
|
||||||
|
|
||||||
|
#include <QMainWindow>
|
||||||
|
#include <lrdesignerplugininterface.h>
|
||||||
|
|
||||||
|
class DesignerFactoryPlugin : public QObject, public LimeReportPluginInterface {
|
||||||
|
Q_OBJECT
|
||||||
|
Q_PLUGIN_METADATA(IID "ru.limereport.DersignerFactoryInterface")
|
||||||
|
Q_INTERFACES( LimeReportPluginInterface )
|
||||||
|
|
||||||
|
public:
|
||||||
|
~DesignerFactoryPlugin();
|
||||||
|
|
||||||
|
QString getString() const;
|
||||||
|
QVariant getVar() const;
|
||||||
|
QMainWindow* getDesignerWindow(LimeReport::ReportEnginePrivateInterface* report, QWidget* parent, QSettings* settings);
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif
|
13
designer_plugin/main.cpp
Normal file
13
designer_plugin/main.cpp
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
#include <QApplication>
|
||||||
|
#include <LimeReport>
|
||||||
|
|
||||||
|
int main(int argc, char *argv[])
|
||||||
|
{
|
||||||
|
QApplication a(argc, argv);
|
||||||
|
LimeReport::ReportEngine report;
|
||||||
|
if (a.arguments().count()>1){
|
||||||
|
report.loadFromFile(a.arguments().at(1));
|
||||||
|
}
|
||||||
|
report.designReport();
|
||||||
|
return a.exec();
|
||||||
|
}
|
91
include/lrrenderengine.h
Normal file
91
include/lrrenderengine.h
Normal file
@ -0,0 +1,91 @@
|
|||||||
|
#ifndef LRRENDERENGINE_H
|
||||||
|
#define LRRENDERENGINE_H
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
#include <QSettings>
|
||||||
|
#include <QPrintDialog>
|
||||||
|
|
||||||
|
#include "lrglobal.h"
|
||||||
|
#include "lrdatasourcemanagerintf.h"
|
||||||
|
#include "lrscriptenginemanagerintf.h"
|
||||||
|
#include "lrpreviewreportwidget.h"
|
||||||
|
|
||||||
|
namespace LimeReport{
|
||||||
|
|
||||||
|
class PrintRange{
|
||||||
|
public:
|
||||||
|
int fromPage() const { return m_fromPage;}
|
||||||
|
int toPage() const { return m_toPage;}
|
||||||
|
QPrintDialog::PrintRange rangeType() const { return m_rangeType;}
|
||||||
|
PrintRange(QAbstractPrintDialog::PrintRange rangeType=QPrintDialog::AllPages, int fromPage=0, int toPage=0);
|
||||||
|
void setRangeType(QAbstractPrintDialog::PrintRange rangeType){ m_rangeType=rangeType;}
|
||||||
|
void setFromPage(int fromPage){ m_fromPage = fromPage;}
|
||||||
|
void setToPage(int toPage){ m_toPage = toPage;}
|
||||||
|
private:
|
||||||
|
QPrintDialog::PrintRange m_rangeType;
|
||||||
|
int m_fromPage;
|
||||||
|
int m_toPage;
|
||||||
|
};
|
||||||
|
|
||||||
|
class DataSourceManager;
|
||||||
|
class PageDesignIntf;
|
||||||
|
class PageItemDesignIntf;
|
||||||
|
class PreviewReportWidget;
|
||||||
|
|
||||||
|
typedef QList< QSharedPointer<PageItemDesignIntf> > ReportPages;
|
||||||
|
|
||||||
|
class RenderEnginePrivate;
|
||||||
|
|
||||||
|
class LIMEREPORT_EXPORT RenderEngine: public QObject{
|
||||||
|
Q_OBJECT
|
||||||
|
friend class PreviewReportWidget;
|
||||||
|
public:
|
||||||
|
static void setSettings(QSettings *value){m_settings=value;}
|
||||||
|
public:
|
||||||
|
explicit RenderEngine(QObject *parent = 0);
|
||||||
|
explicit RenderEngine(RenderEnginePrivate* dd, QObject *parent = 0);
|
||||||
|
~RenderEngine();
|
||||||
|
bool printReport(QPrinter *printer=0);
|
||||||
|
bool printPages(ReportPages pages, QPrinter *printer);
|
||||||
|
void printToFile(const QString& fileName);
|
||||||
|
PageDesignIntf *createPreviewScene(QObject *parent = 0);
|
||||||
|
bool printToPDF(const QString& fileName);
|
||||||
|
void previewReport(PreviewHints hints = PreviewBarsUserSetting);
|
||||||
|
IDataSourceManager* dataManager();
|
||||||
|
IScriptEngineManager* scriptManager();
|
||||||
|
bool loadFromFile(const QString& fileName, bool autoLoadPreviewOnChange = false);
|
||||||
|
bool loadFromByteArray(QByteArray *data);
|
||||||
|
bool loadFromString(const QString& data);
|
||||||
|
QString reportFileName();
|
||||||
|
void setReportFileName(const QString& fileName);
|
||||||
|
QString lastError();
|
||||||
|
PreviewReportWidget *createPreviewWidget(QWidget *parent = 0);
|
||||||
|
void setPreviewWindowTitle(const QString& title);
|
||||||
|
void setPreviewWindowIcon(const QIcon& icon);
|
||||||
|
void setResultEditable(bool value);
|
||||||
|
bool resultIsEditable();
|
||||||
|
bool isBusy();
|
||||||
|
void setPassPharse(QString& passPharse);
|
||||||
|
QList<QLocale::Language> aviableLanguages();
|
||||||
|
bool setReportLanguage(QLocale::Language language);
|
||||||
|
Qt::LayoutDirection previewLayoutDirection();
|
||||||
|
void setPreviewLayoutDirection(const Qt::LayoutDirection& previewLayoutDirection);
|
||||||
|
QSettings* settings(){ return m_settings;}
|
||||||
|
signals:
|
||||||
|
void renderStarted();
|
||||||
|
void renderFinished();
|
||||||
|
void renderPageFinished(int renderedPageCount);
|
||||||
|
void onLoad(bool& loaded);
|
||||||
|
public slots:
|
||||||
|
void cancelRender();
|
||||||
|
protected:
|
||||||
|
QObject* d_ptr;
|
||||||
|
private:
|
||||||
|
static QSettings* m_settings;
|
||||||
|
void init();
|
||||||
|
private:
|
||||||
|
Q_DECLARE_PRIVATE(RenderEngine)
|
||||||
|
};
|
||||||
|
|
||||||
|
} // namespace LimeReport
|
||||||
|
#endif // LRRENDERENGINE_H
|
120
limerender/limerender.h
Normal file
120
limerender/limerender.h
Normal file
@ -0,0 +1,120 @@
|
|||||||
|
/***************************************************************************
|
||||||
|
* This file is part of the Lime Report project *
|
||||||
|
* Copyright (C) 2015 by Alexander Arin *
|
||||||
|
* arin_a@bk.ru *
|
||||||
|
* *
|
||||||
|
** GNU General Public License Usage **
|
||||||
|
* *
|
||||||
|
* This library is free software: you can redistribute it and/or modify *
|
||||||
|
* it under the terms of the GNU General Public License as published by *
|
||||||
|
* the Free Software Foundation, either version 3 of the License, or *
|
||||||
|
* (at your option) any later version. *
|
||||||
|
* You should have received a copy of the GNU General Public License *
|
||||||
|
* along with this program. If not, see <http://www.gnu.org/licenses/>. *
|
||||||
|
* *
|
||||||
|
** GNU Lesser General Public License **
|
||||||
|
* *
|
||||||
|
* This library is free software: you can redistribute it and/or modify *
|
||||||
|
* it under the terms of the GNU Lesser General Public License as *
|
||||||
|
* published by the Free Software Foundation, either version 3 of the *
|
||||||
|
* License, or (at your option) any later version. *
|
||||||
|
* You should have received a copy of the GNU Lesser General Public *
|
||||||
|
* License along with this library. *
|
||||||
|
* If not, see <http://www.gnu.org/licenses/>. *
|
||||||
|
* *
|
||||||
|
* 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. See the *
|
||||||
|
* GNU General Public License for more details. *
|
||||||
|
****************************************************************************/
|
||||||
|
#ifndef LRLIMERENDER_H
|
||||||
|
#define LRLIMERENDER_H
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
#include <QSettings>
|
||||||
|
#include <QPrintDialog>
|
||||||
|
//#include <QJSEngine>
|
||||||
|
|
||||||
|
#include "lrreportrender.h"
|
||||||
|
#include "limerender_p.h"
|
||||||
|
#include "lrglobal.h"
|
||||||
|
#include "lrdatasourcemanagerintf.h"
|
||||||
|
#include "lrscriptenginemanagerintf.h"
|
||||||
|
#include "lrpreviewreportwidget.h"
|
||||||
|
|
||||||
|
class QPrinter;
|
||||||
|
|
||||||
|
namespace LimeReport {
|
||||||
|
|
||||||
|
//class PrintRange{
|
||||||
|
//public:
|
||||||
|
// int fromPage() const { return m_fromPage;}
|
||||||
|
// int toPage() const { return m_toPage;}
|
||||||
|
// QPrintDialog::PrintRange rangeType() const { return m_rangeType;}
|
||||||
|
// PrintRange(QAbstractPrintDialog::PrintRange rangeType=QPrintDialog::AllPages, int fromPage=0, int toPage=0);
|
||||||
|
// void setRangeType(QAbstractPrintDialog::PrintRange rangeType){ m_rangeType=rangeType;}
|
||||||
|
// void setFromPage(int fromPage){ m_fromPage = fromPage;}
|
||||||
|
// void setToPage(int toPage){ m_toPage = toPage;}
|
||||||
|
//private:
|
||||||
|
// QPrintDialog::PrintRange m_rangeType;
|
||||||
|
// int m_fromPage;
|
||||||
|
// int m_toPage;
|
||||||
|
//};
|
||||||
|
|
||||||
|
class DataSourceManager;
|
||||||
|
class LimeRenderPrivate;
|
||||||
|
class PageDesignIntf;
|
||||||
|
class PageItemDesignIntf;
|
||||||
|
class PreviewReportWidget;
|
||||||
|
|
||||||
|
typedef QList< QSharedPointer<PageItemDesignIntf> > ReportPages;
|
||||||
|
|
||||||
|
class LIMEREPORT_EXPORT LimeRender : public QObject{
|
||||||
|
Q_OBJECT
|
||||||
|
friend class PreviewReportWidget;
|
||||||
|
public:
|
||||||
|
static void setSettings(QSettings *value){m_settings=value;}
|
||||||
|
public:
|
||||||
|
explicit LimeRender(QObject *parent = 0);
|
||||||
|
~LimeRender();
|
||||||
|
bool printReport(QPrinter *printer=0);
|
||||||
|
bool printPages(ReportPages pages, QPrinter *printer);
|
||||||
|
void printToFile(const QString& fileName);
|
||||||
|
PageDesignIntf *createPreviewScene(QObject *parent = 0);
|
||||||
|
bool printToPDF(const QString& fileName);
|
||||||
|
void previewReport(PreviewHints hints = PreviewBarsUserSetting);
|
||||||
|
IDataSourceManager* dataManager();
|
||||||
|
IScriptEngineManager* scriptManager();
|
||||||
|
bool loadFromFile(const QString& fileName, bool autoLoadPreviewOnChange = false);
|
||||||
|
bool loadFromByteArray(QByteArray *data);
|
||||||
|
bool loadFromString(const QString& data);
|
||||||
|
QString lastError();
|
||||||
|
PreviewReportWidget *createPreviewWidget(QWidget *parent = 0);
|
||||||
|
void setPreviewWindowTitle(const QString& title);
|
||||||
|
void setPreviewWindowIcon(const QIcon& icon);
|
||||||
|
void setResultEditable(bool value);
|
||||||
|
bool resultIsEditable();
|
||||||
|
bool isBusy();
|
||||||
|
void setPassPharse(QString& passPharse);
|
||||||
|
QList<QLocale::Language> aviableLanguages();
|
||||||
|
bool setReportLanguage(QLocale::Language language);
|
||||||
|
Qt::LayoutDirection previewLayoutDirection();
|
||||||
|
void setPreviewLayoutDirection(const Qt::LayoutDirection& previewLayoutDirection);
|
||||||
|
signals:
|
||||||
|
void renderStarted();
|
||||||
|
void renderFinished();
|
||||||
|
void renderPageFinished(int renderedPageCount);
|
||||||
|
void onLoad(bool& loaded);
|
||||||
|
public slots:
|
||||||
|
void cancelRender();
|
||||||
|
protected:
|
||||||
|
LimeRenderPrivate * const d_ptr;
|
||||||
|
LimeRender(LimeRenderPrivate &dd, QObject * parent=0);
|
||||||
|
private:
|
||||||
|
Q_DECLARE_PRIVATE(LimeRender)
|
||||||
|
static QSettings* m_settings;
|
||||||
|
};
|
||||||
|
|
||||||
|
} // namespace LimeReport
|
||||||
|
|
||||||
|
#endif // LRLIMERENDER_H
|
156
limerender/limerender.pri
Normal file
156
limerender/limerender.pri
Normal file
@ -0,0 +1,156 @@
|
|||||||
|
include(../common.pri)
|
||||||
|
|
||||||
|
DEFINES += IS_RENDER_BUILD
|
||||||
|
|
||||||
|
INCLUDEPATH += \
|
||||||
|
$$REPORT_PATH/ \
|
||||||
|
$$REPORT_PATH/items \
|
||||||
|
$$REPORT_PATH/bands \
|
||||||
|
$$REPORT_PATH/base \
|
||||||
|
$$REPORT_PATH/scripteditor
|
||||||
|
|
||||||
|
SOURCES += \
|
||||||
|
$$REPORT_PATH/bands/lrpageheader.cpp \
|
||||||
|
$$REPORT_PATH/bands/lrpagefooter.cpp \
|
||||||
|
$$REPORT_PATH/bands/lrreportheader.cpp \
|
||||||
|
$$REPORT_PATH/bands/lrreportfooter.cpp \
|
||||||
|
$$REPORT_PATH/bands/lrdataband.cpp \
|
||||||
|
$$REPORT_PATH/bands/lrgroupbands.cpp \
|
||||||
|
$$REPORT_PATH/bands/lrsubdetailband.cpp \
|
||||||
|
$$REPORT_PATH/bands/lrtearoffband.cpp \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlqrectserializator.cpp \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlbasetypesserializators.cpp \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlreader.cpp \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlwriter.cpp \
|
||||||
|
$$REPORT_PATH/scripteditor/lrscripteditor.cpp \
|
||||||
|
$$REPORT_PATH/scripteditor/lrcodeeditor.cpp \
|
||||||
|
$$REPORT_PATH/scripteditor/lrscripthighlighter.cpp \
|
||||||
|
$$REPORT_PATH/items/lrhorizontallayout.cpp \
|
||||||
|
$$REPORT_PATH/items/editors/lritemeditorwidget.cpp \
|
||||||
|
$$REPORT_PATH/items/editors/lrfonteditorwidget.cpp \
|
||||||
|
$$REPORT_PATH/items/editors/lrtextalignmenteditorwidget.cpp \
|
||||||
|
$$REPORT_PATH/items/editors/lritemsaligneditorwidget.cpp \
|
||||||
|
$$REPORT_PATH/items/editors/lritemsborderseditorwidget.cpp \
|
||||||
|
$$REPORT_PATH/items/lrsimpletagparser.cpp \
|
||||||
|
$$REPORT_PATH/items/lrimageitem.cpp \
|
||||||
|
$$REPORT_PATH/items/lrtextitemeditor.cpp \
|
||||||
|
$$REPORT_PATH/items/lrshapeitem.cpp \
|
||||||
|
$$REPORT_PATH/items/lrtextitem.cpp \
|
||||||
|
$$REPORT_PATH/lrbanddesignintf.cpp \
|
||||||
|
$$REPORT_PATH/lrpageitemdesignintf.cpp \
|
||||||
|
$$REPORT_PATH/lrpagedesignintf.cpp \
|
||||||
|
$$REPORT_PATH/lrbandsmanager.cpp \
|
||||||
|
$$REPORT_PATH/lrglobal.cpp \
|
||||||
|
$$REPORT_PATH/lritemdesignintf.cpp \
|
||||||
|
$$REPORT_PATH/lrdatadesignintf.cpp \
|
||||||
|
$$REPORT_PATH/lrbasedesignintf.cpp \
|
||||||
|
$$REPORT_PATH/lrdatasourcemanager.cpp \
|
||||||
|
$$REPORT_PATH/lrreportrender.cpp \
|
||||||
|
$$REPORT_PATH/lrscriptenginemanager.cpp \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwindow.cpp \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwidget.cpp \
|
||||||
|
$$REPORT_PATH/lrgraphicsviewzoom.cpp \
|
||||||
|
$$REPORT_PATH/lrvariablesholder.cpp \
|
||||||
|
$$REPORT_PATH/lrgroupfunctions.cpp \
|
||||||
|
$$REPORT_PATH/lrsimplecrypt.cpp \
|
||||||
|
$$REPORT_PATH/lraboutdialog.cpp \
|
||||||
|
$$REPORT_PATH/lritemscontainerdesignitf.cpp \
|
||||||
|
$$REPORT_PATH/lrcolorindicator.cpp \
|
||||||
|
$$REPORT_PATH/items/lrchartitem.cpp \
|
||||||
|
$$REPORT_PATH/lrreporttranslation.cpp
|
||||||
|
# $$PWD/lrreportrender.cpp
|
||||||
|
|
||||||
|
|
||||||
|
contains(CONFIG, staticlib){
|
||||||
|
SOURCES += $$REPORT_PATH/lrfactoryinitializer.cpp
|
||||||
|
}
|
||||||
|
|
||||||
|
contains(CONFIG, zint){
|
||||||
|
SOURCES += $$REPORT_PATH/items/lrbarcodeitem.cpp
|
||||||
|
}
|
||||||
|
|
||||||
|
HEADERS += \
|
||||||
|
$$REPORT_PATH/base/lrsingleton.h \
|
||||||
|
$$REPORT_PATH/base/lrsimpleabstractfactory.h \
|
||||||
|
$$REPORT_PATH/base/lrattribsabstractfactory.h \
|
||||||
|
$$REPORT_PATH/bands/lrpageheader.h \
|
||||||
|
$$REPORT_PATH/bands/lrpagefooter.h \
|
||||||
|
$$REPORT_PATH/bands/lrreportheader.h \
|
||||||
|
$$REPORT_PATH/bands/lrreportfooter.h \
|
||||||
|
$$REPORT_PATH/bands/lrdataband.h \
|
||||||
|
$$REPORT_PATH/bands/lrtearoffband.h \
|
||||||
|
$$REPORT_PATH/bands/lrsubdetailband.h \
|
||||||
|
$$REPORT_PATH/bands/lrgroupbands.h \
|
||||||
|
$$REPORT_PATH/serializators/lrserializatorintf.h \
|
||||||
|
$$REPORT_PATH/serializators/lrstorageintf.h \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlqrectserializator.h \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlserializatorsfactory.h \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlbasetypesserializators.h \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlreader.h \
|
||||||
|
$$REPORT_PATH/serializators/lrxmlwriter.h \
|
||||||
|
$$REPORT_PATH/scripteditor/lrscripteditor.h \
|
||||||
|
$$REPORT_PATH/scripteditor/lrcodeeditor.h \
|
||||||
|
$$REPORT_PATH/scripteditor/lrscripthighlighter.h \
|
||||||
|
$$REPORT_PATH/items/editors/lritemeditorwidget.h \
|
||||||
|
$$REPORT_PATH/items/editors/lrfonteditorwidget.h \
|
||||||
|
$$REPORT_PATH/items/editors/lrtextalignmenteditorwidget.h \
|
||||||
|
$$REPORT_PATH/items/editors/lritemsaligneditorwidget.h \
|
||||||
|
$$REPORT_PATH/items/editors/lritemsborderseditorwidget.h \
|
||||||
|
$$REPORT_PATH/items/lrtextitem.h \
|
||||||
|
$$REPORT_PATH/items/lrhorizontallayout.h \
|
||||||
|
$$REPORT_PATH/items/lrtextitemeditor.h \
|
||||||
|
$$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 \
|
||||||
|
$$REPORT_PATH/lrglobal.h \
|
||||||
|
$$REPORT_PATH/lrdatadesignintf.h \
|
||||||
|
$$REPORT_PATH/lrcollection.h \
|
||||||
|
$$REPORT_PATH/lrpagedesignintf.h \
|
||||||
|
$$REPORT_PATH/lrdatasourcemanager.h \
|
||||||
|
$$REPORT_PATH/lrreportrender.h \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwindow.h \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwidget.h \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwidget_p.h \
|
||||||
|
$$REPORT_PATH/lrgraphicsviewzoom.h \
|
||||||
|
$$REPORT_PATH/lrbasedesignintf.h \
|
||||||
|
$$REPORT_PATH/lritemdesignintf.h \
|
||||||
|
$$REPORT_PATH/lrdesignelementsfactory.h \
|
||||||
|
$$REPORT_PATH/lrscriptenginemanager.h \
|
||||||
|
$$REPORT_PATH/lrvariablesholder.h \
|
||||||
|
$$REPORT_PATH/lrgroupfunctions.h \
|
||||||
|
$$REPORT_PATH/lrdatasourcemanagerintf.h \
|
||||||
|
$$REPORT_PATH/lrscriptenginemanagerintf.h \
|
||||||
|
$$REPORT_PATH/lrsimplecrypt.h \
|
||||||
|
$$REPORT_PATH/lraboutdialog.h \
|
||||||
|
$$REPORT_PATH/lrcallbackdatasourceintf.h \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwidget_p.h \
|
||||||
|
$$REPORT_PATH/lritemscontainerdesignitf.h \
|
||||||
|
$$REPORT_PATH/lrcolorindicator.h \
|
||||||
|
$$REPORT_PATH/items/lrchartitem.h \
|
||||||
|
$$REPORT_PATH/lrreporttranslation.h
|
||||||
|
# $$PWD/limerender.h \
|
||||||
|
# $$PWD/limerender_p.h
|
||||||
|
|
||||||
|
contains(CONFIG, staticlib){
|
||||||
|
HEADERS += $$REPORT_PATH/lrfactoryinitializer.h
|
||||||
|
}
|
||||||
|
|
||||||
|
contains(CONFIG,zint){
|
||||||
|
HEADERS += $$REPORT_PATH/items/lrbarcodeitem.h
|
||||||
|
}
|
||||||
|
|
||||||
|
FORMS += \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwindow.ui \
|
||||||
|
$$REPORT_PATH/lrpreviewreportwidget.ui \
|
||||||
|
$$REPORT_PATH/items/lrtextitemeditor.ui \
|
||||||
|
$$REPORT_PATH/lraboutdialog.ui \
|
||||||
|
$$REPORT_PATH/scripteditor/lrscripteditor.ui
|
||||||
|
|
||||||
|
RESOURCES += \
|
||||||
|
$$REPORT_PATH/report.qrc \
|
||||||
|
$$REPORT_PATH/items/items.qrc
|
||||||
|
|
124
limerender/limerender.pro
Normal file
124
limerender/limerender.pro
Normal file
@ -0,0 +1,124 @@
|
|||||||
|
contains(CONFIG,release) {
|
||||||
|
TARGET = limerender
|
||||||
|
} else {
|
||||||
|
TARGET = limerenderd
|
||||||
|
}
|
||||||
|
|
||||||
|
TEMPLATE = lib
|
||||||
|
|
||||||
|
contains(CONFIG, static_build){
|
||||||
|
CONFIG += staticlib
|
||||||
|
}
|
||||||
|
|
||||||
|
!contains(CONFIG, staticlib){
|
||||||
|
CONFIG += lib
|
||||||
|
CONFIG += dll
|
||||||
|
}
|
||||||
|
|
||||||
|
CONFIG += create_prl
|
||||||
|
CONFIG += link_prl
|
||||||
|
|
||||||
|
macx{
|
||||||
|
CONFIG -= dll
|
||||||
|
CONFIG += lib_bundle
|
||||||
|
CONFIG += plugin
|
||||||
|
}
|
||||||
|
|
||||||
|
DEFINES += LIMEREPORT_EXPORTS
|
||||||
|
|
||||||
|
contains(CONFIG, staticlib){
|
||||||
|
DEFINES += HAVE_STATIC_BUILD
|
||||||
|
message(STATIC_BUILD)
|
||||||
|
DEFINES -= LIMEREPORT_EXPORTS
|
||||||
|
}
|
||||||
|
|
||||||
|
EXTRA_FILES += \
|
||||||
|
$$PWD/../limereport/lrglobal.cpp \
|
||||||
|
$$PWD/../limereport/lrglobal.h \
|
||||||
|
$$PWD/../limereport/lrdatasourcemanagerintf.h \
|
||||||
|
$$PWD/../limereport/lrreportengine.h \
|
||||||
|
$$PWD/../limereport/lrscriptenginemanagerintf.h \
|
||||||
|
$$PWD/../limereport/lrcallbackdatasourceintf.h \
|
||||||
|
$$PWD/../limereport/lrpreviewreportwidget.h
|
||||||
|
|
||||||
|
include(limerender.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/
|
||||||
|
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
|
||||||
|
}
|
||||||
|
}
|
||||||
|
macx{
|
||||||
|
for(FILE,EXTRA_FILES){
|
||||||
|
QMAKE_POST_LINK += $$QMAKE_COPY $$quote($$FILE) $$quote($${DEST_INCLUDE_DIR}) $$escape_expand(\\n\\t)
|
||||||
|
}
|
||||||
|
QMAKE_POST_LINK += mkdir -p $$quote($${DESTDIR}/include) $$escape_expand(\\n\\t)
|
||||||
|
}
|
||||||
|
QMAKE_POST_LINK += $$QMAKE_COPY_DIR $$quote($${DEST_INCLUDE_DIR}) $$quote($${DESTDIR})
|
||||||
|
}
|
||||||
|
|
||||||
|
win32 {
|
||||||
|
EXTRA_FILES ~= s,/,\\,g
|
||||||
|
BUILD_DIR ~= s,/,\\,g
|
||||||
|
DESTDIR = $${DEST_LIBS}
|
||||||
|
DEST_DIR = $$DESTDIR/include
|
||||||
|
DEST_DIR ~= s,/,\\,g
|
||||||
|
DEST_INCLUDE_DIR ~= s,/,\\,g
|
||||||
|
|
||||||
|
for(FILE,EXTRA_FILES){
|
||||||
|
QMAKE_POST_LINK += $$QMAKE_COPY \"$$FILE\" \"$${DEST_INCLUDE_DIR}\" $$escape_expand(\\n\\t)
|
||||||
|
}
|
||||||
|
QMAKE_POST_LINK += $$QMAKE_COPY_DIR \"$${DEST_INCLUDE_DIR}\" \"$${DEST_DIR}\"
|
||||||
|
}
|
||||||
|
|
||||||
|
contains(CONFIG,zint){
|
||||||
|
message(zint)
|
||||||
|
INCLUDEPATH += $$ZINT_PATH/backend $$ZINT_PATH/backend_qt
|
||||||
|
DEPENDPATH += $$ZINT_PATH/backend $$ZINT_PATH/backend_qt
|
||||||
|
LIBS += -L$${DEST_LIBS}
|
||||||
|
contains(CONFIG,release) {
|
||||||
|
LIBS += -lQtZint
|
||||||
|
} else {
|
||||||
|
LIBS += -lQtZintd
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
####Automatically build required translation files (*.qm)
|
||||||
|
|
||||||
|
contains(CONFIG,build_translations){
|
||||||
|
LANGUAGES = ru es_ES ar
|
||||||
|
|
||||||
|
defineReplace(prependAll) {
|
||||||
|
for(a,$$1):result += $$2$${a}$$3
|
||||||
|
return($$result)
|
||||||
|
}
|
||||||
|
|
||||||
|
TRANSLATIONS = $$prependAll(LANGUAGES, \"$$TRANSLATIONS_PATH/limereport_,.ts\")
|
||||||
|
|
||||||
|
qtPrepareTool(LUPDATE, lupdate)
|
||||||
|
|
||||||
|
greaterThan(QT_MAJOR_VERSION, 4) {
|
||||||
|
ts.commands = $$LUPDATE $$shell_quote($$PWD) -ts $$TRANSLATIONS
|
||||||
|
}
|
||||||
|
lessThan(QT_MAJOR_VERSION, 5){
|
||||||
|
ts.commands = $$LUPDATE $$quote($$PWD) -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
|
||||||
|
OTHER_FILES += $$TRANSLATIONS
|
||||||
|
QMAKE_EXTRA_TARGETS += qm ts
|
||||||
|
POST_TARGETDEPS += qm
|
||||||
|
}
|
||||||
|
|
||||||
|
#### EN AUTOMATIC TRANSLATIONS
|
192
limerender/limerender_p.h
Normal file
192
limerender/limerender_p.h
Normal file
@ -0,0 +1,192 @@
|
|||||||
|
/***************************************************************************
|
||||||
|
* This file is part of the Lime Report project *
|
||||||
|
* Copyright (C) 2015 by Alexander Arin *
|
||||||
|
* arin_a@bk.ru *
|
||||||
|
* *
|
||||||
|
** GNU General Public License Usage **
|
||||||
|
* *
|
||||||
|
* This library is free software: you can redistribute it and/or modify *
|
||||||
|
* it under the terms of the GNU General Public License as published by *
|
||||||
|
* the Free Software Foundation, either version 3 of the License, or *
|
||||||
|
* (at your option) any later version. *
|
||||||
|
* You should have received a copy of the GNU General Public License *
|
||||||
|
* along with this program. If not, see <http://www.gnu.org/licenses/>. *
|
||||||
|
* *
|
||||||
|
** GNU Lesser General Public License **
|
||||||
|
* *
|
||||||
|
* This library is free software: you can redistribute it and/or modify *
|
||||||
|
* it under the terms of the GNU Lesser General Public License as *
|
||||||
|
* published by the Free Software Foundation, either version 3 of the *
|
||||||
|
* License, or (at your option) any later version. *
|
||||||
|
* You should have received a copy of the GNU Lesser General Public *
|
||||||
|
* License along with this library. *
|
||||||
|
* If not, see <http://www.gnu.org/licenses/>. *
|
||||||
|
* *
|
||||||
|
* 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. See the *
|
||||||
|
* GNU General Public License for more details. *
|
||||||
|
****************************************************************************/
|
||||||
|
#ifndef LRLIMERENDER_P_H
|
||||||
|
#define LRLIMERENDER_P_H
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
#include <QSharedPointer>
|
||||||
|
#include <QMainWindow>
|
||||||
|
|
||||||
|
#include "limerender.h"
|
||||||
|
#include "lrcollection.h"
|
||||||
|
#include "lrglobal.h"
|
||||||
|
#include "lrdatasourcemanager.h"
|
||||||
|
#include "lrbanddesignintf.h"
|
||||||
|
#include "serializators/lrstorageintf.h"
|
||||||
|
#include "lrscriptenginemanager.h"
|
||||||
|
#include "lrreporttranslation.h"
|
||||||
|
|
||||||
|
class QFileSystemWatcher;
|
||||||
|
|
||||||
|
namespace LimeReport{
|
||||||
|
|
||||||
|
class PageDesignIntf;
|
||||||
|
class PrintRange;
|
||||||
|
class ReportDesignWindow;
|
||||||
|
|
||||||
|
//TODO: Add on render callback
|
||||||
|
|
||||||
|
class LimeRenderPrivate : public QObject, public ICollectionContainer, public ITranslationContainer
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
Q_DECLARE_PUBLIC(ReportEngine)
|
||||||
|
Q_PROPERTY(ACollectionProperty pages READ fakeCollectionReader())
|
||||||
|
Q_PROPERTY(QObject* datasourcesManager READ dataManager)
|
||||||
|
Q_PROPERTY(QObject* scriptContext READ scriptContext)
|
||||||
|
Q_PROPERTY(bool suppressFieldAndVarError READ suppressFieldAndVarError WRITE setSuppressFieldAndVarError)
|
||||||
|
Q_PROPERTY(ATranslationProperty translation READ fakeTranslationReader)
|
||||||
|
friend class PreviewReportWidget;
|
||||||
|
public:
|
||||||
|
static void printReport(ItemsReaderIntf::Ptr reader, QPrinter &printer);
|
||||||
|
static void printReport(ReportPages pages, QPrinter &printer);
|
||||||
|
Q_INVOKABLE QStringList aviableReportTranslations();
|
||||||
|
Q_INVOKABLE void setReportTranslation(const QString& languageName);
|
||||||
|
public:
|
||||||
|
explicit LimeRenderPrivate(QObject *parent = 0);
|
||||||
|
virtual ~LimeRenderPrivate();
|
||||||
|
|
||||||
|
PageDesignIntf* appendPage(const QString& pageName="");
|
||||||
|
bool deletePage(PageDesignIntf *page);
|
||||||
|
PageDesignIntf* createPreviewPage();
|
||||||
|
PageDesignIntf* pageAt(int index){return (index<=(m_pages.count()-1)) ? m_pages.at(index):0;}
|
||||||
|
int pageCount() {return m_pages.count();}
|
||||||
|
DataSourceManager* dataManager(){return m_datasources;}
|
||||||
|
ScriptEngineContext* scriptContext(){return m_scriptEngineContext;}
|
||||||
|
ScriptEngineManager* scriptManager();
|
||||||
|
IDataSourceManager* dataManagerIntf(){return m_datasources;}
|
||||||
|
|
||||||
|
IScriptEngineManager* scriptManagerIntf(){
|
||||||
|
ScriptEngineManager::instance().setDataManager(dataManager());
|
||||||
|
return &ScriptEngineManager::instance();
|
||||||
|
}
|
||||||
|
|
||||||
|
void clearReport();
|
||||||
|
bool printReport(QPrinter *printer=0);
|
||||||
|
bool printPages(ReportPages pages, QPrinter *printer);
|
||||||
|
void printToFile(const QString& fileName);
|
||||||
|
bool printToPDF(const QString& fileName);
|
||||||
|
void previewReport(PreviewHints hints = PreviewBarsUserSetting);
|
||||||
|
void setSettings(QSettings* value);
|
||||||
|
QSettings* settings();
|
||||||
|
bool loadFromFile(const QString& fileName, bool autoLoadPreviewOnChange);
|
||||||
|
bool loadFromByteArray(QByteArray *data, const QString& name = "");
|
||||||
|
bool loadFromString(const QString& report, const QString& name = "");
|
||||||
|
QString lastError();
|
||||||
|
ReportEngine * q_ptr;
|
||||||
|
bool emitLoadReport();
|
||||||
|
bool hasActivePreview(){return m_activePreview;}
|
||||||
|
PageDesignIntf *createPreviewScene(QObject *parent);
|
||||||
|
PreviewReportWidget *createPreviewWidget(QWidget *parent);
|
||||||
|
QIcon previewWindowIcon() const;
|
||||||
|
void setPreviewWindowIcon(const QIcon &previewWindowIcon);
|
||||||
|
QString previewWindowTitle() const;
|
||||||
|
void setPreviewWindowTitle(const QString &previewWindowTitle);
|
||||||
|
|
||||||
|
bool suppressFieldAndVarError() const;
|
||||||
|
void setSuppressFieldAndVarError(bool suppressFieldAndVarError);
|
||||||
|
bool isBusy();
|
||||||
|
bool resultIsEditable() const;
|
||||||
|
void setResultEditable(bool value);
|
||||||
|
|
||||||
|
void setPassPhrase(const QString &passPhrase);
|
||||||
|
bool addTranslationLanguage(QLocale::Language language);
|
||||||
|
bool removeTranslationLanguage(QLocale::Language language);
|
||||||
|
bool setReportLanguage(QLocale::Language language);
|
||||||
|
QList<QLocale::Language> aviableLanguages();
|
||||||
|
ReportTranslation* reportTranslation(QLocale::Language language);
|
||||||
|
void reorderPages(const QList<PageDesignIntf *> &reorderedPages);
|
||||||
|
void clearSelection();
|
||||||
|
Qt::LayoutDirection previewLayoutDirection();
|
||||||
|
void setPreviewLayoutDirection(const Qt::LayoutDirection& previewLayoutDirection);
|
||||||
|
signals:
|
||||||
|
void pagesLoadFinished();
|
||||||
|
void datasourceCollectionLoadFinished(const QString& collectionName);
|
||||||
|
void cleared();
|
||||||
|
void renderStarted();
|
||||||
|
void renderFinished();
|
||||||
|
void renderPageFinished(int renderedPageCount);
|
||||||
|
void onLoad(bool& loaded);
|
||||||
|
public slots:
|
||||||
|
bool slotLoadFromFile(const QString& fileName);
|
||||||
|
void cancelRender();
|
||||||
|
protected:
|
||||||
|
PageDesignIntf* createPage(const QString& pageName="");
|
||||||
|
protected slots:
|
||||||
|
void slotDataSourceCollectionLoaded(const QString& collectionName);
|
||||||
|
private slots:
|
||||||
|
void slotPreviewWindowDestroyed(QObject *window);
|
||||||
|
private:
|
||||||
|
//ICollectionContainer
|
||||||
|
virtual QObject* createElement(const QString&,const QString&);
|
||||||
|
virtual int elementsCount(const QString&);
|
||||||
|
virtual QObject* elementAt(const QString&, int index);
|
||||||
|
virtual void collectionLoadFinished(const QString&);
|
||||||
|
void saveError(QString message);
|
||||||
|
void showError(QString message);
|
||||||
|
//ICollectionContainer
|
||||||
|
//ITranslationContainer
|
||||||
|
Translations* translations(){ return &m_translations;}
|
||||||
|
void updateTranslations();
|
||||||
|
//ITranslationContainer
|
||||||
|
ReportPages renderToPages();
|
||||||
|
QString renderToString();
|
||||||
|
PageDesignIntf* getPageByName(const QString& pageName);
|
||||||
|
ATranslationProperty fakeTranslationReader(){ return ATranslationProperty();}
|
||||||
|
private:
|
||||||
|
QList<PageDesignIntf*> m_pages;
|
||||||
|
DataSourceManager* m_datasources;
|
||||||
|
ScriptEngineContext* m_scriptEngineContext;
|
||||||
|
ReportRender::Ptr m_reportRender;
|
||||||
|
QString m_fileName;
|
||||||
|
QString m_lastError;
|
||||||
|
QSettings* m_settings;
|
||||||
|
bool m_ownedSettings;
|
||||||
|
QScopedPointer<QPrinter> m_printer;
|
||||||
|
bool m_printerSelected;
|
||||||
|
bool m_showProgressDialog;
|
||||||
|
QString m_reportsDir;
|
||||||
|
QString m_reportName;
|
||||||
|
QMainWindow* m_activePreview;
|
||||||
|
QIcon m_previewWindowIcon;
|
||||||
|
QString m_previewWindowTitle;
|
||||||
|
QPointer<ReportDesignWindow> m_designerWindow;
|
||||||
|
ReportSettings m_reportSettings;
|
||||||
|
bool m_LimeRendering;
|
||||||
|
bool m_resultIsEditable;
|
||||||
|
QString m_passPhrase;
|
||||||
|
QFileSystemWatcher *m_fileWatcher;
|
||||||
|
Translations m_translations;
|
||||||
|
QLocale::Language m_reportLanguage;
|
||||||
|
void activateLanguage(QLocale::Language language);
|
||||||
|
Qt::LayoutDirection m_previewLayoutDirection;
|
||||||
|
};
|
||||||
|
|
||||||
|
}
|
||||||
|
#endif // LRLIMERENDER_P_H
|
1104
limerender/lrreportrender.cpp
Normal file
1104
limerender/lrreportrender.cpp
Normal file
File diff suppressed because it is too large
Load Diff
@ -15,7 +15,7 @@ SUBDIRS += \
|
|||||||
|
|
||||||
CONFIG += ordered
|
CONFIG += ordered
|
||||||
|
|
||||||
SUBDIRS += demo_r1 demo_r2 designer
|
SUBDIRS += demo_r1 demo_r2 designer designer_plugin
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -31,23 +31,31 @@
|
|||||||
|
|
||||||
namespace LimeReport{
|
namespace LimeReport{
|
||||||
|
|
||||||
FontEditorWidget::FontEditorWidget(ReportDesignWidget *reportEditor, const QString &title, QWidget *parent)
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
: ItemEditorWidget(reportEditor,title,parent), m_ignoreSlots(false) {
|
//FontEditorWidget::FontEditorWidget(ReportDesignWidget *reportEditor, const QString &title, QWidget *parent)
|
||||||
initEditor();
|
// : ItemEditorWidget(reportEditor,title,parent), m_ignoreSlots(false) {
|
||||||
}
|
// initEditor();
|
||||||
|
//}
|
||||||
|
|
||||||
FontEditorWidget::FontEditorWidget(ReportDesignWidget *reportEditor, QWidget *parent)
|
//FontEditorWidget::FontEditorWidget(ReportDesignWidget *reportEditor, QWidget *parent)
|
||||||
:ItemEditorWidget(reportEditor,parent), m_ignoreSlots(false) {
|
// :ItemEditorWidget(reportEditor,parent), m_ignoreSlots(false) {
|
||||||
initEditor();
|
// initEditor();
|
||||||
}
|
//}
|
||||||
|
//#endif
|
||||||
|
|
||||||
FontEditorWidget::FontEditorWidget(PageDesignIntf *page, const QString &title, QWidget *parent)
|
//FontEditorWidget::FontEditorWidget(PageDesignIntf *page, const QString &title, QWidget *parent)
|
||||||
:ItemEditorWidget(page,title,parent), m_ignoreSlots(false) {
|
// :ItemEditorWidget(page,title,parent), m_ignoreSlots(false) {
|
||||||
initEditor();
|
// initEditor();
|
||||||
}
|
//}
|
||||||
|
|
||||||
FontEditorWidget::FontEditorWidget(LimeReport::PageDesignIntf *page, QWidget *parent)
|
//FontEditorWidget::FontEditorWidget(LimeReport::PageDesignIntf *page, QWidget *parent)
|
||||||
:ItemEditorWidget(page,parent), m_ignoreSlots(false){
|
// :ItemEditorWidget(page,parent), m_ignoreSlots(false){
|
||||||
|
// initEditor();
|
||||||
|
//}
|
||||||
|
|
||||||
|
FontEditorWidget::FontEditorWidget(const QString& title, QWidget* parent)
|
||||||
|
:ItemEditorWidget(title, parent), m_ignoreSlots(false)
|
||||||
|
{
|
||||||
initEditor();
|
initEditor();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -101,10 +109,13 @@ void FontEditorWidget::initEditor()
|
|||||||
connect(m_fontUnderline,SIGNAL(toggled(bool)),this,SLOT(slotFontAttribsChanged(bool)));
|
connect(m_fontUnderline,SIGNAL(toggled(bool)),this,SLOT(slotFontAttribsChanged(bool)));
|
||||||
addAction(m_fontUnderline);
|
addAction(m_fontUnderline);
|
||||||
|
|
||||||
if (reportEditor()){
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
connect(reportEditor(),SIGNAL(itemPropertyChanged(QString,QString,QVariant,QVariant)),
|
// if (reportEditor()){
|
||||||
this,SLOT(slotPropertyChanged(QString,QString,QVariant,QVariant)));
|
// connect(reportEditor(),SIGNAL(itemPropertyChanged(QString,QString,QVariant,QVariant)),
|
||||||
}
|
// this,SLOT(slotPropertyChanged(QString,QString,QVariant,QVariant)));
|
||||||
|
// }
|
||||||
|
//#endif
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void FontEditorWidget::updateValues(const QFont& font)
|
void FontEditorWidget::updateValues(const QFont& font)
|
||||||
@ -118,34 +129,41 @@ void FontEditorWidget::updateValues(const QFont& font)
|
|||||||
m_ignoreSlots=false;
|
m_ignoreSlots=false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool FontEditorWidget::ignoreSlots() const
|
||||||
|
{
|
||||||
|
return m_ignoreSlots;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void FontEditorWidget::slotFontChanged(const QFont &font)
|
void FontEditorWidget::slotFontChanged(const QFont &font)
|
||||||
{
|
{
|
||||||
if (reportEditor() && !m_ignoreSlots) reportEditor()->setFont(font);
|
// if (page()) page()->setFont(font);
|
||||||
if (page()) page()->setFont(font);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void FontEditorWidget::slotFontSizeChanged(const QString &value)
|
void FontEditorWidget::slotFontSizeChanged(const QString &value)
|
||||||
{
|
{
|
||||||
if (m_ignoreSlots) return;
|
if (m_ignoreSlots) return;
|
||||||
|
|
||||||
QFont resFont(fontNameEditor()->currentFont());
|
m_resFont = fontNameEditor()->currentFont();
|
||||||
resFont.setPointSize(value.toInt());
|
m_resFont.setPointSize(value.toInt());
|
||||||
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
if (reportEditor()) reportEditor()->setFont(resFont);
|
// if (reportEditor()) reportEditor()->setFont(resFont);
|
||||||
if (page()) page()->setFont(resFont);
|
//#endif
|
||||||
|
// if (page()) page()->setFont(resFont);
|
||||||
}
|
}
|
||||||
|
|
||||||
void FontEditorWidget::slotFontAttribsChanged(bool)
|
void FontEditorWidget::slotFontAttribsChanged(bool)
|
||||||
{
|
{
|
||||||
if (m_ignoreSlots) return;
|
if (m_ignoreSlots) return;
|
||||||
|
|
||||||
QFont resFont(m_fontNameEditor->currentFont());
|
m_resFont = m_fontNameEditor->currentFont();
|
||||||
resFont.setBold(m_fontBold->isChecked());
|
m_resFont.setBold(m_fontBold->isChecked());
|
||||||
resFont.setItalic(m_fontItalic->isChecked());
|
m_resFont.setItalic(m_fontItalic->isChecked());
|
||||||
resFont.setUnderline(m_fontUnderline->isChecked());
|
m_resFont.setUnderline(m_fontUnderline->isChecked());
|
||||||
if (reportEditor()) reportEditor()->setFont(resFont);
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
if (page()) page()->setFont(resFont);
|
// if (reportEditor()) reportEditor()->setFont(resFont);
|
||||||
|
//#endif
|
||||||
|
// if (page()) page()->setFont(resFont);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -159,4 +177,49 @@ void FontEditorWidget::slotPropertyChanged(const QString &objectName, const QStr
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void FontEditorWidgetForPage::slotFontChanged(const QFont& font)
|
||||||
|
{
|
||||||
|
m_page->setFont(font);
|
||||||
|
}
|
||||||
|
|
||||||
|
void FontEditorWidgetForPage::slotFontSizeChanged(const QString& value)
|
||||||
|
{
|
||||||
|
FontEditorWidget::slotFontSizeChanged(value);
|
||||||
|
m_page->setFont(resFont());
|
||||||
|
}
|
||||||
|
|
||||||
|
void FontEditorWidgetForPage::slotFontAttribsChanged(bool value)
|
||||||
|
{
|
||||||
|
FontEditorWidget::slotFontAttribsChanged(value);
|
||||||
|
m_page->setFont(resFont());
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef IS_REPORT_DESIGNER
|
||||||
|
void FontEditorWidgetForDesigner::initEditor()
|
||||||
|
{
|
||||||
|
FontEditorWidget::initEditor();
|
||||||
|
connect(m_reportEditor,SIGNAL(itemPropertyChanged(QString,QString,QVariant,QVariant)),
|
||||||
|
this,SLOT(slotPropertyChanged(QString,QString,QVariant,QVariant)));
|
||||||
|
}
|
||||||
|
|
||||||
|
void FontEditorWidgetForDesigner::slotFontChanged(const QFont& font)
|
||||||
|
{
|
||||||
|
if (!ignoreSlots()) m_reportEditor->setFont(font);
|
||||||
|
}
|
||||||
|
|
||||||
|
void FontEditorWidgetForDesigner::slotFontSizeChanged(const QString& value)
|
||||||
|
{
|
||||||
|
FontEditorWidget::slotFontSizeChanged(value);
|
||||||
|
m_reportEditor->setFont(resFont());
|
||||||
|
}
|
||||||
|
|
||||||
|
void FontEditorWidgetForDesigner::slotFontAttribsChanged(bool value)
|
||||||
|
{
|
||||||
|
FontEditorWidget::slotFontAttribsChanged(value);
|
||||||
|
m_reportEditor->setFont(resFont());
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
} //namespace LimeReport
|
} //namespace LimeReport
|
||||||
|
@ -35,7 +35,10 @@
|
|||||||
#include <QStringListModel>
|
#include <QStringListModel>
|
||||||
#include <QAction>
|
#include <QAction>
|
||||||
|
|
||||||
|
#ifdef IS_REPORT_DESIGNER
|
||||||
#include "lrreportdesignwidget.h"
|
#include "lrreportdesignwidget.h"
|
||||||
|
#endif
|
||||||
|
|
||||||
#include "lritemeditorwidget.h"
|
#include "lritemeditorwidget.h"
|
||||||
|
|
||||||
namespace LimeReport{
|
namespace LimeReport{
|
||||||
@ -43,20 +46,27 @@ namespace LimeReport{
|
|||||||
class FontEditorWidget :public ItemEditorWidget{
|
class FontEditorWidget :public ItemEditorWidget{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
explicit FontEditorWidget(ReportDesignWidget* reportEditor, const QString &title, QWidget *parent = 0);
|
explicit FontEditorWidget(const QString &title, QWidget *parent = 0);
|
||||||
explicit FontEditorWidget(ReportDesignWidget* reportEditor, QWidget *parent = 0);
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
explicit FontEditorWidget(PageDesignIntf* page, const QString &title, QWidget *parent = 0);
|
// explicit FontEditorWidget(ReportDesignWidget* reportEditor, const QString &title, QWidget *parent = 0);
|
||||||
explicit FontEditorWidget(PageDesignIntf* page, QWidget *parent = 0);
|
// explicit FontEditorWidget(ReportDesignWidget* reportEditor, QWidget *parent = 0);
|
||||||
|
//#endif
|
||||||
|
// explicit FontEditorWidget(PageDesignIntf* page, const QString &title, QWidget *parent = 0);
|
||||||
|
// explicit FontEditorWidget(PageDesignIntf* page, QWidget *parent = 0);
|
||||||
|
bool ignoreSlots() const;
|
||||||
protected:
|
protected:
|
||||||
void setItemEvent(BaseDesignIntf *item);
|
void setItemEvent(BaseDesignIntf *item);
|
||||||
QFontComboBox* fontNameEditor(){return m_fontNameEditor;}
|
QFontComboBox* fontNameEditor(){return m_fontNameEditor;}
|
||||||
private slots:
|
virtual void initEditor();
|
||||||
void slotFontChanged(const QFont& font);
|
protected slots:
|
||||||
void slotFontSizeChanged(const QString& value);
|
virtual void slotFontChanged(const QFont& font);
|
||||||
void slotFontAttribsChanged(bool);
|
virtual void slotFontSizeChanged(const QString& value);
|
||||||
|
virtual void slotFontAttribsChanged(bool);
|
||||||
void slotPropertyChanged(const QString& objectName, const QString& property, const QVariant &oldValue, const QVariant &newValue);
|
void slotPropertyChanged(const QString& objectName, const QString& property, const QVariant &oldValue, const QVariant &newValue);
|
||||||
|
protected:
|
||||||
|
QFont resFont(){return m_resFont;}
|
||||||
private:
|
private:
|
||||||
void initEditor();
|
|
||||||
void updateValues(const QFont &font);
|
void updateValues(const QFont &font);
|
||||||
|
|
||||||
QFontComboBox* m_fontNameEditor;
|
QFontComboBox* m_fontNameEditor;
|
||||||
@ -68,9 +78,41 @@ private:
|
|||||||
QAction* m_fontUnderline;
|
QAction* m_fontUnderline;
|
||||||
|
|
||||||
bool m_ignoreSlots;
|
bool m_ignoreSlots;
|
||||||
|
QFont m_resFont;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
class FontEditorWidgetForPage : public FontEditorWidget{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
explicit FontEditorWidgetForPage(PageDesignIntf* page, const QString &title, QWidget *parent = 0)
|
||||||
|
: FontEditorWidget(title, parent), m_page(page){}
|
||||||
|
protected slots:
|
||||||
|
virtual void slotFontChanged(const QFont& font);
|
||||||
|
virtual void slotFontSizeChanged(const QString& value);
|
||||||
|
virtual void slotFontAttribsChanged(bool value);
|
||||||
|
private:
|
||||||
|
PageDesignIntf* m_page;
|
||||||
|
};
|
||||||
|
|
||||||
|
#ifdef IS_REPORT_DESIGNER
|
||||||
|
class FontEditorWidgetForDesigner : public FontEditorWidget{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
explicit FontEditorWidgetForDesigner(ReportDesignWidget* reportEditor, const QString &title, QWidget *parent = 0)
|
||||||
|
: FontEditorWidget(title, parent), m_reportEditor(reportEditor){}
|
||||||
|
|
||||||
|
protected:
|
||||||
|
void initEditor();
|
||||||
|
protected slots:
|
||||||
|
virtual void slotFontChanged(const QFont& font);
|
||||||
|
virtual void slotFontSizeChanged(const QString& value);
|
||||||
|
virtual void slotFontAttribsChanged(bool value);
|
||||||
|
private:
|
||||||
|
ReportDesignWidget* m_reportEditor;
|
||||||
|
};
|
||||||
|
#endif
|
||||||
|
|
||||||
} //namespace LimeReport
|
} //namespace LimeReport
|
||||||
|
|
||||||
#endif // LRFONTEDITORWIDGET_H
|
#endif // LRFONTEDITORWIDGET_H
|
||||||
|
@ -31,25 +31,35 @@
|
|||||||
|
|
||||||
namespace LimeReport{
|
namespace LimeReport{
|
||||||
|
|
||||||
ItemEditorWidget::ItemEditorWidget(ReportDesignWidget* reportEditor, const QString& title, QWidget* parent)
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
:QToolBar(title,parent), m_reportEditor(reportEditor), m_item(0), m_page(0)
|
//ItemEditorWidget::ItemEditorWidget(ReportDesignWidget* reportEditor, const QString& title, QWidget* parent)
|
||||||
{
|
// :QToolBar(title,parent), m_reportEditor(reportEditor), m_item(0), m_page(0)
|
||||||
}
|
//{
|
||||||
|
//}
|
||||||
|
|
||||||
ItemEditorWidget::ItemEditorWidget(ReportDesignWidget* reportEditor, QWidget* parent)
|
//ItemEditorWidget::ItemEditorWidget(ReportDesignWidget* reportEditor, QWidget* parent)
|
||||||
:QToolBar(parent), m_reportEditor(reportEditor), m_item(0), m_page(0)
|
// :QToolBar(parent), m_reportEditor(reportEditor), m_item(0), m_page(0)
|
||||||
{
|
//{
|
||||||
}
|
//}
|
||||||
|
//#endif
|
||||||
|
|
||||||
ItemEditorWidget::ItemEditorWidget(PageDesignIntf* page, const QString& title, QWidget* parent)
|
//ItemEditorWidget::ItemEditorWidget(PageDesignIntf* page, const QString& title, QWidget* parent)
|
||||||
:QToolBar(title,parent), m_reportEditor(0), m_item(0), m_page(page)
|
// :QToolBar(title,parent),
|
||||||
{
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
}
|
// m_reportEditor(0),
|
||||||
|
//#endif
|
||||||
|
// m_item(0), m_page(page)
|
||||||
|
//{
|
||||||
|
//}
|
||||||
|
|
||||||
ItemEditorWidget::ItemEditorWidget(PageDesignIntf* page, QWidget* parent)
|
//ItemEditorWidget::ItemEditorWidget(PageDesignIntf* page, QWidget* parent)
|
||||||
:QToolBar(parent), m_reportEditor(0), m_item(0), m_page(page)
|
// :QToolBar(parent),
|
||||||
{
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
}
|
// m_reportEditor(0),
|
||||||
|
//#endif
|
||||||
|
// m_item(0), m_page(page)
|
||||||
|
//{
|
||||||
|
//}
|
||||||
|
|
||||||
void ItemEditorWidget::setItem(BaseDesignIntf* item)
|
void ItemEditorWidget::setItem(BaseDesignIntf* item)
|
||||||
{
|
{
|
||||||
|
@ -31,7 +31,11 @@
|
|||||||
#define LRITEMEDITORWIDGET_H
|
#define LRITEMEDITORWIDGET_H
|
||||||
|
|
||||||
#include <QToolBar>
|
#include <QToolBar>
|
||||||
|
|
||||||
|
#ifdef IS_REPORT_DESIGNER
|
||||||
#include "lrreportdesignwidget.h"
|
#include "lrreportdesignwidget.h"
|
||||||
|
#endif
|
||||||
|
#include "lrpagedesignintf.h"
|
||||||
|
|
||||||
namespace LimeReport {
|
namespace LimeReport {
|
||||||
|
|
||||||
@ -39,26 +43,35 @@ class ItemEditorWidget : public QToolBar
|
|||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
explicit ItemEditorWidget(ReportDesignWidget* reportEditor, const QString &title, QWidget *parent = 0);
|
explicit ItemEditorWidget(const QString &title, QWidget *parent = 0)
|
||||||
explicit ItemEditorWidget(ReportDesignWidget* reportEditor, QWidget *parent = 0);
|
: QToolBar(title, parent), m_item(0){}
|
||||||
explicit ItemEditorWidget(PageDesignIntf* page, const QString &title, QWidget *parent = 0);
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
explicit ItemEditorWidget(PageDesignIntf* page, QWidget *parent = 0);
|
// explicit ItemEditorWidget(ReportDesignWidget* reportEditor, const QString &title, QWidget *parent = 0);
|
||||||
|
// explicit ItemEditorWidget(ReportDesignWidget* reportEditor, QWidget *parent = 0);
|
||||||
|
//#endif
|
||||||
|
// explicit ItemEditorWidget(PageDesignIntf* page, const QString &title, QWidget *parent = 0);
|
||||||
|
// explicit ItemEditorWidget(PageDesignIntf* page, QWidget *parent = 0);
|
||||||
void setItem(BaseDesignIntf *item);
|
void setItem(BaseDesignIntf *item);
|
||||||
void setReportEditor(ReportDesignWidget* editor){m_reportEditor = editor;}
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
|
// void setReportEditor(ReportDesignWidget* editor){m_reportEditor = editor;}
|
||||||
|
//#endif
|
||||||
protected:
|
protected:
|
||||||
virtual void setItemEvent(BaseDesignIntf*){}
|
virtual void setItemEvent(BaseDesignIntf*){}
|
||||||
virtual void properyChangedEvent(const QString& propertName, const QVariant& oldValue, const QVariant& newValue);
|
virtual void properyChangedEvent(const QString& propertName, const QVariant& oldValue, const QVariant& newValue);
|
||||||
BaseDesignIntf* item(){return m_item;}
|
BaseDesignIntf* item(){return m_item;}
|
||||||
ReportDesignWidget* reportEditor(){return m_reportEditor;}
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
PageDesignIntf* page(){return m_page;}
|
// ReportDesignWidget* reportEditor(){return m_reportEditor;}
|
||||||
|
//#endif
|
||||||
|
// PageDesignIntf* page(){return m_page;}
|
||||||
private slots:
|
private slots:
|
||||||
void slotItemDestroyed(QObject* item);
|
void slotItemDestroyed(QObject* item);
|
||||||
void slotPropertyChanged(const QString& propertName, const QVariant& oldValue, const QVariant& newValue);
|
void slotPropertyChanged(const QString& propertName, const QVariant& oldValue, const QVariant& newValue);
|
||||||
private:
|
private:
|
||||||
ReportDesignWidget* m_reportEditor;
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
|
// ReportDesignWidget* m_reportEditor;
|
||||||
|
//#endif
|
||||||
BaseDesignIntf* m_item;
|
BaseDesignIntf* m_item;
|
||||||
PageDesignIntf* m_page;
|
// PageDesignIntf* m_page;
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace LimeReport
|
} // namespace LimeReport
|
||||||
|
@ -31,19 +31,19 @@
|
|||||||
#include <QAction>
|
#include <QAction>
|
||||||
|
|
||||||
namespace LimeReport{
|
namespace LimeReport{
|
||||||
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
|
//ItemsBordersEditorWidget::ItemsBordersEditorWidget(ReportDesignWidget* reportEditor, const QString& title, QWidget* parent)
|
||||||
|
// : ItemEditorWidget(reportEditor,title,parent), m_changing(false)
|
||||||
|
//{
|
||||||
|
// initEditor();
|
||||||
|
//}
|
||||||
|
|
||||||
ItemsBordersEditorWidget::ItemsBordersEditorWidget(ReportDesignWidget* reportEditor, const QString& title, QWidget* parent)
|
//ItemsBordersEditorWidget::ItemsBordersEditorWidget(ReportDesignWidget* reportEditor, QWidget* parent)
|
||||||
: ItemEditorWidget(reportEditor,title,parent), m_changing(false)
|
// : ItemEditorWidget(reportEditor,parent), m_changing(false)
|
||||||
{
|
//{
|
||||||
initEditor();
|
// initEditor();
|
||||||
}
|
//}
|
||||||
|
//#endif
|
||||||
ItemsBordersEditorWidget::ItemsBordersEditorWidget(ReportDesignWidget* reportEditor, QWidget* parent)
|
|
||||||
: ItemEditorWidget(reportEditor,parent), m_changing(false)
|
|
||||||
{
|
|
||||||
initEditor();
|
|
||||||
}
|
|
||||||
|
|
||||||
void ItemsBordersEditorWidget::setItemEvent(BaseDesignIntf* item)
|
void ItemsBordersEditorWidget::setItemEvent(BaseDesignIntf* item)
|
||||||
{
|
{
|
||||||
QVariant borders=item->property("borders");
|
QVariant borders=item->property("borders");
|
||||||
@ -65,8 +65,10 @@ void ItemsBordersEditorWidget::properyChangedEvent(const QString& property, cons
|
|||||||
|
|
||||||
void ItemsBordersEditorWidget::noBordesClicked()
|
void ItemsBordersEditorWidget::noBordesClicked()
|
||||||
{
|
{
|
||||||
if (reportEditor())
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
reportEditor()->setBorders(0);
|
// if (reportEditor())
|
||||||
|
// reportEditor()->setBorders(0);
|
||||||
|
//#endif
|
||||||
updateValues(0);
|
updateValues(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -78,14 +80,15 @@ void ItemsBordersEditorWidget::allBordesClicked()
|
|||||||
BaseDesignIntf::BottomLine;
|
BaseDesignIntf::BottomLine;
|
||||||
|
|
||||||
updateValues((BaseDesignIntf::BorderLines)borders);
|
updateValues((BaseDesignIntf::BorderLines)borders);
|
||||||
if (reportEditor())
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
reportEditor()->setBorders((BaseDesignIntf::BorderLines)borders);
|
// if (reportEditor())
|
||||||
|
// reportEditor()->setBorders((BaseDesignIntf::BorderLines)borders);
|
||||||
|
//#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void ItemsBordersEditorWidget::buttonClicked(bool)
|
void ItemsBordersEditorWidget::buttonClicked(bool)
|
||||||
{
|
{
|
||||||
if (!m_changing&&reportEditor())
|
|
||||||
reportEditor()->setBorders(createBorders());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void ItemsBordersEditorWidget::initEditor()
|
void ItemsBordersEditorWidget::initEditor()
|
||||||
@ -151,4 +154,29 @@ BaseDesignIntf::BorderLines ItemsBordersEditorWidget::createBorders()
|
|||||||
return (BaseDesignIntf::BorderLines)borders;
|
return (BaseDesignIntf::BorderLines)borders;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool ItemsBordersEditorWidget::changing() const
|
||||||
|
{
|
||||||
|
return m_changing;
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef IS_REPORT_DESIGNER
|
||||||
|
void ItemsBordersEditorWidgetForDesigner::buttonClicked(bool)
|
||||||
|
{
|
||||||
|
if (!changing())
|
||||||
|
m_reportEditor->setBorders(createBorders());
|
||||||
|
}
|
||||||
|
|
||||||
|
void ItemsBordersEditorWidgetForDesigner::noBordesClicked()
|
||||||
|
{
|
||||||
|
m_reportEditor->setBorders(0);
|
||||||
|
ItemsBordersEditorWidget::noBordesClicked();
|
||||||
|
}
|
||||||
|
|
||||||
|
void ItemsBordersEditorWidgetForDesigner::allBordesClicked()
|
||||||
|
{
|
||||||
|
ItemsBordersEditorWidget::allBordesClicked();
|
||||||
|
m_reportEditor->setBorders(createBorders());
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
} //namespace LimeReport
|
} //namespace LimeReport
|
||||||
|
@ -36,23 +36,32 @@
|
|||||||
|
|
||||||
namespace LimeReport{
|
namespace LimeReport{
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
class ItemsBordersEditorWidget : public ItemEditorWidget
|
class ItemsBordersEditorWidget : public ItemEditorWidget
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
explicit ItemsBordersEditorWidget(ReportDesignWidget* reportEditor, const QString &title, QWidget *parent = 0);
|
explicit ItemsBordersEditorWidget(const QString &title, QWidget *parent = 0)
|
||||||
explicit ItemsBordersEditorWidget(ReportDesignWidget* reportEditor, QWidget *parent = 0);
|
: ItemEditorWidget(title, parent), m_changing(false), m_borders(0){
|
||||||
private slots:
|
initEditor();
|
||||||
void noBordesClicked();
|
}
|
||||||
void allBordesClicked();
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
void buttonClicked(bool);
|
// explicit ItemsBordersEditorWidget(ReportDesignWidget* reportEditor, const QString &title, QWidget *parent = 0);
|
||||||
|
// explicit ItemsBordersEditorWidget(ReportDesignWidget* reportEditor, QWidget *parent = 0);
|
||||||
|
//#endif
|
||||||
|
bool changing() const;
|
||||||
|
protected slots:
|
||||||
|
virtual void noBordesClicked();
|
||||||
|
virtual void allBordesClicked();
|
||||||
|
virtual void buttonClicked(bool);
|
||||||
protected:
|
protected:
|
||||||
void setItemEvent(BaseDesignIntf *item);
|
void setItemEvent(BaseDesignIntf *item);
|
||||||
void properyChangedEvent(const QString &property, const QVariant &oldValue, const QVariant &newValue);
|
void properyChangedEvent(const QString &property, const QVariant &oldValue, const QVariant &newValue);
|
||||||
|
BaseDesignIntf::BorderLines createBorders();
|
||||||
private:
|
private:
|
||||||
void initEditor();
|
void initEditor();
|
||||||
void updateValues(BaseDesignIntf::BorderLines borders);
|
void updateValues(BaseDesignIntf::BorderLines borders);
|
||||||
BaseDesignIntf::BorderLines createBorders();
|
|
||||||
QAction* m_noLines;
|
QAction* m_noLines;
|
||||||
QAction* m_leftLine;
|
QAction* m_leftLine;
|
||||||
QAction* m_rightLine;
|
QAction* m_rightLine;
|
||||||
@ -60,8 +69,25 @@ private:
|
|||||||
QAction* m_bottomLine;
|
QAction* m_bottomLine;
|
||||||
QAction* m_allLines;
|
QAction* m_allLines;
|
||||||
bool m_changing;
|
bool m_changing;
|
||||||
|
int m_borders;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef IS_REPORT_DESIGNER
|
||||||
|
class ItemsBordersEditorWidgetForDesigner : public ItemsBordersEditorWidget{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
explicit ItemsBordersEditorWidgetForDesigner(ReportDesignWidget* reportEditor, const QString &title="", QWidget *parent = 0)
|
||||||
|
: ItemsBordersEditorWidget(title,parent), m_reportEditor(reportEditor){}
|
||||||
|
protected slots:
|
||||||
|
void buttonClicked(bool);
|
||||||
|
void noBordesClicked();
|
||||||
|
void allBordesClicked();
|
||||||
|
private:
|
||||||
|
ReportDesignWidget* m_reportEditor;
|
||||||
|
};
|
||||||
|
#endif
|
||||||
|
|
||||||
}//namespace LimeReport
|
}//namespace LimeReport
|
||||||
|
|
||||||
#endif // LRITEMSBORDERSEDITORWIDGET_H
|
#endif // LRITEMSBORDERSEDITORWIDGET_H
|
||||||
|
@ -30,30 +30,36 @@
|
|||||||
#include "lrtextalignmenteditorwidget.h"
|
#include "lrtextalignmenteditorwidget.h"
|
||||||
|
|
||||||
namespace LimeReport{
|
namespace LimeReport{
|
||||||
|
TextAlignmentEditorWidget::TextAlignmentEditorWidget(const QString& title, QWidget* parent)
|
||||||
TextAlignmentEditorWidget::TextAlignmentEditorWidget(ReportDesignWidget *reportEditor, const QString &title, QWidget *parent)
|
:ItemEditorWidget(title, parent), m_textAttibutesIsChanging(false), m_flag(0)
|
||||||
:ItemEditorWidget(reportEditor,title,parent), m_textAttibutesIsChanging(false)
|
|
||||||
{
|
{
|
||||||
initEditor();
|
initEditor();
|
||||||
}
|
}
|
||||||
|
|
||||||
TextAlignmentEditorWidget::TextAlignmentEditorWidget(ReportDesignWidget *reportEditor, QWidget *parent)
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
:ItemEditorWidget(reportEditor,parent), m_textAttibutesIsChanging(false)
|
//TextAlignmentEditorWidget::TextAlignmentEditorWidget(ReportDesignWidget *reportEditor, const QString &title, QWidget *parent)
|
||||||
{
|
// :ItemEditorWidget(reportEditor,title,parent), m_textAttibutesIsChanging(false)
|
||||||
initEditor();
|
//{
|
||||||
}
|
// initEditor();
|
||||||
|
//}
|
||||||
|
|
||||||
TextAlignmentEditorWidget::TextAlignmentEditorWidget(PageDesignIntf* page, const QString& title, QWidget* parent)
|
//TextAlignmentEditorWidget::TextAlignmentEditorWidget(ReportDesignWidget *reportEditor, QWidget *parent)
|
||||||
:ItemEditorWidget(page,title,parent), m_textAttibutesIsChanging(false)
|
// :ItemEditorWidget(reportEditor,parent), m_textAttibutesIsChanging(false)
|
||||||
{
|
//{
|
||||||
initEditor();
|
// initEditor();
|
||||||
}
|
//}
|
||||||
|
//#endif
|
||||||
|
//TextAlignmentEditorWidget::TextAlignmentEditorWidget(PageDesignIntf* page, const QString& title, QWidget* parent)
|
||||||
|
// :ItemEditorWidget(page,title,parent), m_textAttibutesIsChanging(false)
|
||||||
|
//{
|
||||||
|
// initEditor();
|
||||||
|
//}
|
||||||
|
|
||||||
TextAlignmentEditorWidget::TextAlignmentEditorWidget(PageDesignIntf* page, QWidget* parent)
|
//TextAlignmentEditorWidget::TextAlignmentEditorWidget(PageDesignIntf* page, QWidget* parent)
|
||||||
:ItemEditorWidget(page,parent), m_textAttibutesIsChanging(false)
|
// :ItemEditorWidget(page,parent), m_textAttibutesIsChanging(false)
|
||||||
{
|
//{
|
||||||
initEditor();
|
// initEditor();
|
||||||
}
|
//}
|
||||||
|
|
||||||
void TextAlignmentEditorWidget::setItemEvent(BaseDesignIntf *item)
|
void TextAlignmentEditorWidget::setItemEvent(BaseDesignIntf *item)
|
||||||
{
|
{
|
||||||
@ -109,21 +115,22 @@ void TextAlignmentEditorWidget::initEditor()
|
|||||||
m_textAliginBottom->setCheckable(true);
|
m_textAliginBottom->setCheckable(true);
|
||||||
connect(m_textAliginBottom,SIGNAL(toggled(bool)),this,SLOT(slotTextVAttribsChanged(bool)));
|
connect(m_textAliginBottom,SIGNAL(toggled(bool)),this,SLOT(slotTextVAttribsChanged(bool)));
|
||||||
addAction(m_textAliginBottom);
|
addAction(m_textAliginBottom);
|
||||||
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
if (reportEditor()){
|
// if (reportEditor()){
|
||||||
connect(reportEditor(),SIGNAL(itemPropertyChanged(QString,QString,QVariant,QVariant)),
|
// connect(reportEditor(),SIGNAL(itemPropertyChanged(QString,QString,QVariant,QVariant)),
|
||||||
this,SLOT(slotPropertyChanged(QString,QString,QVariant,QVariant)));
|
// this,SLOT(slotPropertyChanged(QString,QString,QVariant,QVariant)));
|
||||||
}
|
// }
|
||||||
if (page()){
|
//#endif
|
||||||
connect(page(),SIGNAL(itemPropertyChanged(QString,QString,QVariant,QVariant)),
|
// if (page()){
|
||||||
this,SLOT(slotPropertyChanged(QString,QString,QVariant,QVariant)));
|
// connect(page(),SIGNAL(itemPropertyChanged(QString,QString,QVariant,QVariant)),
|
||||||
}
|
// this,SLOT(slotPropertyChanged(QString,QString,QVariant,QVariant)));
|
||||||
|
// }
|
||||||
setEnabled(false);
|
setEnabled(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
void TextAlignmentEditorWidget::updateValues(const Qt::Alignment &align)
|
void TextAlignmentEditorWidget::updateValues(const Qt::Alignment &align)
|
||||||
{
|
{
|
||||||
m_textAttibutesIsChanging=true;
|
m_textAttibutesIsChanging=true;
|
||||||
m_textAliginLeft->setChecked((align & Qt::AlignLeft)==Qt::AlignLeft);
|
m_textAliginLeft->setChecked((align & Qt::AlignLeft)==Qt::AlignLeft);
|
||||||
m_textAliginRight->setChecked((align & Qt::AlignRight)==Qt::AlignRight);
|
m_textAliginRight->setChecked((align & Qt::AlignRight)==Qt::AlignRight);
|
||||||
m_textAliginHCenter->setChecked((align & Qt::AlignHCenter)==Qt::AlignHCenter);
|
m_textAliginHCenter->setChecked((align & Qt::AlignHCenter)==Qt::AlignHCenter);
|
||||||
@ -157,17 +164,18 @@ void TextAlignmentEditorWidget::slotTextHAttribsChanged(bool)
|
|||||||
m_textAliginRight->setChecked(sender()==m_textAliginRight);
|
m_textAliginRight->setChecked(sender()==m_textAliginRight);
|
||||||
m_textAliginJustify->setChecked(sender()==m_textAliginJustify);
|
m_textAliginJustify->setChecked(sender()==m_textAliginJustify);
|
||||||
|
|
||||||
int flag = 0;
|
m_flag = 0;
|
||||||
if (sender()==m_textAliginLeft) flag |= Qt::AlignLeft;
|
if (sender()==m_textAliginLeft) m_flag |= Qt::AlignLeft;
|
||||||
if (sender()==m_textAliginHCenter) flag |= Qt::AlignHCenter;
|
if (sender()==m_textAliginHCenter) m_flag |= Qt::AlignHCenter;
|
||||||
if (sender()==m_textAliginRight) flag |= Qt::AlignRight;
|
if (sender()==m_textAliginRight) m_flag |= Qt::AlignRight;
|
||||||
if (sender()==m_textAliginJustify) flag |= Qt::AlignJustify;
|
if (sender()==m_textAliginJustify) m_flag |= Qt::AlignJustify;
|
||||||
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
if (reportEditor()) reportEditor()->setTextAlign(true,Qt::AlignmentFlag(flag));
|
// if (reportEditor()) reportEditor()->setTextAlign(true,Qt::AlignmentFlag(flag));
|
||||||
if (page()) {
|
//#endif
|
||||||
//page()->setTextAlign(createAlignment());
|
// if (page()) {
|
||||||
page()->changeSelectedGrpoupTextAlignPropperty(true,Qt::AlignmentFlag(flag));
|
// //page()->setTextAlign(createAlignment());
|
||||||
}
|
// page()->changeSelectedGrpoupTextAlignPropperty(true,Qt::AlignmentFlag(flag));
|
||||||
|
// }
|
||||||
m_textAttibutesIsChanging = false;
|
m_textAttibutesIsChanging = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -180,13 +188,14 @@ void TextAlignmentEditorWidget::slotTextVAttribsChanged(bool)
|
|||||||
m_textAliginVCenter->setChecked(sender()==m_textAliginVCenter);
|
m_textAliginVCenter->setChecked(sender()==m_textAliginVCenter);
|
||||||
m_textAliginBottom->setChecked(sender()==m_textAliginBottom);
|
m_textAliginBottom->setChecked(sender()==m_textAliginBottom);
|
||||||
|
|
||||||
int flag = 0;
|
m_flag = 0;
|
||||||
if (sender()==m_textAliginTop) flag |= Qt::AlignTop;
|
if (sender()==m_textAliginTop) m_flag |= Qt::AlignTop;
|
||||||
if (sender()==m_textAliginVCenter) flag |= Qt::AlignVCenter;
|
if (sender()==m_textAliginVCenter) m_flag |= Qt::AlignVCenter;
|
||||||
if (sender()==m_textAliginBottom) flag |= Qt::AlignBottom;
|
if (sender()==m_textAliginBottom) m_flag |= Qt::AlignBottom;
|
||||||
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
if (reportEditor()) reportEditor()->setTextAlign(false,Qt::AlignmentFlag(flag));
|
// if (reportEditor()) reportEditor()->setTextAlign(false,Qt::AlignmentFlag(flag));
|
||||||
if (page()) page()->changeSelectedGrpoupTextAlignPropperty(false,Qt::AlignmentFlag(flag) );
|
//#endif
|
||||||
|
// if (page()) page()->changeSelectedGrpoupTextAlignPropperty(false,Qt::AlignmentFlag(flag) );
|
||||||
m_textAttibutesIsChanging = false;
|
m_textAttibutesIsChanging = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -200,5 +209,63 @@ void TextAlignmentEditorWidget::slotPropertyChanged(const QString &objectName, c
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int TextAlignmentEditorWidget::flag() const
|
||||||
|
{
|
||||||
|
return m_flag;
|
||||||
|
}
|
||||||
|
|
||||||
|
void TextAlignmentEditorWidgetForPage::initEditor()
|
||||||
|
{
|
||||||
|
TextAlignmentEditorWidget::initEditor();
|
||||||
|
connect(m_page,SIGNAL(itemPropertyChanged(QString,QString,QVariant,QVariant)),
|
||||||
|
this,SLOT(slotPropertyChanged(QString,QString,QVariant,QVariant)));
|
||||||
|
}
|
||||||
|
|
||||||
|
void TextAlignmentEditorWidgetForPage::slotTextHAttribsChanged(bool value)
|
||||||
|
{
|
||||||
|
|
||||||
|
TextAlignmentEditorWidget::slotTextHAttribsChanged(value);
|
||||||
|
if (m_textAttibutesIsChanging) return;
|
||||||
|
m_textAttibutesIsChanging = true;
|
||||||
|
m_page->changeSelectedGrpoupTextAlignPropperty(true,Qt::AlignmentFlag(flag()));
|
||||||
|
m_textAttibutesIsChanging = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
void TextAlignmentEditorWidgetForPage::slotTextVAttribsChanged(bool value)
|
||||||
|
{
|
||||||
|
TextAlignmentEditorWidget::slotTextVAttribsChanged(value);
|
||||||
|
if (m_textAttibutesIsChanging) return;
|
||||||
|
m_textAttibutesIsChanging = true;
|
||||||
|
m_page->changeSelectedGrpoupTextAlignPropperty(false,Qt::AlignmentFlag(flag()) );
|
||||||
|
m_textAttibutesIsChanging = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef IS_REPORT_DESIGNER
|
||||||
|
void TextAlignmentEditorWidgetForDesigner::initEditor()
|
||||||
|
{
|
||||||
|
TextAlignmentEditorWidget::initEditor();
|
||||||
|
connect(m_reportEditor,SIGNAL(itemPropertyChanged(QString,QString,QVariant,QVariant)),
|
||||||
|
this,SLOT(slotPropertyChanged(QString,QString,QVariant,QVariant)));
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void TextAlignmentEditorWidgetForDesigner::slotTextHAttribsChanged(bool value)
|
||||||
|
{
|
||||||
|
TextAlignmentEditorWidget::slotTextHAttribsChanged(value);
|
||||||
|
if (m_textAttibutesIsChanging) return;
|
||||||
|
m_textAttibutesIsChanging = true;
|
||||||
|
m_reportEditor->setTextAlign(true,Qt::AlignmentFlag(flag()));
|
||||||
|
m_textAttibutesIsChanging = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
void TextAlignmentEditorWidgetForDesigner::slotTextVAttribsChanged(bool value)
|
||||||
|
{
|
||||||
|
TextAlignmentEditorWidget::slotTextVAttribsChanged(value);
|
||||||
|
if (m_textAttibutesIsChanging) return;
|
||||||
|
m_textAttibutesIsChanging = true;
|
||||||
|
m_reportEditor->setTextAlign(false,Qt::AlignmentFlag(flag()));
|
||||||
|
m_textAttibutesIsChanging = false;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
} //namespace LimeReport
|
} //namespace LimeReport
|
||||||
|
@ -41,23 +41,26 @@ class TextAlignmentEditorWidget:public ItemEditorWidget
|
|||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
explicit TextAlignmentEditorWidget(ReportDesignWidget* reportEditor, const QString &title, QWidget *parent = 0);
|
explicit TextAlignmentEditorWidget(const QString &title, QWidget *parent = 0);
|
||||||
explicit TextAlignmentEditorWidget(ReportDesignWidget* reportEditor, QWidget *parent = 0);
|
//#ifdef IS_REPORT_DESIGNER
|
||||||
explicit TextAlignmentEditorWidget(PageDesignIntf* page, const QString &title, QWidget *parent = 0);
|
// explicit TextAlignmentEditorWidget(ReportDesignWidget* reportEditor, const QString &title, QWidget *parent = 0);
|
||||||
explicit TextAlignmentEditorWidget(PageDesignIntf* page, QWidget *parent = 0);
|
// explicit TextAlignmentEditorWidget(ReportDesignWidget* reportEditor, QWidget *parent = 0);
|
||||||
|
//#endif
|
||||||
|
// explicit TextAlignmentEditorWidget(PageDesignIntf* page, const QString &title, QWidget *parent = 0);
|
||||||
|
// explicit TextAlignmentEditorWidget(PageDesignIntf* page, QWidget *parent = 0);
|
||||||
|
int flag() const;
|
||||||
protected:
|
protected:
|
||||||
void setItemEvent(BaseDesignIntf *item);
|
void setItemEvent(BaseDesignIntf *item);
|
||||||
|
virtual void initEditor();
|
||||||
|
bool m_textAttibutesIsChanging;
|
||||||
private:
|
private:
|
||||||
void initEditor();
|
|
||||||
void updateValues(const Qt::Alignment& align);
|
void updateValues(const Qt::Alignment& align);
|
||||||
Qt::Alignment createAlignment();
|
Qt::Alignment createAlignment();
|
||||||
private slots:
|
protected slots:
|
||||||
void slotTextHAttribsChanged(bool);
|
virtual void slotTextHAttribsChanged(bool);
|
||||||
void slotTextVAttribsChanged(bool);
|
virtual void slotTextVAttribsChanged(bool);
|
||||||
void slotPropertyChanged(const QString& objectName, const QString& property, const QVariant &oldValue, const QVariant &newValue);
|
virtual void slotPropertyChanged(const QString& objectName, const QString& property, const QVariant &oldValue, const QVariant &newValue);
|
||||||
private:
|
private:
|
||||||
bool m_textAttibutesIsChanging;
|
|
||||||
|
|
||||||
QAction* m_textAliginLeft;
|
QAction* m_textAliginLeft;
|
||||||
QAction* m_textAliginRight;
|
QAction* m_textAliginRight;
|
||||||
QAction* m_textAliginHCenter;
|
QAction* m_textAliginHCenter;
|
||||||
@ -66,8 +69,40 @@ private:
|
|||||||
QAction* m_textAliginBottom;
|
QAction* m_textAliginBottom;
|
||||||
QAction* m_textAliginVCenter;
|
QAction* m_textAliginVCenter;
|
||||||
|
|
||||||
|
int m_flag;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
class TextAlignmentEditorWidgetForPage: public TextAlignmentEditorWidget{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
TextAlignmentEditorWidgetForPage(PageDesignIntf* page, const QString &title, QWidget *parent = 0)
|
||||||
|
:TextAlignmentEditorWidget(title, parent), m_page(page){}
|
||||||
|
protected:
|
||||||
|
void initEditor();
|
||||||
|
protected slots:
|
||||||
|
void slotTextHAttribsChanged(bool value);
|
||||||
|
void slotTextVAttribsChanged(bool value);
|
||||||
|
private:
|
||||||
|
PageDesignIntf* m_page;
|
||||||
|
};
|
||||||
|
|
||||||
|
#ifdef IS_REPORT_DESIGNER
|
||||||
|
class TextAlignmentEditorWidgetForDesigner: public TextAlignmentEditorWidget{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
TextAlignmentEditorWidgetForDesigner(ReportDesignWidget* reportEditor, const QString &title, QWidget *parent = 0)
|
||||||
|
:TextAlignmentEditorWidget(title, parent), m_reportEditor(reportEditor){}
|
||||||
|
protected:
|
||||||
|
void initEditor();
|
||||||
|
protected slots:
|
||||||
|
void slotTextHAttribsChanged(bool value);
|
||||||
|
void slotTextVAttribsChanged(bool value);
|
||||||
|
private:
|
||||||
|
ReportDesignWidget* m_reportEditor;
|
||||||
|
};
|
||||||
|
#endif
|
||||||
|
|
||||||
} //namespace LimeReport
|
} //namespace LimeReport
|
||||||
|
|
||||||
#endif // LRTEXTALIGNMENTEDITORWIDGET_H
|
#endif // LRTEXTALIGNMENTEDITORWIDGET_H
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
include(../common.pri)
|
include(../common.pri)
|
||||||
|
|
||||||
contains(CONFIG,dialogdesigner){
|
#contains(CONFIG,dialogdesigner){
|
||||||
include($$REPORT_PATH/dialogdesigner/dialogdesigner.pri)
|
# include($$REPORT_PATH/dialogdesigner/dialogdesigner.pri)
|
||||||
}
|
#}
|
||||||
|
|
||||||
DEFINES += INSPECT_BASEDESIGN
|
DEFINES += INSPECT_BASEDESIGN
|
||||||
|
|
||||||
@ -11,9 +11,10 @@ INCLUDEPATH += \
|
|||||||
$$REPORT_PATH/items \
|
$$REPORT_PATH/items \
|
||||||
$$REPORT_PATH/bands \
|
$$REPORT_PATH/bands \
|
||||||
$$REPORT_PATH/base \
|
$$REPORT_PATH/base \
|
||||||
$$REPORT_PATH/objectinspector \
|
# $$REPORT_PATH/objectinspector \
|
||||||
$$REPORT_PATH/databrowser \
|
# $$REPORT_PATH/databrowser \
|
||||||
$$REPORT_PATH/scripteditor
|
$$REPORT_PATH/scripteditor
|
||||||
|
# $$REPORT_PATH/../designer_plugin
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += \
|
||||||
$$REPORT_PATH/bands/lrpageheader.cpp \
|
$$REPORT_PATH/bands/lrpageheader.cpp \
|
||||||
@ -24,59 +25,59 @@ SOURCES += \
|
|||||||
$$REPORT_PATH/bands/lrgroupbands.cpp \
|
$$REPORT_PATH/bands/lrgroupbands.cpp \
|
||||||
$$REPORT_PATH/bands/lrsubdetailband.cpp \
|
$$REPORT_PATH/bands/lrsubdetailband.cpp \
|
||||||
$$REPORT_PATH/bands/lrtearoffband.cpp \
|
$$REPORT_PATH/bands/lrtearoffband.cpp \
|
||||||
$$REPORT_PATH/databrowser/lrdatabrowser.cpp \
|
# $$REPORT_PATH/databrowser/lrdatabrowser.cpp \
|
||||||
$$REPORT_PATH/databrowser/lrsqleditdialog.cpp \
|
# $$REPORT_PATH/databrowser/lrsqleditdialog.cpp \
|
||||||
$$REPORT_PATH/databrowser/lrconnectiondialog.cpp \
|
# $$REPORT_PATH/databrowser/lrconnectiondialog.cpp \
|
||||||
$$REPORT_PATH/databrowser/lrvariabledialog.cpp \
|
# $$REPORT_PATH/databrowser/lrvariabledialog.cpp \
|
||||||
$$REPORT_PATH/databrowser/lrdatabrowsertree.cpp \
|
# $$REPORT_PATH/databrowser/lrdatabrowsertree.cpp \
|
||||||
$$REPORT_PATH/serializators/lrxmlqrectserializator.cpp \
|
$$REPORT_PATH/serializators/lrxmlqrectserializator.cpp \
|
||||||
$$REPORT_PATH/serializators/lrxmlbasetypesserializators.cpp \
|
$$REPORT_PATH/serializators/lrxmlbasetypesserializators.cpp \
|
||||||
$$REPORT_PATH/serializators/lrxmlreader.cpp \
|
$$REPORT_PATH/serializators/lrxmlreader.cpp \
|
||||||
$$REPORT_PATH/serializators/lrxmlwriter.cpp \
|
$$REPORT_PATH/serializators/lrxmlwriter.cpp \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrstringpropitem.cpp \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrstringpropitem.cpp \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrrectproptem.cpp \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrrectproptem.cpp \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrintpropitem.cpp \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrintpropitem.cpp \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrenumpropitem.cpp \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrenumpropitem.cpp \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrboolpropitem.cpp \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrboolpropitem.cpp \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrflagspropitem.cpp \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrflagspropitem.cpp \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrfontpropitem.cpp \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrfontpropitem.cpp \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrimagepropitem.cpp \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrimagepropitem.cpp \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrqrealpropitem.cpp \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrqrealpropitem.cpp \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrcolorpropitem.cpp \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrcolorpropitem.cpp \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrdatasourcepropitem.cpp \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrdatasourcepropitem.cpp \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrgroupfieldpropitem.cpp \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrgroupfieldpropitem.cpp \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrcontentpropitem.cpp \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrcontentpropitem.cpp \
|
||||||
$$REPORT_PATH/objectinspector/editors/lrtextitempropertyeditor.cpp \
|
# $$REPORT_PATH/objectinspector/editors/lrtextitempropertyeditor.cpp \
|
||||||
$$REPORT_PATH/objectinspector/editors/lrcomboboxeditor.cpp \
|
# $$REPORT_PATH/objectinspector/editors/lrcomboboxeditor.cpp \
|
||||||
$$REPORT_PATH/objectinspector/editors/lrcheckboxeditor.cpp \
|
# $$REPORT_PATH/objectinspector/editors/lrcheckboxeditor.cpp \
|
||||||
$$REPORT_PATH/objectinspector/editors/lrbuttonlineeditor.cpp \
|
# $$REPORT_PATH/objectinspector/editors/lrbuttonlineeditor.cpp \
|
||||||
$$REPORT_PATH/objectinspector/editors/lrfonteditor.cpp \
|
# $$REPORT_PATH/objectinspector/editors/lrfonteditor.cpp \
|
||||||
$$REPORT_PATH/objectinspector/editors/lrimageeditor.cpp \
|
# $$REPORT_PATH/objectinspector/editors/lrimageeditor.cpp \
|
||||||
$$REPORT_PATH/objectinspector/editors/lrcoloreditor.cpp \
|
# $$REPORT_PATH/objectinspector/editors/lrcoloreditor.cpp \
|
||||||
$$REPORT_PATH/objectinspector/lrbasedesignobjectmodel.cpp \
|
# $$REPORT_PATH/objectinspector/lrbasedesignobjectmodel.cpp \
|
||||||
$$REPORT_PATH/objectinspector/lrobjectinspectorwidget.cpp \
|
# $$REPORT_PATH/objectinspector/lrobjectinspectorwidget.cpp \
|
||||||
$$REPORT_PATH/objectinspector/lrobjectitemmodel.cpp \
|
# $$REPORT_PATH/objectinspector/lrobjectitemmodel.cpp \
|
||||||
$$REPORT_PATH/objectinspector/lrobjectpropitem.cpp \
|
# $$REPORT_PATH/objectinspector/lrobjectpropitem.cpp \
|
||||||
$$REPORT_PATH/objectinspector/lrpropertydelegate.cpp \
|
# $$REPORT_PATH/objectinspector/lrpropertydelegate.cpp \
|
||||||
$$REPORT_PATH/objectsbrowser/lrobjectbrowser.cpp \
|
# $$REPORT_PATH/objectsbrowser/lrobjectbrowser.cpp \
|
||||||
$$REPORT_PATH/scriptbrowser/lrscriptbrowser.cpp \
|
# $$REPORT_PATH/scriptbrowser/lrscriptbrowser.cpp \
|
||||||
$$REPORT_PATH/scripteditor/lrscripteditor.cpp \
|
$$REPORT_PATH/scripteditor/lrscripteditor.cpp \
|
||||||
$$REPORT_PATH/scripteditor/lrcodeeditor.cpp \
|
$$REPORT_PATH/scripteditor/lrcodeeditor.cpp \
|
||||||
$$REPORT_PATH/scripteditor/lrscripthighlighter.cpp \
|
$$REPORT_PATH/scripteditor/lrscripthighlighter.cpp \
|
||||||
$$REPORT_PATH/items/lrsubitemparentpropitem.cpp \
|
# $$REPORT_PATH/items/lrsubitemparentpropitem.cpp \
|
||||||
$$REPORT_PATH/items/lralignpropitem.cpp \
|
# $$REPORT_PATH/items/lralignpropitem.cpp \
|
||||||
$$REPORT_PATH/items/lrhorizontallayout.cpp \
|
$$REPORT_PATH/items/lrhorizontallayout.cpp \
|
||||||
$$REPORT_PATH/items/editors/lritemeditorwidget.cpp \
|
$$REPORT_PATH/items/editors/lritemeditorwidget.cpp \
|
||||||
$$REPORT_PATH/items/editors/lrfonteditorwidget.cpp \
|
$$REPORT_PATH/items/editors/lrfonteditorwidget.cpp \
|
||||||
$$REPORT_PATH/items/editors/lrtextalignmenteditorwidget.cpp \
|
$$REPORT_PATH/items/editors/lrtextalignmenteditorwidget.cpp \
|
||||||
$$REPORT_PATH/items/editors/lritemsaligneditorwidget.cpp \
|
# $$REPORT_PATH/items/editors/lritemsaligneditorwidget.cpp \
|
||||||
$$REPORT_PATH/items/editors/lritemsborderseditorwidget.cpp \
|
# $$REPORT_PATH/items/editors/lritemsborderseditorwidget.cpp \
|
||||||
$$REPORT_PATH/items/lrsimpletagparser.cpp \
|
$$REPORT_PATH/items/lrsimpletagparser.cpp \
|
||||||
$$REPORT_PATH/items/lrimageitem.cpp \
|
$$REPORT_PATH/items/lrimageitem.cpp \
|
||||||
$$REPORT_PATH/items/lrtextitemeditor.cpp \
|
$$REPORT_PATH/items/lrtextitemeditor.cpp \
|
||||||
$$REPORT_PATH/items/lrshapeitem.cpp \
|
$$REPORT_PATH/items/lrshapeitem.cpp \
|
||||||
$$REPORT_PATH/items/lrtextitem.cpp \
|
$$REPORT_PATH/items/lrtextitem.cpp \
|
||||||
$$REPORT_PATH/translationeditor/translationeditor.cpp \
|
# $$REPORT_PATH/translationeditor/translationeditor.cpp \
|
||||||
$$REPORT_PATH/lrbanddesignintf.cpp \
|
$$REPORT_PATH/lrbanddesignintf.cpp \
|
||||||
$$REPORT_PATH/lrpageitemdesignintf.cpp \
|
$$REPORT_PATH/lrpageitemdesignintf.cpp \
|
||||||
$$REPORT_PATH/lrpagedesignintf.cpp \
|
$$REPORT_PATH/lrpagedesignintf.cpp \
|
||||||
@ -84,11 +85,11 @@ SOURCES += \
|
|||||||
$$REPORT_PATH/lrglobal.cpp \
|
$$REPORT_PATH/lrglobal.cpp \
|
||||||
$$REPORT_PATH/lritemdesignintf.cpp \
|
$$REPORT_PATH/lritemdesignintf.cpp \
|
||||||
$$REPORT_PATH/lrdatadesignintf.cpp \
|
$$REPORT_PATH/lrdatadesignintf.cpp \
|
||||||
$$REPORT_PATH/lrreportdesignwidget.cpp \
|
# $$REPORT_PATH/lrreportdesignwidget.cpp \
|
||||||
$$REPORT_PATH/lrbasedesignintf.cpp \
|
$$REPORT_PATH/lrbasedesignintf.cpp \
|
||||||
$$REPORT_PATH/lrreportengine.cpp \
|
$$REPORT_PATH/lrreportengine.cpp \
|
||||||
$$REPORT_PATH/lrdatasourcemanager.cpp \
|
$$REPORT_PATH/lrdatasourcemanager.cpp \
|
||||||
$$REPORT_PATH/lrreportdesignwindow.cpp \
|
# $$REPORT_PATH/lrreportdesignwindow.cpp \
|
||||||
$$REPORT_PATH/lrreportrender.cpp \
|
$$REPORT_PATH/lrreportrender.cpp \
|
||||||
$$REPORT_PATH/lrscriptenginemanager.cpp \
|
$$REPORT_PATH/lrscriptenginemanager.cpp \
|
||||||
$$REPORT_PATH/lrpreviewreportwindow.cpp \
|
$$REPORT_PATH/lrpreviewreportwindow.cpp \
|
||||||
@ -104,7 +105,7 @@ SOURCES += \
|
|||||||
$$REPORT_PATH/items/lrchartitem.cpp \
|
$$REPORT_PATH/items/lrchartitem.cpp \
|
||||||
$$REPORT_PATH/items/lrchartitemeditor.cpp \
|
$$REPORT_PATH/items/lrchartitemeditor.cpp \
|
||||||
$$REPORT_PATH/lrreporttranslation.cpp \
|
$$REPORT_PATH/lrreporttranslation.cpp \
|
||||||
$$REPORT_PATH/translationeditor/languageselectdialog.cpp
|
# $$REPORT_PATH/translationeditor/languageselectdialog.cpp
|
||||||
|
|
||||||
contains(CONFIG, staticlib){
|
contains(CONFIG, staticlib){
|
||||||
SOURCES += $$REPORT_PATH/lrfactoryinitializer.cpp
|
SOURCES += $$REPORT_PATH/lrfactoryinitializer.cpp
|
||||||
@ -126,11 +127,11 @@ HEADERS += \
|
|||||||
$$REPORT_PATH/bands/lrtearoffband.h \
|
$$REPORT_PATH/bands/lrtearoffband.h \
|
||||||
$$REPORT_PATH/bands/lrsubdetailband.h \
|
$$REPORT_PATH/bands/lrsubdetailband.h \
|
||||||
$$REPORT_PATH/bands/lrgroupbands.h \
|
$$REPORT_PATH/bands/lrgroupbands.h \
|
||||||
$$REPORT_PATH/databrowser/lrdatabrowser.h \
|
# $$REPORT_PATH/databrowser/lrdatabrowser.h \
|
||||||
$$REPORT_PATH/databrowser/lrsqleditdialog.h \
|
# $$REPORT_PATH/databrowser/lrsqleditdialog.h \
|
||||||
$$REPORT_PATH/databrowser/lrconnectiondialog.h \
|
# $$REPORT_PATH/databrowser/lrconnectiondialog.h \
|
||||||
$$REPORT_PATH/databrowser/lrvariabledialog.h \
|
# $$REPORT_PATH/databrowser/lrvariabledialog.h \
|
||||||
$$REPORT_PATH/databrowser/lrdatabrowsertree.h \
|
# $$REPORT_PATH/databrowser/lrdatabrowsertree.h \
|
||||||
$$REPORT_PATH/serializators/lrserializatorintf.h \
|
$$REPORT_PATH/serializators/lrserializatorintf.h \
|
||||||
$$REPORT_PATH/serializators/lrstorageintf.h \
|
$$REPORT_PATH/serializators/lrstorageintf.h \
|
||||||
$$REPORT_PATH/serializators/lrxmlqrectserializator.h \
|
$$REPORT_PATH/serializators/lrxmlqrectserializator.h \
|
||||||
@ -138,50 +139,50 @@ HEADERS += \
|
|||||||
$$REPORT_PATH/serializators/lrxmlbasetypesserializators.h \
|
$$REPORT_PATH/serializators/lrxmlbasetypesserializators.h \
|
||||||
$$REPORT_PATH/serializators/lrxmlreader.h \
|
$$REPORT_PATH/serializators/lrxmlreader.h \
|
||||||
$$REPORT_PATH/serializators/lrxmlwriter.h \
|
$$REPORT_PATH/serializators/lrxmlwriter.h \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrstringpropitem.h \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrstringpropitem.h \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrrectproptem.h \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrrectproptem.h \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrdatasourcepropitem.h \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrdatasourcepropitem.h \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrfontpropitem.h \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrfontpropitem.h \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrimagepropitem.h \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrimagepropitem.h \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrintpropitem.h \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrintpropitem.h \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrenumpropitem.h \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrenumpropitem.h \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrboolpropitem.h \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrboolpropitem.h \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrflagspropitem.h \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrflagspropitem.h \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrgroupfieldpropitem.h \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrgroupfieldpropitem.h \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrcontentpropitem.h \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrcontentpropitem.h \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrqrealpropitem.h \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrqrealpropitem.h \
|
||||||
$$REPORT_PATH/objectinspector/propertyItems/lrcolorpropitem.h \
|
# $$REPORT_PATH/objectinspector/propertyItems/lrcolorpropitem.h \
|
||||||
$$REPORT_PATH/objectinspector/editors/lrtextitempropertyeditor.h \
|
# $$REPORT_PATH/objectinspector/editors/lrtextitempropertyeditor.h \
|
||||||
$$REPORT_PATH/objectinspector/editors/lrcomboboxeditor.h \
|
# $$REPORT_PATH/objectinspector/editors/lrcomboboxeditor.h \
|
||||||
$$REPORT_PATH/objectinspector/editors/lrcheckboxeditor.h \
|
# $$REPORT_PATH/objectinspector/editors/lrcheckboxeditor.h \
|
||||||
$$REPORT_PATH/objectinspector/editors/lrbuttonlineeditor.h \
|
# $$REPORT_PATH/objectinspector/editors/lrbuttonlineeditor.h \
|
||||||
$$REPORT_PATH/objectinspector/editors/lrimageeditor.h \
|
# $$REPORT_PATH/objectinspector/editors/lrimageeditor.h \
|
||||||
$$REPORT_PATH/objectinspector/editors/lrcoloreditor.h \
|
# $$REPORT_PATH/objectinspector/editors/lrcoloreditor.h \
|
||||||
$$REPORT_PATH/objectinspector/editors/lrfonteditor.h \
|
# $$REPORT_PATH/objectinspector/editors/lrfonteditor.h \
|
||||||
$$REPORT_PATH/objectinspector/lrbasedesignobjectmodel.h \
|
# $$REPORT_PATH/objectinspector/lrbasedesignobjectmodel.h \
|
||||||
$$REPORT_PATH/objectinspector/lrobjectinspectorwidget.h \
|
# $$REPORT_PATH/objectinspector/lrobjectinspectorwidget.h \
|
||||||
$$REPORT_PATH/objectinspector/lrobjectitemmodel.h \
|
# $$REPORT_PATH/objectinspector/lrobjectitemmodel.h \
|
||||||
$$REPORT_PATH/objectinspector/lrobjectpropitem.h \
|
# $$REPORT_PATH/objectinspector/lrobjectpropitem.h \
|
||||||
$$REPORT_PATH/objectinspector/lrpropertydelegate.h \
|
# $$REPORT_PATH/objectinspector/lrpropertydelegate.h \
|
||||||
$$REPORT_PATH/objectsbrowser/lrobjectbrowser.h \
|
# $$REPORT_PATH/objectsbrowser/lrobjectbrowser.h \
|
||||||
$$REPORT_PATH/scriptbrowser/lrscriptbrowser.h \
|
# $$REPORT_PATH/scriptbrowser/lrscriptbrowser.h \
|
||||||
$$REPORT_PATH/scripteditor/lrscripteditor.h \
|
$$REPORT_PATH/scripteditor/lrscripteditor.h \
|
||||||
$$REPORT_PATH/scripteditor/lrcodeeditor.h \
|
$$REPORT_PATH/scripteditor/lrcodeeditor.h \
|
||||||
$$REPORT_PATH/scripteditor/lrscripthighlighter.h \
|
$$REPORT_PATH/scripteditor/lrscripthighlighter.h \
|
||||||
$$REPORT_PATH/items/editors/lritemeditorwidget.h \
|
$$REPORT_PATH/items/editors/lritemeditorwidget.h \
|
||||||
$$REPORT_PATH/items/editors/lrfonteditorwidget.h \
|
$$REPORT_PATH/items/editors/lrfonteditorwidget.h \
|
||||||
$$REPORT_PATH/items/editors/lrtextalignmenteditorwidget.h \
|
$$REPORT_PATH/items/editors/lrtextalignmenteditorwidget.h \
|
||||||
$$REPORT_PATH/items/editors/lritemsaligneditorwidget.h \
|
# $$REPORT_PATH/items/editors/lritemsaligneditorwidget.h \
|
||||||
$$REPORT_PATH/items/editors/lritemsborderseditorwidget.h \
|
# $$REPORT_PATH/items/editors/lritemsborderseditorwidget.h \
|
||||||
$$REPORT_PATH/items/lrtextitem.h \
|
$$REPORT_PATH/items/lrtextitem.h \
|
||||||
$$REPORT_PATH/items/lrsubitemparentpropitem.h \
|
# $$REPORT_PATH/items/lrsubitemparentpropitem.h \
|
||||||
$$REPORT_PATH/items/lralignpropitem.h \
|
# $$REPORT_PATH/items/lralignpropitem.h \
|
||||||
$$REPORT_PATH/items/lrhorizontallayout.h \
|
$$REPORT_PATH/items/lrhorizontallayout.h \
|
||||||
$$REPORT_PATH/items/lrtextitemeditor.h \
|
$$REPORT_PATH/items/lrtextitemeditor.h \
|
||||||
$$REPORT_PATH/items/lrshapeitem.h \
|
$$REPORT_PATH/items/lrshapeitem.h \
|
||||||
$$REPORT_PATH/items/lrimageitem.h \
|
$$REPORT_PATH/items/lrimageitem.h \
|
||||||
$$REPORT_PATH/items/lrsimpletagparser.h \
|
$$REPORT_PATH/items/lrsimpletagparser.h \
|
||||||
$$REPORT_PATH/translationeditor/translationeditor.h \
|
# $$REPORT_PATH/translationeditor/translationeditor.h \
|
||||||
$$REPORT_PATH/lrfactoryinitializer.h \
|
$$REPORT_PATH/lrfactoryinitializer.h \
|
||||||
$$REPORT_PATH/lrbanddesignintf.h \
|
$$REPORT_PATH/lrbanddesignintf.h \
|
||||||
$$REPORT_PATH/lrpageitemdesignintf.h \
|
$$REPORT_PATH/lrpageitemdesignintf.h \
|
||||||
@ -190,10 +191,10 @@ HEADERS += \
|
|||||||
$$REPORT_PATH/lrdatadesignintf.h \
|
$$REPORT_PATH/lrdatadesignintf.h \
|
||||||
$$REPORT_PATH/lrcollection.h \
|
$$REPORT_PATH/lrcollection.h \
|
||||||
$$REPORT_PATH/lrpagedesignintf.h \
|
$$REPORT_PATH/lrpagedesignintf.h \
|
||||||
$$REPORT_PATH/lrreportdesignwidget.h \
|
# $$REPORT_PATH/lrreportdesignwidget.h \
|
||||||
$$REPORT_PATH/lrreportengine_p.h \
|
$$REPORT_PATH/lrreportengine_p.h \
|
||||||
$$REPORT_PATH/lrdatasourcemanager.h \
|
$$REPORT_PATH/lrdatasourcemanager.h \
|
||||||
$$REPORT_PATH/lrreportdesignwindow.h \
|
# $$REPORT_PATH/lrreportdesignwindow.h \
|
||||||
$$REPORT_PATH/lrreportrender.h \
|
$$REPORT_PATH/lrreportrender.h \
|
||||||
$$REPORT_PATH/lrpreviewreportwindow.h \
|
$$REPORT_PATH/lrpreviewreportwindow.h \
|
||||||
$$REPORT_PATH/lrpreviewreportwidget.h \
|
$$REPORT_PATH/lrpreviewreportwidget.h \
|
||||||
@ -216,9 +217,9 @@ HEADERS += \
|
|||||||
$$REPORT_PATH/lritemscontainerdesignitf.h \
|
$$REPORT_PATH/lritemscontainerdesignitf.h \
|
||||||
$$REPORT_PATH/lrcolorindicator.h \
|
$$REPORT_PATH/lrcolorindicator.h \
|
||||||
$$REPORT_PATH/items/lrchartitem.h \
|
$$REPORT_PATH/items/lrchartitem.h \
|
||||||
$$REPORT_PATH/items/lrchartitemeditor.h \
|
$$REPORT_PATH/items/lrchartitemeditor.h
|
||||||
$$REPORT_PATH/lrreporttranslation.h \
|
# $$REPORT_PATH/lrreporttranslation.h \
|
||||||
$$REPORT_PATH/translationeditor/languageselectdialog.h
|
# $$REPORT_PATH/translationeditor/languageselectdialog.h
|
||||||
|
|
||||||
contains(CONFIG, staticlib){
|
contains(CONFIG, staticlib){
|
||||||
HEADERS += $$REPORT_PATH/lrfactoryinitializer.h
|
HEADERS += $$REPORT_PATH/lrfactoryinitializer.h
|
||||||
@ -229,26 +230,26 @@ contains(CONFIG,zint){
|
|||||||
}
|
}
|
||||||
|
|
||||||
FORMS += \
|
FORMS += \
|
||||||
$$REPORT_PATH/databrowser/lrsqleditdialog.ui \
|
# $$REPORT_PATH/databrowser/lrsqleditdialog.ui \
|
||||||
$$REPORT_PATH/databrowser/lrconnectiondialog.ui \
|
# $$REPORT_PATH/databrowser/lrconnectiondialog.ui \
|
||||||
$$REPORT_PATH/databrowser/lrdatabrowser.ui \
|
# $$REPORT_PATH/databrowser/lrdatabrowser.ui \
|
||||||
$$REPORT_PATH/databrowser/lrvariabledialog.ui \
|
# $$REPORT_PATH/databrowser/lrvariabledialog.ui \
|
||||||
$$REPORT_PATH/objectinspector/editors/ltextitempropertyeditor.ui \
|
# $$REPORT_PATH/objectinspector/editors/ltextitempropertyeditor.ui \
|
||||||
$$REPORT_PATH/lrpreviewreportwindow.ui \
|
$$REPORT_PATH/lrpreviewreportwindow.ui \
|
||||||
$$REPORT_PATH/lrpreviewreportwidget.ui \
|
$$REPORT_PATH/lrpreviewreportwidget.ui \
|
||||||
$$REPORT_PATH/items/lrtextitemeditor.ui \
|
$$REPORT_PATH/items/lrtextitemeditor.ui \
|
||||||
$$REPORT_PATH/lraboutdialog.ui \
|
$$REPORT_PATH/lraboutdialog.ui \
|
||||||
$$REPORT_PATH/lrsettingdialog.ui \
|
$$REPORT_PATH/lrsettingdialog.ui \
|
||||||
$$REPORT_PATH/scriptbrowser/lrscriptbrowser.ui \
|
# $$REPORT_PATH/scriptbrowser/lrscriptbrowser.ui \
|
||||||
$$REPORT_PATH/items/lrchartitemeditor.ui \
|
$$REPORT_PATH/items/lrchartitemeditor.ui \
|
||||||
$$REPORT_PATH/translationeditor/translationeditor.ui \
|
# $$REPORT_PATH/translationeditor/translationeditor.ui \
|
||||||
$$REPORT_PATH/translationeditor/languageselectdialog.ui \
|
# $$REPORT_PATH/translationeditor/languageselectdialog.ui \
|
||||||
$$REPORT_PATH/scripteditor/lrscripteditor.ui
|
$$REPORT_PATH/scripteditor/lrscripteditor.ui
|
||||||
|
|
||||||
RESOURCES += \
|
RESOURCES += \
|
||||||
$$REPORT_PATH/objectinspector/lobjectinspector.qrc \
|
# $$REPORT_PATH/objectinspector/lobjectinspector.qrc \
|
||||||
$$REPORT_PATH/databrowser/lrdatabrowser.qrc \
|
# $$REPORT_PATH/databrowser/lrdatabrowser.qrc \
|
||||||
$$REPORT_PATH/report.qrc \
|
$$REPORT_PATH/report.qrc \
|
||||||
$$REPORT_PATH/items/items.qrc \
|
$$REPORT_PATH/items/items.qrc
|
||||||
$$REPORT_PATH/scriptbrowser/lrscriptbrowser.qrc \
|
# $$REPORT_PATH/scriptbrowser/lrscriptbrowser.qrc \
|
||||||
$$REPORT_PATH/translationeditor/translationeditor.qrc
|
# $$REPORT_PATH/translationeditor/translationeditor.qrc
|
||||||
|
@ -31,7 +31,7 @@
|
|||||||
#define LRDESIGNELEMENTSFACTORY_H
|
#define LRDESIGNELEMENTSFACTORY_H
|
||||||
|
|
||||||
#include "lrbanddesignintf.h"
|
#include "lrbanddesignintf.h"
|
||||||
#include "lrpageheader.h"
|
//#include "lrpageheader.h"
|
||||||
#include "lrattribsabstractfactory.h"
|
#include "lrattribsabstractfactory.h"
|
||||||
#include "lrsimpleabstractfactory.h"
|
#include "lrsimpleabstractfactory.h"
|
||||||
#include "lrsingleton.h"
|
#include "lrsingleton.h"
|
||||||
|
30
limereport/lrdesignerplugininterface.h
Normal file
30
limereport/lrdesignerplugininterface.h
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
#ifndef LRDESIGNERPLUGININTERFACE_H
|
||||||
|
#define LRDESIGNERPLUGININTERFACE_H
|
||||||
|
|
||||||
|
#include <QString>
|
||||||
|
#include <QVariant>
|
||||||
|
|
||||||
|
#include <QtPlugin>
|
||||||
|
|
||||||
|
QT_BEGIN_NAMESPACE
|
||||||
|
class QSettings;
|
||||||
|
class QMainWindow;
|
||||||
|
QT_END_NAMESPACE
|
||||||
|
|
||||||
|
namespace LimeReport {
|
||||||
|
class ReportDesignWindow;
|
||||||
|
class ReportEnginePrivateInterface;
|
||||||
|
}
|
||||||
|
|
||||||
|
class LimeReportPluginInterface {
|
||||||
|
public:
|
||||||
|
virtual ~LimeReportPluginInterface() { }
|
||||||
|
|
||||||
|
virtual QString getString() const = 0;
|
||||||
|
virtual QVariant getVar() const = 0;
|
||||||
|
virtual QMainWindow* getDesignerWindow(LimeReport::ReportEnginePrivateInterface* report, QWidget *parent = 0, QSettings* settings=0) = 0;
|
||||||
|
};
|
||||||
|
|
||||||
|
Q_DECLARE_INTERFACE( LimeReportPluginInterface, "ru.limereport.LimeReport.DesignerPluginInterface/1.0" )
|
||||||
|
|
||||||
|
#endif // LRDESIGNERPLUGININTERFACE_H
|
@ -66,10 +66,10 @@ PreviewReportWindow::PreviewReportWindow(ReportEngine *report, QWidget *parent,
|
|||||||
connect(m_previewReportWidget->d_ptr->m_previewPage,SIGNAL(selectionChanged()),this,SLOT(slotSelectionChanged()));
|
connect(m_previewReportWidget->d_ptr->m_previewPage,SIGNAL(selectionChanged()),this,SLOT(slotSelectionChanged()));
|
||||||
connect(m_pagesNavigator,SIGNAL(valueChanged(int)),this,SLOT(slotPageNavigatorChanged(int)));
|
connect(m_pagesNavigator,SIGNAL(valueChanged(int)),this,SLOT(slotPageNavigatorChanged(int)));
|
||||||
|
|
||||||
m_fontEditor = new FontEditorWidget(m_previewReportWidget->d_ptr->m_previewPage,tr("Font"),this);
|
m_fontEditor = new FontEditorWidgetForPage(m_previewReportWidget->d_ptr->m_previewPage,tr("Font"),this);
|
||||||
m_fontEditor->setObjectName("fontTools");
|
m_fontEditor->setObjectName("fontTools");
|
||||||
m_fontEditor->setIconSize(ui->toolBar->iconSize());
|
m_fontEditor->setIconSize(ui->toolBar->iconSize());
|
||||||
m_textAlignmentEditor = new TextAlignmentEditorWidget(m_previewReportWidget->d_ptr->m_previewPage,tr("Text align"),this);
|
m_textAlignmentEditor = new TextAlignmentEditorWidgetForPage(m_previewReportWidget->d_ptr->m_previewPage,tr("Text align"),this);
|
||||||
m_textAlignmentEditor->setObjectName("textAlignmentTools");
|
m_textAlignmentEditor->setObjectName("textAlignmentTools");
|
||||||
m_textAlignmentEditor->setIconSize(ui->toolBar->iconSize());
|
m_textAlignmentEditor->setIconSize(ui->toolBar->iconSize());
|
||||||
addToolBar(Qt::TopToolBarArea,m_fontEditor);
|
addToolBar(Qt::TopToolBarArea,m_fontEditor);
|
||||||
|
@ -51,7 +51,7 @@ namespace LimeReport {
|
|||||||
|
|
||||||
// ReportDesignIntf
|
// ReportDesignIntf
|
||||||
|
|
||||||
ReportDesignWidget::ReportDesignWidget(ReportEngine *report, QMainWindow *mainWindow, QWidget *parent) :
|
ReportDesignWidget::ReportDesignWidget(ReportEnginePrivateInterface* report, QMainWindow *mainWindow, QWidget *parent) :
|
||||||
QWidget(parent),
|
QWidget(parent),
|
||||||
#ifdef HAVE_QTDESIGNER_INTEGRATION
|
#ifdef HAVE_QTDESIGNER_INTEGRATION
|
||||||
m_dialogDesignerManager(new DialogDesignerManager(this)),
|
m_dialogDesignerManager(new DialogDesignerManager(this)),
|
||||||
@ -72,20 +72,20 @@ ReportDesignWidget::ReportDesignWidget(ReportEngine *report, QMainWindow *mainWi
|
|||||||
mainLayout->addWidget(m_tabWidget);
|
mainLayout->addWidget(m_tabWidget);
|
||||||
setLayout(mainLayout);
|
setLayout(mainLayout);
|
||||||
|
|
||||||
if (!report) {
|
// if (!report) {
|
||||||
m_report=new ReportEnginePrivate(this);
|
// m_report=new ReportEnginePrivate(this);
|
||||||
m_report->setObjectName("report");
|
// m_report->setObjectName("report");
|
||||||
m_report->appendPage("page1");
|
// m_report->appendPage("page1");
|
||||||
}
|
// }
|
||||||
else {
|
// else {
|
||||||
m_report=report->d_ptr;
|
m_report=report;//report->d_ptr;
|
||||||
if (!m_report->pageCount()) m_report->appendPage("page1");
|
if (!m_report->pageCount()) m_report->appendPage("page1");
|
||||||
}
|
// }
|
||||||
|
|
||||||
createTabs();
|
createTabs();
|
||||||
|
|
||||||
connect(m_report,SIGNAL(pagesLoadFinished()),this,SLOT(slotPagesLoadFinished()));
|
connect(dynamic_cast<QObject*>(m_report), SIGNAL(pagesLoadFinished()),this,SLOT(slotPagesLoadFinished()));
|
||||||
connect(m_report,SIGNAL(cleared()),this,SIGNAL(cleared()));
|
connect(dynamic_cast<QObject*>(m_report), SIGNAL(cleared()),this,SIGNAL(cleared()));
|
||||||
connect(m_tabWidget, SIGNAL(currentChanged(int)), this, SLOT(slotCurrentTabChanged(int)));
|
connect(m_tabWidget, SIGNAL(currentChanged(int)), this, SLOT(slotCurrentTabChanged(int)));
|
||||||
#ifdef HAVE_UI_LOADER
|
#ifdef HAVE_UI_LOADER
|
||||||
connect(m_report->scriptContext(), SIGNAL(dialogDeleted(QString)), this, SLOT(slotDialogDeleted(QString)));
|
connect(m_report->scriptContext(), SIGNAL(dialogDeleted(QString)), this, SLOT(slotDialogDeleted(QString)));
|
||||||
@ -241,9 +241,11 @@ void ReportDesignWidget::createTabs(){
|
|||||||
view->setFrameShape(QFrame::NoFrame);
|
view->setFrameShape(QFrame::NoFrame);
|
||||||
view->setScene(m_report->pageAt(i));
|
view->setScene(m_report->pageAt(i));
|
||||||
|
|
||||||
foreach(QGraphicsItem* item, m_report->pageAt(i)->selectedItems()){
|
// foreach(QGraphicsItem* item, m_report->pageAt(i)->selectedItems()){
|
||||||
item->setSelected(false);
|
// item->setSelected(false);
|
||||||
}
|
// }
|
||||||
|
|
||||||
|
m_report->pageAt(i)->clearSelection();
|
||||||
|
|
||||||
view->centerOn(0,0);
|
view->centerOn(0,0);
|
||||||
view->scale(0.5,0.5);
|
view->scale(0.5,0.5);
|
||||||
@ -796,7 +798,8 @@ void ReportDesignWidget::slotCurrentTabChanged(int index)
|
|||||||
QGraphicsView* view = dynamic_cast<QGraphicsView*>(m_tabWidget->widget(index));
|
QGraphicsView* view = dynamic_cast<QGraphicsView*>(m_tabWidget->widget(index));
|
||||||
if (view) {
|
if (view) {
|
||||||
if (view->scene()){
|
if (view->scene()){
|
||||||
foreach (QGraphicsItem* item, view->scene()->selectedItems()) item->setSelected(false);
|
//foreach (QGraphicsItem* item, view->scene()->selectedItems()) item->setSelected(false);
|
||||||
|
view->scene()->clearSelection();
|
||||||
}
|
}
|
||||||
m_zoomer->setView(view);
|
m_zoomer->setView(view);
|
||||||
}
|
}
|
||||||
@ -807,7 +810,7 @@ void ReportDesignWidget::slotCurrentTabChanged(int index)
|
|||||||
updateDialogs();
|
updateDialogs();
|
||||||
#endif
|
#endif
|
||||||
if (activeTabType() == Translations){
|
if (activeTabType() == Translations){
|
||||||
m_traslationEditor->setReportEngine(report());
|
m_traslationEditor->setReportEngine(dynamic_cast<ITranslationContainer*>(report()));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (activeTabType() == Script){
|
if (activeTabType() == Script){
|
||||||
@ -816,6 +819,8 @@ void ReportDesignWidget::slotCurrentTabChanged(int index)
|
|||||||
}
|
}
|
||||||
|
|
||||||
emit activePageChanged();
|
emit activePageChanged();
|
||||||
|
|
||||||
|
if (view) view->centerOn(0,0);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef HAVE_QTDESIGNER_INTEGRATION
|
#ifdef HAVE_QTDESIGNER_INTEGRATION
|
||||||
|
@ -84,7 +84,7 @@ public:
|
|||||||
Translations,
|
Translations,
|
||||||
TabTypeCount
|
TabTypeCount
|
||||||
};
|
};
|
||||||
ReportDesignWidget(ReportEngine* report, QMainWindow *mainWindow, QWidget *parent = 0);
|
ReportDesignWidget(ReportEnginePrivateInterface* report, QMainWindow *mainWindow, QWidget *parent = 0);
|
||||||
~ReportDesignWidget();
|
~ReportDesignWidget();
|
||||||
void createStartPage();
|
void createStartPage();
|
||||||
void clear();
|
void clear();
|
||||||
@ -105,7 +105,7 @@ public:
|
|||||||
QList<QGraphicsItem *> selectedItems();
|
QList<QGraphicsItem *> selectedItems();
|
||||||
QStringList datasourcesNames();
|
QStringList datasourcesNames();
|
||||||
void scale( qreal sx, qreal sy);
|
void scale( qreal sx, qreal sy);
|
||||||
ReportEnginePrivate* report(){return m_report;}
|
ReportEnginePrivateInterface* report(){return m_report;}
|
||||||
QString reportFileName();
|
QString reportFileName();
|
||||||
bool isNeedToSave();
|
bool isNeedToSave();
|
||||||
bool emitLoadReport();
|
bool emitLoadReport();
|
||||||
@ -200,7 +200,7 @@ protected:
|
|||||||
private:
|
private:
|
||||||
bool eventFilter(QObject *target, QEvent *event);
|
bool eventFilter(QObject *target, QEvent *event);
|
||||||
private:
|
private:
|
||||||
ReportEnginePrivate* m_report;
|
ReportEnginePrivateInterface* m_report;
|
||||||
QGraphicsView *m_view;
|
QGraphicsView *m_view;
|
||||||
ScriptEditor* m_scriptEditor;
|
ScriptEditor* m_scriptEditor;
|
||||||
TranslationEditor* m_traslationEditor;
|
TranslationEditor* m_traslationEditor;
|
||||||
|
@ -62,7 +62,7 @@ namespace LimeReport{
|
|||||||
|
|
||||||
ReportDesignWindow* ReportDesignWindow::m_instance=0;
|
ReportDesignWindow* ReportDesignWindow::m_instance=0;
|
||||||
|
|
||||||
ReportDesignWindow::ReportDesignWindow(ReportEngine *report, QWidget *parent, QSettings* settings) :
|
ReportDesignWindow::ReportDesignWindow(ReportEnginePrivateInterface* report, QWidget *parent, QSettings* settings) :
|
||||||
QMainWindow(parent), m_textAttibutesIsChanging(false), m_settings(settings), m_ownedSettings(false),
|
QMainWindow(parent), m_textAttibutesIsChanging(false), m_settings(settings), m_ownedSettings(false),
|
||||||
m_progressDialog(0), m_showProgressDialog(true), m_editorTabType(ReportDesignWidget::Page), m_reportItemIsLocked(false)
|
m_progressDialog(0), m_showProgressDialog(true), m_editorTabType(ReportDesignWidget::Page), m_reportItemIsLocked(false)
|
||||||
{
|
{
|
||||||
@ -309,11 +309,11 @@ void ReportDesignWindow::createToolBars()
|
|||||||
|
|
||||||
//m_mainToolBar->addAction(m_printReportAction);
|
//m_mainToolBar->addAction(m_printReportAction);
|
||||||
|
|
||||||
m_fontEditorBar = new FontEditorWidget(m_reportDesignWidget,tr("Font"),this);
|
m_fontEditorBar = new FontEditorWidgetForDesigner(m_reportDesignWidget,tr("Font"),this);
|
||||||
m_fontEditorBar->setIconSize(m_mainToolBar->iconSize());
|
m_fontEditorBar->setIconSize(m_mainToolBar->iconSize());
|
||||||
m_fontEditorBar->setObjectName("fontTools");
|
m_fontEditorBar->setObjectName("fontTools");
|
||||||
addToolBar(m_fontEditorBar);
|
addToolBar(m_fontEditorBar);
|
||||||
m_textAlignmentEditorBar = new TextAlignmentEditorWidget(m_reportDesignWidget,tr("Text alignment"),this);
|
m_textAlignmentEditorBar = new TextAlignmentEditorWidgetForDesigner(m_reportDesignWidget,tr("Text alignment"),this);
|
||||||
m_textAlignmentEditorBar->setIconSize(m_mainToolBar->iconSize());
|
m_textAlignmentEditorBar->setIconSize(m_mainToolBar->iconSize());
|
||||||
m_textAlignmentEditorBar->setObjectName("textAlignmentTools");
|
m_textAlignmentEditorBar->setObjectName("textAlignmentTools");
|
||||||
addToolBar(m_textAlignmentEditorBar);
|
addToolBar(m_textAlignmentEditorBar);
|
||||||
@ -324,7 +324,7 @@ void ReportDesignWindow::createToolBars()
|
|||||||
m_itemsAlignmentEditorBar->insertAction(m_itemsAlignmentEditorBar->actions().at(1),m_useMagnetAction);
|
m_itemsAlignmentEditorBar->insertAction(m_itemsAlignmentEditorBar->actions().at(1),m_useMagnetAction);
|
||||||
m_itemsAlignmentEditorBar->insertSeparator(m_itemsAlignmentEditorBar->actions().at(2));
|
m_itemsAlignmentEditorBar->insertSeparator(m_itemsAlignmentEditorBar->actions().at(2));
|
||||||
addToolBar(m_itemsAlignmentEditorBar);
|
addToolBar(m_itemsAlignmentEditorBar);
|
||||||
m_itemsBordersEditorBar = new ItemsBordersEditorWidget(m_reportDesignWidget,tr("Borders"),this);
|
m_itemsBordersEditorBar = new ItemsBordersEditorWidgetForDesigner(m_reportDesignWidget,tr("Borders"),this);
|
||||||
m_itemsBordersEditorBar->setIconSize(m_mainToolBar->iconSize());
|
m_itemsBordersEditorBar->setIconSize(m_mainToolBar->iconSize());
|
||||||
m_itemsBordersEditorBar->setObjectName("itemsBorderTools");
|
m_itemsBordersEditorBar->setObjectName("itemsBorderTools");
|
||||||
addToolBar(m_itemsBordersEditorBar);
|
addToolBar(m_itemsBordersEditorBar);
|
||||||
@ -459,7 +459,7 @@ void ReportDesignWindow::createMainMenu()
|
|||||||
m_recentFilesMenu->setDisabled(m_recentFiles.isEmpty());
|
m_recentFilesMenu->setDisabled(m_recentFiles.isEmpty());
|
||||||
}
|
}
|
||||||
|
|
||||||
void ReportDesignWindow::initReportEditor(ReportEngine* report)
|
void ReportDesignWindow::initReportEditor(ReportEnginePrivateInterface* report)
|
||||||
{
|
{
|
||||||
m_reportDesignWidget=new ReportDesignWidget(report,this,this);
|
m_reportDesignWidget=new ReportDesignWidget(report,this,this);
|
||||||
setCentralWidget(m_reportDesignWidget);
|
setCentralWidget(m_reportDesignWidget);
|
||||||
@ -472,16 +472,16 @@ void ReportDesignWindow::initReportEditor(ReportEngine* report)
|
|||||||
connect(m_reportDesignWidget,SIGNAL(itemInserted(LimeReport::PageDesignIntf*,QPointF,QString)),
|
connect(m_reportDesignWidget,SIGNAL(itemInserted(LimeReport::PageDesignIntf*,QPointF,QString)),
|
||||||
this,SLOT(slotItemInserted(LimeReport::PageDesignIntf*,QPointF,QString)));
|
this,SLOT(slotItemInserted(LimeReport::PageDesignIntf*,QPointF,QString)));
|
||||||
connect(m_reportDesignWidget,SIGNAL(itemInsertCanceled(QString)),this,SLOT(slotItemInsertCanceled(QString)));
|
connect(m_reportDesignWidget,SIGNAL(itemInsertCanceled(QString)),this,SLOT(slotItemInsertCanceled(QString)));
|
||||||
connect(m_reportDesignWidget->report(),SIGNAL(datasourceCollectionLoadFinished(QString)),this,SLOT(slotUpdateDataBrowser(QString)));
|
connect(dynamic_cast<QObject*>(report), SIGNAL(datasourceCollectionLoadFinished(QString)),this,SLOT(slotUpdateDataBrowser(QString)));
|
||||||
connect(m_reportDesignWidget,SIGNAL(commandHistoryChanged()),this,SLOT(slotCommandHistoryChanged()));
|
connect(m_reportDesignWidget,SIGNAL(commandHistoryChanged()),this,SLOT(slotCommandHistoryChanged()));
|
||||||
connect(m_reportDesignWidget,SIGNAL(activePageChanged()),this,SLOT(slotActivePageChanged()));
|
connect(m_reportDesignWidget,SIGNAL(activePageChanged()),this,SLOT(slotActivePageChanged()));
|
||||||
connect(m_reportDesignWidget, SIGNAL(bandAdded(LimeReport::PageDesignIntf*,LimeReport::BandDesignIntf*)),
|
connect(m_reportDesignWidget, SIGNAL(bandAdded(LimeReport::PageDesignIntf*,LimeReport::BandDesignIntf*)),
|
||||||
this, SLOT(slotBandAdded(LimeReport::PageDesignIntf*,LimeReport::BandDesignIntf*)));
|
this, SLOT(slotBandAdded(LimeReport::PageDesignIntf*,LimeReport::BandDesignIntf*)));
|
||||||
connect(m_reportDesignWidget, SIGNAL(bandDeleted(LimeReport::PageDesignIntf*,LimeReport::BandDesignIntf*)),
|
connect(m_reportDesignWidget, SIGNAL(bandDeleted(LimeReport::PageDesignIntf*,LimeReport::BandDesignIntf*)),
|
||||||
this, SLOT(slotBandDeleted(LimeReport::PageDesignIntf*,LimeReport::BandDesignIntf*)));
|
this, SLOT(slotBandDeleted(LimeReport::PageDesignIntf*,LimeReport::BandDesignIntf*)));
|
||||||
connect(m_reportDesignWidget->report(), SIGNAL(renderStarted()), this, SLOT(renderStarted()));
|
connect(dynamic_cast<QObject*>(report), SIGNAL(renderStarted()), this, SLOT(renderStarted()));
|
||||||
connect(m_reportDesignWidget->report(), SIGNAL(renderPageFinished(int)), this, SLOT(renderPageFinished(int)));
|
connect(dynamic_cast<QObject*>(report), SIGNAL(renderPageFinished(int)), this, SLOT(renderPageFinished(int)));
|
||||||
connect(m_reportDesignWidget->report(), SIGNAL(renderFinished()), this, SLOT(renderFinished()));
|
connect(dynamic_cast<QObject*>(report), SIGNAL(renderFinished()), this, SLOT(renderFinished()));
|
||||||
connect(m_reportDesignWidget, SIGNAL(pageAdded(PageDesignIntf*)), this, SLOT(slotPageAdded(PageDesignIntf*)));
|
connect(m_reportDesignWidget, SIGNAL(pageAdded(PageDesignIntf*)), this, SLOT(slotPageAdded(PageDesignIntf*)));
|
||||||
connect(m_reportDesignWidget, SIGNAL(pageDeleted()), this, SLOT(slotPageDeleted()));
|
connect(m_reportDesignWidget, SIGNAL(pageDeleted()), this, SLOT(slotPageDeleted()));
|
||||||
}
|
}
|
||||||
@ -1311,7 +1311,7 @@ void ReportDesignWindow::renderStarted()
|
|||||||
{
|
{
|
||||||
if (m_showProgressDialog){
|
if (m_showProgressDialog){
|
||||||
m_progressDialog = new QProgressDialog(tr("Rendering report"),tr("Abort"),0,0,this);
|
m_progressDialog = new QProgressDialog(tr("Rendering report"),tr("Abort"),0,0,this);
|
||||||
m_progressDialog->open(m_reportDesignWidget->report(),SLOT(cancelRender()));
|
m_progressDialog->open(dynamic_cast<QObject*>(m_reportDesignWidget->report()), SLOT(cancelRender()));
|
||||||
QApplication::processEvents();
|
QApplication::processEvents();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -59,7 +59,7 @@ class ReportDesignWindow : public QMainWindow
|
|||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
explicit ReportDesignWindow(ReportEngine *report, QWidget *parent = 0, QSettings* settings=0);
|
explicit ReportDesignWindow(ReportEnginePrivateInterface *report, QWidget *parent = 0, QSettings* settings=0);
|
||||||
~ReportDesignWindow();
|
~ReportDesignWindow();
|
||||||
static ReportDesignWindow* instance(){return m_instance;}
|
static ReportDesignWindow* instance(){return m_instance;}
|
||||||
|
|
||||||
@ -140,7 +140,7 @@ private:
|
|||||||
void createItemsActions();
|
void createItemsActions();
|
||||||
void createObjectInspector();
|
void createObjectInspector();
|
||||||
void createObjectsBrowser();
|
void createObjectsBrowser();
|
||||||
void initReportEditor(ReportEngine *report);
|
void initReportEditor(ReportEnginePrivateInterface* report);
|
||||||
void createDataWindow();
|
void createDataWindow();
|
||||||
void createScriptWindow();
|
void createScriptWindow();
|
||||||
#ifdef HAVE_QTDESIGNER_INTEGRATION
|
#ifdef HAVE_QTDESIGNER_INTEGRATION
|
||||||
|
@ -34,6 +34,7 @@
|
|||||||
#include <QApplication>
|
#include <QApplication>
|
||||||
#include <QDesktopWidget>
|
#include <QDesktopWidget>
|
||||||
#include <QFileSystemWatcher>
|
#include <QFileSystemWatcher>
|
||||||
|
#include <QPluginLoader>
|
||||||
|
|
||||||
#include "time.h"
|
#include "time.h"
|
||||||
|
|
||||||
@ -42,8 +43,9 @@
|
|||||||
|
|
||||||
#include "lrpagedesignintf.h"
|
#include "lrpagedesignintf.h"
|
||||||
#include "lrdatasourcemanager.h"
|
#include "lrdatasourcemanager.h"
|
||||||
#include "lrdatabrowser.h"
|
//#include "lrdatabrowser.h"
|
||||||
#include "lrreportdesignwindow.h"
|
//#include "lrreportdesignwindow.h"
|
||||||
|
|
||||||
|
|
||||||
#include "serializators/lrxmlwriter.h"
|
#include "serializators/lrxmlwriter.h"
|
||||||
#include "serializators/lrxmlreader.h"
|
#include "serializators/lrxmlreader.h"
|
||||||
@ -51,6 +53,8 @@
|
|||||||
#include "lrpreviewreportwindow.h"
|
#include "lrpreviewreportwindow.h"
|
||||||
#include "lrpreviewreportwidget.h"
|
#include "lrpreviewreportwidget.h"
|
||||||
#include "lrpreviewreportwidget_p.h"
|
#include "lrpreviewreportwidget_p.h"
|
||||||
|
|
||||||
|
|
||||||
#ifdef HAVE_STATIC_BUILD
|
#ifdef HAVE_STATIC_BUILD
|
||||||
#include "lrfactoryinitializer.h"
|
#include "lrfactoryinitializer.h"
|
||||||
#endif
|
#endif
|
||||||
@ -64,7 +68,7 @@ ReportEnginePrivate::ReportEnginePrivate(QObject *parent) :
|
|||||||
m_showProgressDialog(true), m_reportName(""), m_activePreview(0),
|
m_showProgressDialog(true), m_reportName(""), m_activePreview(0),
|
||||||
m_previewWindowIcon(":/report/images/logo32"), m_previewWindowTitle(tr("Preview")),
|
m_previewWindowIcon(":/report/images/logo32"), m_previewWindowTitle(tr("Preview")),
|
||||||
m_reportRendering(false), m_resultIsEditable(true), m_passPhrase("HjccbzHjlbyfCkjy"),
|
m_reportRendering(false), m_resultIsEditable(true), m_passPhrase("HjccbzHjlbyfCkjy"),
|
||||||
m_fileWatcher( new QFileSystemWatcher( this ) ), m_reportLanguage(QLocale::AnyLanguage)
|
m_fileWatcher( new QFileSystemWatcher( this ) ), m_reportLanguage(QLocale::AnyLanguage), m_designerFactory(0)
|
||||||
{
|
{
|
||||||
#ifdef HAVE_STATIC_BUILD
|
#ifdef HAVE_STATIC_BUILD
|
||||||
initResources();
|
initResources();
|
||||||
@ -83,6 +87,29 @@ ReportEnginePrivate::ReportEnginePrivate(QObject *parent) :
|
|||||||
m_datasources->setObjectName("datasources");
|
m_datasources->setObjectName("datasources");
|
||||||
connect(m_datasources,SIGNAL(loadCollectionFinished(QString)),this,SLOT(slotDataSourceCollectionLoaded(QString)));
|
connect(m_datasources,SIGNAL(loadCollectionFinished(QString)),this,SLOT(slotDataSourceCollectionLoaded(QString)));
|
||||||
connect(m_fileWatcher,SIGNAL(fileChanged(const QString &)),this,SLOT(slotLoadFromFile(const QString &)));
|
connect(m_fileWatcher,SIGNAL(fileChanged(const QString &)),this,SLOT(slotLoadFromFile(const QString &)));
|
||||||
|
|
||||||
|
QDir pluginsDir( "../lib" );
|
||||||
|
foreach( const QString& pluginName, pluginsDir.entryList( QDir::Files ) ) {
|
||||||
|
qDebug() << "===============================================================================";
|
||||||
|
qDebug() << "Found:" << pluginName;
|
||||||
|
|
||||||
|
QPluginLoader loader( pluginsDir.absoluteFilePath( pluginName ) );
|
||||||
|
if( loader.load() ) {
|
||||||
|
if( LimeReportPluginInterface* myPlugin = qobject_cast< LimeReportPluginInterface* >( loader.instance() ) ) {
|
||||||
|
qDebug() << "Testing: \n" <<
|
||||||
|
"(1)" << myPlugin->getString() << "\n" <<
|
||||||
|
"(2)" << myPlugin->getVar();
|
||||||
|
m_designerFactory = myPlugin;
|
||||||
|
}
|
||||||
|
//loader.unload();
|
||||||
|
} else {
|
||||||
|
qDebug() << "Failed to load :(";
|
||||||
|
qDebug() << loader.errorString();
|
||||||
|
}
|
||||||
|
|
||||||
|
qDebug() << "";
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ReportEnginePrivate::~ReportEnginePrivate()
|
ReportEnginePrivate::~ReportEnginePrivate()
|
||||||
@ -619,21 +646,32 @@ PageDesignIntf* ReportEngine::createPreviewScene(QObject* parent){
|
|||||||
void ReportEnginePrivate::designReport()
|
void ReportEnginePrivate::designReport()
|
||||||
{
|
{
|
||||||
if (!m_designerWindow) {
|
if (!m_designerWindow) {
|
||||||
Q_Q(ReportEngine);
|
// Q_Q(ReportEngine);
|
||||||
m_designerWindow = new LimeReport::ReportDesignWindow(q,QApplication::activeWindow(),settings());
|
if (m_designerFactory){
|
||||||
m_designerWindow->setAttribute(Qt::WA_DeleteOnClose,true);
|
settings()->beginGroup("DesignerWindow");
|
||||||
m_designerWindow->setWindowIcon(QIcon(":report/images/logo32"));
|
settings()->setValue("showProgressDialog",m_showProgressDialog);
|
||||||
m_designerWindow->setShowProgressDialog(m_showProgressDialog);
|
settings()->endGroup();
|
||||||
|
m_designerWindow = m_designerFactory->getDesignerWindow(this,QApplication::activeWindow(),settings());
|
||||||
|
//m_designerWindow->setAttribute(Qt::WA_DeleteOnClose,true);
|
||||||
|
//m_designerWindow->setWindowIcon(QIcon(":report/images/logo32"));
|
||||||
|
//m_designerWindow->setShowProgressDialog(m_showProgressDialog);
|
||||||
|
} else {
|
||||||
|
//m_designerWindow = new LimeReport::ReportDesignWindow(this,QApplication::activeWindow(),settings());
|
||||||
|
//m_designerWindow->setAttribute(Qt::WA_DeleteOnClose,true);
|
||||||
|
//m_designerWindow->setWindowIcon(QIcon(":report/images/logo32"));
|
||||||
|
//m_designerWindow->setShowProgressDialog(m_showProgressDialog);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
m_datasources->updateDatasourceModel();
|
m_datasources->updateDatasourceModel();
|
||||||
#ifdef Q_OS_WIN
|
#ifdef Q_OS_WIN
|
||||||
m_designerWindow->setWindowModality(Qt::ApplicationModal);
|
m_designerWindow->setWindowModality(Qt::ApplicationModal);
|
||||||
#endif
|
#endif
|
||||||
if (QApplication::activeWindow()==0){
|
// if (QApplication::activeWindow()==0){
|
||||||
m_designerWindow->show();;
|
// m_designerWindow->show();;
|
||||||
} else {
|
// } else {
|
||||||
m_designerWindow->showModal();
|
// m_designerWindow->showModal();
|
||||||
}
|
// }
|
||||||
|
m_designerWindow->show();
|
||||||
}
|
}
|
||||||
|
|
||||||
void ReportEnginePrivate::setSettings(QSettings* value)
|
void ReportEnginePrivate::setSettings(QSettings* value)
|
||||||
|
@ -42,6 +42,7 @@
|
|||||||
#include "serializators/lrstorageintf.h"
|
#include "serializators/lrstorageintf.h"
|
||||||
#include "lrscriptenginemanager.h"
|
#include "lrscriptenginemanager.h"
|
||||||
#include "lrreporttranslation.h"
|
#include "lrreporttranslation.h"
|
||||||
|
#include "lrdesignerplugininterface.h"
|
||||||
|
|
||||||
class QFileSystemWatcher;
|
class QFileSystemWatcher;
|
||||||
|
|
||||||
@ -53,7 +54,40 @@ class ReportDesignWindow;
|
|||||||
|
|
||||||
//TODO: Add on render callback
|
//TODO: Add on render callback
|
||||||
|
|
||||||
class ReportEnginePrivate : public QObject, public ICollectionContainer, public ITranslationContainer
|
class ReportEnginePrivateInterface {
|
||||||
|
public:
|
||||||
|
virtual PageDesignIntf* appendPage(const QString& pageName="") = 0;
|
||||||
|
virtual bool deletePage(PageDesignIntf *page) = 0;
|
||||||
|
virtual void reorderPages(const QList<PageDesignIntf *> &reorderedPages) = 0;
|
||||||
|
virtual int pageCount() = 0;
|
||||||
|
virtual PageDesignIntf* pageAt(int index) = 0;
|
||||||
|
virtual void clearReport() = 0;
|
||||||
|
virtual ScriptEngineContext* scriptContext() = 0;
|
||||||
|
virtual ScriptEngineManager* scriptManager() = 0;
|
||||||
|
virtual DataSourceManager* dataManager() = 0;
|
||||||
|
virtual QString reportFileName() = 0;
|
||||||
|
virtual void setReportFileName(const QString& reportFileName) = 0;
|
||||||
|
virtual void emitSaveFinished() = 0;
|
||||||
|
virtual bool isNeedToSave() = 0;
|
||||||
|
virtual void emitSaveReport() = 0;
|
||||||
|
virtual bool saveToFile() = 0;
|
||||||
|
virtual bool saveToFile(const QString& fileName) = 0;
|
||||||
|
virtual bool isSaved() = 0;
|
||||||
|
virtual QString reportName() = 0;
|
||||||
|
virtual bool loadFromFile(const QString& fileName, bool autoLoadPreviewOnChange) = 0;
|
||||||
|
virtual bool emitLoadReport() = 0;
|
||||||
|
virtual void clearSelection() = 0;
|
||||||
|
virtual bool printReport(QPrinter *printer=0) = 0;
|
||||||
|
virtual void previewReport(PreviewHints hints = PreviewBarsUserSetting) = 0;
|
||||||
|
virtual void setCurrentReportsDir(const QString& dirName) = 0;
|
||||||
|
virtual QString currentReportsDir() = 0;
|
||||||
|
virtual bool suppressFieldAndVarError() const = 0;
|
||||||
|
virtual void setSuppressFieldAndVarError(bool suppressFieldAndVarError) = 0;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
class ReportEnginePrivate : public QObject, public ICollectionContainer, public ITranslationContainer,
|
||||||
|
public ReportEnginePrivateInterface
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
Q_DECLARE_PUBLIC(ReportEngine)
|
Q_DECLARE_PUBLIC(ReportEngine)
|
||||||
@ -195,7 +229,7 @@ private:
|
|||||||
QMainWindow* m_activePreview;
|
QMainWindow* m_activePreview;
|
||||||
QIcon m_previewWindowIcon;
|
QIcon m_previewWindowIcon;
|
||||||
QString m_previewWindowTitle;
|
QString m_previewWindowTitle;
|
||||||
QPointer<ReportDesignWindow> m_designerWindow;
|
QPointer<QMainWindow> m_designerWindow;
|
||||||
ReportSettings m_reportSettings;
|
ReportSettings m_reportSettings;
|
||||||
bool m_reportRendering;
|
bool m_reportRendering;
|
||||||
bool m_resultIsEditable;
|
bool m_resultIsEditable;
|
||||||
@ -205,6 +239,7 @@ private:
|
|||||||
QLocale::Language m_reportLanguage;
|
QLocale::Language m_reportLanguage;
|
||||||
void activateLanguage(QLocale::Language language);
|
void activateLanguage(QLocale::Language language);
|
||||||
Qt::LayoutDirection m_previewLayoutDirection;
|
Qt::LayoutDirection m_previewLayoutDirection;
|
||||||
|
LimeReportPluginInterface* m_designerFactory;
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -48,7 +48,7 @@ void ScriptEditor::initEditor(DataSourceManager* dm)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ScriptEditor::setReportEngine(ReportEnginePrivate* reportEngine)
|
void ScriptEditor::setReportEngine(ReportEnginePrivateInterface* reportEngine)
|
||||||
{
|
{
|
||||||
m_reportEngine = reportEngine;
|
m_reportEngine = reportEngine;
|
||||||
DataSourceManager* dm = m_reportEngine->dataManager();
|
DataSourceManager* dm = m_reportEngine->dataManager();
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
namespace LimeReport{
|
namespace LimeReport{
|
||||||
|
|
||||||
class ReportEnginePrivate;
|
class ReportEnginePrivateInterface;
|
||||||
class BaseDesignIntf;
|
class BaseDesignIntf;
|
||||||
class PageDesignIntf;
|
class PageDesignIntf;
|
||||||
class BandDesignIntf;
|
class BandDesignIntf;
|
||||||
@ -25,7 +25,7 @@ class ScriptEditor : public QWidget
|
|||||||
public:
|
public:
|
||||||
explicit ScriptEditor(QWidget *parent = 0);
|
explicit ScriptEditor(QWidget *parent = 0);
|
||||||
~ScriptEditor();
|
~ScriptEditor();
|
||||||
void setReportEngine(ReportEnginePrivate* reportEngine);
|
void setReportEngine(LimeReport::ReportEnginePrivateInterface* reportEngine);
|
||||||
void setReportPage(PageDesignIntf* page);
|
void setReportPage(PageDesignIntf* page);
|
||||||
void setPageBand(BandDesignIntf* band);
|
void setPageBand(BandDesignIntf* band);
|
||||||
void initCompleter();
|
void initCompleter();
|
||||||
@ -48,7 +48,7 @@ private:
|
|||||||
void addItemToCompleater(const QString& pageName, BaseDesignIntf* item, QStringList& dataWords);
|
void addItemToCompleater(const QString& pageName, BaseDesignIntf* item, QStringList& dataWords);
|
||||||
private:
|
private:
|
||||||
Ui::ScriptEditor *ui;
|
Ui::ScriptEditor *ui;
|
||||||
ReportEnginePrivate* m_reportEngine;
|
ReportEnginePrivateInterface* m_reportEngine;
|
||||||
PageDesignIntf* m_page;
|
PageDesignIntf* m_page;
|
||||||
QCompleter* m_completer;
|
QCompleter* m_completer;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user