Re: Anti-Aliased 2D drawing

2005-05-16 Thread John Gill
Not exactly what you asked for (and no use at all if you're not using python), but matplotlib: http://matplotlib.sourceforge.net/ is great for this sort of thing. John Scott Robert Ladd wrote: Anti-Aliased 2D drawing I'm working on a program that draws relatively simple

Re: TreeView: Multiple selection inefficient?

2005-04-11 Thread John Gill
Andrew is suggesting you insert a small delay in between getting the signal the 'selection_changed' signal and actually doing something about it. By adding the delay you allow time for then next signal to come along + if you get a second signal you should reset the timer to zero, to allow for

Re: context menu when right clicking on a TreeViewColumn header

2005-02-26 Thread John Gill
See: http://bugzilla.gnome.org/show_bug.cgi?id=148558 http://bugzilla.gnome.org/show_bug.cgi?id=141937 Short answer: can't really be done at present without probing around in stuff you probably shouldn't. Bug 148558 has some good discussion of how to do it. Funny you should mention

TreeModelFilter performance with large models

2005-02-26 Thread John Gill
I've been experiencing poor performance with a TreeModelFilter as the number of rows in my model grows. Attached is a short Pygtk script which demonstrates the problem. The app loads 1 rows into a ListStore. Buttons on the bottom of the app allow you to filter to show either: All

Re: TreeFilterModel and sorting

2005-02-24 Thread John Gill
I've just run into this problem (using pygtk). I'd like to have a liststore that is both sortable and filterable. In fact, I had such a beast, but I was using my own nasty hacks to implement the filtering. I've had on my to-do list to switch to the TreeModelFilter + I've just tried that --

Re: TreeFilterModel and sorting

2005-02-24 Thread John Gill
[EMAIL PROTECTED] wrote: I've just run into this problem (using pygtk). I'd like to have a liststore that is both sortable and filterable. In fact, I had such a beast, but I was using my own nasty hacks to implement the filtering. I've had on my to-do list to switch to the

Re: gtk Treeview tutorial

2004-11-12 Thread John Gill
A really good way to learn gtk is to work with the python bindings, pygtk. There is a good pygtk tutorial for the treeview here: http://liw.iki.fi/liw/texts/gtktreeview-tutorial.html There are also a whole section on the treeview in the pygtk faq:

Re: Gtk::TreeView performance

2004-10-21 Thread John Gill
Thanks very much indeed for this pointer, armed with this info I've speeded up the loading of my grids by a factor of 5. I had been trying: TreeViewColumn::set_fixed_width() and TreeViewColumn::set_sizing(TREE_VIEW_COLUMN_FIXED) but hadn't noticed CellRenderer::set_fixed_size(width,

Re: Gtk::TreeView performance

2004-10-20 Thread John Gill
I've been running into similar performance issues with the TreeView, using a liststore containing thousands of rows. For example, with about 40K rows with 10 columns the data loads into the store quickly and then the cpu races for around 30-40 seconds. I think what is going on is the treeview

Re: Gtk::TreeView performance

2004-10-20 Thread John Gill
Igor Gorbounov wrote: John Gill wrote: [] My suspicion is that the treeview is calculating the layout of the renderers within the the fixed width of each column. I'm guessing if there was an option to stop it doing this (since its initial layout is more than good enough for me) that we

Re: How do i connect C callbacks to Python scripts ?

2004-09-25 Thread John Gill
I'd be inclined to use pygtk for your gui -- this will allow you to have all your code in python (if i understand correctly the only C code you have is the stuff from glade). There is an excellent pygtk faq here: http://www.async.com.br/faq/pygtk/index.py?req=index There is an excellent

Re: Submenu inside popup menu problems

2004-09-09 Thread John Gill
I recently encountered what I thought was flaky behaviour with gtk menus, but in the end it turned out to be a feature. What I found was that I was bringint the original menu up with the right mouse button and then selecting a sub-menu entry with the left button. Now it appears that whatever

Re: TreeViewColumn and right-click

2004-07-27 Thread John Gill
Thanks very much for the suggestions. For now I've gone with 2) + I've just submitted a bug request as suggested. http://bugzilla.gnome.org/show_bug.cgi?id=148558 Thanks again for the help, much appreciated. John Suggestions: 1) You can access column-button directly and connect to

TreeViewColumn and right-click

2004-07-23 Thread John Gill
I'm using the TreeView and a ListStore to display tables of data. Users often want to sort on a particular column or filter to see a subset of the values in a particular column. The TreeView has excellent support for the former -- I just need to make the column headers clickable and I pretty

Win32 modal dialog problem.

2004-07-20 Thread John Gill
I've been having problems with modal dialogs on win32. Specifically, if I have a modal dialog which in turn pops up a modal dialog then I find that the second dialog comes up behind the first dialog -- it gets the focus correctly and is indeed modal, but it is concealed by the original