XFA: rendering of rectangle elements and borders

This commit is contained in:
Jakub Melka
2021-11-20 18:42:25 +01:00
parent 6b7e839618
commit aab5c41e12
5 changed files with 465 additions and 5 deletions

View File

@@ -1330,12 +1330,12 @@ void PDFAnnotationManager::drawPage(QPainter* painter,
Q_UNUSED(compiledPage);
Q_UNUSED(layoutGetter);
const PDFPage* page = m_document->getCatalog()->getPage(pageIndex);
Q_ASSERT(page);
const PageAnnotations& annotations = getPageAnnotations(pageIndex);
if (!annotations.isEmpty())
{
const PDFPage* page = m_document->getCatalog()->getPage(pageIndex);
Q_ASSERT(page);
PDFRenderer::Features features = m_features;
if (!features.testFlag(PDFRenderer::DisplayAnnotations))
{
@@ -1377,6 +1377,12 @@ void PDFAnnotationManager::drawPage(QPainter* painter,
m_fontCache->setCacheShrinkEnabled(&fontCacheLock, true);
}
// Draw XFA form
if (m_formManager)
{
m_formManager->drawXFAForm(pagePointToDevicePointMatrix, page, errors, painter);
}
}
void PDFAnnotationManager::drawAnnotation(const PageAnnotation& annotation,