You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@pdfbox.apache.org by David Myers <D....@astronautics.com> on 2009/11/30 19:21:52 UTC
Highlighting, Zoom, and Text Search
Hello all,
I am trying to create a PDF Document Reader using PDFBox that supports
highlighting, text search, and zoom. Is this possible with PDFBox? Are
there any examples out there that demonstrate how to do these three
things? (I didn't see any examples that demonstrate this in the
src/main/java/org/apache/pdfbox/examples folder)
Thanks for your help,
David
Locating specific text in a PDF
Posted by David Myers <D....@astronautics.com>.
Hello,
Does anyone know how to locate certain text in a PDF? Does anyone know
how to determine the height and width of this text too? (I'm trying to
implement highlighting as described in section 3 on this page
http://pdfbox.apache.org/userguide/highlighting.html)
Thanks in advance,
David
RE: Locating specific text in a PDF
Posted by David Myers <D....@astronautics.com>.
Can anyone help me with this? Is there some demo code out there that
does this?
Thanks,
David
-----Original Message-----
From: David Myers
Sent: Thursday, December 03, 2009 9:16 AM
To: 'users@pdfbox.apache.org'
Subject: Locating specific text in a PDF
Hello,
Does anyone know how to locate certain text in a PDF? Does anyone know
how to determine the height and width of this text too? (I'm trying to
implement highlighting as described in section 3 on this page
http://pdfbox.apache.org/userguide/highlighting.html)
Thanks in advance,
David
Re: Highlighting, Zoom, and Text Search
Posted by Andreas Lehmkühler <an...@lehmi.de>.
Hi,
Patrick Herber wrote:
> Hello David
>
> I'm not really an expert of PDFBox...
>
> I can tell you that text search is possible (I use it for text-extraction)
AFAIK there are 2 possible solutions:
- extract the text with [1] and just search in the result for your self
- use the integrated lucene search engine [2]
> Highlighting seams also possible:
> http://pdfbox.apache.org/userguide/highlighting.html
>
> Zooming I don't know...
> You could perhaps first convert the page as image
> (PDPage.convertToImage()) and than you can zoom the image...
Have a look at the PDFREader [3]. It's a simple PDF doucument reader. It uses
PDPage.convertToImage() to create an image for each page. It should be easy to
add zooming using Java2D.
> Best regards,
> Patrick
>
>
> David Myers wrote:
>> Can anyone help me with these questions?
>>
>> -----Original Message-----
>> From: David Myers [mailto:D.Myers@astronautics.com] Sent: Monday,
>> November 30, 2009 11:22 AM
>> To: users@pdfbox.apache.org
>> Subject: Highlighting, Zoom, and Text Search
>>
>> Hello all,
>>
>> I am trying to create a PDF Document Reader using PDFBox that supports
>> highlighting, text search, and zoom. Is this possible with PDFBox? Are
>> there any examples out there that demonstrate how to do these three
>> things? (I didn't see any examples that demonstrate this in the
>> src/main/java/org/apache/pdfbox/examples folder)
>>
>> Thanks for your help,
>>
>> David
BR
Andreas Lehmkühler
[1] http://pdfbox.apache.org/commandlineutilities/ExtractText.html
[2]
http://svn.apache.org/repos/asf/pdfbox/trunk/src/main/java/org/apache/pdfbox/searchengine/lucene/IndexFiles.java
[3]
http://svn.apache.org/repos/asf/pdfbox/trunk/src/main/java/org/apache/pdfbox/PDFReader.java
Re: Highlighting, Zoom, and Text Search
Posted by Patrick Herber <pa...@gmail.com>.
Hello David
I'm not really an expert of PDFBox...
I can tell you that text search is possible (I use it for text-extraction)
Highlighting seams also possible:
http://pdfbox.apache.org/userguide/highlighting.html
Zooming I don't know...
You could perhaps first convert the page as image
(PDPage.convertToImage()) and than you can zoom the image...
Best regards,
Patrick
David Myers wrote:
> Can anyone help me with these questions?
>
> -----Original Message-----
> From: David Myers [mailto:D.Myers@astronautics.com]
> Sent: Monday, November 30, 2009 11:22 AM
> To: users@pdfbox.apache.org
> Subject: Highlighting, Zoom, and Text Search
>
> Hello all,
>
>
>
> I am trying to create a PDF Document Reader using PDFBox that supports
> highlighting, text search, and zoom. Is this possible with PDFBox? Are
> there any examples out there that demonstrate how to do these three
> things? (I didn't see any examples that demonstrate this in the
> src/main/java/org/apache/pdfbox/examples folder)
>
>
>
> Thanks for your help,
>
>
>
> David
>
>
>
RE: Highlighting, Zoom, and Text Search
Posted by David Myers <D....@astronautics.com>.
Can anyone help me with these questions?
-----Original Message-----
From: David Myers [mailto:D.Myers@astronautics.com]
Sent: Monday, November 30, 2009 11:22 AM
To: users@pdfbox.apache.org
Subject: Highlighting, Zoom, and Text Search
Hello all,
I am trying to create a PDF Document Reader using PDFBox that supports
highlighting, text search, and zoom. Is this possible with PDFBox? Are
there any examples out there that demonstrate how to do these three
things? (I didn't see any examples that demonstrate this in the
src/main/java/org/apache/pdfbox/examples folder)
Thanks for your help,
David