James R. Barlow
d6128e6937
Fix support for older versions of pdfminer.six (boxes_flow error)
2020-07-26 21:51:25 -07:00
James R. Barlow
642437e804
Merge branch 'master' of github.com:jbarlow83/OCRmyPDF
2020-07-22 00:34:33 -07:00
James R. Barlow
a672422b0b
Enable pikepdf mmap in other contexts
2020-07-22 00:20:07 -07:00
James R. Barlow
addc2cbad0
Enable pikepdf mmap and set up signal handlers
2020-07-22 00:19:50 -07:00
James R. Barlow
93f9bffb37
Merge branch 'feature/leptonica-179'
2020-07-20 21:23:53 -07:00
James R. Barlow
44149ad319
Disable test_error_trap for Leptonica < 1.79
...
Old error trap seems unreliable in the first place so difficult to set up
a test.
2020-07-20 21:12:00 -07:00
fcatus and GitHub
d80d963cea
pdfinfo: Replace list comp with gen expr'n
2020-07-20 02:21:58 -07:00
James R. Barlow
5cbbff8472
For Leptonica 1.79+ use leptSetStderrHandler
...
Lock free and considerably less dangerous to stderr messages.
2020-07-19 03:40:33 -07:00
James R. Barlow
fa6e47c277
Merge branch 'feature/optimize-cleanup'
2020-07-19 01:53:11 -07:00
James R. Barlow
4ea9cffebd
Add locking to Leptonica error trap
...
To protect another thread from interfering with our redirection of
stderr.
2020-07-19 01:51:58 -07:00
James R. Barlow
1558e068f1
docs: explain firstresult hook behavior
2020-07-16 00:01:59 -07:00
James R. Barlow
a510b21b20
optimize: add typing for Xref, remove fspath()'s
2020-07-09 14:06:41 -07:00
James R. Barlow
373f27832b
optimize: improve typing of xref_exts
2020-07-07 22:41:29 -07:00
James R. Barlow
b20a6e4c5d
optimize: add type hints
2020-07-07 22:18:50 -07:00
James R. Barlow
49734d5456
optimize: fix incorrect to prevent re-optimizing JBIG2s
2020-07-07 21:52:11 -07:00
James R. Barlow
60be64a5f1
Fix debug.log missing pageno handler
2020-07-04 03:59:38 -07:00
James R. Barlow
190294634c
docs: edit plugins
2020-07-03 16:16:01 -07:00
James R. Barlow
dc42beb6a8
More typing improvements
...
Typing fixes bugs.
2020-06-30 15:02:30 -07:00
James R. Barlow
378f543619
TextPositionTracker: set boxes_flow=None
...
We don't care about the order of lines in our analysis, and this is an
expensive calculation in pdfminer.
2020-06-30 04:20:58 -07:00
James R. Barlow
62924ee280
Improve API documentation
2020-06-30 04:20:14 -07:00
James R. Barlow
86a73191b0
Plugin manager: accept Path(plugin)
2020-06-30 04:17:30 -07:00
James R. Barlow
86875997b8
Fix more mypy errors
2020-06-29 02:17:14 -07:00
James R. Barlow
b939584c7a
quality: fixing typing issues
2020-06-29 01:45:45 -07:00
James R. Barlow
30404f53f0
Add test to sanity check our pdf renderers
2020-06-22 16:18:38 -07:00
James R. Barlow
1ce8edbdfe
hocrtransform: some text not included in output after Tesseract changes
2020-06-22 15:48:23 -07:00
James R. Barlow
d4b704a0ae
hocrtransform: refactor colors
2020-06-22 15:22:48 -07:00
James R. Barlow
2d64e1536d
hocrtransform: refactor xpath manipulations
2020-06-22 14:44:34 -07:00
James R. Barlow
c8b581ac31
hoctransform: remove deprecated element.getchildren()
...
Breaks Python 3.9.
2020-06-22 14:28:18 -07:00
James R. Barlow
ad8dead7df
Document that API accepts streams now
2020-06-22 14:27:27 -07:00
James R. Barlow
c9bd87254e
A few minor typing issues
2020-06-22 02:31:53 -07:00
James R. Barlow and James R. Barlow
f4cb424451
Support input/output streams at API level
2020-06-22 02:02:18 -07:00
James R. Barlow
86ec63f215
Decouple plugin manager forking from PdfContext/Pagecontext
2020-06-22 01:16:59 -07:00
James R. Barlow
5b10ec9d39
jobcontext.PdfContext: remove dead code, add annotations
2020-06-22 00:34:58 -07:00
James R. Barlow
ebfe4f0d29
Fix issue #582 - PDF/A acquires title "Untitled" after conversion
2020-06-20 02:01:16 -07:00
James R. Barlow
6ac50646f0
Fix OMP_THREAD_LIMIT rounded down to 0 in some cases
2020-06-17 14:43:19 -07:00
James R. Barlow
e802896d4d
unpaper: use PNG input where possible
...
Unpaper accepts PNG as input now, so avoid generating a huge
temporary PPM file if we can. If we
must create a PNG, compress it lightly to keep our temp usage down.
2020-06-16 00:50:18 -07:00
James R. Barlow
642998ead6
sync: refactor preprocess image filtering
2020-06-15 15:26:41 -07:00
James R. Barlow
698aab4f75
Add a lot of type annotations
2020-06-15 15:20:50 -07:00
James R. Barlow
34231ac667
sync: refactor intermediate image production
2020-06-15 15:02:28 -07:00
James R. Barlow
ddedf7cd2e
For --clean-final, use same image as --clean if possible
2020-06-15 13:48:49 -07:00
James R. Barlow
9d127d354c
docs: improve description of plugins
2020-06-15 12:51:49 -07:00
James R. Barlow
862861e3ca
Fix error message in logging from repeated filtering
...
If logging somehow triggers PageNumberFilter multiple times, it would fail on the second occurrence.
2020-06-13 14:50:58 -07:00
James R. Barlow
eeb44f78cc
Fix tests that failed on other platforms from previous fix
2020-06-12 12:59:46 -07:00
James R. Barlow
393c5a9ea4
Fix error on -l lang1+lang2
2020-06-12 12:10:29 -07:00
James R. Barlow
7caf1e85ff
info: change "Scan" message
2020-06-10 12:11:37 -07:00
James R. Barlow
f59a757e8b
info: tidy handling of content streams
2020-06-10 12:09:24 -07:00
James R. Barlow
872bafad4b
Reinstate quick test for text/no text
...
Partial revert of commit 991db17
2020-06-10 12:00:52 -07:00
James R. Barlow
8599400445
Only do page analysis on pages we will do OCR on
2020-06-10 11:33:27 -07:00
James R. Barlow
b6eebadf05
Use pikepdf.open with block to manage PdfInfo
2020-06-10 11:32:46 -07:00
James R. Barlow
a4e88eb8f0
Simplify plugin_manager pickling
2020-06-10 00:41:19 -07:00