-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Tilegrid size properties #5749
Tilegrid size properties #5749
Conversation
This passed pre-commit locally:
But it failed the formatting check in CI. I'm not sure what could account for the difference. Trying to look into it to see if my version of uncrustify could be different. |
This also seems to have failed several of the builds in CI. But a local build of one of the same boards suceeded:
|
The build failures are due to tomlkit==0.8.0 being incompatible with 0.7.2. I'll look into it further. It'll probably need a cascadetoml release to fix. The pre-commit failures are "correct", your code isn't properly indented. Let's figure out why your local config is not working. First, what's |
@jepler thank you
|
This reverts commit 577358a.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good, thanks. Didn't actually test it. The cascadetoml build failures will need to be fixed by other means.
Don't try to set the height property of Sprite, because [it now inherits it from displayio.TileGrid](adafruit/circuitpython#5749).
This change introduces properties to access
height
,width
, as well astile_height
, andtile_width
for TileGrid objects. Can be accessed like this:These values can make it easier to place a TileGrid in some relative position i.e. center it in the center of the display.