Mercurial > py-sdl2
changeset 142:cf3f8d9fe64b
- fixed issue #38: document the points arguments of RenderContext.draw_points()
and RenderContext.draw_line()
| author | Marcus von Appen <marcus@sysfault.org> |
|---|---|
| date | Thu, 23 Jan 2014 08:10:31 +0100 |
| parents | 74e977a37b77 |
| children | 3af6789406f0 |
| files | doc/modules/sdl2ext_sprite.rst |
| diffstat | 1 files changed, 16 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/doc/modules/sdl2ext_sprite.rst Thu Jan 23 07:48:03 2014 +0100 +++ b/doc/modules/sdl2ext_sprite.rst Thu Jan 23 08:10:31 2014 +0100 @@ -307,20 +307,31 @@ .. method:: draw_line(points : iterable[, color=None]) -> None - Draws one or multiple lines on the rendering context. + Draws one or multiple lines on the rendering context. The *line* + argument contains the start and end coordinates of the individual lines + in the form ``(line1_x1, line1_y1, line1_x2, line1_y2, line2_x1, + line2_y1, ...)``. .. method:: draw_point(points : iterable[, color=None]) -> None - Draws one or multiple points on the rendering context. + Draws one or multiple points on the rendering context. The *points* + argument contains the x and y values of the points as simple sequence in + the form ``(point1_x, point1_y, point2_x, point2_y, ...)``. .. method:: draw_rect(rects : iterable[, color=None]) -> None - Draws one or multiple rectangles on the rendering context. + Draws one or multiple rectangles on the rendering context. *rects* + contains sequences of four values denoting the x and y offset and width + and height of each individual rectangle in the form ``((x1, y1, w1, h1), + (x2, y2, w2, h2), ...)``. .. method:: fill(rects : iterable[, color=None]) -> None - Fills one or multiple rectangular areas on the rendering context - with the current set or passed *color*. + Fills one or multiple rectangular areas on the rendering context with + the current set or passed *color*. *rects* contains sequences of four + values denoting the x and y offset and width and height of each + individual rectangle in the form ``((x1, y1, w1, h1), (x2, y2, w2, h2), + ...)``. .. method:: present() -> None
