mirror of
https://github.com/FliegendeWurst/cursive.git
synced 2024-11-23 17:35:00 +00:00
Rustfmt
This commit is contained in:
parent
a22c92a1a1
commit
5b25893496
@ -173,7 +173,8 @@ impl Printer {
|
||||
}
|
||||
|
||||
/// Returns a printer on a subset of this one's area.
|
||||
pub fn sub_printer<S: Into<Vec2>, T: Into<Vec2>>(&self, offset: S, size: T, focused: bool)
|
||||
pub fn sub_printer<S: Into<Vec2>, T: Into<Vec2>>(&self, offset: S,
|
||||
size: T, focused: bool)
|
||||
-> Printer {
|
||||
let offset = offset.into().or_min(self.size);
|
||||
Printer {
|
||||
|
@ -80,7 +80,10 @@ impl EditView {
|
||||
|
||||
impl View for EditView {
|
||||
fn draw(&self, printer: &Printer) {
|
||||
assert!(printer.size.x == self.last_length, "Was promised {}, received {}", self.last_length, printer.size.x);
|
||||
assert!(printer.size.x == self.last_length,
|
||||
"Was promised {}, received {}",
|
||||
self.last_length,
|
||||
printer.size.x);
|
||||
|
||||
let width = self.content.width();
|
||||
printer.with_color(ColorStyle::Secondary, |printer| {
|
||||
|
@ -8,4 +8,4 @@ pub trait With: Sized {
|
||||
}
|
||||
}
|
||||
|
||||
impl <T: Sized> With for T {}
|
||||
impl<T: Sized> With for T {}
|
||||
|
Loading…
Reference in New Issue
Block a user