Skip to main content

pdfls is a small utility to debug a PDF file.

Project description

pdfls

Build Status

pdfls is a small utility to debug a PDF file.

pdftitle uses pdfminer.six project to parse PDF document.

Installation

pip install pdfls

Usage

pdfls -p <pdf-file> displays the structure of the PDF file.

For example:

$ pdfls -p knuth65.pdf

catalog.objnum: 713
outlines:
pagetree.objnum: 709
  page[1].objnum: 715
		xobject.types: [ Im1=XObject.Image/CCITTFaxDecode.1710x2580 ]
		content.length: [ 654/2094 548/2092 556/2090 600/2094 605/2103 595/2090 560/2096 615/2066 ]
	page[2].objnum: 1
		xobject.types: [ Im1=XObject.Image/CCITTFaxDecode.1710x2580 ]
		content.length: [ 113/134 4054/22698 41/39 11/3 ]
	page[3].objnum: 13
		xobject.types: [ Im1=XObject.Image/CCITTFaxDecode.1710x2580 ]
		content.length: [ 172/332 2784/14487 79/80 41/39 11/3 ]
...
...

shows the catalog, page tree and first 3 page objects. For each page object, xobjects and contents (content streams) are shown. For each XObject, its type.subtype/filter.widthxheight is shown. For each content stream, its raw data len/decoded data len is shown.

If -i option is given, it also shows the instructions.

More info can be seen in verbose mode with -v. This is mostly for development and debugging of pdfls.

Changes

0.1:

  • first public release.
  • probably unstable version, only for testing.

Project details


Release history Release notifications | RSS feed

This version

0.1

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pdfls-0.1.tar.gz (4.2 kB view details)

Uploaded Source

File details

Details for the file pdfls-0.1.tar.gz.

File metadata

  • Download URL: pdfls-0.1.tar.gz
  • Upload date:
  • Size: 4.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.4.2 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/3.8.10

File hashes

Hashes for pdfls-0.1.tar.gz
Algorithm Hash digest
SHA256 dde35e9df51b9107eab2fc2288b6044d49582e25be0887789b8506e63fe23744
MD5 bd2b606455c7487e556255ac7d4ed9a6
BLAKE2b-256 c7631ed504c29c3695badb6437ff999e5c383023ca15afc92554bbabf684b04f

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page