Commit Graph

19824 Commits

Author SHA1 Message Date
Kevin Matocha 40829d4cc8 switch to > in displayio_area_canon 2021-03-19 20:30:37 -05:00
Jeff Epler f5fd42c393 displayio: Move bitmap read-only checking to displayio_bitmap_set_dirty_area
This is a modest code savings, but more importantly it reduces
boilerplate in bitmap-modifying routines.

Callers need only ensure they call displayio_bitmap_set_dirty_area in
advance of the bitmap modifications they perform.

(note that this assumes that no bitmap operation can enter background
tasks. If an operation COULD enter background tasks, it MUST re-dirty
the area it touches when it exits, simply by a fresh call to
set_dirty_area with the same area as before)
2021-03-18 09:20:56 -05:00
Jeff Epler 36d608aa67 displayio_bitmap_set_dirty_area: rewrite in terms of displayio_area
.. simplifying code in the process.  For instance, now fill_region
uses area routines to order and constrain its coordinates.

Happily, this change also frees a modest amount of code space.
2021-03-18 09:20:56 -05:00
Jeff Epler 3b506f0fa5 displayio: area: add displayio_area_canon
This routine will be used to simplify code that deals with ranges
of bitmap coordinates.
2021-03-18 09:06:00 -05:00
Jeff Epler f40c0c13ad displayio: area: add displayo_area_copy_coords, displayio_area_empty
.. and simplify the implmentation of displayio_area_union

This _slightly_ changes the behavior of displayio_area_union:

Formerly, if one of the areas was empty, its coordinates were still
used in the min/max calculations.

Now, if one of the areas is empty, the result gets the other area's coords

