summaryrefslogtreecommitdiff
path: root/shared-bindings/displayio/Shape.c
diff options
context:
space:
mode:
authordherrada <dylan.herrada@gmail.com>2020-05-07 10:54:09 -0400
committerdherrada <dylan.herrada@gmail.com>2020-05-07 10:54:09 -0400
commit2ebe3035dff0ce66b2fe65eb91d6889c4ba93b5c (patch)
tree60954388417613578138c9be870f5b2dc510b042 /shared-bindings/displayio/Shape.c
parent0e465e63b98c3825298219e2144a145208aaff7f (diff)
Did board, digitalio, displayio
Diffstat (limited to 'shared-bindings/displayio/Shape.c')
-rw-r--r--shared-bindings/displayio/Shape.c31
1 files changed, 16 insertions, 15 deletions
diff --git a/shared-bindings/displayio/Shape.c b/shared-bindings/displayio/Shape.c
index 7c7b10501..0f22bb2a3 100644
--- a/shared-bindings/displayio/Shape.c
+++ b/shared-bindings/displayio/Shape.c
@@ -34,22 +34,23 @@
#include "shared-bindings/util.h"
#include "supervisor/shared/translate.h"
-//| .. currentmodule:: displayio
+//| class Shape:
+//| """.. currentmodule:: displayio
//|
-//| :class:`Shape` -- Represents a shape by defining its bounds on each row
-//| ==========================================================================
+//| :class:`Shape` -- Represents a shape by defining its bounds on each row
+//| ==========================================================================
//|
-//| Represents any shape made by defining boundaries that may be mirrored.
+//| Represents any shape made by defining boundaries that may be mirrored."""
//|
-//| .. class:: Shape(width, height, *, mirror_x=False, mirror_y=False)
+//| def __init__(self, width: int, height: int, *, mirror_x: bool = False, mirror_y: bool = False):
+//| """Create a Shape object with the given fixed size. Each pixel is one bit and is stored by the
+//| column boundaries of the shape on each row. Each row's boundary defaults to the full row.
//|
-//| Create a Shape object with the given fixed size. Each pixel is one bit and is stored by the
-//| column boundaries of the shape on each row. Each row's boundary defaults to the full row.
-//|
-//| :param int width: The number of pixels wide
-//| :param int height: The number of pixels high
-//| :param bool mirror_x: When true the left boundary is mirrored to the right.
-//| :param bool mirror_y: When true the top boundary is mirrored to the bottom.
+//| :param int width: The number of pixels wide
+//| :param int height: The number of pixels high
+//| :param bool mirror_x: When true the left boundary is mirrored to the right.
+//| :param bool mirror_y: When true the top boundary is mirrored to the bottom."""
+//| ...
//|
STATIC mp_obj_t displayio_shape_make_new(const mp_obj_type_t *type, size_t n_args, const mp_obj_t *pos_args, mp_map_t *kw_args) {
enum { ARG_width, ARG_height, ARG_mirror_x, ARG_mirror_y };
@@ -83,9 +84,9 @@ STATIC mp_obj_t displayio_shape_make_new(const mp_obj_type_t *type, size_t n_arg
}
-//| .. method:: set_boundary(y, start_x, end_x)
-//|
-//| Loads pre-packed data into the given row.
+//| def set_boundary(self, y: Any, start_x: Any, end_x: Any) -> Any:
+//| """Loads pre-packed data into the given row."""
+//| ...
//|
STATIC mp_obj_t displayio_shape_obj_set_boundary(size_t n_args, const mp_obj_t *args) {
(void) n_args;