Logo Search packages:      
Sourcecode: libpodofo version File versions  Download package

int PoDoFo::PdfPage::GetNumFields (  ) const
the number of PdfFields on this page.

Definition at line 517 of file PdfPage.cpp.

References GetAnnotation(), PoDoFo::PdfVariant::GetDictionary(), GetNumAnnots(), PoDoFo::PdfElement::GetObject(), PoDoFo::PdfAnnotation::GetType(), and PoDoFo::PdfDictionary::HasKey().

    int                  nCount  = 0;
    int                  nAnnots = this->GetNumAnnots();
    const PdfAnnotation* pAnnot  = NULL;
    for( int i=0;i<nAnnots;i++ )
        pAnnot = const_cast<PdfPage*>(this)->GetAnnotation( i );
        // Count every widget annotation with a FieldType as PdfField
        if( pAnnot->GetType() == ePdfAnnotation_Widget && 
            pAnnot->GetObject()->GetDictionary().HasKey( PdfName("FT") ) )

    return nCount;

Here is the call graph for this function:

Generated by  Doxygen 1.6.0   Back to index