From b702dbbdbff38920240d303af3340a024e3ad776 Mon Sep 17 00:00:00 2001 From: foamyguy Date: Thu, 29 May 2025 08:49:31 -0500 Subject: [PATCH 1/3] displayio API updates --- adafruit_simple_text_display.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/adafruit_simple_text_display.py b/adafruit_simple_text_display.py index d5561f9..5b03db5 100644 --- a/adafruit_simple_text_display.py +++ b/adafruit_simple_text_display.py @@ -26,6 +26,7 @@ try: from typing import Optional, Tuple + import busdisplay from fontio import FontProtocol except ImportError: pass @@ -72,7 +73,7 @@ def __init__( text_scale: int = 1, font: Optional[FontProtocol] = None, colors: Optional[Tuple[Tuple[int, int, int], ...]] = None, - display: Optional[displayio.Display] = None, + display: Optional[busdisplay.BusDisplay] = None, ) -> None: """Display lines of text on a display using displayio. Lines of text are created in order as shown in the example below. If you skip a number, the line will be shown blank on the @@ -107,7 +108,7 @@ def __init__( library. For example, if you import the library as ``from adafruit_simple_text_display import SimpleTextDisplay``, you can indicate the colors as follows: ``colors=(SimpleTextDisplay.WHITE, SimpleTextDisplay.RED)``. - :param ~displayio.Display|None display: The display object. Defaults to assuming a built-in + :param ~busdisplay.BusDisplay|None display: The display object. Defaults to assuming a built-in display. To use with an external display, instantiate the display object and provide it here. Defaults to ``board.DISPLAY``. From 182c913d0ef29b07bd663e460d5271e020526609 Mon Sep 17 00:00:00 2001 From: foamyguy Date: Thu, 29 May 2025 08:53:52 -0500 Subject: [PATCH 2/3] code format --- adafruit_simple_text_display.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/adafruit_simple_text_display.py b/adafruit_simple_text_display.py index 5b03db5..8e55522 100644 --- a/adafruit_simple_text_display.py +++ b/adafruit_simple_text_display.py @@ -108,9 +108,9 @@ def __init__( library. For example, if you import the library as ``from adafruit_simple_text_display import SimpleTextDisplay``, you can indicate the colors as follows: ``colors=(SimpleTextDisplay.WHITE, SimpleTextDisplay.RED)``. - :param ~busdisplay.BusDisplay|None display: The display object. Defaults to assuming a built-in - display. To use with an external display, instantiate the display object and provide it - here. Defaults to ``board.DISPLAY``. + :param ~busdisplay.BusDisplay|None display: The display object. Defaults to assuming + a built-in display. To use with an external display, instantiate the display + object and provide it here. Defaults to ``board.DISPLAY``. This example displays two lines with temperature data in C and F on the display. Remember to call `show()` after the list to update the display. From 919d77615300f6eb19b96b70a9d366ed5f0428e8 Mon Sep 17 00:00:00 2001 From: foamyguy Date: Wed, 4 Jun 2025 10:00:20 -0500 Subject: [PATCH 3/3] update rtd.yml file Signed-off-by: foamyguy --- .readthedocs.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.readthedocs.yaml b/.readthedocs.yaml index 88bca9f..255dafd 100644 --- a/.readthedocs.yaml +++ b/.readthedocs.yaml @@ -12,7 +12,7 @@ sphinx: configuration: docs/conf.py build: - os: ubuntu-20.04 + os: ubuntu-lts-latest tools: python: "3"