Re: Is it possible having different GtkAdjustment values in GtkTreeView

2008-12-09 Thread Keedi Kim
Thanks for your help. The key point was GTK_TYPE_TREE_MODEL! But it doesn't still work properly with G_TYPE_INTERFACE. Your example code was very useful. And thanks again! :-D 2008/12/9 Tadej Borovšak <[EMAIL PROTECTED]> > I forgot to explain why G_TYPE_OBJECT does not work in this situation. >

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: Window backround not showing

2008-12-09 Thread Tadej Borovšak
Hello. You need to tell gtk that your window can be painted from within you application. Just put this line of code: gtk_widget_set_app_paintable( window, TRUE ); somewhere before gtk_widget_show function call and you should get your application background painted. 2008/12/9 Bill Czermak <[EMAIL

Window backround not showing

2008-12-09 Thread Bill Czermak
Am trying to set image as a backround for a window. It flashes in the window and disappears. Running Fedora9 with latest patches Cutdown source shows problem: #include static GtkWidget *entry; staticGtkWidget *window,*label,*vbox,*hbox,*button,*seperator; static GdkPixbuf *pixBuf; static

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

GtkTreeView - drag & drop

2008-12-09 Thread John M Collins
Could a kind person point me at some specimen code to do drag & drop with a GtkTreeView? The Tree View tutorial fizzles out on that issue. All I want to do is let the user use the mouse to shuffle round the order of items in a list - I don't require to drag anything to another widget in fact I wan

Re: Is it possible having different GtkAdjustment values in GtkTreeView

2008-12-09 Thread Tadej Borovšak
I forgot to explain why G_TYPE_OBJECT does not work in this situation. The GtkTreeModel is just an interface for GtkList/TreeStore objects and is not derived from GObject but from GInterface. So it is perfectly legal to use G_TYPE_INTERFACE instead GTK_TYPE_TREE_MODEL in my code. Another key funct

Re: Is it possible having different GtkAdjustment values in GtkTreeView

2008-12-09 Thread Tadej Borovšak
Hi. I've created a simple app that demonstrates some G(TK)_TYPE macro magic;) -- #include enum { MODEL_COL, NO_COLS }; static GtkTreeModel * create_and_fill_model (void) { GtkListStore *store; GtkListStore *model; GtkTreeIteriter; model = gtk_list_sto

Re: Is it possible having different GtkAdjustment values in GtkTreeView

2008-12-09 Thread Keedi Kim
Hi, guys. I have one more question about GtkTreeView. In my GtkTreeView, another column use GtkCellRenderCombo, and I tried store the GtkListStore (for GtkCellRenderCombo) using G_TYPE_OBJECT and set it up as an attribute ("model" -> list_store). But this doesn't seem work properly and warning o