mirror of
https://github.com/jsvine/pdfplumber.git
synced 2026-08-29 08:34:23 +08:00
21 lines
453 B
Python
21 lines
453 B
Python
from pdfplumber.pdf import PDF
|
|
import pdfplumber.utils
|
|
import pdfminer
|
|
import pdfminer.pdftypes
|
|
pdfminer.pdftypes.STRICT = False
|
|
pdfminer.pdfinterp.STRICT = False
|
|
|
|
VERSION_TUPLE = (0, 2, 0)
|
|
VERSION = ".".join(map(str, VERSION_TUPLE))
|
|
|
|
def load(file_or_buffer, **kwargs):
|
|
return PDF(file_or_buffer, **kwargs)
|
|
|
|
def from_path(path, **kwargs):
|
|
return PDF(open(path, "rb"), **kwargs)
|
|
|
|
def set_debug(debug=0):
|
|
pdfminer.debug = debug
|
|
|
|
set_debug(0)
|