Re: [pygtk] Caching list view/-model ?
Am 2003.07.23 07:47 schrieb(en) James Henstridge: > The reason why the text in every row is measured (which can take a while > for a large model). > > However, you can set a fixed height for the text cells using the > gtk.CellRendererText.set_fixed_height_from_font() method. It takes a > single argument: the number of rows of text in the cell. That way it > won't bother measuring the text to find the row height. I see. In fact I kept wondering why the ListView was acting so silly! I will try it (no time yet) but it looks as if it would be the solution. Thank you, Peter ___ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
[pygtk] Caching list view/-model ?
Hi, I am in desparate need of a List/Tree widget that does *not* read the whole database / model, but only a portion of it, essentially what is displayed. This looks as an innocuous enough requirement, but I failed completely to get anything to work, or even to find a model implementation. The libgnomedb appears to contain something in this direction, however a.t.m. I am still searching for it :-) Anyway, it should not be that uncommon a requirement, because it is not uncommon to have large databases, and expensive per item processing. A minimum would be to disconnect the scrollbar from the listview, so that one could reflect the position in a data base of, say, 1 records in the scrollbar, but only display the first twenty records, say, at the beginning. Has anyone ever tried this? Regards, Peter ___ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
[pygtk] Associating a Window with a MenuItem?
Hi, I'd like to (perhaps) share the menu call backs between multiple windows. So I tried to get the window concerned from the MenuItem object passed to the call back. Now, I'm puzzled by the fact that in a call back the get_toplevel() for the MenuItem does not give the associated window, nor does is_ancestor() work. I.e.: 1. Window: 2. MenuItem.get_toplevel(): This looks strange to my (novice) eyes. I have to add that the Window at (1) is a subclass of gtk.Window. As I happen to have no idea of how Python implements subclasses, this may be the reason for the behaviour in question. If this be the case, it should be possible to navigate somehow between the two aspects? Regards, Peter -- Key fingerprint = DDB1 E6A4 522E 1CBF 0C37 031A AAA9 FB5C 3984 CF9D ___ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/