PyMuPDF 1.13.20__tar.gz → 1.14.19__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,13 +1,12 @@
1
1
  Metadata-Version: 1.1
2
2
  Name: PyMuPDF
3
- Version: 1.13.20
3
+ Version: 1.14.19
4
4
  Summary: Python bindings for the PDF rendering library MuPDF
5
- Home-page: https://github.com/rk700/PyMuPDF
6
- Author: Ruikai Liu, Jorj McKie
7
- Author-email: lrk700@gmail.com
8
- License: GPLv3+
9
- Description:
10
- Release date: September 10, 2018
5
+ Home-page: https://github.com/pymupdf/PyMuPDF
6
+ Author: Jorj McKie, Ruikai Liu
7
+ Author-email: jorj.x.mckie@outlook.de
8
+ License: UNKNOWN
9
+ Description: Release date: July 18, 2019
11
10
 
12
11
  Authors
13
12
  =======
@@ -18,42 +17,43 @@ Description:
18
17
  Introduction
19
18
  ============
20
19
 
21
- This is **version 1.13.20 of PyMuPDF**, a Python binding for `MuPDF <http://mupdf.com/>`_ - "a lightweight PDF and XPS viewer".
20
+ This is **version 1.14.19 of PyMuPDF**, a Python binding for `MuPDF <http://mupdf.com/>`_ - "a lightweight PDF and XPS viewer".
22
21
 
23
- MuPDF can access files in PDF, XPS, OpenXPS, epub, comic archives and fiction book formats, and it is known for its top performance and high rendering quality.
22
+ MuPDF can access files in PDF, XPS, OpenXPS, epub, comic and fiction book formats, and it is known for both, its top performance and high rendering quality.
24
23
 
25
- PyMuPDF should run on all platforms that are supported by both, MuPDF and Python. These include, but are not limited to, Windows (XP SP2 and up), Mac OS and Linux, 32-bit or 64-bit. If you can generate MuPDF on a Python supported platform, then also PyMuPDF can be used there.
24
+ With PyMuPDF you therefore can access files with extensions ``*.pdf``, ``*.xps``, ``*.oxps``, ``*.epub``, ``*.cbz`` or ``*.fb2`` from your Python scripts. A number of popular image formats is supported as well, including multi-page TIFF images.
26
25
 
27
- PyMuPDF is hosted on `GitHub <https://github.com/rk700/PyMuPDF>`_ where you find up-to-date information of its features, our `issue tracker <https://github.com/rk700/PyMuPDF/issues>`_, `Wikis <https://github.com/rk700/PyMuPDF/wiki>`_ and much more.
26
+ PyMuPDF should run on all platforms that are supported by both, MuPDF and Python. These include, but are not limited to, Windows (XP/SP2 and up), Mac OS and Linux, 32-bit or 64-bit. If you can generate MuPDF on a Python supported platform, then also PyMuPDF can be used there.
27
+
28
+ PyMuPDF is hosted on `GitHub <https://github.com/pymupdf/PyMuPDF>`_ where you find up-to-date information of its features, our `issue tracker <https://github.com/pymupdf/PyMuPDF/issues>`_, `Wikis <https://github.com/pymupdf/PyMuPDF/wiki>`_ and much more.
28
29
 
29
30
  Installation
30
31
  ============
31
32
 
32
- For all MS Windows versions (XP/SP2 and up), and popular Max OS and Linux versions, we are providing Python wheels - see the download section of this site and the current `release directory <https://github.com/rk700/PyMuPDF/releases/latest>`_ of our home page. For Windows users, `zip-based installation <https://github.com/JorjMcKie/PyMuPDF-Optional-Material>`_ options are also available. Other platforms need to download and generate the MuPDF library first and then set up PyMuPDF. Do visit our GitHub home, which has more details on this, including latest bugfixes, pre-releases, etc.
33
+ For all MS Windows versions as well as popular Max OS and Linux versions, we are providing Python wheels - see the download section of this site and the current `release directory <https://github.com/pymupdf/PyMuPDF/releases/latest>`_ of our home page. Other platforms need to download and generate the MuPDF library first and then set up PyMuPDF. Do visit our GitHub home, which has more details on this, including latest bugfixes, pre-releases, etc.
33
34
 
