From f07fb6d22a7124f945a29c2895cec87a69e08b37 Mon Sep 17 00:00:00 2001 From: Daniel Thompson Date: Thu, 14 May 2020 21:44:05 +0100 Subject: [PATCH] wasp: draw565: docstrings for headings and __init__ --- docs/wasp.rst | 1 - wasp/draw565.py | 8 +++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/docs/wasp.rst b/docs/wasp.rst index 991950b..87dd301 100644 --- a/docs/wasp.rst +++ b/docs/wasp.rst @@ -62,7 +62,6 @@ Libraries .. automodule:: draw565 :members: - :undoc-members: .. automodule:: icons :members: diff --git a/wasp/draw565.py b/wasp/draw565.py index f6fe272..a69e526 100644 --- a/wasp/draw565.py +++ b/wasp/draw565.py @@ -1,6 +1,10 @@ # SPDX-License-Identifier: LGPL-3.0-or-later # Copyright (C) 2020 Daniel Thompson +"""RGB565 drawing library +~~~~~~~~~~~~~~~~~~~~~~~~~ +""" + import array import fonts.sans24 import micropython @@ -76,6 +80,8 @@ class Draw565(object): A full framebufer is not required although the library will 'borrow' a line buffer from the underlying display driver. + + .. automethod:: __init__ """ def __init__(self, display): @@ -96,7 +102,7 @@ class Draw565(object): self.set_font(fonts.sans24) def fill(self, bg=None, x=0, y=0, w=None, h=None): - """Draw a solid color rectangle. + """Draw a solid colour rectangle. If no arguments a provided the whole display will be filled with the background colour (typically black).