def insertTextbox(page, rect, buffer,<EOL>fontname="<STR_LIT>",<EOL>fontfile=None,<EOL>set_simple=<NUM_LIT:0>,<EOL>encoding=<NUM_LIT:0>,<EOL>fontsize=<NUM_LIT:11>,<EOL>color=None,<EOL>fill=None,<EOL>expandtabs=<NUM_LIT:1>,<EOL>align=<NUM_LIT:0>,<EOL>rotate=<NUM_LIT:0>,<EOL>render_mode=<NUM_LIT:0>,<EOL>border_width=<NUM_LIT:1>,<EOL>morph=None,<EOL>overlay=True):
img = page.newShape()<EOL>rc = img.insertTextbox(rect, buffer,<EOL>fontsize=fontsize,<EOL>fontname=fontname,<EOL>fontfile=fontfile,<EOL>set_simple=set_simple,<EOL>encoding=encoding,<EOL>color=color,<EOL>fill=fill,<EOL>expandtabs=expandtabs,<EOL>render_mode=render_mode,<EOL>border_width=border_width,<EOL>align=align,<EOL>rotate=rotate,<EOL>morph=morph)<EOL>if rc >= <NUM_LIT:0>:<EOL><INDENT>img.commit(overlay)<EOL><DEDENT>return rc<EOL>
Insert text into a given rectangle.

    Notes:
        Creates a Shape object, uses its same-named method and commits it.
    Parameters:
        rect: (rect-like) area to use for text.
        buffer: text to be inserted
        fontname: a Base-14 font, font name or '/name'
        fontfile: name of a font file
        fontsize: font size
        color: RGB color triple
        expandtabs: handles tabulators with string function
        align: left, center, right, justified
        rotate: 0, 90, 180, or 270 degrees
        morph: morph box with  a matrix and a pivotal point
        overlay: put text in foreground or background
    Returns:
        unused or deficit rectangle area (float)