Pixmap, Box and Button problem



	Hi guys, I'm trying to develop a Window Maker dock app with gtk,
and a problem apeered. My dock is already full working, but i can't put
both a button and a box on the dock area.

	With the code this way:

	-----------------------
        button = gtk_button_new ();

        gtk_signal_connect_object(GTK_OBJECT(button),
                        "event",
                        GTK_SIGNAL_FUNC(button_press),
                        GTK_OBJECT(button));

        box1 = xpm_label_box(dockArea, "info.xpm", "");

        gtk_widget_show(box1);
        gtk_container_add (GTK_CONTAINER (button), box1);

        gtk_widget_show(button);
        gtk_container_add (GTK_CONTAINER (dockArea), button);

        gtk_widget_show(dockArea);
        gtk_widget_show(gtkiw);

        gtk_main ();
	-----------------------

	Everything works, but I get no icon in the little window.


	But....


	If I change the line

		gtk_container_add (GTK_CONTAINER (button), box1);

	by

		gtk_container_add (GTK_CONTAINER (dockArea), box1);


	The icon apeers, but the mouse actions does not work anymore.



	Any hint. As I'm a newbie to gtk programming (just some hours) any
help is welcome.

-- 
[]s Rafael.
3wt - Wireless Web World Technologies
A Division of GDS Corporation




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]