(
        text: str,
        template: Union[Template, Sequence[Template]],
        seed: Hashable = None,
        mapper: Callable[[Callable, Iterable], Iterable] = map,
)
return mapper(renderer, pages)
Handwrite `text` with the configurations in `template`, and return an
    Iterable of Pillow's Images.

    `template` could be a Template instance or a Sequence of Template
    instances. If pass a Template Sequence, the inside Template instances will
    be applied cyclically to the output pages.

    `seed` could be used for reproducibility.

    A different implementation of map built-in function (only accept one
    Iterable though) could be passed to `mapper` to boost the page rendering
    process, e.g. `multiprocessing.Pool.map`.

    Throw BackgroundTooLargeError, if the width or height of `background` in
    `template` exceeds 65,534.
    Throw LayoutError, if the settings are conflicting, which makes it
    impossible to layout the `text`.
Handwrite `text` with the configurations in `template`, and return an
    Iterable of Pillow's Images.
Handwrite text with the configurations in template and return an Iterable of Pillow s Images .
def handwrite(
        text: str,
        template: Union[Template, Sequence[Template]],
        seed: Hashable = None,
        mapper: Callable[[Callable, Iterable], Iterable] = map,
) -> Iterable[PIL.Image.Image]:
    """Handwrite `text` with the configurations in `template`, and return an
    Iterable of Pillow's Images.

    `template` could be a Template instance or a Sequence of Template
    instances. If pass a Template Sequence, the inside Template instances will
    be applied cyclically to the output pages.

    `seed` could be used for reproducibility.

    A different implementation of map built-in function (only accept one
    Iterable though) could be passed to `mapper` to boost the page rendering
    process, e.g. `multiprocessing.Pool.map`.

    Throw BackgroundTooLargeError, if the width or height of `background` in
    `template` exceeds 65,534.
    Throw LayoutError, if the settings are conflicting, which makes it
    impossible to layout the `text`.
    """
    if isinstance(template, Template):
        templates = (template,)
    else:
        templates = template
    pages = _draft(text, templates, seed)
    renderer = _Renderer(templates, seed)
    return mapper(renderer, pages)
def handwrite ( text : str , template : Union [ Template , Sequence [ Template ] ] , seed : Hashable = None , mapper : Callable [ [ Callable , Iterable ] , Iterable ] = map , ) -> Iterable [ PIL . Image . Image ] : if isinstance ( template , Template ) : templates = ( template , ) else : templates = template pages = _draft ( text , templates , seed ) renderer = _Renderer ( templates , seed ) return mapper ( renderer , pages )