Update textarea.md
This commit is contained in:
committed by
GitHub
parent
1b7e2b5103
commit
6d8799fbbf
@@ -74,6 +74,11 @@ In password mode `lv_textarea_get_text(textarea)` returns the actual text entere
|
|||||||
|
|
||||||
The visibility time can be adjusted with `LV_TEXTAREA_DEF_PWD_SHOW_TIME)` in `lv_conf.h`.
|
The visibility time can be adjusted with `LV_TEXTAREA_DEF_PWD_SHOW_TIME)` in `lv_conf.h`.
|
||||||
|
|
||||||
|
### Text alignment
|
||||||
|
|
||||||
|
To align the text in the Text area ` lv_textarea_set_align(textarea, LV_TEXT_ALIGN_LEFT/RIGHT/CENTER)` needs to be used instead of setting the `text_align` style property.
|
||||||
|
|
||||||
|
|
||||||
### Accepted characters
|
### Accepted characters
|
||||||
You can set a list of accepted characters with `lv_textarae_set_accepted_chars(textarea, "0123456789.+-")`.
|
You can set a list of accepted characters with `lv_textarae_set_accepted_chars(textarea, "0123456789.+-")`.
|
||||||
Other characters will be ignored.
|
Other characters will be ignored.
|
||||||
@@ -81,6 +86,7 @@ Other characters will be ignored.
|
|||||||
### Max text length
|
### Max text length
|
||||||
The maximum number of characters can be limited with `lv_textarea_set_max_length(textarea, max_char_num)`
|
The maximum number of characters can be limited with `lv_textarea_set_max_length(textarea, max_char_num)`
|
||||||
|
|
||||||
|
|
||||||
### Very long texts
|
### Very long texts
|
||||||
If there is a very long text in the Text area (e. g. > 20k characters), scrolling and drawing might be slow.
|
If there is a very long text in the Text area (e. g. > 20k characters), scrolling and drawing might be slow.
|
||||||
However, by enabling `LV_LABEL_LONG_TXT_HINT 1` in `lv_conf.h` the performance can be hugely improved.
|
However, by enabling `LV_LABEL_LONG_TXT_HINT 1` in `lv_conf.h` the performance can be hugely improved.
|
||||||
|
|||||||
Reference in New Issue
Block a user