Q: I have tried to understand ElementReaderAdv.java class, and but I
didn't get that how to extract all marked area in pdf.
Let me explain you my exact requirement:
Before doing extraction, I am marking all the required areas as a
figure in pdf using "TouchUp Reading Order" tool of pdf. After marking
all areas I am trying to extract all those areas at run time without
knowing the location of marked areas. I meant I have to find these
areas coordinates at run time then need to extract those areas.
According to me I think its possible because when I have marked three
areas in pdf and then calculate the "Element.e_marked_content_begin"
data it was showing three more than of the previous one, this means
its reading these marked areas, but I don't know how to convert these
areas in image and export it.
Now tell me, is it possible? If yes, then please let me know with some
Since I am new for that API, so please guide me how to do that?
A: ElementReaderAdv (http://www.pdftron.com/pdfnet/
samplecode.html#ElementReaderAdv) and LogicalStructure (http://
are probably the best place to look at.
Since you want to extract content based on marked content you would
need to look for marked content identifiers
(Element.e_marked_content_begin/end etc.) in the display list and use
them to identify start/end point for your copy operation.
You may also want to check out ElementEdit sample
Which shows how you could selectively copy elements from one page to
another (or to the same page).