Solo Controller Documentation 1.0
Documentation for the Solo Controller
 
Loading...
Searching...
No Matches
Monofonto-Regular-180.h
Go to the documentation of this file.
1/******************************************************************************/
7/*
8 * DO NOT EDIT THIS FILE!
9 *
10 * This file was generated by the script, parse_font_xml.py.
11 *
12 ******************************************************************************/
13
14#ifndef Monofonto_Regular_180_DEFINED
15#define Monofonto_Regular_180_DEFINED
16
17#include "GrFont.h"
18
19/******************************************************************************/
23struct Monofonto_Regular_180 : public GrFont {
24
25 const uint8_t charDefNdxOffset = 32;
26 static const int8_t charDefNdx[] PROGMEM;
27 static const int16_t charDefData[69][7] PROGMEM;
28
33 : GrFont({
34 7405000, // Address in Flash ROM
35 880, // width of Image in Flash
36 800 // height of Image in Flash
37 },
38 180, // Line Height
39 173) {}
40
41
49 bool charDef(char cc, CharDef_t &results) const
50 {
51 // See if there is a valid char
52 int8_t ndx = pgm_read_byte(&(charDefNdx[cc - charDefNdxOffset]));
53 if (ndx == -1)
54 {
55 return false;
56 };
57
58 // Load the data from Flash. Copy data into results
59 uint8_t sizeSt = sizeof(results);
60 int16_t data[sizeSt];
61 for (uint8_t ii = 0; ii < sizeSt; ii++)
62 {
63 data[ii] = pgm_read_byte(&(charDefData[ndx][ii]));
64 }
65 memcpy(&results, &data, 2*sizeSt);
66
67 return true;
68 };
69
70
76 int8_t kerning(uint16_t ID) const {
77 switch(ID) {
78 default: return false;
79
80 }
81 };
82};
83
84#endif
Defines the base class used by all Graphical Fonts.
Data Structure that defines an individual character.
Definition GrFont.h:19
int8_t kerning(uint16_t ID) const
Returns the amount of kerning that should be used between two characters.
Definition Monofonto-Regular-180.h:76
const uint8_t charDefNdxOffset
Offset to the first character in the index.
Definition Monofonto-Regular-180.h:25
static const int8_t charDefNdx[] PROGMEM
Index mapping characters to entries in the charDefData table.
Definition Monofonto-Regular-180.h:26
bool charDef(char cc, CharDef_t &results) const
Defines the properties of each character.
Definition Monofonto-Regular-180.h:49
Monofonto_Regular_180(void)
Constructs a new font object.
Definition Monofonto-Regular-180.h:32