format and add fmt config

This commit is contained in:
LordMZTE 2021-09-24 20:21:32 +02:00
parent 227bba597a
commit d9216db411
2 changed files with 19 additions and 9 deletions

12
rustfmt.toml Normal file
View File

@ -0,0 +1,12 @@
unstable_features = true
binop_separator = "Back"
format_code_in_doc_comments = true
format_macro_matchers = true
format_strings = true
imports_layout = "HorizontalVertical"
match_block_trailing_comma = true
merge_imports = true
normalize_comments = true
use_field_init_shorthand = true
use_try_shorthand = true
wrap_comments = true

View File

@ -1,11 +1,9 @@
use gtk::prelude::FrameExt;
use gtk::prelude::OrientableExt;
use gtk::prelude::TextBufferExt;
use gtk::prelude::TextViewExt;
use gtk::prelude::WidgetExt;
use gtk::{Inhibit, Orientation};
use relm::Widget;
use relm::{connect, Relm};
use gtk::{
prelude::{FrameExt, OrientableExt, TextBufferExt, TextViewExt, WidgetExt},
Inhibit,
Orientation,
};
use relm::{connect, Relm, Widget};
use relm_derive::{widget, Msg};
fn main() {
@ -68,7 +66,7 @@ impl Widget for Win {
}
}
}
}
},
}
}