Changeset View
Changeset View
Standalone View
Standalone View
src/renderer/KReportPreRenderer.cpp
Show First 20 Lines • Show All 360 Lines • ▼ Show 20 Line(s) | 359 | } else { | |||
---|---|---|---|---|---|
361 | itemHeight = ob->renderSimpleData(m_page, sec, offset, itemData, m_scriptHandler); | 361 | itemHeight = ob->renderSimpleData(m_page, sec, offset, itemData, m_scriptHandler); | ||
362 | } | 362 | } | ||
363 | } | 363 | } | ||
364 | 364 | | |||
365 | if (itemHeight > sectionHeight) { | 365 | if (itemHeight > sectionHeight) { | ||
366 | sectionHeight = itemHeight; | 366 | sectionHeight = itemHeight; | ||
367 | } | 367 | } | ||
368 | } | 368 | } | ||
369 | for (int i = 0; i < m_page->primitives(); ++i) { | 369 | for (int i = 0; i < m_page->primitiveCount(); ++i) { | ||
370 | OROPrimitive *prim = m_page->primitive(i); | 370 | OROPrimitive *prim = m_page->primitive(i); | ||
371 | if (prim->type() == OROTextBox::TextBox) { | 371 | if (prim->type() == OROTextBox::TextBox) { | ||
372 | OROTextBox *text = static_cast<OROTextBox*>(prim); | 372 | OROTextBox *text = static_cast<OROTextBox*>(prim); | ||
373 | if (text->requiresPostProcessing()) { | 373 | if (text->requiresPostProcessing()) { | ||
374 | m_postProcText.append(text); | 374 | m_postProcText.append(text); | ||
375 | } | 375 | } | ||
376 | } | 376 | } | ||
377 | } | 377 | } | ||
▲ Show 20 Lines • Show All 199 Lines • ▼ Show 20 Line(s) | 573 | if (m_reportDocument->m_reportFooter) { | |||
577 | renderSection(*(m_reportDocument->m_reportFooter)); | 577 | renderSection(*(m_reportDocument->m_reportFooter)); | ||
578 | } | 578 | } | ||
579 | } | 579 | } | ||
580 | finishCurPage(true); | 580 | finishCurPage(true); | ||
581 | 581 | | |||
582 | #ifdef KREPORT_SCRIPTING | 582 | #ifdef KREPORT_SCRIPTING | ||
583 | // _postProcText contains those text boxes that need to be updated | 583 | // _postProcText contains those text boxes that need to be updated | ||
584 | // with information that wasn't available at the time it was added to the document | 584 | // with information that wasn't available at the time it was added to the document | ||
585 | m_scriptHandler->setPageTotal(m_document->pages()); | 585 | m_scriptHandler->setPageTotal(m_document->pageCount()); | ||
586 | 586 | | |||
587 | for (int i = 0; i < m_postProcText.size(); i++) { | 587 | for (int i = 0; i < m_postProcText.size(); i++) { | ||
588 | OROTextBox * tb = m_postProcText.at(i); | 588 | OROTextBox * tb = m_postProcText.at(i); | ||
589 | 589 | | |||
590 | m_scriptHandler->setPageNumber(tb->page()->page() + 1); | 590 | m_scriptHandler->setPageNumber(tb->page()->page() + 1); | ||
591 | 591 | | |||
592 | tb->setText(m_scriptHandler->evaluate(tb->text()).toString()); | 592 | tb->setText(m_scriptHandler->evaluate(tb->text()).toString()); | ||
593 | } | 593 | } | ||
▲ Show 20 Lines • Show All 105 Lines • Show Last 20 Lines |