BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lvgl
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
lvgl
Commits
cf3b94d2
Commit
cf3b94d2
authored
Jun 27, 2017
by
Gabor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lv_list: lv_list_set_element_text_roll() added
parent
678e119d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
0 deletions
+26
-0
lv_list.c
lv_objx/lv_list.c
+19
-0
lv_list.h
lv_objx/lv_list.h
+7
-0
No files found.
lv_objx/lv_list.c
View file @
cf3b94d2
...
...
@@ -230,6 +230,25 @@ void lv_list_set_sb_out(lv_obj_t * list, bool out)
}
/**
* Enable or disable the text rolling on a list element
* @param liste pinter to list element
* @param en true: enable text scrolling, false: disable text scrolling
*/
void
lv_list_set_element_text_roll
(
lv_obj_t
*
liste
,
bool
en
)
{
/*The last child is the label*/
lv_obj_t
*
label
=
lv_obj_get_child
(
liste
,
NULL
);
if
(
en
==
false
)
{
lv_label_set_long_mode
(
label
,
LV_LABEL_LONG_DOTS
);
}
else
{
lv_obj_set_width
(
label
,
liste
->
cords
.
x2
-
label
->
cords
.
x1
);
lv_label_set_long_mode
(
label
,
LV_LABEL_LONG_ROLL
);
}
}
/**
* Set styles of the list elements of a list in each state
* @param list pointer to list object
* @param rel pointer to a style for releases state
...
...
lv_objx/lv_list.h
View file @
cf3b94d2
...
...
@@ -104,6 +104,13 @@ void lv_list_down(lv_obj_t * list);
void
lv_list_set_sb_out
(
lv_obj_t
*
list
,
bool
out
);
/**
* Enable or disable the text rolling on a list element
* @param liste pinter to list element
* @param en true: enable text scrolling, false: disable text scrolling
*/
void
lv_list_set_element_text_roll
(
lv_obj_t
*
liste
,
bool
en
);
/**
* Set styles of the list elements of a list in each state
* @param list pointer to list object
* @param rel pointer to a style for releases state
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment