use tk::*;
use tk::ttk_treeview::*;
use tk::cmd::*;
fn main() -> TkResult<()> {
let tk = make_tk!()?;
let root = tk.root();
let tree = root.add_ttk_treeview(())?.pack(())?;
tree.insert( "", Index::End, "widgets" -text("Widget Tour") )?;
tree.insert( "", 0, "gallery" -text("Applications") )?;
let id = tree
.insert( "", Index::End, -text("Tutorial") )?
.unwrap();
tree.insert( "widgets", Index::End, -text("Canvas") )?;
tree.insert( &id, Index::End, -text("Tree") )?;
tree.set_item( "widgets", -open("true") )?;
let is_open = tree.item( "widgets", open )?;
println!( "is_open:{}", is_open );
Ok( main_loop() )
}