Prusa MINI Firmware overview
|
Go to the source code of this file.
◆ RENDER_FLG_ALIGN
#define RENDER_FLG_ALIGN 0x00ff |
◆ RENDER_FLG_ROPFN
#define RENDER_FLG_ROPFN 0x0f00 |
◆ RENDER_FLG_WORDB
#define RENDER_FLG_WORDB 0x1000 |
◆ RENDER_FLG
#define RENDER_FLG |
( |
|
a, |
|
|
|
r |
|
) |
| (a | r << 8) |
◆ render_text_align()
11 uint16_t y = rc_pad.
y;
13 const char *str = text;
14 while ((n =
font_line_chars(font, str, rc_pad.
w)) && ((y + font->
h) <= (rc_pad.
y + rc_pad.
h))) {
17 while (str[
i] ==
' ' || str[
i] ==
'\n')
29 rect_ui16_t rc_b = { rc.
x, rc_pad.
y + rc_pad.
h, rc.
w, (rc.
y + rc.
h) - (rc_pad.
y + rc_pad.
h) };
31 rect_ui16_t rc_r = { rc_pad.
x + rc_pad.
w, rc.
y, (rc.
x + rc.
w) - (rc_pad.
x + rc_pad.
w), rc.
h };
38 if (wh_txt.
x && wh_txt.
y) {
42 rect_ui16_t rc_b = { rc.
x, rc_txt.
y + rc_txt.
h, rc.
w, (rc.
y + rc.
h) - (rc_txt.
y + rc_txt.
h) };
44 rect_ui16_t rc_r = { rc_txt.
x + rc_txt.
w, rc.
y, (rc.
x + rc.
w) - (rc_txt.
x + rc_txt.
w), rc.
h };
◆ render_icon_align()
57 if (wh_ico.
x && wh_ico.
y) {
61 rect_ui16_t rc_b = { rc.
x, rc_ico.
y + rc_ico.
h, rc.
w, (rc.
y + rc.
h) - (rc_ico.
y + rc_ico.
h) };
63 rect_ui16_t rc_r = { rc_ico.
x + rc_ico.
w, rc.
y, (rc.
x + rc.
w) - (rc_ico.
x + rc_ico.
w), rc.
h };
uint16_t y
Definition: guitypes.h:71
uint8_t h
Definition: guitypes.h:78
uint16_t w
Definition: guitypes.h:72
display_draw_char_t * draw_char
Definition: display.h:34
static rect_ui16_t rect_ui16(uint16_t x, uint16_t y, uint16_t w, uint16_t h)
Definition: guitypes.h:159
uint16_t x
Definition: guitypes.h:65
#define ALIGN_MASK
Definition: guitypes.h:18
#define RENDER_FLG_WORDB
Definition: display_helper.h:9
uint8_t i
Definition: screen_test_graph.c:72
u8_t flags
Definition: netif.h:305
display_draw_text_t * draw_text
Definition: display.h:35
Definition: guitypes.h:64
int font_line_chars(font_t *pf, const char *str, uint16_t line_width)
Definition: guitypes.c:122
rect_ui16_t rect_ui16_sub_padding_ui8(rect_ui16_t rc, padding_ui8_t pad)
Definition: guitypes.c:55
display_fill_rect_t * fill_rect
Definition: display.h:33
uint16_t y
Definition: guitypes.h:66
rect_ui16_t rect_intersect_ui16(rect_ui16_t rc, rect_ui16_t rc1)
Definition: guitypes.c:37
uint8_t w
Definition: guitypes.h:77
point_ui16_t icon_meas(const uint8_t *pi)
Definition: guitypes.c:155
#define ROPFN_SWAPBW
Definition: guitypes.h:32
Definition: guitypes.h:69
const uint8_t * resource_ptr(uint16_t id)
Definition: guitypes.c:168
display_t * display
Definition: display.c:6
uint16_t h
Definition: guitypes.h:73
display_draw_icon_t * draw_icon
Definition: display.h:36
uint16_t x
Definition: guitypes.h:70
point_ui16_t font_meas_text(font_t *pf, const char *str)
Definition: guitypes.c:97
static point_ui16_t point_ui16(uint16_t x, uint16_t y)
Definition: guitypes.h:154
rect_ui16_t rect_align_ui16(rect_ui16_t rc, rect_ui16_t rc1, uint8_t align)
Definition: guitypes.c:64