store size in tex instead of bot_right
This commit is contained in:
@@ -20,10 +20,12 @@ impl Widget for Scroll {
|
||||
.to_abs(output_len);
|
||||
self.container_len = container_len.to_abs(output_len);
|
||||
self.content_len = content_len;
|
||||
|
||||
if self.snap_end {
|
||||
self.amt = self.content_len - self.container_len;
|
||||
}
|
||||
self.update_amt();
|
||||
|
||||
let mut region = UiRegion::FULL.offset(Vec2::from_axis(self.axis, -self.amt, 0.0));
|
||||
region.axis_mut(self.axis).end = region.axis(self.axis).start.offset(self.content_len);
|
||||
painter.widget_within(&self.inner, region);
|
||||
|
||||
Reference in New Issue
Block a user