Because it turned out that people wanted to extract text from PDFs (and not just view them), Adobe added a feature called marked content. This allows the PDF file to contain additional tags as information, preserving the structure of the text. However, this feature needs to be used in the creation of the PDF – otherwise the additional information is not there!
There is a very easy way to tell if the PDF file has been created in this way. Open the file in Acrobat Reader and look at the properties menu – the Tagged PDF menu option (bottom left entry on the advanced section) tells you if the PDF contains these extra tags. This file does not.
If you can create Tagged PDF, it is worth setting this on by default – the files are not much larger and it makes text extraction much more viable if you need it in the future.
This post is part of our “Understanding the PDF File Format” series. In each article, we discuss a PDF feature, bug, gotcha or tip. If you wish to learn more about PDF, we have 13 years worth of PDF knowledge and tips, so click here to visit our series index!
Latest posts by Mark Stephens (see all)
- Final details for NetBeans Day UK next week…. - May 19, 2015
- FSB networking event – Seller beware… - May 14, 2015
- 4 ways to get the most from Android Developer Days (Ankara – May 11-12th 2015) - May 9, 2015
- Exciting list of speakers for NetBeans UK Day 29th May - May 8, 2015
- IDRsolutions releases JPedal 6 - April 27, 2015