In particular, taking the union of the empty area with coords (0,0,0,0)
with the non-empty area (x1,y1,x2,y2) would give the area (0,0,x2,y2)
before, and (x1,y1,x2,y2) after the change.
2021-03-18 09:05:07 -05:00
Jeff Epler 47ca792765 arrayblit: mark bitmap area as dirty 2021-03-17 20:25:22 -05:00
Scott Shawcroft 11e510a06a
Merge pull request #4419 from spe2/main
Add board definition for Sparkfun Pro Micro RP2040
2021-03-17 18:17:24 -07:00
Scott Shawcroft 670375dc0d
Merge pull request #4426 from kmatch98/main
Add getter for displayio.Palette item transparency/opacity.
2021-03-17 18:13:39 -07:00
Scott Shawcroft 588e4b8421
Merge pull request #4427 from weblate/weblate-circuitpython-main
Translations update from Weblate
2021-03-17 18:12:41 -07:00
Hosted Weblate d27055aa4a Merge remote-tracking branch 'origin/main' into main 2021-03-17 22:24:04 +01:00
Jonny Bergdahl 36aa861458
Translated using Weblate (Swedish)
Currently translated at 100.0% (977 of 977 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/sv/
2021-03-17 22:24:04 +01:00
Wellington Terumi Uemura 4d89893aff
Translated using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (977 of 977 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/pt_BR/
2021-03-17 22:24:04 +01:00
Jeff Epler 719e8710f2
Merge pull request #4411 from mintakka/thingplus-rp2040
added board configuration for Sparkfun ThingPlus RP2040
2021-03-17 16:23:55 -05:00
Hosted Weblate f6cabccd9e
Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/
2021-03-17 13:57:41 +01:00
Jeff Epler bfc8c89536
Merge pull request #4403 from jepler/bitmap-read-2
bitmaptools: Add readinto, arrayblit
2021-03-17 07:57:31 -05:00
Kevin Matocha 592f89f6ae add back peculiar r to docstring 2021-03-16 20:45:55 -05:00
Kevin Matocha 5c3cce6f5d add is_transparent getter to displayio.Palette 2021-03-16 20:43:23 -05:00
mintakka 337727ba0c renamed board folder to match board name in boards.yml 2021-03-16 21:10:10 -04:00
Jeff Epler 074ba1daff more doc fixes 2021-03-16 19:05:06 -05:00
Jeff Epler 94fa8e8a60 disable bitmaptools on small board 2021-03-16 19:04:21 -05:00
Jeff Epler 5810004bc9 fix doc error 2021-03-16 19:01:38 -05:00
Jeff Epler 75ba26ee7c
Merge pull request #4421 from kattni/led-pin
Adding LED for D13/L pin name.
2021-03-16 18:58:14 -05:00
Mark 1be5ca7881
Merge pull request #4130 from gamblor21/rp_dp_parallel
Add RP2040 displayio.ParallelBus Support
2021-03-16 13:49:55 -05:00
Scott Shawcroft 856bf302b4
Merge pull request #4418 from weblate/weblate-circuitpython-main
Translations update from Weblate
2021-03-16 11:48:51 -07:00
Jeff Epler df2d08366a make translate 2021-03-16 13:37:19 -05:00
Jeff Epler e1dd396de7 fix stub docs 2021-03-16 13:37:04 -05:00
spe2 dcd9a8ab91
Update ports/raspberrypi/boards/sparkfun_pro_micro_rp2040/mpconfigboard.mk
Co-authored-by: Scott Shawcroft <scott@tannewt.org>
2021-03-16 10:54:20 -07:00
spe2 5bc132a209
Update ports/raspberrypi/boards/sparkfun_pro_micro_rp2040/mpconfigboard.h
Co-authored-by: Scott Shawcroft <scott@tannewt.org>
2021-03-16 10:54:15 -07:00
mintakka b5333f2bdf
Update ports/raspberrypi/boards/sparkfun_thingplus_rp2040/mpconfigboard.h
Co-authored-by: Scott Shawcroft <scott@tannewt.org>
2021-03-16 13:47:33 -04:00
mintakka 3d15877639
Update ports/raspberrypi/boards/sparkfun_thingplus_rp2040/mpconfigboard.mk
Co-authored-by: Scott Shawcroft <scott@tannewt.org>
2021-03-16 13:47:21 -04:00
mintakka cae3397ea0
Update .github/workflows/build.yml
Co-authored-by: Scott Shawcroft <scott@tannewt.org>
2021-03-16 13:47:10 -04:00
Hosted Weblate f13bee0471 Merge remote-tracking branch 'origin/main' into main 2021-03-16 18:25:14 +01:00
Scott Shawcroft 9e0cfcff96
Merge pull request #4416 from adafruit/tannewt-patch-1
Add Sourcegraph link and raspberrypi port
2021-03-16 10:25:09 -07:00
Jeff Epler 58679dc038 Merge remote-tracking branch 'origin/main' into bitmap-read-2 2021-03-16 12:21:50 -05:00
Jeff Epler 97b6664201 re-format with uncrustify 2021-03-16 12:20:09 -05:00
Kattni Rembor 2b910b7292 Adding LED for D13/L pin name. 2021-03-16 12:14:40 -04:00
امير محمد العمري e16c0f38e8
Translated using Weblate (Swedish)
Currently translated at 100.0% (974 of 974 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/sv/
2021-03-16 16:42:27 +01:00
Hosted Weblate 5167e9cbac Merge remote-tracking branch 'origin/main' into main 2021-03-16 15:54:21 +01:00
Jonny Bergdahl 4a5df5ab9b
Translated using Weblate (Swedish)
Currently translated at 100.0% (974 of 974 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/sv/
2021-03-16 15:54:21 +01:00
Wellington Terumi Uemura cd108e50ba
Translated using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (974 of 974 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/pt_BR/
2021-03-16 15:54:21 +01:00
Alessandro Mandelli 9d523fd6da
Translated using Weblate (Italian)
Currently translated at 44.4% (433 of 974 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/it/
2021-03-16 15:54:21 +01:00
Hugo Dahl c6e696ae11
Translated using Weblate (French)
Currently translated at 99.4% (969 of 974 strings)

Translation: CircuitPython/main
Translate-URL: https://hosted.weblate.org/projects/circuitpython/main/fr/
2021-03-16 15:54:19 +01:00
Jeff Epler bc690d4070
Merge pull request #4415 from jepler/pre-commit-no-run-if-empty
pre-commit: code formatter fixes
2021-03-16 09:54:12 -05:00
gamblor21 bdc368895f Formatting 2021-03-16 08:39:44 -05:00
gamblor21 0890b54cd9 More formatting 2021-03-16 08:29:04 -05:00
gamblor21 fb437d8280 Formatting fixes 2021-03-16 08:22:02 -05:00
gamblor21 3b01a65743 Fixed formatting 2021-03-16 08:14:49 -05:00
spe2 9de40f56f3
Add board config files 2021-03-15 22:08:19 -06:00
spe2 c9427780b3
Create pins.c 2021-03-15 22:07:24 -06:00
spe2 ea578a10a6
Update build.yml
Add Pro Micro RP2040 to build.yml.
2021-03-15 21:19:51 -06:00