chore: many trivial spelling and layout fixes (#3008)

Co-authored-by: Gabor Kiss-Vamosi <kisvegabor@gmail.com>
This commit is contained in:
ckielstra
2022-01-17 14:10:23 +01:00
committed by GitHub
parent a9a6cb8efd
commit febafd1cc7
128 changed files with 316 additions and 335 deletions

View File

@@ -299,7 +299,7 @@ The number of cache entries can be defined with `LV_IMG_CACHE_DEF_SIZE` in *lv_c
The size of the cache can be changed at run-time with `lv_img_cache_set_size(entry_num)`.
### Value of images
When you use more images than cache entries, LVGL can't cache all of the images. Instead, the library will close one of the cached images to free space.
When you use more images than cache entries, LVGL can't cache all the images. Instead, the library will close one of the cached images to free space.
To decide which image to close, LVGL uses a measurement it previously made of how long it took to open the image. Cache entries that hold slower-to-open images are considered more valuable and are kept in the cache as long as possible.

View File

@@ -25,7 +25,7 @@ Pointer input devices (like a mouse) can have a cursor.
lv_indev_t * mouse_indev = lv_indev_drv_register(&indev_drv);
LV_IMG_DECLARE(mouse_cursor_icon); /*Declare the image source.*/
lv_obj_t * cursor_obj = lv_img_create(lv_scr_act()); /*Create an image object for the cursor */
lv_obj_t * cursor_obj = lv_img_create(lv_scr_act()); /*Create an image object for the cursor */
lv_img_set_src(cursor_obj, &mouse_cursor_icon); /*Set the image source*/
lv_indev_set_cursor(mouse_indev, cursor_obj); /*Connect the image object to the driver*/
```
@@ -34,7 +34,7 @@ Note that the cursor object should have `lv_obj_clear_flag(cursor_obj, LV_OBJ_FL
For images, *clicking* is disabled by default.
### Gestures
Pointer input devives can detect basic gestures. By default, most of the widgets send the gestures to its parent, so finally the gestures can be detected on the screen object in a form of an `LV_EVENT_GESTURE` event. For example:
Pointer input devices can detect basic gestures. By default, most of the widgets send the gestures to its parent, so finally the gestures can be detected on the screen object in a form of an `LV_EVENT_GESTURE` event. For example:
```c
void my_event(lv_event_t * e)
@@ -62,7 +62,7 @@ void my_event(lv_event_t * e)
lv_obj_add_event_cb(screen1, my_event, LV_EVENT_GESTURE, NULL);
```
To prevent passing the gesture event to the parent from an obejct use `lv_obj_clear_flag(obj, LV_OBJ_FLAG_GESTURE_BUBBLE)`.
To prevent passing the gesture event to the parent from an object use `lv_obj_clear_flag(obj, LV_OBJ_FLAG_GESTURE_BUBBLE)`.
Note that, gestures are not triggered if an object is being scrolled.

View File

@@ -83,7 +83,7 @@ lv_obj_set_pos(parent, 50, 50); /*Move the parent. The child will move with it.*
### Visibility only on the parent
If a child is partially or fully outside of its parent then the parts outside will not be visible.
If a child is partially or fully outside its parent then the parts outside will not be visible.
![](/misc/par_child3.png "A graphical object is visible on its parent")

View File

@@ -5,7 +5,7 @@
# Scroll
## Overview
In LVGL scrolling works very intuitively: if an object is outside of its parent content area (the size without padding), the parent becomes scrollable and scrollbar(s) will appear. That's it.
In LVGL scrolling works very intuitively: if an object is outside its parent content area (the size without padding), the parent becomes scrollable and scrollbar(s) will appear. That's it.
Any object can be scrollable including `lv_obj_t`, `lv_img`, `lv_btn`, `lv_meter`, etc
@@ -17,7 +17,7 @@ The object can either be scrolled horizontally or vertically in one stroke; diag
Scrollbars are displayed according to a configured `mode`. The following `mode`s exist:
- `LV_SCROLLBAR_MODE_OFF` Never show the scrollbars
- `LV_SCROLLBAR_MODE_ON` Always show the scrollbars
- `LV_SCROLLBAR_MODE_ACTIVE` Show scroll bars while a object is being scrolled
- `LV_SCROLLBAR_MODE_ACTIVE` Show scroll bars while an object is being scrolled
- `LV_SCROLLBAR_MODE_AUTO` Show scroll bars when the content is large enough to be scrolled
`lv_obj_set_scrollbar_mode(obj, LV_SCROLLBAR_MODE_...)` sets the scrollbar mode on an object.

View File

@@ -139,7 +139,7 @@ Zoom image-like objects. Multiplied with the zoom set on the object. The value 2
</ul>
## Padding
Properties to describe spacing betwwen the parent's sides and the children and among the children. Very similar to the padding properties in HTML.
Properties to describe spacing between the parent's sides and the children and among the children. Very similar to the padding properties in HTML.
### pad_top
Sets the padding on the top. It makes the content area smaller in this direction.
@@ -307,7 +307,7 @@ Set the intensity of background image recoloring. Value 0, `LV_OPA_0` or `LV_OPA
</ul>
### bg_img_tiled
If enbaled the background image will be tiled. The possible values are `true` or `false`.
If enabled the background image will be tiled. The possible values are `true` or `false`.
<ul>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Default</strong> 0</li>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Inherited</strong> No</li>
@@ -328,7 +328,7 @@ Set the color of the border
</ul>
### border_opa
Set the opcitiy of the border. Value 0, `LV_OPA_0` or `LV_OPA_TRANSP` means fully transparent, 256, `LV_OPA_100` or `LV_OPA_COVER` means fully covering, other values or LV_OPA_10, LV_OPA_20, etc means semi transparency.
Set the opacity of the border. Value 0, `LV_OPA_0` or `LV_OPA_TRANSP` means fully transparent, 256, `LV_OPA_100` or `LV_OPA_COVER` means fully covering, other values or LV_OPA_10, LV_OPA_20, etc means semi transparency.
<ul>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Default</strong> `LV_OPA_COVER`</li>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Inherited</strong> No</li>
@@ -346,7 +346,7 @@ Set hte width of the border. Only pixel values can be used.
</ul>
### border_side
Set ony which side(s) the border should be drawn. The possible values are `LV_BORDER_SIDE_NONE/TOP/BOTTOM/LEFT/RIGHT/INTERNAL`. OR-ed calues an be used as well, e.g. `LV_BORDER_SIDE_TOP | LV_BORDER_SIDE_LEFT`.
Set ony which side(s) the border should be drawn. The possible values are `LV_BORDER_SIDE_NONE/TOP/BOTTOM/LEFT/RIGHT/INTERNAL`. OR-ed values can be used as well, e.g. `LV_BORDER_SIDE_TOP | LV_BORDER_SIDE_LEFT`.
<ul>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Default</strong> `LV_BORDER_SIDE_NONE`</li>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Inherited</strong> No</li>
@@ -355,7 +355,7 @@ Set ony which side(s) the border should be drawn. The possible values are `LV_BO
</ul>
### border_post
Sets whether the the border should be drawn before or after the children ar drawn. `true`: after children, `false`: before children
Sets whether the border should be drawn before or after the children are drawn. `true`: after children, `false`: before children
<ul>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Default</strong> 0</li>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Inherited</strong> No</li>
@@ -364,7 +364,7 @@ Sets whether the the border should be drawn before or after the children ar draw
</ul>
## Outline
Properties to describe the outline. It's like a border but drawn outside of the rectangles.
Properties to describe the outline. It's like a border but drawn outside the rectangles.
### outline_width
Set the width of the outline in pixels.
@@ -433,7 +433,7 @@ Set an offset on the shadow in pixels in Y direction.
</ul>
### shadow_spread
Make the shadow calcuation to use a larger or smaller rectangle as base. The value can be in pixel to make the area larger/smaller
Make the shadow calculation to use a larger or smaller rectangle as base. The value can be in pixel to make the area larger/smaller
<ul>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Default</strong> 0</li>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Inherited</strong> No</li>
@@ -550,7 +550,7 @@ Set the opacity of the lines.
TODO
### arc_width
Set the width (ticjkness) of the arcs in pixel.
Set the width (thickness) of the arcs in pixel.
<ul>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Default</strong> 0</li>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Inherited</strong> No</li>
@@ -595,7 +595,7 @@ Set an image from which the arc will be masked out. It's useful to display compl
</ul>
## Text
Properties to describe the propeties of text. All these properties are inherited.
Properties to describe the properties of text. All these properties are inherited.
### text_color
Sets the color of the text.
@@ -661,7 +661,7 @@ Set how to align the lines of the text. Note that it doesn't align the object it
</ul>
## Miscellaneous
Mixed proprites for various purposes.
Mixed properties for various purposes.
### radius
Set the radius on every corner. The value is interpreted in pixel (>= 0) or `LV_RADIUS_CIRCLE` for max. radius
@@ -709,7 +709,7 @@ The intensity of mixing of color filter.
</ul>
### anim_time
The animation time in milliseconds. It's meaning is widget specific. E.g. blink time of the cursor on the text area or scroll time of a roller. See the widgets' documentation to learn more.
The animation time in milliseconds. Its meaning is widget specific. E.g. blink time of the cursor on the text area or scroll time of a roller. See the widgets' documentation to learn more.
<ul>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Default</strong> 0</li>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Inherited</strong> No</li>
@@ -718,7 +718,7 @@ The animation time in milliseconds. It's meaning is widget specific. E.g. blink
</ul>
### anim_speed
The animation speed in pixel/sec. It's meaning is widget specific. E.g. scroll speed of label. See the widgets' documentation to learn more.
The animation speed in pixel/sec. Its meaning is widget specific. E.g. scroll speed of label. See the widgets' documentation to learn more.
<ul>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Default</strong> 0</li>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Inherited</strong> No</li>
@@ -736,7 +736,7 @@ An initialized `lv_style_transition_dsc_t` to describe a transition.
</ul>
### blend_mode
Describes how to blend the colors to the background. The possibel values are `LV_BLEND_MODE_NORMAL/ADDITIVE/SUBTRACTIVE/MULTIPLY`
Describes how to blend the colors to the background. The possible values are `LV_BLEND_MODE_NORMAL/ADDITIVE/SUBTRACTIVE/MULTIPLY`
<ul>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Default</strong> `LV_BLEND_MODE_NORMAL`</li>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Inherited</strong> No</li>
@@ -754,7 +754,7 @@ Set the layout if the object. The children will be repositioned and resized acco
</ul>
### base_dir
Set the base direction of the obejct. The possible values are `LV_BIDI_DIR_LTR/RTL/AUTO`.
Set the base direction of the object. The possible values are `LV_BIDI_DIR_LTR/RTL/AUTO`.
<ul>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Default</strong> `LV_BASE_DIR_AUTO`</li>
<li style='display:inline; margin-right: 20px; margin-left: 0px'><strong>Inherited</strong> Yes</li>

View File

@@ -68,7 +68,7 @@ For example, finding background colors for released, pressed, checked + pressed,
Instead, for example, use the background color for pressed and checked states and indicate the focused state with a different border color.
## Cascading styles
It's not required to set all the properties in one style. It's possible to add more styles to an object and have the later added style modify or extend appearance.
It's not required to set all the properties in one style. It's possible to add more styles to an object and have the latter added style modify or extend appearance.
For example, create a general gray button style and create a new one for red buttons where only the new background color is set.
This is much like in CSS when used classes are listed like `<div class=".btn .btn-red">`.