/lvgl-3.5.0/docs/widgets/core/ |
D | textarea.md | 7 Long lines are wrapped and when the text becomes long enough the Text area can be scrolled. 12 …of the text area. Uses all the typical background style properties and the text related style prop… 13 - `LV_PART_SCROLLBAR` The scrollbar that is shown when the text is too long. 14 …text](/widgets/core/label.html#text-selection). Only `text_color` and `bg_color` style properties … 18 - `LV_PART_TEXTAREA_PLACEHOLDER` Unique to Text Area, allows styling the placeholder text. 22 ### Add text 24 You can insert text or characters to the current cursor's position with: 27 - `lv_textarea_add_text(textarea, "insert this text")` 31 `lv_textarea_set_text(ta, "New text")` changes the whole text. 35 …aceholder text can be specified - which is displayed when the Text area is empty - with `lv_textar… [all …]
|
D | label.md | 4 A label is the basic object type that is used to display text. 7 …ypical background properties and the text properties. The padding values can be used to add space… 8 - `LV_PART_SCROLLBAR` The scrollbar that is shown when the text is larger than the widget's size. 9 - `LV_PART_SELECTED` Tells the style of the [selected text](#text-selection). Only `text_color` and… 13 ### Set text 14 You can set the text on a label at runtime with `lv_label_set_text(label, "New text")`. 16 Therefore, you don't need to keep the text you pass to `lv_label_set_text` in scope after that func… 18 With `lv_label_set_text_fmt(label, "Value: %d", 15)` printf formatting can be used to set the text. 20 Labels are able to show text from a static character buffer. To do so, use `lv_label_set_text_stat… 21 In this case, the text is not stored in the dynamic memory and the given buffer is used directly in… [all …]
|
D | checkbox.md | 9 - `LV_PART_MAIN` The is the background of the Checkbox and it uses the text and all the typical bac… 20 The text can be modified with the `lv_checkbox_set_text(cb, "New text")` function and will be dynam… 22 To set a static text, 23 …tic_text(cb, txt)`. This way, only a pointer to `txt` will be stored. The text then shouldn't be d…
|
D | dropdown.md | 8 The drop-down list is closed by default and displays a single value or a predefined text. 18 …round of the button. Uses the typical background properties and text properties for the text on it. 19 - `LV_PART_INDICATOR` Typically an arrow symbol that can be an image or a text (`LV_SYMBOL`). 67 …er show the selected option or a static text. If a static is set with `lv_dropdown_set_text(dropdo… 68 If the text is `NULL` the selected option is displayed on the button.
|
D | table.md | 13 …he cells of the table also use all the typical background style properties and the text properties. 20 The cells can store only text so numbers need to be converted to text before displaying them in a t… 22 `lv_table_set_cell_value(table, row, col, "Content")`. The text is saved by the table so it can be … 24 Line breaks can be used in the text like `"Value\n60.3"`.
|
D | roller.md | 8 - `LV_PART_MAIN` The background of the roller uses all the typical background properties and text s… 10 … the typical background properties it uses the text style properties to change the appearance of t…
|
D | btnmatrix.md | 11 - `LV_PART_ITEMS` The buttons all use the text and typical background style properties except trans… 15 ### Button's text 16 There is a text on each button. To specify them a descriptor string array, called *map*, needs to b… 50 The set a control map for a button matrix (similarly to the map for the text), use `lv_btnmatrix_se… 70 `lv_btnmatrix_get_btn_text(btnm, btn_id)` returns a pointer to the text of `btn_id`th button.
|
/lvgl-3.5.0/src/widgets/ |
D | lv_label.c | 85 void lv_label_set_text(lv_obj_t * obj, const char * text) in lv_label_set_text() argument 93 if(text == NULL) text = label->text; in lv_label_set_text() 95 if(label->text == text && label->static_txt == 0) { in lv_label_set_text() 99 size_t len = _lv_txt_ap_calc_bytes_cnt(text); in lv_label_set_text() 101 label->text = lv_mem_realloc(label->text, len); in lv_label_set_text() 102 LV_ASSERT_MALLOC(label->text); in lv_label_set_text() 103 if(label->text == NULL) return; in lv_label_set_text() 105 _lv_txt_ap_proc(label->text, label->text); in lv_label_set_text() 107 label->text = lv_mem_realloc(label->text, strlen(label->text) + 1); in lv_label_set_text() 110 LV_ASSERT_MALLOC(label->text); in lv_label_set_text() [all …]
|
D | lv_label.h | 55 char * text; member 101 void lv_label_set_text(lv_obj_t * obj, const char * text); 117 void lv_label_set_text_static(lv_obj_t * obj, const char * text);
|
/lvgl-3.5.0/docs/widgets/extra/ |
D | span.md | 5 …is the object that is used to display rich text. Different from the label object, `spangroup` can … 12 ### Set text and style 14 …text and text style. so, first we need to create `span` descriptor using `lv_span_t * span = lv_sp… 16 …ll `lv_spangroup_refr_mode()` after you have modified `span` style(eg:set text, changed the font s… 32 - `LV_TEXT_ALIGN_LEFT` Align text to left. 33 - `LV_TEXT_ALIGN_CENTER` Align text to center. 34 - `LV_TEXT_ALIGN_RIGHT` Align text to right. 35 - `LV_TEXT_ALIGN_AUTO` Align text auto. 37 use function `lv_spangroup_set_align(spangroup, LV_TEXT_ALIGN_CENTER)` to set text align. 42 - `LV_SPAN_MODE_EXPAND` Expand the object size to the text size but stay on a single line. [all …]
|
D | list.md | 18 `lv_list_add_btn(list, icon, text)` adds a full-width button with an icon - that can be an image or… 20 The text starts to scroll horizontally if it's too long. 23 `lv_list_add_text(list, text)` adds a text.
|
D | msgbox.md | 5 They are built from a background container, a title, an optional close button, a text and optional … 7 The text will be broken into multiple lines automatically and the height will be set automatically … 15 - Title and text: [lv_label](/widgets/core/label) 24 … is `NULL` the message box will be modal. `title` and `txt` are strings for the title and the text. 25 `btn_txts[]` is an array with the buttons' text. E.g. `const char * btn_txts[] = {"Ok", "Cancel", N… 42 … `lv_msgbox_get_active_btn_text(msgbox)` can be used to get the index and text of the clicked butt…
|
/lvgl-3.5.0/tests/src/test_cases/ |
D | test_textarea.c | 35 const char * text = "Hello LVGL!"; in test_textarea_should_return_actual_text_when_password_mode_is_enabled() local 37 lv_textarea_add_text(textarea, text); in test_textarea_should_return_actual_text_when_password_mode_is_enabled() 41 TEST_ASSERT_EQUAL_STRING(text, lv_textarea_get_text(textarea)); in test_textarea_should_return_actual_text_when_password_mode_is_enabled() 71 const char * text = "Hello LVGL!"; in test_textarea_should_update_placeholder_text() local 74 lv_textarea_set_placeholder_text(textarea, text); in test_textarea_should_update_placeholder_text() 75 TEST_ASSERT_EQUAL_STRING(text, lv_textarea_get_placeholder_text(textarea)); in test_textarea_should_update_placeholder_text()
|
/lvgl-3.5.0/src/misc/ |
D | lv_txt.c | 91 void lv_txt_get_size(lv_point_t * size_res, const char * text, const lv_font_t * font, lv_coord_t l… in lv_txt_get_size() argument 97 if(text == NULL) return; in lv_txt_get_size() 107 while(text[line_start] != '\0') { in lv_txt_get_size() 108 …new_line_start += _lv_txt_get_next_line(&text[line_start], font, letter_space, max_width, NULL, fl… in lv_txt_get_size() 120 …lv_coord_t act_line_length = lv_txt_get_width(&text[line_start], new_line_start - line_start, font… in lv_txt_get_size() 128 if((line_start != 0) && (text[line_start - 1] == '\n' || text[line_start - 1] == '\r')) { in lv_txt_get_size() 458 char * text = 0; in _lv_txt_set_text_vfmt() local 471 text = lv_mem_alloc(len_ap + 1); in _lv_txt_set_text_vfmt() 472 LV_ASSERT_MALLOC(text); in _lv_txt_set_text_vfmt() 473 if(text == NULL) { in _lv_txt_set_text_vfmt() [all …]
|
/lvgl-3.5.0/docs/_ext/ |
D | lv_example.py | 46 …paragraph_node = nodes.raw(text=f"<p>{self.human_language_name(language)} code </p>", format… 47 for text, url in buttons.items(): 48 …paragraph_node.append(nodes.raw(text=f"<a class='lv-example-link-button' onclick=\"event.stopPropa… 77 …layout_node = nodes.raw(text=f"<div class='lv-example-container'>{iframe_html}{description_html}</… 85 trailing_node = nodes.raw(text=f"<hr/>", format='html')
|
/lvgl-3.5.0/src/extra/libs/qrcode/ |
D | qrcodegen.h | 169 bool qrcodegen_encodeText(const char *text, uint8_t tempBuffer[], uint8_t qrcode[], 237 bool qrcodegen_isAlphanumeric(const char *text); 244 bool qrcodegen_isNumeric(const char *text); 280 struct qrcodegen_Segment qrcodegen_makeAlphanumeric(const char *text, uint8_t buf[]);
|
D | qrcodegen.c | 128 bool qrcodegen_encodeText(const char *text, uint8_t tempBuffer[], uint8_t qrcode[], in qrcodegen_encodeText() argument 131 size_t textLen = strlen(text); in qrcodegen_encodeText() 137 if (qrcodegen_isNumeric(text)) { in qrcodegen_encodeText() 140 seg = qrcodegen_makeNumeric(text, tempBuffer); in qrcodegen_encodeText() 141 } else if (qrcodegen_isAlphanumeric(text)) { in qrcodegen_encodeText() 144 seg = qrcodegen_makeAlphanumeric(text, tempBuffer); in qrcodegen_encodeText() 149 tempBuffer[i] = (uint8_t)text[i]; in qrcodegen_encodeText() 797 bool qrcodegen_isAlphanumeric(const char *text) { in qrcodegen_isAlphanumeric() argument 798 assert(text != NULL); in qrcodegen_isAlphanumeric() 799 for (; *text != '\0'; text++) { in qrcodegen_isAlphanumeric() [all …]
|
/lvgl-3.5.0/docs/porting/ |
D | log.md | 42 You can also use the log module via the `LV_LOG_TRACE/INFO/WARN/ERROR/USER(text)` or `LV_LOG(text)`… 44 - `LV_LOG_TRACE/INFO/WARN/ERROR/USER(text)` append following information to your `text` 49 - `LV_LOG(text)` is similar to `LV_LOG_USER` but has no extra information attached.
|
/lvgl-3.5.0/src/extra/widgets/msgbox/ |
D | lv_msgbox.c | 112 mbox->text = lv_label_create(mbox->content); in lv_msgbox_create() 113 lv_label_set_text(mbox->text, txt); in lv_msgbox_create() 114 lv_label_set_long_mode(mbox->text, LV_LABEL_LONG_WRAP); in lv_msgbox_create() 115 lv_obj_set_width(mbox->text, lv_pct(100)); in lv_msgbox_create() 157 return mbox->text; in lv_msgbox_get_text()
|
/lvgl-3.5.0/docs/ |
D | CODING_STYLE.md | 64 * Set a new text for a label. Memory will be allocated to store the text by the label. 66 * @param text '\0' terminated character string. NULL to refresh with the current text. 68 void lv_label_set_text(lv_obj_t * label, const char * text) 78 if(text == ext->txt || text == NULL) { /*Bracket of statements start inline*/
|
/lvgl-3.5.0/examples/widgets/chart/ |
D | lv_example_chart_3.c | 9 if(dsc->id == LV_CHART_AXIS_PRIMARY_X && dsc->text) { in draw_event_cb() 11 lv_snprintf(dsc->text, dsc->text_length, "%s", month[dsc->value]); in draw_event_cb()
|
/lvgl-3.5.0/src/extra/widgets/span/ |
D | lv_span.h | 99 void lv_span_set_text(lv_span_t * span, const char * text); 107 void lv_span_set_text_static(lv_span_t * span, const char * text);
|
/lvgl-3.5.0/examples/widgets/keyboard/ |
D | index.rst | 2 Keyboard with text area
|
/lvgl-3.5.0/examples/others/imgfont/ |
D | index.rst | 1 Use emojis in a text.
|
/lvgl-3.5.0/docs/overview/ |
D | font.md | 17 Your editor needs to be configured to save your code/text as UTF-8 (usually this the default) and b… 89 LVGL not only supports RTL texts but supports mixed (a.k.a. bidirectional, BiDi) text rendering too… 91 ![](/misc/bidi.png "Bidirectional text examples") 95 …r RTL) which determines some rendering rules and the default alignment of the text (Left or Right). 118 …splay Arabic and Persian characters: the *form* of a character depends on its position in the text. 124 - Only displaying text is supported (e.g. on labels), text inputs (e.g. text area) don't support th… 125 - Static text (i.e. const) is not processed. E.g. texts set by `lv_label_set_text()` will be "Arabi… 126 - Text get functions (e.g. `lv_label_get_text()`) will return the processed text. 175 3. Create a label and set the text. Eg. `lv_label_set_text(label, MY_USB_SYMBOL)` 177 …mbol in the font defined in `style.text.font` properties. To use the symbol you may need to change… [all …]
|