Add print at position shortcuts
This commit is contained in:
@@ -38,6 +38,11 @@ int lcd_put_wchar_max(wchar_t c, pixel_len_t max_length);
|
||||
*/
|
||||
int lcd_put_u8str_max(const char * utf8_str, pixel_len_t max_length);
|
||||
|
||||
/**
|
||||
* Set the print baseline position
|
||||
*/
|
||||
void lcd_moveto(const lcd_uint_t col, const lcd_uint_t row);
|
||||
|
||||
/**
|
||||
* @brief Draw a ROM UTF-8 string
|
||||
*
|
||||
@@ -49,13 +54,19 @@ int lcd_put_u8str_max(const char * utf8_str, pixel_len_t max_length);
|
||||
* Draw a ROM UTF-8 string
|
||||
*/
|
||||
int lcd_put_u8str_max_P(PGM_P utf8_str_P, pixel_len_t max_length);
|
||||
|
||||
void lcd_moveto(const lcd_uint_t col, const lcd_uint_t row);
|
||||
inline int lcd_put_u8str_max_P(const lcd_uint_t col, const lcd_uint_t row, PGM_P utf8_str_P, pixel_len_t max_length) {
|
||||
lcd_moveto(col, row);
|
||||
return lcd_put_u8str_max_P(utf8_str_P, max_length);
|
||||
}
|
||||
|
||||
void lcd_put_int(const int i);
|
||||
inline void lcd_put_int(const lcd_uint_t col, const lcd_uint_t row, const int i) { lcd_moveto(col, row); lcd_put_int(i); }
|
||||
|
||||
inline int lcd_put_u8str_P(PGM_P str) { return lcd_put_u8str_max_P(str, PIXEL_LEN_NOLIMIT); }
|
||||
inline int lcd_put_u8str_P(const lcd_uint_t col, const lcd_uint_t row, PGM_P str) { lcd_moveto(col, row); return lcd_put_u8str_P(str); }
|
||||
|
||||
inline int lcd_put_u8str(const char* str) { return lcd_put_u8str_max(str, PIXEL_LEN_NOLIMIT); }
|
||||
inline int lcd_put_u8str(const lcd_uint_t col, const lcd_uint_t row, PGM_P str) { lcd_moveto(col, row); return lcd_put_u8str(str); }
|
||||
|
||||
inline int lcd_put_wchar(const wchar_t c) { return lcd_put_wchar_max(c, PIXEL_LEN_NOLIMIT); }
|
||||
inline int lcd_put_wchar(const lcd_uint_t col, const lcd_uint_t row, const wchar_t c) { lcd_moveto(col, row); return lcd_put_wchar(c); }
|
||||
|
||||
Reference in New Issue
Block a user