mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-01-25 00:34:14 +03:00
Merge branch 'master' into unused-sidebar
This commit is contained in:
commit
1f4900e51f
|
@ -14,7 +14,6 @@ graft src
|
|||
graft depends
|
||||
graft winbuild
|
||||
graft docs
|
||||
prune docs/_static
|
||||
|
||||
# build/src control detritus
|
||||
exclude .appveyor.yml
|
||||
|
|
|
@ -53,8 +53,7 @@ class TestImageFont(PillowTestCase):
|
|||
# (and, other things, but first things first)
|
||||
METRICS = {
|
||||
(">=2.3", "<2.4"): {"multiline": 30, "textsize": 12, "getters": (13, 16)},
|
||||
(">=2.7", "<2.10"): {"multiline": 6.2, "textsize": 2.5, "getters": (12, 16)},
|
||||
(">=2.10",): {"multiline": 14.8, "textsize": 2.5, "getters": (12, 16)},
|
||||
(">=2.7",): {"multiline": 6.2, "textsize": 2.5, "getters": (12, 16)},
|
||||
"Default": {"multiline": 0.5, "textsize": 0.5, "getters": (12, 16)},
|
||||
}
|
||||
|
||||
|
@ -465,9 +464,8 @@ class TestImageFont(PillowTestCase):
|
|||
font.getsize(u"’")
|
||||
|
||||
@unittest.skipIf(
|
||||
sys.platform.startswith("win32")
|
||||
and (sys.version.startswith("2") or hasattr(sys, "pypy_translation_info")),
|
||||
"requires CPython 3.x on Windows",
|
||||
sys.version.startswith("2") or hasattr(sys, "pypy_translation_info"),
|
||||
"requires CPython 3.3+",
|
||||
)
|
||||
def test_unicode_extended(self):
|
||||
# issue #3777
|
||||
|
|
|
@ -4,6 +4,5 @@ from livereload.compiler import shell
|
|||
|
||||
Task.add('*.rst', shell('make html'))
|
||||
Task.add('*/*.rst', shell('make html'))
|
||||
Task.add('_static/*.css', shell('make clean html'))
|
||||
Task.add('Makefile', shell('make html'))
|
||||
Task.add('conf.py', shell('make html'))
|
||||
|
|
1
docs/_static/.gitignore
vendored
1
docs/_static/.gitignore
vendored
|
@ -1 +0,0 @@
|
|||
# Empty file, to make the directory available in the repository
|
|
@ -136,7 +136,7 @@ html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
|
|||
# Add any paths that contain custom static files (such as style sheets) here,
|
||||
# relative to this directory. They are copied after the builtin static files,
|
||||
# so a file named "default.css" will overwrite the builtin "default.css".
|
||||
html_static_path = ["_static", "resources"]
|
||||
html_static_path = ["resources"]
|
||||
|
||||
# Add any extra paths that contain custom files (such as robots.txt or
|
||||
# .htaccess) here, relative to this directory. These files are copied
|
||||
|
|
|
@ -132,11 +132,11 @@ Methods
|
|||
Draws an arc (a portion of a circle outline) between the start and end
|
||||
angles, inside the given bounding box.
|
||||
|
||||
:param xy: Two points to define the bounding box. Sequence of
|
||||
``[(x0, y0), (x1, y1)]`` or ``[x0, y0, x1, y1]``,
|
||||
where ``x1 >= x0`` and ``y1 >= y0``.
|
||||
:param start: Starting angle, in degrees. Angles are measured from
|
||||
3 o'clock, increasing clockwise.
|
||||
:param xy: Two points to define the bounding box. Sequence of ``[(x0, y0),
|
||||
(x1, y1)]`` or ``[x0, y0, x1, y1]``, where ``x1 >= x0`` and ``y1 >=
|
||||
y0``.
|
||||
:param start: Starting angle, in degrees. Angles are measured from 3
|
||||
o'clock, increasing clockwise.
|
||||
:param end: Ending angle, in degrees.
|
||||
:param fill: Color to use for the arc.
|
||||
:param width: The line width, in pixels.
|
||||
|
@ -159,9 +159,9 @@ Methods
|
|||
Same as :py:meth:`~PIL.ImageDraw.ImageDraw.arc`, but connects the end points
|
||||
with a straight line.
|
||||
|
||||
:param xy: Two points to define the bounding box. Sequence of
|
||||
``[(x0, y0), (x1, y1)]`` or ``[x0, y0, x1, y1]``,
|
||||
where ``x1 >= x0`` and ``y1 >= y0``.
|
||||
:param xy: Two points to define the bounding box. Sequence of ``[(x0, y0),
|
||||
(x1, y1)]`` or ``[x0, y0, x1, y1]``, where ``x1 >= x0`` and ``y1 >=
|
||||
y0``.
|
||||
:param outline: Color to use for the outline.
|
||||
:param fill: Color to use for the fill.
|
||||
:param width: The line width, in pixels.
|
||||
|
@ -173,8 +173,8 @@ Methods
|
|||
Draws an ellipse inside the given bounding box.
|
||||
|
||||
:param xy: Two points to define the bounding box. Sequence of either
|
||||
``[(x0, y0), (x1, y1)]`` or ``[x0, y0, x1, y1]``,
|
||||
where ``x1 >= x0`` and ``y1 >= y0``.
|
||||
``[(x0, y0), (x1, y1)]`` or ``[x0, y0, x1, y1]``, where ``x1 >= x0``
|
||||
and ``y1 >= y0``.
|
||||
:param outline: Color to use for the outline.
|
||||
:param fill: Color to use for the fill.
|
||||
:param width: The line width, in pixels.
|
||||
|
@ -203,11 +203,11 @@ Methods
|
|||
Same as arc, but also draws straight lines between the end points and the
|
||||
center of the bounding box.
|
||||
|
||||
:param xy: Two points to define the bounding box. Sequence of
|
||||
``[(x0, y0), (x1, y1)]`` or ``[x0, y0, x1, y1]``,
|
||||
where ``x1 >= x0`` and ``y1 >= y0``.
|
||||
:param start: Starting angle, in degrees. Angles are measured from
|
||||
3 o'clock, increasing clockwise.
|
||||
:param xy: Two points to define the bounding box. Sequence of ``[(x0, y0),
|
||||
(x1, y1)]`` or ``[x0, y0, x1, y1]``, where ``x1 >= x0`` and ``y1 >=
|
||||
y0``.
|
||||
:param start: Starting angle, in degrees. Angles are measured from 3
|
||||
o'clock, increasing clockwise.
|
||||
:param end: Ending angle, in degrees.
|
||||
:param fill: Color to use for the fill.
|
||||
:param outline: Color to use for the outline.
|
||||
|
|
|
@ -20,12 +20,13 @@ for a region of an image.
|
|||
|
||||
Min/max values for each band in the image.
|
||||
|
||||
.. Note:: This relies on the :py:meth:`~PIL.Image.histogram` method, and simply
|
||||
returns the low and high bins used. This is correct for images with 8 bits per
|
||||
channel, but fails for other modes such as ``I`` or ``F``. Instead, use
|
||||
:py:meth:`~PIL.Image.getextrema` to return per-band extrema for the image.
|
||||
This is more correct and efficient because, for non-8-bit modes, the histogram
|
||||
method uses :py:meth:`~PIL.Image.getextrema` to determine the bins used.
|
||||
.. Note:: This relies on the :py:meth:`~PIL.Image.histogram` method,
|
||||
and simply returns the low and high bins used. This is correct for
|
||||
images with 8 bits per channel, but fails for other modes such as
|
||||
``I`` or ``F``. Instead, use :py:meth:`~PIL.Image.getextrema` to
|
||||
return per-band extrema for the image. This is more correct and
|
||||
efficient because, for non-8-bit modes, the histogram method uses
|
||||
:py:meth:`~PIL.Image.getextrema` to determine the bins used.
|
||||
|
||||
.. py:attribute:: count
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user