34
35
  Usage and Documentation
35
36
  ========================
36
37
 
37
38
  For all document types you can render pages in raster (PNG) or vector (SVG) formats, extract text and access meta information, links, annotations and bookmarks, as well as decrypt the document. For PDF files, most of these objects can also be created, modified or deleted. Plus you can rotate, re-arrange, duplicate, create, or delete pages and join or split documents.
38
39
 
39
- Specifically for PDF files, PyMuPDF provides update access to low-level structure information, supports handling of embedded files and modification of page contents (like inserting images, fonts, text, annotations and drawings).
40
+ Specifically for PDF files, PyMuPDF provides update access to low-level structure information, supports handling of embedded files and modification of page contents (like inserting images, fonts, text, annotations and drawings). When saving changes to password protected PDFs you can now choose, whether to keep or remove encryption.
40
41
 
41
- Other features include embedding vector images (SVG, PDF) such as logos or watermarks, "posterizing" a PDF or creating "booklet" and "4-up" versions.
42
+ Other features include embedding vector images (SVG, PDF) such as logos or watermarks, joining or splitting single PDF pages (including things like posterizing and 2-up / 4-up processing).
42
43
 
43
44
  You can now also create **PDF Form fields** with support for text, checkbox, listbox and combobox widgets.
44
45
 
45
- Our home page provides many examples and How-Tos for all of this. At a minimum, read the tutorial section of our documentation.
46
+ Our home page provides many examples and How-Tos for all of this. At a minimum, read the tutorial and the the recipes sections of our documentation.
46
47
 
47
48
  Written using **Sphinx**, documentation is available here:
48
49
 
49
50
  * View it online at `Read The Docs <https://pymupdf.readthedocs.io/en/latest/>`_. For **best quality downloads**, use the following links.
50
51
 
51
- * `HTML <https://github.com/rk700/PyMuPDF/tree/master/doc/html.zip>`_
52
+ * `HTML <https://github.com/pymupdf/PyMuPDF/tree/master/doc/html.zip>`_
52
53
 
53
54
  * `Windows CHM <https://github.com/JorjMcKie/PyMuPDF-optional-material/tree/master/doc/PyMuPDF.chm>`_
54
55
 
55
- * `PDF <https://github.com/rk700/PyMuPDF/tree/master/doc/pymupdf.pdf>`_
56
-
56
+ * `PDF <https://github.com/pymupdf/PyMuPDF/tree/master/doc/pymupdf.pdf>`_
57
57
 
58
58
  Platform: UNKNOWN
59
59
  Classifier: Development Status :: 5 - Production/Stable
@@ -67,4 +67,8 @@ Classifier: Operating System :: POSIX :: Linux
67
67
  Classifier: Programming Language :: C
68
68
  Classifier: Programming Language :: Python :: 2.7
69
69
  Classifier: Programming Language :: Python :: 3
70
+ Classifier: Programming Language :: Python :: 3.4
71
+ Classifier: Programming Language :: Python :: 3.5
72
+ Classifier: Programming Language :: Python :: 3.6
73
+ Classifier: Programming Language :: Python :: 3.7
70
74
  Classifier: Topic :: Utilities
