Make dialog look good
This commit is contained in:
parent
a7db35e8ac
commit
0e34138a6a
@ -48,41 +48,60 @@ impl AsyncComponent for SheetEditDialogModel {
|
||||
set_visible: !model.hidden,
|
||||
set_modal: true,
|
||||
set_title: Some("Edit sheet"),
|
||||
set_default_width: 10,
|
||||
set_default_height: 10,
|
||||
gtk::Box {
|
||||
set_orientation: gtk::Orientation::Vertical,
|
||||
set_margin_all : 5,
|
||||
gtk::Label {
|
||||
set_text: "Sheet name"
|
||||
set_margin_all : 15,
|
||||
set_spacing: 5,
|
||||
gtk::Box {
|
||||
set_spacing: 10,
|
||||
gtk::Label {
|
||||
set_text: "Sheet name"
|
||||
},
|
||||
gtk::Entry {
|
||||
#[watch]
|
||||
set_text: &model.sheet_name,
|
||||
set_width_chars: 40,
|
||||
},
|
||||
},
|
||||
gtk::Entry {
|
||||
#[watch]
|
||||
set_text: &model.sheet_name,
|
||||
gtk::Box {
|
||||
set_spacing: 10,
|
||||
gtk::Label {
|
||||
set_text: "Sheet composer"
|
||||
},
|
||||
gtk::Entry {
|
||||
#[watch]
|
||||
set_text : &model.sheet_composer,
|
||||
set_hexpand: true,
|
||||
},
|
||||
},
|
||||
gtk::Label {
|
||||
set_text: "Sheet composer"
|
||||
},
|
||||
gtk::Entry {
|
||||
#[watch]
|
||||
set_text : &model.sheet_composer,
|
||||
},
|
||||
gtk::Label {
|
||||
set_text: "Book"
|
||||
},
|
||||
gtk::CheckButton {
|
||||
#[watch]
|
||||
set_active: model.is_book,
|
||||
gtk::Box {
|
||||
set_spacing: 10,
|
||||
gtk::Label {
|
||||
set_text: "Book"
|
||||
},
|
||||
gtk::CheckButton {
|
||||
#[watch]
|
||||
set_active: model.is_book,
|
||||
},
|
||||
},
|
||||
gtk::Box {
|
||||
set_orientation: gtk::Orientation::Horizontal,
|
||||
set_margin_top:5,
|
||||
set_margin_top: 10,
|
||||
set_spacing: 10,
|
||||
set_homogeneous: true,
|
||||
set_halign: gtk::Align::Center,
|
||||
set_hexpand: true,
|
||||
|
||||
gtk::Button {
|
||||
set_label: "Cancel",
|
||||
connect_clicked[sender] => move |_| sender.input(SheetEditDialogInput::Cancel)
|
||||
},
|
||||
gtk::Button {
|
||||
set_label : "Confirm",
|
||||
connect_clicked[sender] => move |_| sender.input(SheetEditDialogInput::Accept)
|
||||
},
|
||||
gtk::Button {
|
||||
set_label: "Cancel",
|
||||
connect_clicked[sender] => move |_| sender.input(SheetEditDialogInput::Cancel)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user