Re: USB Device Dection?

2008-04-29 Thread Claudio Saavedra
El mié, 30-04-2008 a las 11:30 +0700, Soulivanh Anothay escribió: > > I like to write a simple application that it shall scan all USB > devices that are currently attached to the computer. > My question is, does anyone know of any C function or a linux system > call which I can use for scanning fo

USB Device Dection?

2008-04-29 Thread Soulivanh Anothay
Hello all, I like to write a simple application that it shall scan all USB devices that are currently attached to the computer. My question is, does anyone know of any C function or a linux system call which I can use for scanning for USB devices, and also report back the types of those devices, e

Re: How to put widget in CUSTOM GtkContainer

2008-04-29 Thread Tomas Carnecky
AlannY wrote: > Tomas Carnecky wrote: >> here you have to set GtkContainerClass->add, remove, forall and >> child_type. See >> http://svn.gnome.org/viewvc/gtk%2B/trunk/gtk/gtkbin.c?revision=19491&view=markup >> as an example of a widget that derives from GtkContainer. > > Since now, Yes

Re: How to put widget in CUSTOM GtkContainer

2008-04-29 Thread Tomas Carnecky
AlannY wrote: > Tomas Carnecky wrote: >> AlannY wrote: >> That still isn't the whole code! What does grid_class_init() do? Attach >> both the whole grid header and source file to the email. > > /* ** */ > > static void > grid_class_init (GridClass *cla

Re: How to put widget in CUSTOM GtkContainer

2008-04-29 Thread AlannY
Milosz Derezynski wrote: > I don't believe that using set_parent() will actually place the widget > inside the container; try gtk_container_add(GTK_CONTAINER(grid), > widget); instead I don't believe in it too ;-) So I decide to ask what to do ;-) gtk_container_add not works ;-)

Re: How to put widget in CUSTOM GtkContainer

2008-04-29 Thread AlannY
Tomas Carnecky wrote: > AlannY wrote: > That still isn't the whole code! What does grid_class_init() do? Attach > both the whole grid header and source file to the email. /* ** */ static void grid_class_init (GridClass *class) { GtkObjectClass *obje

Re: How to put widget in CUSTOM GtkContainer

2008-04-29 Thread Tomas Carnecky
AlannY wrote: > Hi there, my name is Alan and I have some troubles with GtkContainer. > > It's about 2 days, I already have spent trying to solve it, but I (i > guess) can't. > > I'm writing a program, which looks like: > +-+ > | Main Window (GtkWindow) | > | +---

How to put widget in CUSTOM GtkContainer

2008-04-29 Thread AlannY
Hi there, my name is Alan and I have some troubles with GtkContainer. It's about 2 days, I already have spent trying to solve it, but I (i guess) can't. I'm writing a program, which looks like: +-+ | Main Window (GtkWindow) | | +-+ | | | My

Re: GtkContainer problems

2008-04-29 Thread Tomas Carnecky
AlannY wrote: > Hello. > > I'm writing a custom widget. It's inherits from GtkContainer. So: > > typedef struct _MyWidgetMyWidget; > typedef struct _MyWidgetClass MyWidgetClass; > > struct _MyWidget > { >GtkContainer parent; > }; > > struct _MyWidgetClass > { >GtkConta

GtkContainer problems

2008-04-29 Thread AlannY
Hello. I'm writing a custom widget. It's inherits from GtkContainer. So: typedef struct _MyWidgetMyWidget; typedef struct _MyWidgetClass MyWidgetClass; struct _MyWidget { GtkContainer parent; }; struct _MyWidgetClass { GtkContainerClass parent_class; }; I'm wrote a smal