summaryrefslogtreecommitdiff
path: root/fw/fe310/eos/eve/widget/textw.h
diff options
context:
space:
mode:
authorUros Majstorovic <majstor@majstor.org>2020-08-23 22:37:16 +0200
committerUros Majstorovic <majstor@majstor.org>2020-08-23 22:37:16 +0200
commit1e5eb7cb910e6f23c69c2c986b6373e9f9abb980 (patch)
tree5e8ed0ad6b2fcba747c626c1c51afebbf76b3b9d /fw/fe310/eos/eve/widget/textw.h
parent57c1824affca858023c65c84e188ea7dc6c0a5f2 (diff)
dynamic memory alloc for gui added; page navigation added
Diffstat (limited to 'fw/fe310/eos/eve/widget/textw.h')
-rw-r--r--fw/fe310/eos/eve/widget/textw.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/fw/fe310/eos/eve/widget/textw.h b/fw/fe310/eos/eve/widget/textw.h
index cd46ea3..36ab466 100644
--- a/fw/fe310/eos/eve/widget/textw.h
+++ b/fw/fe310/eos/eve/widget/textw.h
@@ -29,11 +29,21 @@ typedef struct EVETextWidget {
} track;
} EVETextWidget;
+typedef struct EVETextSpec {
+ EVEFont *font;
+ uint16_t text_size;
+ uint16_t line_size;
+} EVETextSpec;
+
+int eve_textw_create(EVETextWidget *widget, EVERect *g, EVETextSpec *spec);
+void eve_textw_destroy(EVETextWidget *widget);
void eve_textw_init(EVETextWidget *widget, EVERect *g, EVEFont *font, utf8_t *text, uint16_t text_size, uint16_t *line, uint16_t line_size);
+void eve_textw_update(EVETextWidget *widget, EVEFont *font, utf8_t *text, uint16_t text_size, uint16_t *line, uint16_t line_size);
+
int eve_textw_touch(EVEWidget *_widget, EVEPage *page, uint8_t tag0, int touch_idx);
uint8_t eve_textw_draw(EVEWidget *_widget, EVEPage *page, uint8_t tag0);
void eve_textw_putc(void *_w, int c);
-uint16_t eve_textw_update(EVETextWidget *widget, EVEPage *page, uint16_t line);
+uint16_t eve_textw_text_update(EVETextWidget *widget, EVEPage *page, uint16_t line);
void eve_textw_cursor_update(EVETextWidget *widget, EVETextCursor *cursor);
void eve_textw_cursor_set(EVETextWidget *widget, EVETextCursor *cursor, uint8_t tag, int16_t x);
void eve_textw_cursor_clear(EVETextWidget *widget, EVETextCursor *cursor);