lv_scale_private.h

API reference for lv_scale_private.h

Report on GitHub
See Also: Public APIThis is the private implementation. See the public header for the stable interface.lv_scale.h
Summary

Structs

struct

_lv_scale_section_t

MemberTypeDescription
main_styleconst lv_style_t *Style to use for MAIN part(s) of scale when it falls within this section's range
indicator_styleconst lv_style_t *Style to use for INDICATOR part(s) of scale when it falls within this section's range
items_styleconst lv_style_t *Style to use for ITEMS part(s) of scale when it falls within this section's range
range_minint32_tScale parts with value >= this value will be drawn using applicable style.
range_maxint32_tScale parts with value <= this value will be drawn using applicable style.
first_tick_idx_in_sectionuint32_tInternal (set during drawing): Tick index of first tick that falls within this section; LV_SCALE_TICK_IDX_DEFAULT_ID if section contains no ticks.
last_tick_idx_in_sectionuint32_tInternal (set during drawing): Tick index of last tick that falls within this section; LV_SCALE_TICK_IDX_DEFAULT_ID if section contains no ticks.
first_tick_in_section_widthint32_tInternal (set during drawing)
last_tick_in_section_widthint32_tInternal (set during drawing)
first_tick_in_sectionlv_point_tInternal (set during drawing)
last_tick_in_sectionlv_point_tInternal (set during drawing)
first_tick_idx_is_majoruint32_tInternal (set during drawing): true if first_tick_idx_in_section represents a major tick.
last_tick_idx_is_majoruint32_tInternal (set during drawing): true if last_tick_idx_in_section represents a major tick.
struct

lv_scale_needle_t

MemberTypeDescription
objlv_obj_t *
valueint32_t
lengthint32_t
struct

_lv_scale_t

MemberTypeDescription
objlv_obj_tBase Widget part of Scale
section_lllv_ll_tLinked list for the sections (stores lv_scale_section_t)
txt_srcconst char **Optional list of text strings for major ticks when custom labels are provided.
modelv_scale_mode_tOrientation and layout of scale.
range_minint32_tScale's minimum value
range_maxint32_tScale's maximum value
total_tick_countuint32_tTotal number of ticks (major and minor)
major_tick_everyuint32_tFrequency of major ticks to minor ticks
label_enableduint32_tDraw labels for major ticks?
post_drawuint32_tfalse: drawing occurs during LV_EVENT_DRAW_MAIN; true : drawing occurs during LV_EVENT_DRAW_POST.
draw_ticks_on_topuint32_tDraw ticks on top of main line?
angle_rangeuint32_tDegrees between low end and high end of scale
rotationint32_tClockwise angular offset from 3-o'clock position of low end of scale
custom_label_cntint32_tNumber of custom labels provided in txt_src
last_tick_widthint32_tWidth of last tick in pixels
first_tick_widthint32_tWidth of first tick in pixels
needleslv_array_tNeedle list of this scale

Dependencies

How is this guide?

Last updated on

On this page