Skip to content

Commit b48761b

Browse files
committed
version 1.18.6
1 parent bfb30b4 commit b48761b

22 files changed

+1662
-987
lines changed

PKG-INFO

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Metadata-Version: 1.1
22
Name: PyMuPDF
3-
Version: 1.18.5
3+
Version: 1.18.6
44
Author: Jorj McKie
55
Author-email: [email protected]
66
Maintainer: Jorj McKie
@@ -9,7 +9,7 @@ Home-page: https://github.com/pymupdf/PyMuPDF
99
Download-url: https://github.com/pymupdf/PyMuPDF
1010
Summary: PyMuPDF is a Python binding for the PDF rendering library MuPDF
1111
Description:
12-
Release date: December 20, 2020
12+
Release date: January 7, 2021
1313

1414
Authors
1515
=======
@@ -20,7 +20,7 @@ Description:
2020
Introduction
2121
============
2222

23-
This is **version 1.18.5 of PyMuPDF**, a Python binding for `MuPDF <http://mupdf.com/>`_ - "a lightweight PDF and XPS viewer".
23+
This is **version 1.18.6 of PyMuPDF**, a Python binding for `MuPDF <http://mupdf.com/>`_ - "a lightweight PDF and XPS viewer".
2424

2525
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.
2626

README.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
# PyMuPDF 1.18.5
1+
# PyMuPDF 1.18.6
22

