Library to control a Graphics TFT connected to 4-wire SPI - revised for the Raio RA8875 Display Controller.

Dependents:   FRDM_RA8875_mPaint RA8875_Demo RA8875_KeyPadDemo SignalGenerator ... more

Fork of SPI_TFT by Peter Drescher

See Components - RA8875 Based Display

Enhanced touch-screen support - where it previous supported both the Resistive Touch and Capacitive Touch based on the FT5206 Touch Controller, now it also has support for the GSL1680 Touch Controller.

Offline Help Manual (Windows chm)

/media/uploads/WiredHome/ra8875.zip.bin (download, rename to .zip and unzip)

Revision:
101:e0aad446094a
Parent:
100:0b084475d5a9
Child:
104:8d1d3832a215
--- a/GraphicsDisplay.h	Sat Dec 19 15:55:09 2015 +0000
+++ b/GraphicsDisplay.h	Sun Jan 17 22:16:37 2016 +0000
@@ -192,21 +192,37 @@
     
     virtual RetCode_t blit(int x, int y, int w, int h, const int * color);    
     
+    /// This method returns the width in pixels of the chosen character
+    /// from the previously selected external font.
+    ///
+    /// @param[in] c is the character of interest.
+    /// @param[inout] width is a pointer to where the width will be stored.
+    ///     This parameter is NULL tested and will only be written if not null
+    ///     which is convenient if you only want the height.
+    /// @param[inout] height is a pointer to where the height will be stored.
+    ///     This parameter is NULL tested and will only be written if not null
+    ///     which is convenient if you only want the width.
+    /// @returns a pointer to the raw character data or NULL if not found.
+    ///
+    virtual const uint8_t * getCharMetrics(const unsigned char c, uint8_t * width, uint8_t * height);
+    
     /// This method transfers one character from the external font data
     /// to the screen.
     ///
+    /// The font being used has already been set with the SelectUserFont
+    /// API.
+    ///
     /// @note the font data is in a special format as generate by
     ///         the mikroe font creator.
     ///         See http://www.mikroe.com/glcd-font-creator/
     ///
     /// @param[in] x is the horizontal pixel coordinate
     /// @param[in] y is the vertical pixel coordinate
-    /// @param[in] fontTable is the base of the table which has the metrics
     /// @param[in] c is the character to render
     /// @returns how far the cursor should advance to the right in pixels.
     /// @returns zero if the character could not be rendered.
     ///
-    virtual int fontblit(int x, int y, const unsigned char * fontTable, const unsigned char c);
+    virtual int fontblit(int x, int y, const unsigned char c);
     
     /// This method returns the color value from a palette.
     ///