Skip to content

Convert annotation from pillow to circuitpython_typing #19

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 14, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions adafruit_is31fl3741/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
try:
# Used only for typing
from typing import Optional, Tuple, Union # pylint: disable=unused-import
from PIL.ImageFile import ImageFile
from circuitpython_typing.pil import Image
from adafruit_framebuf import FrameBuffer
import busio
except ImportError:
Expand Down Expand Up @@ -335,7 +335,7 @@ def pixel(self, x: int, y: int, color: Optional[int] = None) -> Union[int, None]
)
return None

def image(self, img: Union[FrameBuffer, ImageFile]) -> None:
def image(self, img: Union[FrameBuffer, Image]) -> None:
"""Copy an in-memory image to the LED matrix. Image should be in
24-bit format (e.g. "RGB888") and dimensions should match matrix,
this isn't super robust yet or anything.
Expand Down
2 changes: 2 additions & 0 deletions optional_requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# SPDX-FileCopyrightText: 2022 Alec Delaney, for Adafruit Industries
#
# SPDX-License-Identifier: Unlicense

pillow
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@
Adafruit-Blinka
adafruit-circuitpython-framebuf
adafruit-circuitpython-busdevice
pillow
adafruit-circuitpython-typing~=1.6
adafruit-circuitpython-register