Description
I am trying to reset an arcs style. Specifically line size, rounded and color.
Every option ends up with the same output
Example:
Before reset
After:
What MCU/Processor/Board and compiler are you using?
PC Emulator
What do you want to achieve?
Reset the parameters based on new ones
What have you tried so far?
Here is the relevant code:
lv_style_t newStyle;
lv_style_copy(&newStyle, &lv_style_plain);
int lineWidth = std::atoi(lv_ta_get_text(odata.pw->arcLineWidth));
newStyle.line.width = lineWidth;
color.ch.alpha = 255;
newStyle.line.color = color;
if (lv_cb_is_checked(odata.pw->arcLineRound))
newStyle.line.rounded = true;
else
newStyle.line.rounded = false;
lv_arc_set_style(odata.pw->selectedObject, LV_ARC_STYLE_MAIN, &newStyle);
odata includes a pointer to the class, selectedObject is the arc I am trying to resize.
Code to reproduce
See above.
I am clearly doing this wrong.
Screenshot and/or video
If possible, add screenshots and/or videos about the current state.