docs(data_binding): fix typos

This commit is contained in:
Gabor Kiss-Vamosi
2025-09-05 11:01:09 +02:00
parent 876dacb881
commit db71f482db
3 changed files with 11 additions and 5 deletions
+1 -1
View File
@@ -152,7 +152,7 @@ value directly. Note that this is a two-way binding (Subject <===> Widget), so
user's direct interaction with the Arc Widget updates the Subject's value and vice user's direct interaction with the Arc Widget updates the Subject's value and vice
versa. versa.
It support integer and float subjects. It supports integer subjects and, when ``LV_USE_FLOAT`` is enabled, float subjects.
- :cpp:expr:`lv_arc_bind_value(arc, &subject)` - :cpp:expr:`lv_arc_bind_value(arc, &subject)`
+9 -4
View File
@@ -212,6 +212,11 @@ the Subject's value is used to update the Label's text as follows:
:integer Subject: Subject's integer value is used with the ``format_string`` argument. :integer Subject: Subject's integer value is used with the ``format_string`` argument.
See :ref:`observer_format_string` for details. See :ref:`observer_format_string` for details.
:float Subject: Subject's float value is used with the ``format_string`` argument.
Requires ``LV_USE_FLOAT``.
See :ref:`observer_format_string` for details.
Note that this is a one-way binding (Subject ===> Widget). Note that this is a one-way binding (Subject ===> Widget).
- :cpp:expr:`lv_label_bind_text(label, &subject, format_string)` - :cpp:expr:`lv_label_bind_text(label, &subject, format_string)`
@@ -233,8 +238,8 @@ printf-like format specifier and be one of the following:
cross-platform equivalent where ``xx`` can be ``8``, cross-platform equivalent where ``xx`` can be ``8``,
``16``, ``32`` or ``64``, depending on the platform). ``16``, ``32`` or ``64``, depending on the platform).
:float Subject: "%f" format specifier, or e.g. "%0.2f" to display two digits after the decimal point. :float Subject: "%f" format specifier, e.g. "%0.2f", to display two digits
after the decimal point.
If ``NULL`` is passed for the ``format_string`` argument: If ``NULL`` is passed for the ``format_string`` argument:
@@ -242,9 +247,9 @@ If ``NULL`` is passed for the ``format_string`` argument:
:integer Subject: The Label will simply display the number. Equivalent to "%d". :integer Subject: The Label will simply display the number. Equivalent to "%d".
:float Subject: The Label will display the value with "%0.1f" format string. :float Subject: The Label will display the value with "%0.1f" format string.
**Example:** "%d |deg|\C" **Example:** "%d |deg|\ C"
As usual with format strings, ``%%`` shall be used to get ``%``. For example ``%d%%`` As usual with format strings, ``%%`` is used to get ``%``. For example ``%d%%``
@@ -122,6 +122,7 @@ unsigned int lv_opengles_texture_get_texture_id(lv_display_t * disp)
if(disp->flush_cb != flush_cb) { if(disp->flush_cb != flush_cb) {
return 0; return 0;
} }
lv_opengles_texture_t * dsc = lv_display_get_driver_data(disp); lv_opengles_texture_t * dsc = lv_display_get_driver_data(disp);
return dsc->texture_id; return dsc->texture_id;
} }