dump_text

Print PDF text data to the console or a file

Usage

pdftl <input> dump_text [output <output>]

Details

The dump_text operation attempts to extract text from a PDF file and dumps it to stdout or the given output file.

Warning This is experimental and may be unreliable.

It uses the python library pypdfium2. To automatically install this optional dependency run:

pip install pdftl[dump-text]

Examples

Print destinations for in.pdf

pdftl in.pdf dump_text

Save text from in.pdf to out.txt

pdftl in.pdf dump_text output out.txt

Tags: info, text, experimental

Source: pdftl.operations.dump_text

Read online: https://pdftl.readthedocs.io/en/stable/operations/dump_text.html

Type: Operation