I love control flow
This commit is contained in:
@@ -26,7 +26,6 @@ impl TextEdit {
|
||||
.lines
|
||||
.iter()
|
||||
.map(|l| l.text())
|
||||
// why is this needed?? what??
|
||||
.collect::<Vec<_>>()
|
||||
.join("\n")
|
||||
}
|
||||
@@ -44,9 +43,7 @@ impl Widget for TextEdit {
|
||||
let size = vec2(1, self.attrs.line_height);
|
||||
painter.primitive_within(
|
||||
RectPrimitive::color(Color::WHITE),
|
||||
size.align(Align::TOP_LEFT)
|
||||
.offset(offset)
|
||||
.within(®ion),
|
||||
size.align(Align::TOP_LEFT).offset(offset).within(®ion),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user