TM STM32F4xx Libraries  v1.0.0
Libraries for STM32F4xx devices from Tilen Majerle
tm_stm32f4_fonts.h
1 
30 #ifndef TM_FONTS_H
31 #define TM_FONTS_H 120
32 
33 /* C++ detection */
34 #ifdef __cplusplus
35 extern C {
36 #endif
37 
76 #include "stm32f4xx.h"
77 #include "defines.h"
78 #include "string.h"
79 
89 typedef struct {
90  uint8_t FontWidth;
91  uint8_t FontHeight;
92  const uint16_t *data;
93 } TM_FontDef_t;
94 
98 typedef struct {
99  uint16_t Length;
100  uint16_t Height;
102 
117 
122 
127 
145 char* TM_FONTS_GetStringSize(char* str, TM_FONTS_SIZE_t* SizeStruct, TM_FontDef_t* Font);
146 
159 /* C++ detection */
160 #ifdef __cplusplus
161 }
162 #endif
163 
164 
165 #endif
166 
char * TM_FONTS_GetStringSize(char *str, TM_FONTS_SIZE_t *SizeStruct, TM_FontDef_t *Font)
Calculates string length and height in units of pixels depending on string and font used...
const uint16_t * data
Definition: tm_stm32f4_fonts.h:92
TM_FontDef_t TM_Font_16x26
16 x 26 pixels font size structure
uint16_t Height
Definition: tm_stm32f4_fonts.h:100
String length and height.
Definition: tm_stm32f4_fonts.h:98
TM_FontDef_t TM_Font_11x18
11 x 18 pixels font size structure
TM_FontDef_t TM_Font_7x10
7 x 10 pixels font size structure
uint16_t Length
Definition: tm_stm32f4_fonts.h:99
uint8_t FontHeight
Definition: tm_stm32f4_fonts.h:91
uint8_t FontWidth
Definition: tm_stm32f4_fonts.h:90
Font structure used on my LCD libraries.
Definition: tm_stm32f4_fonts.h:89