quik77
January 6, 2007, 7:30pm
1
Hi there,
I am using TreeView to display list store data
This works fine.
However, I want that, if you click on the header,
the list store to update and sort alphabetically.
My problem is - there seems to be no event possible
when you click on that header?
Example of my widget:
Name Age Profession
joe | 51 | C# Coder
tim | 31 | Python Coder
pete | 25 | Ruby C.
| |
| |
| |
And I want to update the listings whenever
someone clicks on “Age” or “Profession”
in that header, inserted via
tree_view.insert_column(-1, ‘Age’, renderer, :text => 1)
tree_view.insert_column(-1, ‘Profession’, renderer, :text => 2)
–
Search for products and services at:
Powered by Outblaze
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net ’s Techsay panel and you’ll get the chance to share
your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
quik77
January 19, 2007, 4:30pm
2
Hi,
In [email protected]
“[ruby-gnome2-devel-en] TreeView + Updating list on mouse-click of
header” on Fri, 05 Jan 2007 02:02:03 +0100,
“Roebe XXX” [email protected] wrote:
My problem is - there seems to be no event possible
when you click on that header?
And I want to update the listings whenever
someone clicks on “Age” or “Profession”
in that header, inserted via
tree_view.insert_column(-1, ‘Age’, renderer, :text => 1)
tree_view.insert_column(-1, ‘Profession’, renderer, :text => 2)
You can’t. Use the following way instead of your way:
column = Gtk::TreeViewColumn.new('Age, renderer, :text => 1)
column.set_sort_column_id(1)
tree_view.append_column(column)
This sample source will help you:
CVS Info for project ruby-gnome2
Thanks,
kou
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net ’s Techsay panel and you’ll get the chance to share
your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV