From 7ef9c2e49eb9c43cb6b5ccf0ba852df2096f32cf Mon Sep 17 00:00:00 2001 From: ladyada Date: Thu, 15 Mar 2012 17:30:33 -0400 Subject: [PATCH] made drawRect use fast lines --- Adafruit_GFX.cpp | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/Adafruit_GFX.cpp b/Adafruit_GFX.cpp index 40a5123..cad1216 100644 --- a/Adafruit_GFX.cpp +++ b/Adafruit_GFX.cpp @@ -175,11 +175,9 @@ void Adafruit_GFX::drawLine(int16_t x0, int16_t y0, void Adafruit_GFX::drawRect(uint16_t x, uint16_t y, uint16_t w, uint16_t h, uint16_t color) { - // stupidest version - update in subclasses if desired! - for (uint16_t i=x; i (width() - textsize*6)) { + cursor_y += textsize*8; + cursor_x = 0; + } } #if ARDUINO >= 100 return 1;