mirror of
https://github.com/python/cpython.git
synced 2025-10-02 05:12:23 +00:00
[3.7] bpo-8243: Doc patch for curses.window.addstr and curses.window.addch (GH-5179) (GH-6404)
(cherry picked from commit ef5ce884a4
)
Co-authored-by: Jay Crotts <crotts.jay@gmail.com>
This commit is contained in:
parent
a09bb87c1e
commit
98e8ac8d82
2 changed files with 14 additions and 0 deletions
|
@ -685,6 +685,12 @@ the following methods and attributes:
|
||||||
character previously painter at that location. By default, the character
|
character previously painter at that location. By default, the character
|
||||||
position and attributes are the current settings for the window object.
|
position and attributes are the current settings for the window object.
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
Writing outside the window, subwindow, or pad raises a :exc:`curses.error`.
|
||||||
|
Attempting to write to the lower right corner of a window, subwindow,
|
||||||
|
or pad will cause an exception to be raised after the character is printed.
|
||||||
|
|
||||||
|
|
||||||
.. method:: window.addnstr(str, n[, attr])
|
.. method:: window.addnstr(str, n[, attr])
|
||||||
window.addnstr(y, x, str, n[, attr])
|
window.addnstr(y, x, str, n[, attr])
|
||||||
|
@ -700,6 +706,12 @@ the following methods and attributes:
|
||||||
Paint the character string *str* at ``(y, x)`` with attributes
|
Paint the character string *str* at ``(y, x)`` with attributes
|
||||||
*attr*, overwriting anything previously on the display.
|
*attr*, overwriting anything previously on the display.
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
Writing outside the window, subwindow, or pad raises :exc:`curses.error`.
|
||||||
|
Attempting to write to the lower right corner of a window, subwindow,
|
||||||
|
or pad will cause an exception to be raised after the string is printed.
|
||||||
|
|
||||||
|
|
||||||
.. method:: window.attroff(attr)
|
.. method:: window.attroff(attr)
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,2 @@
|
||||||
|
Add a note about curses.addch and curses.addstr exception behavior when
|
||||||
|
writing outside a window, or pad.
|
Loading…
Add table
Add a link
Reference in a new issue