@@ -0,0 +1,85 @@
1
+ from __future__ import absolute_import
2
+ from fitz.fitz import *
3
+
4
+ # define the supported colorspaces for convenience
5
+ fitz.csRGB = fitz.Colorspace(fitz.CS_RGB)
6
+ fitz.csGRAY = fitz.Colorspace(fitz.CS_GRAY)
7
+ fitz.csCMYK = fitz.Colorspace(fitz.CS_CMYK)
8
+ csRGB = fitz.csRGB
9
+ csGRAY = fitz.csGRAY
10
+ csCMYK = fitz.csCMYK
11
+
12
+ # create the TOOLS object
13
+ TOOLS = fitz.Tools()
14
+ fitz.TOOLS = TOOLS
15
+
16
+ if fitz.VersionFitz != fitz.TOOLS.mupdf_version():
17
+ raise ValueError(
18
+ "MuPDF library mismatch %s <> %s"
19
+ % (fitz.VersionFitz, fitz.TOOLS.mupdf_version())
20
+ )
21
+
22
+
23
+ # copy functions to their respective fitz classes
24
+ import fitz.utils
25
+
26
+ # ------------------------------------------------------------------------------
27
+ # Document
28
+ # ------------------------------------------------------------------------------
29
+ fitz.open = fitz.Document
30
+ fitz.Document.getToC = fitz.utils.getToC
31
+ fitz.Document._do_links = fitz.utils.do_links
32
+ fitz.Document.getPagePixmap = fitz.utils.getPagePixmap
33
+ fitz.Document.getPageText = fitz.utils.getPageText
34
+ fitz.Document.setMetadata = fitz.utils.setMetadata
35
+ fitz.Document.setToC = fitz.utils.setToC
36
+ fitz.Document.searchPageFor = fitz.utils.searchPageFor
37
+ fitz.Document.newPage = fitz.utils.newPage
38
+ fitz.Document.insertPage = fitz.utils.insertPage
39
+ fitz.Document.getCharWidths = fitz.utils.getCharWidths
40
+
41
+ # ------------------------------------------------------------------------------
42
+ # Page
43
+ # ------------------------------------------------------------------------------
44
+ fitz.Page.drawBezier = fitz.utils.drawBezier
45
+ fitz.Page.drawCircle = fitz.utils.drawCircle
46
+ fitz.Page.drawCurve = fitz.utils.drawCurve
47
+ fitz.Page.drawLine = fitz.utils.drawLine
48
+ fitz.Page.drawOval = fitz.utils.drawOval
49
+ fitz.Page.drawPolyline = fitz.utils.drawPolyline
50
+ fitz.Page.drawRect = fitz.utils.drawRect
51
+ fitz.Page.drawQuad = fitz.utils.drawQuad
52
+ fitz.Page.drawSector = fitz.utils.drawSector
53
+ fitz.Page.drawSquiggle = fitz.utils.drawSquiggle
54
+ fitz.Page.drawZigzag = fitz.utils.drawZigzag
55
+ fitz.Page.getTextBlocks = fitz.utils.getTextBlocks
56
+ fitz.Page.getTextWords = fitz.utils.getTextWords
57
+ fitz.Page.getLinks = fitz.utils.getLinks
58
+ fitz.Page.getPixmap = fitz.utils.getPixmap
59
+ fitz.Page.getText = fitz.utils.getText
60
+ fitz.Page.insertLink = fitz.utils.insertLink
61
+ fitz.Page.insertTextbox = fitz.utils.insertTextbox
62
+ fitz.Page.insertText = fitz.utils.insertText
63
+ fitz.Page.searchFor = fitz.utils.searchFor
64
+ fitz.Page.showPDFpage = fitz.utils.showPDFpage
65
+ fitz.Page.insertImage = fitz.utils.insertImage
66
+ fitz.Page.updateLink = fitz.utils.updateLink
67
+ fitz.Page.newShape = lambda x: fitz.utils.Shape(x)
68
+
69
+ # ------------------------------------------------------------------------------
70
+ # Rect
71
+ # ------------------------------------------------------------------------------
72
+ fitz.Rect.getRectArea = fitz.utils.getRectArea
73
+ fitz.Rect.getArea = fitz.utils.getRectArea
74
+
75
+ # ------------------------------------------------------------------------------
76
+ # IRect
77
+ # ------------------------------------------------------------------------------
78
+ fitz.IRect.getRectArea = fitz.utils.getRectArea
79
+ fitz.IRect.getArea = fitz.utils.getRectArea
80
+
81
+ fitz.__doc__ = "PyMuPDF %s: Python bindings for the MuPDF %s library,\nbuilt on %s" % (
82
+ fitz.VersionBind,
83
+ fitz.VersionFitz,
84
+ fitz.VersionDate,
85
+ )