lv_obj_get_x2() function
Get the x2 coordinate of object.
Return value
distance of `obj` from the right side of its parent plus the parent's right padding
Notes
The position of the object is recalculated only on the next redraw. To force coordinate recalculation call `lv_obj_update_layout(obj)`. Zero return value means the object is on the right padding of the parent, and not on the right edge. Scrolling of the parent doesn't change the returned value. The returned value is always the distance from the parent even if `obj` is positioned by a layout.