[poppler] Regarding page search

amit aggarwal amitcs06 at gmail.com
Wed Mar 10 04:33:43 PST 2010


Hi All,

I am using page search API in different thread to search the word of
that particular page. But I am getting one problem that its returning
same co-ordinate every time even though that page is containing more
than 2 search hit also.
So that while loop is never ending. Please help me for the same and
let me know If I am doing something wrong.

I am attaching my code snippets and log also.

     QRectF searchHit;
     while(mDocument->page(pageindex)->search(
                searchText,
                searchHit,
                Poppler::Page::NextResult,
                Poppler::Page::CaseInsensitive)) {


qDebug()<<"**********Page:"<<pageIndex+1<<"qrect:"<<searchHit<<"searchText:"<<searchText;
                (mResults[page]).append(searchHit);
    }

Debug: **********Page: 1 qrect: QRectF(391.9,226.28 110.48x46.52)
searchText: "Office"
Debug: **********Page: 1 qrect: QRectF(391.9,226.28 110.48x46.52)
searchText: "Office"
Debug: **********Page: 1 qrect: QRectF(391.9,226.28 110.48x46.52)
searchText: "Office"
Debug: **********Page: 1 qrect: QRectF(391.9,226.28 110.48x46.52)
searchText: "Office"
Debug: **********Page: 1 qrect: QRectF(391.9,226.28 110.48x46.52)
searchText: "Office"
Debug: **********Page: 1 qrect: QRectF(391.9,226.28 110.48x46.52)
searchText: "Office"
Debug: **********Page: 1 qrect: QRectF(391.9,226.28 110.48x46.52)
searchText: "Office"
Debug: **********Page: 1 qrect: QRectF(391.9,226.28 110.48x46.52)
searchText: "Office"
Debug: **********Page: 1 qrect: QRectF(391.9,226.28 110.48x46.52)
searchText: "Office"



-- 
Thanks
Amit Aggarwal


More information about the poppler mailing list