33
![logo](https://github.com/pymupdf/PyMuPDF/blob/master/demo/pymupdf.jpg)
44

5-
Release date: December 20, 2020
5+
Release date: January 7, 2021
66

77
**Travis-CI:** [![Build Status](https://travis-ci.org/JorjMcKie/py-mupdf.svg?branch=master)](https://travis-ci.org/JorjMcKie/py-mupdf)
88

@@ -15,7 +15,7 @@ On **[PyPI](https://pypi.org/project/PyMuPDF)** since August 2016: [![](https://
1515

1616
# Introduction
1717

18-
This is **version 1.18.5 of PyMuPDF**, a Python binding with support for [MuPDF 1.18.*](http://mupdf.com/) - "a lightweight PDF, XPS, and E-book viewer".
18+
This is **version 1.18.6 of PyMuPDF**, a Python binding with support for [MuPDF 1.18.*](http://mupdf.com/) - "a lightweight PDF, XPS, and E-book viewer".
1919

2020
MuPDF can access files in PDF, XPS, OpenXPS, CBZ, EPUB and FB2 (e-books) formats, and it is known for its top performance and high rendering quality.
2121

docs/annot.rst

+6-6
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ There is a parent-child relationship between an annotation and its page. If the
7171

7272
.. method:: get_pixmap(matrix=fitz.Identity, colorspace=fitz.csRGB, alpha=False)
7373

74-
Creates a pixmap from the annotation as it appears on the page in untransformed coordinates. The pixmap's :ref:`IRect` equals *Annot.rect.irect* (see below).
74+
Creates a pixmap from the annotation as it appears on the page in untransformed coordinates. The pixmap's :ref:`IRect` equals *Annot.rect.irect* (see below). **All parameters are keyword only.**
7575

7676
:arg matrix_like matrix: a matrix to be used for image creation. Default is the *fitz.Identity* matrix.
7777

@@ -98,13 +98,13 @@ There is a parent-child relationship between an annotation and its page. If the
9898
pair: xhtml; Annot.get_text
9999
pair: xml; Annot.get_text
100100

101-
.. method:: get_text(opt="text", clip=None, flags=None)
101+
.. method:: get_text(opt, clip=None, flags=None)
102102

103103
*(New in 1.18.0)*
104104

105105
Retrieves the content of the annotation in a variety of formats -- much like the same method for :ref:`Page`.. This currently only delivers relevant data for annotation types 'FreeText' and 'Stamp'. Other types return an empty string (or equivalent objects).
106106

107-
:arg str opt: the desired format - one of the following values. Please note that this method works exactly like the same-named method of :ref:`Page`.
107+
:arg str opt: (positional only) the desired format - one of the following values. Please note that this method works exactly like the same-named method of :ref:`Page`.
108108

109109
* "text" -- :meth:`TextPage.extractTEXT`, default
110110
* "blocks" -- :meth:`TextPage.extractBLOCKS`
@@ -116,8 +116,8 @@ There is a parent-child relationship between an annotation and its page. If the
116116
* "json" -- :meth:`TextPage.extractJSON`
117117
* "rawdict" -- :meth:`TextPage.extractRAWDICT`
118118

119-
:arg rect-like clip: restrict the extraction to this area. Should hardly ever be required, defaults to :attr:`Annot.rect`.
120-
:arg int flags: control the amount of data returned. Defaults to simple text extraction.
119+
:arg rect-like clip: (keyword only) restrict the extraction to this area. Should hardly ever be required, defaults to :attr:`Annot.rect`.
120+
:arg int flags: (keyword only) control the amount of data returned. Defaults to simple text extraction.
121121

122122
.. method:: get_textbox(rect)
123123

@@ -147,7 +147,7 @@ There is a parent-child relationship between an annotation and its page. If the
147147

148148
.. note::
149149

150-
* While only 'FreeText', 'Line', 'PolyLine', and 'Polygon' annotations can have these properties, (Py-) MuPDF does not support line ends for 'FreeText', because the call-out variant for these is not supported.
150+
* While 'FreeText', 'Line', 'PolyLine', and 'Polygon' annotations can have these properties, (Py-) MuPDF does not support line ends for 'FreeText', because the call-out variant of it is not supported.
151151
* *(Changed in v1.16.16)* Some symbols have an interior area (diamonds, circles, squares, etc.). By default, these areas are filled with the fill color of the annotation. If this is *None*, then white is chosen. The *fill_color* argument of :meth:`Annot.update` can now be used to override this and give line end symbols their own fill color.
152152

153153
:arg int start: The symbol number for the first point.

docs/app4.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ RuntimeError: orphaned object: parent is None
167167
<... omitted lines ...>
168168
RuntimeError: orphaned object: parent is None
169169

170-
.. note:: Objects outside the above relationship are not included in this mechanism. If you e.g. created a table of contents by *toc = doc.getToC()*, and later close or change the document, then this cannot and does not change variable *toc* in any way. It is your responsibility to refresh such variables as required.
170+
.. note:: Objects outside the above relationship are not included in this mechanism. If you e.g. created a table of contents by *toc = doc.get_toc()*, and later close or change the document, then this cannot and does not change variable *toc* in any way. It is your responsibility to refresh such variables as required.
171171

172172
------------
173173

docs/changes.rst

+20-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,25 @@
11
Change Logs
22
===============
33

4+
Changes in Version 1.18.6
5+
-------------------------
6+
* **Fixed** issue `#793 <https://github.com/pymupdf/PyMuPDF/issues/793>`_. Invalid document metadata previously prevented opening some documents at all. This error has been removed.
7+
* **Fixed** issue `#792 <https://github.com/pymupdf/PyMuPDF/issues/792>`_. Text search and text extraction will make no rectangle containment checks at all if the default ``clip=None`` is used.
8+
* **Fixed** issue `#785 <https://github.com/pymupdf/PyMuPDF/issues/785>`_.
9+
* **Fixed** issue `#780 <https://github.com/pymupdf/PyMuPDF/issues/780>`_. Corrected a parameter check error.
10+
* **Fixed** issue `#779 <https://github.com/pymupdf/PyMuPDF/issues/779>`_. Fixed typo
11+
* **Added** an option to set the desired line height for text boxes. Implements `#804 <https://github.com/pymupdf/PyMuPDF/issues/804>`_.
12+
* **Changed** text position retrieval to better cope with Tesseract's glyphless font. Implements `#803 <https://github.com/pymupdf/PyMuPDF/issues/803>`_.
13+
* **Added** an option to choose the prefix of new annotations, fields and links for providing unique annotation ids. Implements request `#807 <https://github.com/pymupdf/PyMuPDF/issues/807>`_.
14+
* **Added** getting and setting color and text properties for Table of Contents items for PDFs. Implements `#779 <https://github.com/pymupdf/PyMuPDF/issues/779>`_.
15+
* **Added** PDF page label handling: :meth:`Page.get_label()` returns the page label, :meth:`Document.get_page_numbers` return all page numbers having a specified label, and :meth:`Document.set_page_labels` adds or updates a PDF's page label definition.
16+
17+
18+
19+
.. note::
20+
This version introduces **Python type hinting**. The goal is to provide each parameter and the return value of all functions and methods with type information. This still is work in progress although the majority of functions has already been handled.
21+
22+
423
Changes in Version 1.18.5
524
-------------------------
625
Apart from several fixes, this version also focusses on several minor, but important feature improvements. Among the latter is a more precise computation of proper line heights and insertion points for writing / inserting text. As opposed to using font-agnostic constants, these values are now taken from the font's properties.
@@ -696,7 +715,7 @@ Changes in Version 1.12.0
696715
--------------------------
697716
This version is based on and requires MuPDF v1.12.0. The new MuPDF version contains quite a number of changes -- most of them around text extraction. Some of the changes impact the programmer's API.
698717

699-
* :meth:`Outline.saveText` and :meth:`Outline.saveXML` have been deleted without replacement. You probably haven't used them much anyway. But if you are looking for a replacement: the output of :meth:`Document.getToC` can easily be used to produce something equivalent.
718+
* :meth:`Outline.saveText` and :meth:`Outline.saveXML` have been deleted without replacement. You probably haven't used them much anyway. But if you are looking for a replacement: the output of :meth:`Document.get_toc` can easily be used to produce something equivalent.
700719

701720
* Class *TextSheet* does no longer exist.
702721

docs/conf.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
# built documents.
4141
#
4242
# The full version, including alpha/beta/rc tags.
43-
release = "1.18.5"
43+
release = "1.18.6"
4444

4545
# The short X.Y version
4646
version = release

0 commit comments

Comments
 (0)