Major comit before connecting graph
This commit is contained in:
parent
f37cbb7096
commit
fab65c66e5
89
src/lib.rs
89
src/lib.rs
|
|
@ -39,14 +39,16 @@ pub fn build_ui(app: >k::Application, config: Arc::<Mutex::<Config>>) {
|
||||||
let win = builder.get_object::<gtk::ApplicationWindow>("win").expect("Resource file missing!");
|
let win = builder.get_object::<gtk::ApplicationWindow>("win").expect("Resource file missing!");
|
||||||
win.set_application(Some(app));
|
win.set_application(Some(app));
|
||||||
let bar = builder.get_object::<gtk::Statusbar>("status_bar").expect("Resource file missing!");
|
let bar = builder.get_object::<gtk::Statusbar>("status_bar").expect("Resource file missing!");
|
||||||
|
let log_area = builder.get_object::<gtk::TextView>("log_area").expect("Resource file missing!");
|
||||||
|
|
||||||
let _ = Graph::new(
|
let _ = Graph::new(
|
||||||
builder.get_object::<gtk::DrawingArea>("draw_area").expect("Resource file missing!"),
|
builder.get_object::<gtk::DrawingArea>("draw_area").expect("Resource file missing!"),
|
||||||
0.0, 30.0,
|
0.0, 100.0,
|
||||||
0.0, 50.0,
|
0.0, 100.0,
|
||||||
vec![
|
vec![
|
||||||
// Line::new(1.0,1.0,1.0,vec![(10.0,10.0),(20.0,20.0)]),
|
Line::new(1.0,1.0,1.0,vec![(10.0,10.0),(20.0,20.0)]),
|
||||||
// Line::new(1.0,0.0,1.0,vec![(15.0,15.0),(50.0,25.0)])
|
Line::new(1.0,0.0,1.0,vec![(15.0,15.0),(50.0,25.0)]),
|
||||||
|
Line::new(1.0,0.0,0.0,vec![(50.0,10.0),(70.0,60.0)])
|
||||||
]
|
]
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
@ -105,25 +107,16 @@ pub fn build_ui(app: >k::Application, config: Arc::<Mutex::<Config>>) {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
//jagrit_btn
|
//jagrit_btn
|
||||||
let jagrit_btn = builder.get_object::<gtk::RadioToolButton>("jagrit_btn").expect("Resource file missing!");
|
let jagrit_btn = builder.get_object::<gtk::ToolButton>("jagrit_btn").expect("Resource file missing!");
|
||||||
|
|
||||||
let tmp_bar = bar.clone();
|
let tmp_bar = bar.clone();
|
||||||
let tmp_config = Arc::clone(&config);
|
let tmp_config = Arc::clone(&config);
|
||||||
jagrit_btn.connect_clicked(move |btn | {
|
jagrit_btn.connect_clicked(move |_ | {
|
||||||
println!("In jagrit_btn!");
|
|
||||||
match tmp_config.lock() {
|
match tmp_config.lock() {
|
||||||
Ok(mut config) => {
|
Ok(mut config) => {
|
||||||
if btn.get_active() {
|
|
||||||
tmp_bar.push(1, "Jagrit");
|
tmp_bar.push(1, "Jagrit");
|
||||||
btn.set_icon_name(Some("media-playback-pause"));
|
|
||||||
config.status = Status::PARIVARTIT;
|
config.status = Status::PARIVARTIT;
|
||||||
} else {
|
|
||||||
tmp_bar.push(1, "Sayan");
|
|
||||||
btn.set_icon_name(Some("media-playback-start"));
|
|
||||||
config.status = Status::SAYAN;
|
|
||||||
}
|
|
||||||
}, Err(_) => {
|
}, Err(_) => {
|
||||||
tmp_bar.push(1, "Failed to change port!");
|
tmp_bar.push(1, "Failed to change port!");
|
||||||
}
|
}
|
||||||
|
|
@ -135,14 +128,10 @@ pub fn build_ui(app: >k::Application, config: Arc::<Mutex::<Config>>) {
|
||||||
|
|
||||||
let tmp_bar = bar.clone();
|
let tmp_bar = bar.clone();
|
||||||
let tmp_config = Arc::clone(&config);
|
let tmp_config = Arc::clone(&config);
|
||||||
avrodith_btn.connect_clicked(move |btn| {
|
avrodith_btn.connect_clicked(move |_| {
|
||||||
match tmp_config.lock() {
|
match tmp_config.lock() {
|
||||||
Ok(mut config) => {
|
Ok(mut config) => {
|
||||||
tmp_bar.push(1, "Avrodhit");
|
tmp_bar.push(1, "Avrodhit");
|
||||||
println!("Before");
|
|
||||||
jagrit_btn.set_active(false);
|
|
||||||
println!("After!");
|
|
||||||
jagrit_btn.set_icon_name(Some("media-playback-start"));
|
|
||||||
config.status = Status::AVRODTIH;
|
config.status = Status::AVRODTIH;
|
||||||
}, Err(_) => {
|
}, Err(_) => {
|
||||||
tmp_bar.push(1, "Failed to change port!");
|
tmp_bar.push(1, "Failed to change port!");
|
||||||
|
|
@ -150,6 +139,32 @@ pub fn build_ui(app: >k::Application, config: Arc::<Mutex::<Config>>) {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
//clear_log
|
||||||
|
let clear_log = builder.get_object::<gtk::ToolButton>("clear_log").expect("Resource file missing!");
|
||||||
|
|
||||||
|
let tmp_log_area = log_area.clone();
|
||||||
|
clear_log.connect_clicked(move |_| {
|
||||||
|
tmp_log_area.get_buffer().expect("Couldn't get window").set_text("");
|
||||||
|
});
|
||||||
|
|
||||||
|
// send_entry
|
||||||
|
let send_entry = builder.get_object::<gtk::Entry>("send_entry").expect("Resource file missing!");
|
||||||
|
|
||||||
|
let tmp_bar = bar.clone();
|
||||||
|
let tmp_config = Arc::clone(&config);
|
||||||
|
send_entry.connect_activate(move |ent| {
|
||||||
|
send_text(&tmp_config, ent, &tmp_bar);
|
||||||
|
});
|
||||||
|
|
||||||
|
//send_btn
|
||||||
|
let send_btn = builder.get_object::<gtk::Button>("send_btn").expect("Resource file missing!");
|
||||||
|
|
||||||
|
let tmp_bar = bar.clone();
|
||||||
|
let tmp_config = Arc::clone(&config);
|
||||||
|
send_btn.connect_activate(move |_| {
|
||||||
|
send_text(&tmp_config, &send_entry, &tmp_bar);
|
||||||
|
});
|
||||||
|
|
||||||
// serial
|
// serial
|
||||||
let (sender, receiver) = glib::MainContext::channel(glib::PRIORITY_DEFAULT);
|
let (sender, receiver) = glib::MainContext::channel(glib::PRIORITY_DEFAULT);
|
||||||
|
|
||||||
|
|
@ -162,10 +177,8 @@ pub fn build_ui(app: >k::Application, config: Arc::<Mutex::<Config>>) {
|
||||||
Ok(mut config) => {
|
Ok(mut config) => {
|
||||||
match config.status {
|
match config.status {
|
||||||
Status::AVRODTIH => {
|
Status::AVRODTIH => {
|
||||||
if let Some(_) = bufread {
|
|
||||||
bufread = None;
|
bufread = None;
|
||||||
println!("Avrohit!");
|
config.status = Status::SAYAN;
|
||||||
}
|
|
||||||
},
|
},
|
||||||
Status::JAGRIT => {
|
Status::JAGRIT => {
|
||||||
if let Some(read) = &mut bufread {
|
if let Some(read) = &mut bufread {
|
||||||
|
|
@ -198,14 +211,18 @@ pub fn build_ui(app: >k::Application, config: Arc::<Mutex::<Config>>) {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
let full_log = builder.get_object::<gtk::CheckButton>("full_log").expect("Resource file missing!");
|
||||||
let log_area = builder.get_object::<gtk::TextView>("log_area").expect("Resource file missing!");
|
|
||||||
receiver.attach(None, move |msg| {
|
receiver.attach(None, move |msg| {
|
||||||
match msg {
|
match msg {
|
||||||
Message::Msg(text) => {
|
Message::Msg(text) => {
|
||||||
|
if !full_log.get_active() && text.starts_with("#") {
|
||||||
|
|
||||||
|
} else {
|
||||||
let buf = log_area.get_buffer()
|
let buf = log_area.get_buffer()
|
||||||
.expect("Couldn't get window");
|
.expect("Couldn't get log_area");
|
||||||
buf.insert(&mut buf.get_end_iter(), &text);
|
buf.insert(&mut buf.get_end_iter(), &text);
|
||||||
|
log_area.scroll_to_iter(&mut buf.get_end_iter(), 0.4, true, 0.0, 0.0);
|
||||||
|
}
|
||||||
},
|
},
|
||||||
Message::Status(text) => {
|
Message::Status(text) => {
|
||||||
bar.push(1, &text);
|
bar.push(1, &text);
|
||||||
|
|
@ -215,3 +232,23 @@ pub fn build_ui(app: >k::Application, config: Arc::<Mutex::<Config>>) {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fn send_text(config: &Arc<Mutex<Config>>, entry: >k::Entry, bar: >k::Statusbar) {
|
||||||
|
match config.lock() {
|
||||||
|
Ok(config) => {
|
||||||
|
let mut p = match serialport::new(&config.port, config.bondrate).open() {
|
||||||
|
Ok(p) => p,
|
||||||
|
Err(_) => {
|
||||||
|
bar.push(1, "Failed to change port!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
unsafe {
|
||||||
|
p.write_all(entry.get_text().to_string().as_bytes_mut()).unwrap();
|
||||||
|
}
|
||||||
|
entry.set_text("");
|
||||||
|
}, Err(_) => {
|
||||||
|
bar.push(1, "Failed to change port!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -7,9 +7,12 @@ fn start() {
|
||||||
let ports = serialport::available_ports();
|
let ports = serialport::available_ports();
|
||||||
println!("{:?}",ports);
|
println!("{:?}",ports);
|
||||||
|
|
||||||
let p = serialport::new("/dev/ttyUSB0", 9600).timeout(Duration::from_millis(10))
|
let mut p = serialport::new("/dev/ttyUSB1", 9600).timeout(Duration::from_millis(10))
|
||||||
.open().expect("Failed to open port");
|
.open().expect("Failed to open port");
|
||||||
|
|
||||||
|
unsafe {
|
||||||
|
p.write_all("buf".to_owned().as_bytes_mut()).unwrap();
|
||||||
|
}
|
||||||
let mut read = BufReader::new(p);
|
let mut read = BufReader::new(p);
|
||||||
let mut buf = String::new();
|
let mut buf = String::new();
|
||||||
loop {
|
loop {
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,16 @@
|
||||||
<!-- Generated with glade 3.38.2 -->
|
<!-- Generated with glade 3.38.2 -->
|
||||||
<interface>
|
<interface>
|
||||||
<requires lib="gtk+" version="3.22"/>
|
<requires lib="gtk+" version="3.22"/>
|
||||||
|
<object class="GtkImage" id="image1">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">False</property>
|
||||||
|
<property name="icon-name">document-save</property>
|
||||||
|
</object>
|
||||||
|
<object class="GtkImage" id="send_image">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">False</property>
|
||||||
|
<property name="icon-name">go-next</property>
|
||||||
|
</object>
|
||||||
<object class="GtkApplicationWindow" id="win">
|
<object class="GtkApplicationWindow" id="win">
|
||||||
<property name="can-focus">False</property>
|
<property name="can-focus">False</property>
|
||||||
<property name="title" translatable="yes">Trangam</property>
|
<property name="title" translatable="yes">Trangam</property>
|
||||||
|
|
@ -28,38 +38,11 @@
|
||||||
<property name="can-focus">False</property>
|
<property name="can-focus">False</property>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkImageMenuItem">
|
<object class="GtkImageMenuItem">
|
||||||
<property name="label">gtk-new</property>
|
<property name="label">Save Log</property>
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="can-focus">False</property>
|
<property name="can-focus">False</property>
|
||||||
<property name="use-underline">True</property>
|
<property name="image">image1</property>
|
||||||
<property name="use-stock">True</property>
|
<property name="use-stock">False</property>
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
|
||||||
<object class="GtkImageMenuItem">
|
|
||||||
<property name="label">gtk-open</property>
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<property name="use-stock">True</property>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
|
||||||
<object class="GtkImageMenuItem">
|
|
||||||
<property name="label">gtk-save</property>
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<property name="use-stock">True</property>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
|
||||||
<object class="GtkImageMenuItem">
|
|
||||||
<property name="label">gtk-save-as</property>
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<property name="use-stock">True</property>
|
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
|
|
@ -81,64 +64,6 @@
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
|
||||||
<object class="GtkMenuItem">
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="label" translatable="yes">_Edit</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<child type="submenu">
|
|
||||||
<object class="GtkMenu">
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<child>
|
|
||||||
<object class="GtkImageMenuItem">
|
|
||||||
<property name="label">gtk-cut</property>
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<property name="use-stock">True</property>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
|
||||||
<object class="GtkImageMenuItem">
|
|
||||||
<property name="label">gtk-copy</property>
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<property name="use-stock">True</property>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
|
||||||
<object class="GtkImageMenuItem">
|
|
||||||
<property name="label">gtk-paste</property>
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<property name="use-stock">True</property>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
|
||||||
<object class="GtkImageMenuItem">
|
|
||||||
<property name="label">gtk-delete</property>
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<property name="use-stock">True</property>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
|
||||||
<object class="GtkMenuItem">
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="label" translatable="yes">_View</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkMenuItem">
|
<object class="GtkMenuItem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
|
|
@ -223,13 +148,12 @@
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkRadioToolButton" id="jagrit_btn">
|
<object class="GtkToolButton" id="jagrit_btn">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="can-focus">False</property>
|
<property name="can-focus">False</property>
|
||||||
<property name="label" translatable="yes">Connect</property>
|
<property name="label" translatable="yes">Connect</property>
|
||||||
<property name="use-underline">True</property>
|
<property name="use-underline">True</property>
|
||||||
<property name="icon-name">media-playback-start</property>
|
<property name="icon-name">media-playback-start</property>
|
||||||
<property name="active">True</property>
|
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
|
|
@ -274,6 +198,53 @@
|
||||||
<property name="shrink">True</property>
|
<property name="shrink">True</property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkBox">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">False</property>
|
||||||
|
<property name="orientation">vertical</property>
|
||||||
|
<child>
|
||||||
|
<object class="GtkToolbar">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">False</property>
|
||||||
|
<child>
|
||||||
|
<object class="GtkToolButton" id="clear_log">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">False</property>
|
||||||
|
<property name="label" translatable="yes">Clear</property>
|
||||||
|
<property name="use-underline">True</property>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="homogeneous">True</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkToolItem">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">False</property>
|
||||||
|
<child>
|
||||||
|
<object class="GtkCheckButton" id="full_log">
|
||||||
|
<property name="label" translatable="yes">Show full log</property>
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">True</property>
|
||||||
|
<property name="receives-default">False</property>
|
||||||
|
<property name="draw-indicator">True</property>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="homogeneous">True</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="position">0</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkScrolledWindow">
|
<object class="GtkScrolledWindow">
|
||||||
<property name="width-request">300</property>
|
<property name="width-request">300</property>
|
||||||
|
|
@ -290,6 +261,49 @@
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="position">1</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkBox">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">False</property>
|
||||||
|
<child>
|
||||||
|
<object class="GtkEntry" id="send_entry">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">True</property>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">True</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="position">0</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkButton" id="send_btn">
|
||||||
|
<property name="label" translatable="yes">Send</property>
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">True</property>
|
||||||
|
<property name="receives-default">True</property>
|
||||||
|
<property name="image">send_image</property>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="position">1</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="position">2</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="resize">True</property>
|
<property name="resize">True</property>
|
||||||
<property name="shrink">True</property>
|
<property name="shrink">True</property>
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,16 @@
|
||||||
<!-- Generated with glade 3.38.2 -->
|
<!-- Generated with glade 3.38.2 -->
|
||||||
<interface>
|
<interface>
|
||||||
<requires lib="gtk+" version="3.22"/>
|
<requires lib="gtk+" version="3.22"/>
|
||||||
|
<object class="GtkImage" id="image1">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">False</property>
|
||||||
|
<property name="icon-name">document-save</property>
|
||||||
|
</object>
|
||||||
|
<object class="GtkImage" id="send_image">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">False</property>
|
||||||
|
<property name="icon-name">go-next</property>
|
||||||
|
</object>
|
||||||
<object class="GtkApplicationWindow" id="win">
|
<object class="GtkApplicationWindow" id="win">
|
||||||
<property name="can-focus">False</property>
|
<property name="can-focus">False</property>
|
||||||
<property name="title" translatable="yes">Trangam</property>
|
<property name="title" translatable="yes">Trangam</property>
|
||||||
|
|
@ -28,38 +38,11 @@
|
||||||
<property name="can-focus">False</property>
|
<property name="can-focus">False</property>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkImageMenuItem">
|
<object class="GtkImageMenuItem">
|
||||||
<property name="label">gtk-new</property>
|
<property name="label">Save Log</property>
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="can-focus">False</property>
|
<property name="can-focus">False</property>
|
||||||
<property name="use-underline">True</property>
|
<property name="image">image1</property>
|
||||||
<property name="use-stock">True</property>
|
<property name="use-stock">False</property>
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
|
||||||
<object class="GtkImageMenuItem">
|
|
||||||
<property name="label">gtk-open</property>
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<property name="use-stock">True</property>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
|
||||||
<object class="GtkImageMenuItem">
|
|
||||||
<property name="label">gtk-save</property>
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<property name="use-stock">True</property>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
|
||||||
<object class="GtkImageMenuItem">
|
|
||||||
<property name="label">gtk-save-as</property>
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<property name="use-stock">True</property>
|
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
|
|
@ -81,64 +64,6 @@
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
|
||||||
<object class="GtkMenuItem">
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="label" translatable="yes">_Edit</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<child type="submenu">
|
|
||||||
<object class="GtkMenu">
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<child>
|
|
||||||
<object class="GtkImageMenuItem">
|
|
||||||
<property name="label">gtk-cut</property>
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<property name="use-stock">True</property>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
|
||||||
<object class="GtkImageMenuItem">
|
|
||||||
<property name="label">gtk-copy</property>
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<property name="use-stock">True</property>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
|
||||||
<object class="GtkImageMenuItem">
|
|
||||||
<property name="label">gtk-paste</property>
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<property name="use-stock">True</property>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
|
||||||
<object class="GtkImageMenuItem">
|
|
||||||
<property name="label">gtk-delete</property>
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
<property name="use-stock">True</property>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
|
||||||
<object class="GtkMenuItem">
|
|
||||||
<property name="visible">True</property>
|
|
||||||
<property name="can-focus">False</property>
|
|
||||||
<property name="label" translatable="yes">_View</property>
|
|
||||||
<property name="use-underline">True</property>
|
|
||||||
</object>
|
|
||||||
</child>
|
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkMenuItem">
|
<object class="GtkMenuItem">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
|
|
@ -223,13 +148,12 @@
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkRadioToolButton" id="jagrit_btn">
|
<object class="GtkToolButton" id="jagrit_btn">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="can-focus">False</property>
|
<property name="can-focus">False</property>
|
||||||
<property name="label" translatable="yes">Connect</property>
|
<property name="label" translatable="yes">Connect</property>
|
||||||
<property name="use-underline">True</property>
|
<property name="use-underline">True</property>
|
||||||
<property name="icon-name">media-playback-start</property>
|
<property name="icon-name">media-playback-start</property>
|
||||||
<property name="active">True</property>
|
|
||||||
</object>
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="expand">False</property>
|
<property name="expand">False</property>
|
||||||
|
|
@ -274,6 +198,53 @@
|
||||||
<property name="shrink">True</property>
|
<property name="shrink">True</property>
|
||||||
</packing>
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkBox">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">False</property>
|
||||||
|
<property name="orientation">vertical</property>
|
||||||
|
<child>
|
||||||
|
<object class="GtkToolbar">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">False</property>
|
||||||
|
<child>
|
||||||
|
<object class="GtkToolButton" id="clear_log">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">False</property>
|
||||||
|
<property name="label" translatable="yes">Clear</property>
|
||||||
|
<property name="use-underline">True</property>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="homogeneous">True</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkToolItem">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">False</property>
|
||||||
|
<child>
|
||||||
|
<object class="GtkCheckButton" id="full_log">
|
||||||
|
<property name="label" translatable="yes">Show full log</property>
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">True</property>
|
||||||
|
<property name="receives-default">False</property>
|
||||||
|
<property name="draw-indicator">True</property>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="homogeneous">True</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="position">0</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkScrolledWindow">
|
<object class="GtkScrolledWindow">
|
||||||
<property name="width-request">300</property>
|
<property name="width-request">300</property>
|
||||||
|
|
@ -290,6 +261,49 @@
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="position">1</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkBox">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">False</property>
|
||||||
|
<child>
|
||||||
|
<object class="GtkEntry" id="send_entry">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">True</property>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">True</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="position">0</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkButton" id="send_btn">
|
||||||
|
<property name="label" translatable="yes">Send</property>
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can-focus">True</property>
|
||||||
|
<property name="receives-default">True</property>
|
||||||
|
<property name="image">send_image</property>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="position">1</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="position">2</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
<packing>
|
<packing>
|
||||||
<property name="resize">True</property>
|
<property name="resize">True</property>
|
||||||
<property name="shrink">True</property>
|
<property name="shrink">True</property>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue