Re: Difficult structure



Meghal Harish Varia <varia ecf utoronto ca> writes:
> 
> _______________________________________________
> |                             |               |
> |                             |               |
> |                             |               |
> |                             |     Buttons   |
> |                             |               |
> |                             |               |
> |      Drag Destination       |               |
> |                             |               |
> |                             |---------------|
> |                             |               |
> |                             |               |
> |                             |   Drag Source |
> |                             |               |
> |                             |               |
> -----------------------------------------------
> 
> >From this layout, you can see that items (rectangles) can be dragged from
> the source to the destination.  While being dragged, they can also go
> through the button space.
> 
> To make the whole area "draggable", I think I have to make it a
> GtkDrawingArea.. however, since the drawing area is not a container, how
> do I add the buttons?
> 

If you use the GTK drag and drop stuff, instead of manually
implementing dragging on a drawing area, it will solve the problem.
It is a bit tricky to figure out, but the testdnd.c example that comes
with GTK is reasonably straightforward.

Havoc




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