Re: GtkTreeView: how to get the cell with current focus?

2018-07-12 Thread Reuben Rissler
I do this all the time in Python with: def key_tree_tab(self, treeview, event): keyname = Gdk.keyval_name(event.keyval) path, col = treeview.get_cursor() # only visible columns!! columns = [c for c in treeview.get_columns() if c.get_visible()] colnum =

Re: GtkTreeView: how to get the cell with current focus?

2018-07-12 Thread Lars Paulsen
Hi All, I did some further tests and the addresses returned in focus_column are the same as the columns I created with "gtk_tree_view_column_new();". Well, it's quite obvious but somehow I expected that there is some API function which returns an index for a column. Anyway, I will continue by

Re: gtktreeview problem.

2015-03-23 Thread John Coppens
On Mon, 23 Mar 2015 12:50:28 + Ubirajara Marques da Cruz wrote: > Into ON_DRAG_RECEIVED signal when I copy selection data with memcpy I have a > surprise. Gtk selection has the same structure but data is empty. And only > one data is copied and it is wrong. It is a genum. Maybe this tutori

Re: gtktreeview: highlighting a cell

2015-01-06 Thread Stefan Sauer
On 12/12/2014 06:57 PM, Allin Cottrell wrote: > I'm using GtkTreeView to implement a simple spreadsheet. > > With GTK 2, if use gtk_tree_view_set_cursor() to place keyboard focus > on a given cell, with the last argument set to FALSE so that editing > mode is not entered immediately, I get a visual

Re: GtkTreeView isn't updating when GtkListStore appended and set

2014-01-07 Thread Colomban Wendling
Le 07/01/2014 22:48, Jordan H. a écrit : > > Man, sorry, but I guess I'm still not getting this. > > I've added a GtkTreeViewColumn and GtkCellRenderer to the GtkTreeView: > > > Button Label > True > True > > > > Actually the patch should look like this: > --- button-actions.glade > +++ b

Re: GtkTreeView isn't updating when GtkListStore appended and set

2014-01-06 Thread Colomban Wendling
Le 06/01/2014 22:10, jorda...@fastmail.fm a écrit : > I suppose an attachment would be helpful (weird that it didn't send). OK, better now indeed. So, your problem is that you don't add columns to your tree view. A TreeView [1] displays TreeViewColumns [2], which itself contain CellRenderer [3].

Re: GtkTreeView isn't updating when GtkListStore appended and set

2014-01-06 Thread jordannh
I suppose an attachment would be helpful (weird that it didn't send). -- jorda...@fastmail.fm On Mon, Jan 6, 2014, at 08:50 AM, Colomban Wendling wrote: > Hi, > > Le 06/01/2014 17:26, Jordan H. a écrit : > > Attached is the Glade file. The GtkListStore ("liststore_button_list") > > is assi

Re: GtkTreeView isn't updating when GtkListStore appended and set

2014-01-06 Thread Colomban Wendling
Hi, Le 06/01/2014 17:26, Jordan H. a écrit : > Attached is the Glade file. The GtkListStore ("liststore_button_list") > is assigned the GtkTreeView ("treeview_button_order"). Looks like the attachment is missing. > The GtkTreeView doesn't seem to reflect the changes made to the > GtkListStore.

Re: GtkTreeView isn't updating when GtkListStore appended and set

2014-01-06 Thread Jordan H.
Thank you. I'll look into templates. Attached is the Glade file. The GtkListStore ("liststore_button_list") is assigned the GtkTreeView ("treeview_button_order"). The GtkTreeView doesn't seem to reflect the changes made to the GtkListStore. I iterated through the GtkListStore itself and found tha

Re: GtkTreeView isn't updating when GtkListStore appended and set

2014-01-05 Thread Tristan Van Berkom
On Sat, 2014-01-04 at 23:46 -0600, Michael Cronenworth wrote: > On 01/04/2014 05:21 PM, Jordan H. wrote: > > In Glade I've defined column "0" in the list store as a "gchararray" > > cell. I even tried forcing the assignment of GtkListStore to GtkTreeView > > (knowing full well I wouldn't need to) t

Re: GtkTreeView isn't updating when GtkListStore appended and set

2014-01-04 Thread Michael Cronenworth
On 01/04/2014 05:21 PM, Jordan H. wrote: In Glade I've defined column "0" in the list store as a "gchararray" cell. I even tried forcing the assignment of GtkListStore to GtkTreeView (knowing full well I wouldn't need to) to no avail. I don't get any errors, but the GtkTreeView doesn't reflect t

Re: GtkTreeView doesn't refresh

2013-11-27 Thread Jarosław Sobieszek
On Wed, 27 Nov 2013 14:19:37 +0100, Colomban Wendling wrote: > Le 27/11/2013 12:57, Jarosław Sobieszek a écrit : >> Hello, >> >> I'm trying to dynamically modify list based on some action. Program below >> should add 3 rows at the top and 3 rows at the bottom of the list for >> every >> click of

Re: GtkTreeView doesn't refresh

2013-11-27 Thread Colomban Wendling
Le 27/11/2013 12:57, Jarosław Sobieszek a écrit : > Hello, > > I'm trying to dynamically modify list based on some action. Program below > should add 3 rows at the top and 3 rows at the bottom of the list for every > click of the button. For some reason it doesn't work - I'm seeing partial > updat

Re: GtkTreeView doesn't refresh

2013-11-27 Thread Rafał Mużyło
On Wed, Nov 27, 2013 at 11:57:57AM +, Jarosław Sobieszek wrote: > Hello, > > I'm trying to dynamically modify list based on some action. Program below > should add 3 rows at the top and 3 rows at the bottom of the list for every > click of the button. For some reason it doesn't work - I'm seei

Re: GtkTreeView very slow for large lists

2011-12-16 Thread Tristan Van Berkom
On Fri, Dec 16, 2011 at 10:32 PM, John Lindgren wrote: > Steve, > > I use the "time" shell command and wait for my CPU meter to drop back to > idle before quitting the test program, giving something like this: > >    time ./list-test > >    real    0m31.719s >    user    0m29.168s >    sys    0m0.

Re: GtkTreeView very slow for large lists

2011-12-16 Thread John Lindgren
Jannis Pohlmann wrote: > I only briefly read the other replies, so maybe I'm repeating something > here. One thing I remember that can speed things up drastically is to > only associate the model with the tree view once it has all its data. > AFAIR, populating the model while it's linked to the tre

Re: GtkTreeView very slow for large lists

2011-12-16 Thread John Lindgren
On 12/16/2011 05:54 AM, jcup...@gmail.com wrote: > ... > > I did notice that you forgot to put the treeview into fixed-height mode. > > Normally, treeview lets rows vary in height (so you can change font > between rows, for example). To make this work, treeview has a idle > task which scans the ent

Re: GtkTreeView very slow for large lists

2011-12-16 Thread John Lindgren
Steve, I use the "time" shell command and wait for my CPU meter to drop back to idle before quitting the test program, giving something like this: time ./list-test real0m31.719s user0m29.168s sys0m0.023s -- John On 12/16/2011 12:24 AM, Steve . wrote: > John, > > Tim

Re: GtkTreeView very slow for large lists

2011-12-16 Thread jcupitt
On 16 December 2011 10:36, wrote: > 2011/12/16 John Lindgren : >> Lately I have been trying to improve the performance with large >> playlists (i.e. on the order of 100,000 entries).  The one remaining >> problem spot seems to be GtkTreeView.  I am attaching a simple test >> program that creates

Re: GtkTreeView very slow for large lists

2011-12-16 Thread Jannis Pohlmann
On Thu, 15 Dec 2011 20:13:03 -0500 John Lindgren wrote: > Hi, > > I am the lead developer of Audacious (a GTK+ based music player). > Lately I have been trying to improve the performance with large > playlists (i.e. on the order of 100,000 entries). The one remaining > problem spot seems to be

Re: GtkTreeView very slow for large lists

2011-12-16 Thread jcupitt
2011/12/16 John Lindgren : > Lately I have been trying to improve the performance with large > playlists (i.e. on the order of 100,000 entries).  The one remaining > problem spot seems to be GtkTreeView.  I am attaching a simple test > program that creates a GtkTreeView with 3 columns and 100,000 r

Re: GtkTreeView very slow for large lists

2011-12-15 Thread John Lindgren
Steve, Are you looking at the time it takes to show the window or the time before the CPU usage drops to idle? GtkTreeView does a lot of work in the background after the window appears. -- John On 12/15/2011 11:17 PM, Steve . wrote: > John, > > I just ran your test on my thinkpadx61, It only t

Re: GtkTreeView very slow for large lists

2011-12-15 Thread John Lindgren
On 12/15/2011 09:56 PM, Steve . wrote: > John, > > I can't tell you this /will work/. More over this is how I'd first > approach the problem (maybe I'm way off base here too) > > My initial thoughts are that the user can't see 100,000 items at once > so there is no need to expect the widget to hand

Re: GtkTreeView very slow for large lists

2011-12-15 Thread John Lindgren
Hi Steve, I'm not sure that I understand. Are you saying that we should assume that the user wants access to only part of the playlist and somehow try to predict what part? This doesn't sound like a good solution to me. -- John On 12/15/2011 08:33 PM, Steve . wrote: > John, > > I have no exper

Re: GtkTreeView with 2 Columns

2011-09-10 Thread Michal Suchanek
On 10 September 2011 15:45, Paolo wrote: > Hi at all! I have a problem about a tree with two columns. The first one is > a column that shows an icon and the second one shows a text. All works fine, > but between the columns I see an ugly vertical sperator. I know that there > are the style propert

Re: GtkTreeView with 2 Columns

2011-09-10 Thread Michal Suchanek
On 10 September 2011 15:45, Paolo wrote: > Hi at all! I have a problem about a tree with two columns. The first one is > a column that shows an icon and the second one shows a text. All works fine, > but between the columns I see an ugly vertical sperator. I know that there > are the style propert

RE: GtkTreeView signal before row change

2011-03-08 Thread Lance Zhang
ed to achieve that with a timeout. A huge lot of work to achieve something trivial. It's so unnatural that I suspect there is a more elegant way not known to me who am still a novice in GTK+. Lance -------- > Date: Wed, 9 Mar 2011 06:41:11 +0900 > S

Re: GtkTreeView signal before row change

2011-03-08 Thread Tristan Van Berkom
On Wed, Mar 9, 2011 at 12:38 AM, Lance Zhang wrote: > > Hi: > > I have a situation where I need to verify data before allowing a row change > in a GtkTreeView. Essentially: > > 1. User requests a row change through a keyboard or a mouse; > 2. Check if data in the current row has been edited witho

Re: GtkTreeView in VBox

2010-01-16 Thread Stefan Kost
Am 07.01.2010 14:24, schrieb Amol Kulkarni: > Hi All, > Is it possible to add GtkTreeView inside VBox and then add that VBox to > ScrolledWindow using gtk_scrolled_window_add_with_viewport(sw,vbox). > GtkTreeView has inbuilt scrolling support hence it is expected to add it > directely to scrolledwi

Re: GtkTreeView in VBox

2010-01-12 Thread Rhishikesh Joshi
Hi, I have also faced a similar situation in which case i need to pack a treeview inside a VBox. I would not mind the treeview apis not working but the packing is something i am looking to keep. The scrolling of the VBox works fine for smaller sizes of the TreeView. But when the treeview consis

Re: GtkTreeView in VBox

2010-01-07 Thread Kristian Rietveld
On Thu, Jan 7, 2010 at 1:24 PM, Amol Kulkarni wrote: > Is it possible to add GtkTreeView inside VBox and then add that VBox to > ScrolledWindow using gtk_scrolled_window_add_with_viewport(sw,vbox). > Is this expected/supported use case or am i doing something wrong here? > Thanks for your time.

Re : GtkTreeView sorting triggered by cell renderer while, retaining row selection

2010-01-04 Thread Nicolas SOUBEIRAN
I've already signaling the issue between selection and toggle cell : here is the answer by kris If the column is sorted, when one activates the toggle, the tree is re-sorted (normal) but the selected row is changed (unexpected). I investigated and I found that when clicking on a toggle cell rend

Re: GtkTreeView auto selecting row

2009-12-16 Thread Tadej Borovšak
Hello. Just call gtk_tree_selection_select_iter/path() and you should be good. Tadej -- Tadej Borovšak tadeboro.blogspot.com tadeb...@gmail.com tadej.borov...@gmail.com ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome

Re: GtkTreeView: g_signal_handlers_unblock_by_func

2009-11-01 Thread Carlos Pereira
Tadej Borovšak wrote: Hello. Essentially adding a simple store model: store = gtk_list_store_new (1, G_TYPE_STRING); while (foo_bar != NULL) { gtk_list_store_append (store, &iter); gtk_list_store_set (store, &iter, 0, my_name, -1); } gtk_tree_view_set_model (GTK_TREE_VIEW (treeview), GT

Re: GtkTreeView: g_signal_handlers_unblock_by_func

2009-10-31 Thread Tadej Borovšak
Hello. > Essentially adding a simple store model: > > store = gtk_list_store_new (1, G_TYPE_STRING); > while (foo_bar != NULL) >  { >  gtk_list_store_append (store, &iter); >  gtk_list_store_set (store, &iter, 0, my_name, -1); >  } > gtk_tree_view_set_model (GTK_TREE_VIEW (treeview), GTK_TREE_MODE

Re: GtkTreeView: g_signal_handlers_unblock_by_func

2009-10-31 Thread Carlos Pereira
Tadej Borovšak wrote: Hello. Only situation that comes to my mind that would cause g_signal_handlers_block_by_func to misbehave is if you do something inside blocked part of code that installs idle handler to do the real work. What are you doing inside "do_stuff" part? Essentially adding a

Re: GtkTreeView: g_signal_handlers_unblock_by_func

2009-10-31 Thread Tadej Borovšak
Hello. Only situation that comes to my mind that would cause g_signal_handlers_block_by_func to misbehave is if you do something inside blocked part of code that installs idle handler to do the real work. What are you doing inside "do_stuff" part? Tadej -- Tadej Borovšak tadeboro.blogspot.com t

Re: GtkTreeView - drag & drop

2008-12-09 Thread John M Collins
Thanks for your help I'd completely missed gtk_tree_view_set_reorderable and it does what I wanted apart from the ctrl to copy - perhaps I'll do that with a "duplicate selected item" button and then have the user use drag and drop to put the newly created item where he/she wants it. Now wrestling

Re: GtkTreeView - drag & drop

2008-12-09 Thread Tadej Borovšak
Hello. I'm far from expert at those things, but to achieve simple reordering, I think it's enough to call gtk_tree_view_set_reorderable on your GtkTreeView (if you created custom tree store for your treeview, you need to implement GtkDragSource and the GtkDragDest interfaces in it to make things w

Re: gtktreeview sort string function

2008-11-24 Thread Kristian Rietveld
Hi, On Mon, Nov 24, 2008 at 4:25 PM, Johnson Wong <[EMAIL PROTECTED]> wrote: > What compare functions does gtktreeview-columns use to sort strings? If I am not mistaking GtkListStore and GtkTreeStore use g_utf8_collate() by default for comparing strings. You can override the sort function used,

Re: GtkTreeView and lazy population

2008-09-19 Thread Kristian Rietveld
Hi, On Tue, Sep 16, 2008 at 3:48 PM, Sam Thursfield <[EMAIL PROTECTED]> wrote: > It seems as though the first thing GtkTreeView does on receiving the > model is to iterate through every root node, calling iter_has_child > and iter_next for each until iter_next returns FALSE. This then leads > to m

Re: GtkTreeView row colors

2008-08-27 Thread Roland Roberts
Damien Caliste wrote: Have a look to this answer: http://www.mail-archive.com/gtk-app-devel-list%40gnome.org/msg11865.htm I've posted a complete example on my blog at http://www.astrofoto.org/node/793 so I don't forget what I learned :-) Thanks again, I had a big conceptual hurdle to get over

Re: GtkTreeView row colors

2008-08-27 Thread Roland Roberts
Damien Caliste wrote: Le 26/08/2008, Roland Roberts <[EMAIL PROTECTED]> a écrit : I'm having trouble figuring out how to change the font color/weight for each row individually in my GtkTreeView. Have a look to this answer: http://www.mail-archive.com/gtk-app-devel-list%40gnome.org/msg11

Re: GtkTreeView row colors

2008-08-26 Thread Damien Caliste
Hello, Le 26/08/2008, Roland Roberts <[EMAIL PROTECTED]> a écrit : > I'm having trouble figuring out how to change the font color/weight > for each row individually in my GtkTreeView. Have a look to this answer: http://www.mail-archive.com/gtk-app-devel-list%40gnome.org/msg11865.html Don't hesita

Re: GtkTreeView Expand All

2008-05-05 Thread Kristian Rietveld
Hi, On Wed, Apr 30, 2008 at 08:35:42AM -0700, Eric Pastoor wrote: > I am trying to figure how to recursively expand all from the current > selection in a gtk tree. > > I know the function gtk_tree_view_expand_all(GtkTreeView*) will expand the > entire tree. However, I have set up a right click me

Re: gtktreeview and doubles

2008-04-30 Thread Martin (OpenGeoMap)
Hi: > On Wed, 2008-04-30 at 10:49 +0200, Martin (OpenGeoMap) wrote: > >> Hi all: >> >> It´s posible edit the cellrender for doubles?? >> >> Always put 6 decimals. Can i modify that?? >> >> Any tips appreciated. >> > > You can use gtk_tree_view_column_set_cell_data_func() to change how data

Re: gtktreeview and doubles

2008-04-30 Thread Murray Cumming
On Wed, 2008-04-30 at 10:49 +0200, Martin (OpenGeoMap) wrote: > Hi all: > > It´s posible edit the cellrender for doubles?? > > Always put 6 decimals. Can i modify that?? > > Any tips appreciated. You can use gtk_tree_view_column_set_cell_data_func() to change how data is displayed in your cell

Re: GtkTreeView: GTK_SELECTION_SINGLE not working?

2008-04-20 Thread Kristian Rietveld
Hi, Apologies for the late reply, have been very busy lately. Comments inline. On Fri, Apr 04, 2008 at 08:07:42PM +0100, Carlos Pereira wrote: > > 1) In GtkTreeview with GtkListStore, show always the first item as default, > when selec

Re: GtkTreeView: GTK_SELECTION_SINGLE not working?

2008-04-04 Thread Carlos Pereira
Thanks for replying! I certainly would be glad if proved wrong, but I see three problems here, two are human interface issues, the other is a technical issue. 1) In GtkTreeview with GtkListStore, show always the first item as default, w

Re: GtkTreeView: GTK_SELECTION_SINGLE not working?

2008-04-04 Thread Kristian Rietveld
Hello, Could you more precisely describe what you think is wrong? I quickly tested with GTK+ trunk and I do not see any problems. It is indeed the case that one row is basically always selected (both with single and browse mode) and the main difference between browse and single mode is that in b

Re: GtkTreeView row selection change events

2007-12-30 Thread Emmanuele Bassi
On Sun, 2007-12-30 at 04:48 -0500, Christopher Harvey wrote: > Hello GTKers, > What is the event name that fires when the user changes the current > GtkTreeView row selection, and what structure is it associated with? GtkTreeSelection::changed: http://library.gnome.org/devel/gtk/stable/GtkTree

Re: GtkTreeView row selection change events

2007-12-30 Thread Micah Carrick
I believe it's "row-activated" when a user double-clicks and "cursor-changed" when the selected row has changed. - Micah Carrick Developer - http://www.micahcarrick.com GTK+ Forums - http://www.gtkforums.com Christopher Harvey wrote: > Hello GTKers, > What is the event name that fires whe

Re: GtkTreeView: how to reduce size of cell

2007-12-17 Thread Abirami.T
hi, The padding space can be reduced by setting the style parameter "vertical-separator" through rc file. The height of the cell renderer can also be set to a lesser value using the "height" style property. Regards, Abirami. - Original Message - From: "Romain Liévin" <[EMAIL P

Re: GtkTreeView: how to reduce size of cell

2007-12-15 Thread Kristian Rietveld
Hello, On Sat, Dec 15, 2007 at 12:03:22PM +0100, Romain Li?vin wrote: > I'm working on a debugger > (http://www.lievin.net/downloads/lpg/vti_dock.png). As you can see, > there is a lot of space between each line of the left upper frame. > > How can I decrease space between lines or value of pad

RE: GtkTreeView+vscroll in hbox

2007-08-10 Thread Kumar Siddharth
Hi, >>the problem is, in hbox the width of hbox is equally divided for both treeview and vscroll. >>So a huge gap is coming between treeview and vscroll. This depends upon how did you create your HBOX. If you create it like: gtk_hbox_new(TRUE, ..); then, all packed widgets will have same width,

Re: GtkTreeView+vscroll in hbox

2007-08-10 Thread Damien Caliste
Hello, Le 10/08/2007, "Prasanna Kumar K" <[EMAIL PROTECTED]> a écrit : > gtk_box_pack_start (GTK_BOX(hbox), treeview, TRUE, TRUE, 0); > gtk_box_pack_start (GTK_BOX(hbox), vscroll, TRUE, TRUE, 0); > gtk_box_pack_start (GTK_BOX(vbox), hbox, TRUE, TRUE, 1); > > the problem is, in hbox the width

Re: GtkTreeView in a Scrolled Window

2007-06-20 Thread Yeti
On Wed, Jun 20, 2007 at 12:38:31PM +0530, Divya yadav wrote: > I tried adding a Treeview inside a scroll window. and i am updating my > treeview using *gtk_list_store_prepend *it is working fine but the scrollbar > is also moving along with these updates by the end of all updates it is > somewhere

Re: GtkTreeView: different renderes within one row?

2007-05-31 Thread Felix Kater
"Vivien Malerba" <[EMAIL PROTECTED]> wrote: > > I'd like to create a two column list with simple text display on the > > left but each row having a different renderer on the right (combo, > > spin, entry). > > I suggest you then create a custom cell renderer which will adapt > itself to the displ

Re: GtkTreeView: different renderes within one row?

2007-05-31 Thread Vivien Malerba
On 5/30/07, Felix Kater <[EMAIL PROTECTED]> wrote: > hi, > > I am new to GtkTreeView: > > Are cell renderers bound to columns or can they change between rows of > the same column? AFAIK cell renderers are defined once for each column, and are the same for all the rows, but you can have more than o

Re: GtkTreeView: different renderes within one row?

2007-05-30 Thread Felix Kater
typo in subject line: GtkTreeView: different renderers within one COLUMN? ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Re: GtkTreeView: Simple application

2007-05-25 Thread Felipe Balbi
Wow... thanks... :-) Now I can keep going with my app... thanks a lot :-) On 5/26/07, David Nečas (Yeti) <[EMAIL PROTECTED]> wrote: > On Sat, May 26, 2007 at 03:19:49AM +0300, Felipe Balbi wrote: > > > > my doubt regards this code: > > > > int main(int argc, char *argv[]) > > { > > GladeXM

Re: GtkTreeView: Simple application

2007-05-25 Thread Yeti
On Sat, May 26, 2007 at 03:19:49AM +0300, Felipe Balbi wrote: > > my doubt regards this code: > > int main(int argc, char *argv[]) > { > GladeXML*openhset; > GtkWidget *main_window, *test_window; > GtkWidget *main_window_treeview1; > GtkWidget *ma

Re: GtkTreeView colspan, rowspan

2007-03-29 Thread Gabriel Schulhof
Hi! On Thu, March 29, 2007 14:40, Stefan Kost wrote: > Unfortunately it is not, although I really miss it. What about implementing your own cell renderer? You could make a fancier version of GtkCellRendererText that can handle multiple text strings arranged in a grid. Of course, if what you reall

Re: GtkTreeView colspan, rowspan

2007-03-29 Thread Yeti
On Thu, Mar 29, 2007 at 11:32:53AM +0200, Iago Toral Quiroga wrote: > is it possible to create complex layouts using a GtkTreeView widget? I > mean, being able to expand rows or columns as in GtkTable to achieve > layouts like this one: > > - > | aa | bb

Re: GtkTreeView colspan, rowspan

2007-03-29 Thread Stefan Kost
Hi, Quoting Iago Toral Quiroga <[EMAIL PROTECTED]>: > Hi all, > > is it possible to create complex layouts using a GtkTreeView widget? I > mean, being able to expand rows or columns as in GtkTable to achieve > layouts like this one: > > - > | aa | b

Re: GtkTreeView having nodes with underlined text

2006-11-27 Thread Gian Mario Tagliaretti
2006/11/23, [EMAIL PROTECTED] <[EMAIL PROTECTED]>: > Wow. Thanks, David, for your concise example. and for the pythonists: http://www.async.com.br/faq/pygtk/index.py?req=show&file=faq13.047.htp thanks David cheers -- Gian Mario Tagliaretti http://www.parafernalia.org/pygtk/ ___

Re: GtkTreeview

2006-11-27 Thread Andrea Zagli
Il giorno lun, 27/11/2006 alle 12.03 +0800, sunzysjzri ha scritto: > a simple question, that which signal of GtkTreeView could i use to catch a > mouse clicked event? the GtkTreeSelection's "changed" signal for a single click; the GtkTreeView's "row-activated" for a double click _

Re: GtkTreeView having nodes with underlined text

2006-11-23 Thread tomas
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Wed, Nov 22, 2006 at 02:57:37PM +0100, David Nečas (Yeti) wrote: [...] > #include Wow. Thanks, David, for your concise example. Regards - -- tomás -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.1 (GNU/Linux) iD8DBQFFZWyrBcgs9XrR2kYRAhu2AJ9y

Re: GtkTreeView having nodes with underlined text

2006-11-22 Thread Miroslav Rajcic
by itself (I forgot to increment column count). Regards, Miroslav - Original Message - From: "David Necas (Yeti)" <[EMAIL PROTECTED]> To: Sent: Wednesday, November 22, 2006 2:57 PM Subject: Re: GtkTreeView having nodes with underlined text > On Wed, Nov 22, 2006

Re: GtkTreeView having nodes with underlined text

2006-11-22 Thread Yeti
On Wed, Nov 22, 2006 at 01:28:32PM +0100, Miroslav Rajcic wrote: > I am having a problem to underline text for some (not all) nodes in a > GtkTreeView. > > I've tried following: > > 1. a) add new column in the tree store of type G_TYPE_ENUM (tried integer > type too) Should be G_TYPE_UINT. >

Re: gtktreeview

2006-09-21 Thread Tim Müller
On Wed, 2006-08-23 at 14:45 +0200, Andrea Zagli wrote: > is there a way to have various cellrender type for each row for the same > column? Example: > > row 1 with gtkcellrenderertext > row 2 with gtkcellrenderercombo > row 3 with gtkcellrenderertext > row 4 with gtkcellrenderertoggle You _might_

Re: gtktreeview

2006-08-23 Thread Paul Pogonyshev
Andrea Zagli wrote: > is there a way to have various cellrender type for each row for the same > column? > > example: > > row 1 with gtkcellrenderertext > row 2 with gtkcellrenderercombo > row 3 with gtkcellrenderertext > row 4 with gtkcellrenderertoggle No (at least not that I know of.) But yo

Re: GtkTreeView, GtkListStore and more...

2006-08-17 Thread Iago Rubio
On Thu, 2006-08-17 at 17:43 +0200, Fernando Apesteguía wrote: > for(){ >... >if(should_be_deleted) > gtk_list_store_remove(model,&iter); > > gtk_tree_model_iter_next(GTK_TREE_MODEL(model),&iter); > } Try: if(should_be_deleted) gtk_list_store_remove(model, &ite

Re: GtkTreeView row colour not continuous

2006-06-06 Thread tomas
On Wed, Jun 07, 2006 at 01:25:37AM +0200, kiraly laszlo wrote: [...] > Yes, this is good but one. Now, only the first column has gap. Glad that helped a bit... > http://kiru.mikroweb.hu/gtk2.jpg Now this looks rather strange. Sorry, that's beyond my capabilities at the moment. Regards -- tomás

Re: GtkTreeView row colour not continuous

2006-06-06 Thread kiraly laszlo
[EMAIL PROTECTED] wrote: > On Mon, Jun 05, 2006 at 06:32:45PM +0200, kiraly laszlo wrote: > > Hi list, > > > > I have a problem with GtkTreeView. > > I want to change the colours of the rows of the GtkTreeView > > dynamically. > [...] > > How can I make continuous colour without gaps, like in th

Re: GtkTreeView row colour not continuous

2006-06-05 Thread tomas
On Mon, Jun 05, 2006 at 06:32:45PM +0200, kiraly laszlo wrote: > Hi list, > > I have a problem with GtkTreeView. > I want to change the colours of the rows of the GtkTreeView > dynamically. [...] > How can I make continuous colour without gaps, like in the > selection? The GtkTreeView widget has

Re: GtkTreeView PixBuf cell to display 2 images

2006-04-21 Thread daa84
Van H Tran wrote: Hi! I want to implement some kind of FOLDER browser window using GtkTreeView. This tree has 2 columns, first column for some icon, and the second for the folder name I have 4 icons 1. icon of a Folder open 2. icon of a Folder closed 3. icon of a small + sign 4. icon of a smal

Re: GtkTreeView: How do I detect right-click?

2006-04-10 Thread Guy Rouillier
Ang Bodhi wrote: Hi, Guy Rouillier wrote: Ang Bodhi wrote: Hi, I have a GtkTreeView widget that I would like to detect the mouse button right-click, how can I do that? In Gtk 1.2, I used to be able to connect to a button_press_event signal of a GtkTreeItem widget. Did you search archive

Re: GtkTreeView: How do I detect right-click?

2006-04-10 Thread Ang Bodhi
Hi, Guy Rouillier wrote: Ang Bodhi wrote: Hi, I have a GtkTreeView widget that I would like to detect the mouse button right-click, how can I do that? In Gtk 1.2, I used to be able to connect to a button_press_event signal of a GtkTreeItem widget. Did you search archives before posting?

Re: GtkTreeView: How do I detect right-click?

2006-04-09 Thread Guy Rouillier
Ang Bodhi wrote: Hi, I have a GtkTreeView widget that I would like to detect the mouse button right-click, how can I do that? In Gtk 1.2, I used to be able to connect to a button_press_event signal of a GtkTreeItem widget. Did you search archives before posting? I just answered this 5 days ag

Re: GtktreeView & Model segmentation fault

2006-03-13 Thread David Necas (Yeti)
On Mon, Mar 13, 2006 at 11:16:04AM -0800, Van H Tran wrote: > I get a "Segmentation fault" in a gtktreeview i'm > using. Basically, it's a Treeview with expandable > folders (like a file browser) > > The problem is: The program crashes very randomly when > i just try to click to expand/collapse t

Re: GtkTreeView - Selecting the first row

2006-02-24 Thread Justin Clift
Hannes Mayr wrote: renderer = gtk_cell_renderer_text_new(); path = gtk_tree_path_new_from_string("0"); gtk_tree_view_set_cursor(GTK_TREE_VIEW(treeview), path, NULL, renderer); Hi Hannes, You may also like to consider: path = gtk_tree_path_new_first(); as a replacement for: path = gtk_t

Re: GtkTreeView - Selecting the first row

2006-02-24 Thread Hannes Mayr
Hannes Mayr wrote: Stefan Kost wrote: hi, just a wild guess, are use using the GTK_SELECTION_BROWSE selection mode? GtkTreeSelection *select; select = gtk_tree_view_get_selection (GTK_TREE_VIEW (tree)); gtk_tree_selection_set_mode (select, GTK_SELECTION_BROWSE); Yes, I already tried that

Re: GtkTreeView - Selecting the first row

2006-02-23 Thread Hannes Mayr
Stefan Kost wrote: hi, just a wild guess, are use using the GTK_SELECTION_BROWSE selection mode? GtkTreeSelection *select; select = gtk_tree_view_get_selection (GTK_TREE_VIEW (tree)); gtk_tree_selection_set_mode (select, GTK_SELECTION_BROWSE); Yes, I already tried that without success. I've

Re: GtkTreeView - Selecting the first row

2006-02-23 Thread Stefan Kost
hi, just a wild guess, are use using the GTK_SELECTION_BROWSE selection mode? GtkTreeSelection *select; select = gtk_tree_view_get_selection (GTK_TREE_VIEW (tree)); gtk_tree_selection_set_mode (select, GTK_SELECTION_BROWSE); Ciao Stefan Hannes Mayr wrote: Hello, I'm having a problem with

Re: Re: GtkTreeView get selected row AND column AND start editing ;-)

2006-02-15 Thread Juan Pablo
Stefan Kost wrote: > Juan Pablo wrote: > >> Hi list! >> I have a GtkTreeView and what I want to do is when the user is over an >> editable cell, the editing begins automatically without having to press >> enter. And the other thing that i want to do is that when the user is >> over a cell on a cer

Re: GtkTreeView get selected row AND column

2006-02-14 Thread Stefan Kost
Juan Pablo wrote: Hi list! I have a GtkTreeView and what I want to do is when the user is over an editable cell, the editing begins automatically without having to press enter. And the other thing that i want to do is that when the user is over a cell on a certain column the cursor changes automa

Re: GtkTreeView only displays one column

2006-01-09 Thread Tony Houghton
In <[EMAIL PROTECTED]>, you wrote: > On Mon, Jan 09, 2006 at 02:23:08PM +, Tony Houghton wrote: > > > > I've distilled my code down to a standalone program. Hopefully now > > someone else will easily be able to play with it and see what's wrong. > > The column becomes visible when you > (a)

Re: GtkTreeView only displays one column

2006-01-09 Thread David Necas (Yeti)
On Mon, Jan 09, 2006 at 02:23:08PM +, Tony Houghton wrote: > > I've distilled my code down to a standalone program. Hopefully now > someone else will easily be able to play with it and see what's wrong. The column becomes visible when you (a) do not set sizing mode to GTK_TREE_VIEW_COLUMN_FIX

Re: GtkTreeView only displays one column

2006-01-09 Thread Tony Houghton
In <[EMAIL PROTECTED]>, Tony Houghton wrote: > I'm trying to use GtkTreeView with GtkListStore to show a list of rows, > each containing a radio button and a bit of text (file leafname). The > trouble is I can only get the TreeView to show one column at a time. I've distilled my code down to a s

Re: GtkTreeView

2005-11-20 Thread tcleaver
All, Yes I have done that (Sorry for not mentioning that). However, I am curious about this. When you set GTK_TREE_VIEW_COLUMN_FIXED do you need to make sure you set the actual width of the column to a size bigger than the data you have? Do you have to set the size at all (gtk_tree_view_colum

Re: GtkTreeView

2005-11-16 Thread Claudio Saavedra
On Mon, 2005-11-14 at 16:39 +1000, tcleaver wrote: [...] > > My limited understanding is that these iterations are so that the TreeView > knows the maximum sizes/formatting of each cell (get_value is called from > gtk_tree_view_column_cell_set_cell_data) so as to calculate things such > as visibil

Re: gtktreeview - hide some rows

2005-10-16 Thread Stefan Kost
Hi, HuamiSoft Hubert Sokolowski wrote: Hi! I have a treeview which is a list. is it possible to hide some particular rows? I want to implement some filter on my treeview, so the user could find quicker some rows. regards have look at http://developer.gnome.org/doc/API/2.0/gtk/GtkTreeModelFilt

Re: GtkTreeView Search Popup

2005-09-29 Thread Christian Neumair
Am Donnerstag, den 29.09.2005, 12:46 -0400 schrieb Alex Levin: > Hello. I have an application which has a very specific UI built into > it. I have a GtkTreeView widget in which I would like to enable the > typeahead search functionality. My problem is that if I use the > gtk_tree_view_set_enable

Re: GtkTreeView Row Style or Color

2005-08-29 Thread Juan Pablo Ugarte
Ops, I forget to mention, that would be for columns For rows its better to attach the "foreground" property of the GtkCellRendererText to a model column. renderer = gtk_cell_renderer_text_new (); column = gtk_tree_view_column_new_with_attributes ("Type", renderer, "text", TEXT_COLUMN, "foreground"

Re: GtkTreeView Row Style or Color

2005-08-29 Thread Juan Pablo Ugarte
On Mon, 2005-08-29 at 16:52 +0300, Razvan Gavril wrote: > Is there a way to modify the style(or only the color) of some rows(not all) > in a GtkTreeView? I know it simple with GtkCList/GtkCTree(using > gtk_clist_set_row_style) but i want to do something like that in a > GtkTreeView. I know it m

Re: GtkTreeView Row Style or Color

2005-08-29 Thread John Coppens
On Mon, 29 Aug 2005 16:52:58 +0300 Razvan Gavril <[EMAIL PROTECTED]> wrote: > Is there a way to modify the style(or only the color) of some rows(not > all) in a GtkTreeView? I know it simple with GtkCList/GtkCTree(using > gtk_clist_set_row_style) but i want to do something like that in a > GtkT

Re: GtkTreeView : Drag and drop

2005-08-22 Thread HuamiSoft Hubert Sokolowski
Hi! On Mon, 22 Aug 2005 00:37:34 +0200 Thym <[EMAIL PROTECTED]> wrote: > Hello, > > ( I speak french, sorry for my english ) > > in my GtkTreeView, I activated drag and drop with : > gtk_tree_view_set_reorderable(GTK_TREE_VIEW(pTreeView), TRUE); > > The DnD works fine, but I would like contr

Re: GtkTreeView issues (porting from GtkCList)

2005-06-24 Thread André Pedralho
On 6/24/05, Jan-Marek Glogowski <[EMAIL PROTECTED]> wrote: > > Ok ok! However it doesn't work on my situation. What I am trying to do > > is something similar a bookmark. Then it has a root folder: Bookmark > > (that cotain all the folders and url's); and it has the url's (that > > are the 'leafs')

Re: GtkTreeView issues (porting from GtkCList)

2005-06-24 Thread Jan-Marek Glogowski
> Ok ok! However it doesn't work on my situation. What I am trying to do > is something similar a bookmark. Then it has a root folder: Bookmark > (that cotain all the folders and url's); and it has the url's (that > are the 'leafs'). One requirement is I may move the folders and url's. > So I need

  1   2   >