change default text align and fix scroll drawing
This commit is contained in:
@@ -24,7 +24,8 @@ impl Widget for Scroll {
|
||||
self.amt = self.content_len - self.container_len;
|
||||
}
|
||||
self.update_amt();
|
||||
let region = UiRegion::FULL.offset(Vec2::from_axis(self.axis, -self.amt, 0.0));
|
||||
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