Commit Graph
487 Commits
Author SHA1 Message Date
Mikey Sklar d850c892d6 Merge pull request #302 from kinafu/master
Add const specifier for strings
2026-10-23 19:28:03 -07:00
Mikey Sklar 55a94acea3 Merge pull request #100 from wiredolphin/bitmap-font-inclusion
Bitmap font inclusion
2026-10-22 19:08:09 -07:00
Mikey Sklar 2815ae5993 Merge pull request #525 from mikeysklar/circle-helpers-startwrite
Make the circle helpers draw when called directly
2026-10-22 19:08:05 -07:00
Mikey Sklar 922c70e027 Merge pull request #524 from mikeysklar/gfx-virtual-destructor
Free canvas memory when deleted through an Adafruit_GFX pointer
2026-10-22 19:08:01 -07:00
Mikey SklarandClaude Opus 5.5 4d6d9bdf95 Make the circle helpers draw when called directly
drawCircleHelper and fillCircleHelper wrote pixels without startWrite,
so direct calls drew nothing on SPI displays (#437). They now open
their own write, and fillCircle, drawRoundRect and fillRoundRect close
theirs first so writes never nest.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-21 17:31:56 -07:00
Mikey SklarandClaude Opus 5.5 89f5117284 Format DigitalWF fonts like the other fonts
Add #pragma once and the Adafruit_GFX include, then run clang-format,
so CI passes.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-21 15:31:42 -07:00
Mikey SklarandClaude Opus 5.5 019a40791e Give Adafruit_GFX a virtual destructor except on AVR
Deleting a canvas or display through an Adafruit_GFX pointer called
only the base destructor, so the canvas buffer leaked (#369). AVR is
left out because a virtual destructor links malloc and free into
display sketches that never use the heap (+602 bytes on an Uno).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-21 13:09:49 -07:00
Tyeth Gundry 85ce269b27 Bump version to 1.13.0
Update version to 1.13.0
1.13.0
2026-10-20 16:23:49 +01:00
Adabot 152ea3bde2 Bump version to 1.13.0 2026-10-20 16:01:37 +01:00
Mikey Sklar bc85af5aa4 Merge pull request #522 from mikeysklar/nrf52840-softspi-hang
Fix software SPI displays hanging on nRF52840 boards
2026-10-18 05:41:57 -07:00
Mikey Sklar 7c2dac7953 Merge pull request #521 from mikeysklar/esp8266-softspi-wdt
Stop ESP8266 resets during long software SPI fills
2026-10-18 05:41:53 -07:00
Mikey SklarandClaude Opus 5.5 98ecc97d39 nRF52840: only use the SPIM3 DMA path with hardware SPI
writePixels and writeColor used hwspi._spi without checking the connection,
so displays on software SPI hung on the first fill.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-17 16:27:10 -07:00
Mikey SklarandClaude Opus 5.5 b36a1f0e2e ESP8266: shorter soft SPI fill passes to avoid soft WDT reset
Each 20000-pixel pass took about 1.65 s with no yield on a 3.5" HX8357,
which tripped the soft watchdog. 5000 pixels is about 0.4 s.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-17 16:25:01 -07:00
Mikey Sklar 0e844ad645 Merge pull request #520 from mikeysklar/esp8266-optimistic-yield-draw
Stop ESP8266 crashes when drawing from a timer
2026-10-17 05:46:22 -07:00
Mikey Sklar 725f6504e5 Merge pull request #518 from mikeysklar/canvas-malloc-fail
Make canvas 0x0 when buffer allocation fails
2026-10-17 05:46:19 -07:00
Mikey Sklar 6e254d955c Merge pull request #399 from asukiaaa/feature/support-larger-type-for-pins
Use int16_t for pins instead of int8_t
2026-10-17 05:46:16 -07:00
Mikey Sklar a1b383586a Merge pull request #370 from johnboiles/patch-1
Faster `writePixels` for ESP8266 with hardware SPI
2026-10-17 05:46:12 -07:00
Mikey SklarandClaude Opus 5.5 d9e22fb62e ESP8266: use optimistic_yield in line, circle, ellipse and soft SPI fills
yield() panics when drawing from a timer or Ticker callback (#285).
optimistic_yield(10000) still yields on long draws so the watchdog
stays fed, and does nothing where yielding is not allowed.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-16 16:42:02 -07:00
Mikey Sklar 9b7f8ef181 Merge pull request #519 from mikeysklar/esp8266-optimistic-yield
Make small drawing calls fast again on ESP8266
2026-10-16 16:26:15 -07:00
Mikey SklarandClaude Opus 5.5 9569fc6f3e ESP8266: use optimistic_yield in writeColor instead of delay(1)
delay(1) ran on every writeColor call, making small fills about 3x
slower (#479). delay(0) no longer yields on core 3.x and trips the
soft WDT, and yield() panics when drawing from SYS context.
optimistic_yield(10000) yields only after 10 ms and is a no-op where
yielding is not allowed.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-16 07:08:59 -07:00
Mikey SklarandClaude Opus 5.5 0e70b50655 Make canvas 0x0 when buffer allocation fails
If malloc fails in a GFXcanvas1/8/16 constructor, buffer is NULL and
fillRect, lines and text write through it and crash the board. Set the
canvas size to 0x0 instead so every draw call clips out, and sketches
can check width()/height() or getBuffer().

Based on #441 by @aremmell and the 0x0 idea from @jepler.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 18:23:25 -07:00
Mikey Sklar e6ffe30f00 Merge pull request #396 from leres/update
add missing newlines to a couple of error messages (in fontconvert)
2026-10-15 18:08:06 -07:00
Mikey Sklar af4ffdea12 Merge pull request #463 from adenvt/master
fix(fontconvert): use `pkg-config`
2026-10-15 18:07:57 -07:00
Mikey Sklar df5a4711c2 Merge pull request #457 from johnboiles/master
For ESP-IDF builds use arduino-esp32 instead of arduino dependency
2026-10-15 18:07:45 -07:00
Mikey Sklar a06b05f394 Merge pull request #507 from dforsi/patch-1
Update Adafruit_GFX.h
2026-10-15 18:07:36 -07:00
Mikey Sklar eca95ee801 Merge pull request #409 from BillyDonahue/patch-1
Fix `setAddrWindow` documentation copy paste error
2026-10-15 18:07:33 -07:00
Mikey Sklar 4a57ac5e9e Merge pull request #454 from gilesp1729/master
Make Adafruit_GFX_Button::drawButton work with custom fonts by using …
2026-10-15 14:14:55 -07:00
Mikey Sklar e21f500c28 Merge pull request #493 from bobmoss/fix-fillellipse-function
Modified fillEllipse to use writeFastHLine instead of drawFastHLine
2026-10-15 14:14:45 -07:00
Mikey Sklar 15ca7a42b0 Merge pull request #513 from 94xhn/fix/button-uninitialized-state
fix(GFX_Button): initialize currstate/laststate
2026-10-15 14:14:36 -07:00
Mikey Sklar 7e0dc0131f Merge pull request #514 from 94xhn/fix/gfxfont-word-range
Fix GFXfont range reads on big-endian targets
2026-10-15 14:14:13 -07:00
Mikey SklarandClaude Opus 5.5 a0f92f1f27 Measure button label at (0,0) and keep charBounds non-virtual
Measuring at the button position predicts a line wrap that print()
never does, so a wide label on a button near the right edge moved
off its button. Measure at (0,0) and offset by the returned x/y.

The charBounds virtual change is unrelated to this fix, so it is
dropped.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-15 08:11:04 -07:00
94xhn 43e293c138 Preserve wide custom-font ranges on big-endian targets
GFXfont stores first and last as uint16_t, but the custom-font paths read them as bytes. Use word-width reads while retaining the existing 8-bit character API, so the stored range is interpreted correctly without changing the font format or adding UTF-8 behavior.

Constraint: Keep the public 8-bit character API and limit the patch to issue #490\nRejected: UTF-8/API refactor | broader scope is outside the reported portability bug\nConfidence: high\nScope-risk: narrow\nReversibility: clean\nDirective: Keep GFXfont first/last accesses word-width when reading the stored range\nTested: MinGW GCC 8 -Wall -Wextra -Werror with an endian-aware host fixture; WSL GCC AddressSanitizer and UBSan; baseline fixture fails with 0x0 bounds while the fix passes with 5x7\nNot-tested: Physical Arduino board hardware
2026-07-18 14:13:48 +08:00
94xhn b522b1edba fix(GFX_Button): initialize currstate/laststate
Adafruit_GFX_Button's constructor only initializes _gfx, leaving
currstate/laststate as indeterminate memory. justPressed()/
justReleased() read these before the first press() call, so they can
report a spurious press/release transition on a button that was never
actually touched.

Fixes #401

Signed-off-by: 94xhn <87560781+94xhn@users.noreply.github.com>
2026-07-11 16:35:19 +08:00
Tyeth Gundry ac6d7c3869 Bump version to 1.12.6
Update version to 1.12.6
1.12.6
2026-04-09 22:30:17 +01:00
Adabot 90256fa0a0 Bump version to 1.12.6 2026-04-09 19:40:58 +01:00
BillMerryman c5f9fb14f1 Add drawRotatedRect and fillRotatedRect methods (#508)
* Add drawRotatedRect and fillRotatedRect methods

* Corrected docs
2026-04-01 10:21:37 -04:00
dforsi 2d6d9c3fa2 Update Adafruit_GFX.h
Fix comments of struct items

Background and text were inverted.
2026-03-24 21:56:03 +01:00
tyeth-ai-assistedandAdabot 7ab6d09178 Bump version to 1.12.5
Co-authored-by: Adabot <adabot@adafruit.com>
1.12.5
2026-02-26 01:46:41 +00:00
bfa5417212 Run clang-format (#505)
* Run clang-format

Co-authored-by: ladyada <limor@ladyada.net>

* Fix destructor spacing for CI clang-format

Co-authored-by: ladyada <limor@ladyada.net>

* Revert .ino formatting — keep examples as-is

Co-authored-by: ladyada <limor@ladyada.net>

---------

Co-authored-by: clawpi <clawpi@adafruit.com>
Co-authored-by: ladyada <limor@ladyada.net>
2026-02-17 15:26:49 -05:00
Bob Moss d68f27b7bf Modified fillEllipse to use writeFastHLine instead of drawFastHLine 2025-11-28 11:10:51 +00:00
Tyeth Gundry e4df4cc64f Update version to 1.12.4 in library.properties 1.12.4 2025-11-11 15:52:59 +00:00
BillMerryman 20abf158a1 Correct circle method docs (#487) 2025-11-07 14:26:52 -05:00
Tyeth Gundry a969a704bb Bump version to 1.12.3 in library.properties 1.12.3 2025-09-24 19:00:09 +01:00
DS-Aditya-928 4c89798ccd Optimise fillEllipse function. ~36% faster (#478)
* Optimised fillEllipse function

* Cleaned up code
2025-09-17 12:08:09 -04:00
Tyeth Gundry 9e06b6d222 Update version to 1.12.2 in library.properties 1.12.2 2025-09-16 15:07:43 +01:00
DS-Aditya-928 32da3d2094 Added drawEllipse and fillEllipse functions (#477)
* Added drawEllipse and fillEllipse functions

* Formatting fixes
2025-09-14 08:28:20 -04:00
Tyeth Gundry 21648a8299 Update library.properties - bump version to 1.12.1 1.12.1 2025-04-22 17:21:01 +01:00
Carter Nelson c450adbc04 Merge pull request #470 from caternuson/iss469_rp2040_spi
Fix RP2040 SPI peripheral mapping
2025-04-09 11:35:18 -07:00
caternuson 9709959658 fix RP2040 SPI peripheral mapping 2025-04-09 11:17:59 -07:00
Liz 87e15509a9 Update library.properties 1.12.0 2025-02-24 12:54:02 -05:00