Opt out of running doctest
This commit is contained in:
parent
3f26a1301a
commit
184a6152f6
@ -164,10 +164,10 @@ class FreeTypePen(BasePen):
|
|||||||
dimension.
|
dimension.
|
||||||
|
|
||||||
:Example:
|
:Example:
|
||||||
>>> pen = FreeTypePen(None)
|
>> pen = FreeTypePen(None)
|
||||||
>>> glyph.draw(pen)
|
>> glyph.draw(pen)
|
||||||
>>> buf, size = pen.buffer(width=500, height=1000)
|
>> buf, size = pen.buffer(width=500, height=1000)
|
||||||
>>> type(buf), len(buf), size
|
>> type(buf), len(buf), size
|
||||||
(<class 'bytes'>, 500000, (500, 1000))
|
(<class 'bytes'>, 500000, (500, 1000))
|
||||||
"""
|
"""
|
||||||
offset_x, offset_y = offset or (0, 0)
|
offset_x, offset_y = offset or (0, 0)
|
||||||
@ -218,10 +218,10 @@ class FreeTypePen(BasePen):
|
|||||||
Each element takes a value in the range of ``[0.0, 1.0]``.
|
Each element takes a value in the range of ``[0.0, 1.0]``.
|
||||||
|
|
||||||
:Example:
|
:Example:
|
||||||
>>> pen = FreeTypePen(None)
|
>> pen = FreeTypePen(None)
|
||||||
>>> glyph.draw(pen)
|
>> glyph.draw(pen)
|
||||||
>>> arr = pen.array(width=500, height=1000)
|
>> arr = pen.array(width=500, height=1000)
|
||||||
>>> type(a), a.shape
|
>> type(a), a.shape
|
||||||
(<class 'numpy.ndarray'>, (1000, 500))
|
(<class 'numpy.ndarray'>, (1000, 500))
|
||||||
"""
|
"""
|
||||||
import numpy as np
|
import numpy as np
|
||||||
@ -245,9 +245,9 @@ class FreeTypePen(BasePen):
|
|||||||
rendering glyphs with negative sidebearings without clipping.
|
rendering glyphs with negative sidebearings without clipping.
|
||||||
|
|
||||||
:Example:
|
:Example:
|
||||||
>>> pen = FreeTypePen(None)
|
>> pen = FreeTypePen(None)
|
||||||
>>> glyph.draw(pen)
|
>> glyph.draw(pen)
|
||||||
>>> pen.show(width=500, height=1000)
|
>> pen.show(width=500, height=1000)
|
||||||
"""
|
"""
|
||||||
from matplotlib import pyplot as plt
|
from matplotlib import pyplot as plt
|
||||||
a = self.array(offset=offset, width=width, height=height, evenOdd=evenOdd, scale=scale, contain=contain)
|
a = self.array(offset=offset, width=width, height=height, evenOdd=evenOdd, scale=scale, contain=contain)
|
||||||
@ -275,10 +275,10 @@ class FreeTypePen(BasePen):
|
|||||||
channel obtained from the rendered bitmap.
|
channel obtained from the rendered bitmap.
|
||||||
|
|
||||||
:Example:
|
:Example:
|
||||||
>>> pen = FreeTypePen(None)
|
>> pen = FreeTypePen(None)
|
||||||
>>> glyph.draw(pen)
|
>> glyph.draw(pen)
|
||||||
>>> img = pen.image(width=500, height=1000)
|
>> img = pen.image(width=500, height=1000)
|
||||||
>>> type(img), img.size
|
>> type(img), img.size
|
||||||
(<class 'PIL.Image.Image'>, (500, 1000))
|
(<class 'PIL.Image.Image'>, (500, 1000))
|
||||||
"""
|
"""
|
||||||
from PIL import Image
|
from PIL import Image
|
||||||
|
Loading…
x
Reference in New Issue
Block a user