0
0
mirror of https://github.com/fralx/LimeReport.git synced 2025-11-25 08:28:06 +03:00

useAlternateBackgroundColor property has been added

This commit is contained in:
Arin Alexander
2017-03-04 00:21:21 +03:00
parent 4c6c0dfd3b
commit 242dbe75d2
6 changed files with 58 additions and 12 deletions

View File

@@ -431,13 +431,14 @@ BandDesignIntf* ReportRender::renderBand(BandDesignIntf *patternBand, BandDesign
if (patternBand->isFooter())
m_lastRenderedFooter = patternBand;
bandClone->setBackgroundColor(
(datasources()->variable(QLatin1String("line_")+patternBand->objectName().toLower()).toInt() %2 !=0 ?
bandClone->backgroundColor():
bandClone->alternateBackgroundColor()
)
);
if (bandClone->useAlternateBackgroundColor()){
bandClone->setBackgroundColor(
(datasources()->variable(QLatin1String("line_")+patternBand->objectName().toLower()).toInt() %2 == 0 ?
bandClone->backgroundColor() :
bandClone->alternateBackgroundColor()
)
);
}
patternBand->emitBandRendered(bandClone);
emit(patternBand->afterRender());