[Python-checkins] bpo-35250: Correct argument name "num" -> "btn" in turtle docs. (GH-10565)

Miss Islington (bot) webhook-mailer at python.org
Fri Nov 16 08:55:17 EST 2018


https://github.com/python/cpython/commit/0461c3b635d53e8e75145695803a2fca288a1689
commit: 0461c3b635d53e8e75145695803a2fca288a1689
branch: 3.7
author: Miss Islington (bot) <31488909+miss-islington at users.noreply.github.com>
committer: GitHub <noreply at github.com>
date: 2018年11月16日T05:55:14-08:00
summary:
bpo-35250: Correct argument name "num" -> "btn" in turtle docs. (GH-10565)
(cherry picked from commit 4edeaeac4c194ba5d09187640b5cfca5e03be617)
Co-authored-by: Srinivas Thatiparthy (శ్రీనివాస్ తాటిపర్తి) <thatiparthysreenivas at gmail.com>
files:
M Doc/library/turtle.rst
M Lib/turtle.py
diff --git a/Doc/library/turtle.rst b/Doc/library/turtle.rst
index 595a244342c4..175010b89906 100644
--- a/Doc/library/turtle.rst
+++ b/Doc/library/turtle.rst
@@ -1309,7 +1309,7 @@ Using events
 
 :param fun: a function with two arguments which will be called with the
 coordinates of the clicked point on the canvas
- :param num: number of the mouse-button, defaults to 1 (left mouse button)
+ :param btn: number of the mouse-button, defaults to 1 (left mouse button)
 :param add: ``True`` or ``False`` -- if ``True``, a new binding will be
 added, otherwise it will replace a former binding
 
@@ -1330,7 +1330,7 @@ Using events
 
 :param fun: a function with two arguments which will be called with the
 coordinates of the clicked point on the canvas
- :param num: number of the mouse-button, defaults to 1 (left mouse button)
+ :param btn: number of the mouse-button, defaults to 1 (left mouse button)
 :param add: ``True`` or ``False`` -- if ``True``, a new binding will be
 added, otherwise it will replace a former binding
 
@@ -1354,7 +1354,7 @@ Using events
 
 :param fun: a function with two arguments which will be called with the
 coordinates of the clicked point on the canvas
- :param num: number of the mouse-button, defaults to 1 (left mouse button)
+ :param btn: number of the mouse-button, defaults to 1 (left mouse button)
 :param add: ``True`` or ``False`` -- if ``True``, a new binding will be
 added, otherwise it will replace a former binding
 
@@ -1735,7 +1735,7 @@ Using screen events
 
 :param fun: a function with two arguments which will be called with the
 coordinates of the clicked point on the canvas
- :param num: number of the mouse-button, defaults to 1 (left mouse button)
+ :param btn: number of the mouse-button, defaults to 1 (left mouse button)
 :param add: ``True`` or ``False`` -- if ``True``, a new binding will be
 added, otherwise it will replace a former binding
 
diff --git a/Lib/turtle.py b/Lib/turtle.py
index 9db564b7eb8b..47a94f2a4702 100644
--- a/Lib/turtle.py
+++ b/Lib/turtle.py
@@ -1352,7 +1352,7 @@ def onclick(self, fun, btn=1, add=None):
 Arguments:
 fun -- a function with two arguments, the coordinates of the
 clicked point on the canvas.
- num -- the number of the mouse-button, defaults to 1
+ btn -- the number of the mouse-button, defaults to 1
 
 Example (for a TurtleScreen instance named screen)
 
@@ -3526,7 +3526,7 @@ def onclick(self, fun, btn=1, add=None):
 Arguments:
 fun -- a function with two arguments, to which will be assigned
 the coordinates of the clicked point on the canvas.
- num -- number of the mouse-button defaults to 1 (left mouse button).
+ btn -- number of the mouse-button defaults to 1 (left mouse button).
 add -- True or False. If True, new binding will be added, otherwise
 it will replace a former binding.
 
@@ -3547,7 +3547,7 @@ def onrelease(self, fun, btn=1, add=None):
 Arguments:
 fun -- a function with two arguments, to which will be assigned
 the coordinates of the clicked point on the canvas.
- num -- number of the mouse-button defaults to 1 (left mouse button).
+ btn -- number of the mouse-button defaults to 1 (left mouse button).
 
 Example (for a MyTurtle instance named joe):
 >>> class MyTurtle(Turtle):
@@ -3572,7 +3572,7 @@ def ondrag(self, fun, btn=1, add=None):
 Arguments:
 fun -- a function with two arguments, to which will be assigned
 the coordinates of the clicked point on the canvas.
- num -- number of the mouse-button defaults to 1 (left mouse button).
+ btn -- number of the mouse-button defaults to 1 (left mouse button).
 
 Every sequence of mouse-move-events on a turtle is preceded by a
 mouse-click event on that turtle.


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /