PDA

View Full Version : DragDrop function in Qt



cic
29th August 2013, 08:14
I want to implement a dragdrop function in my Qt App,
but I have no idea usually in Qt how I should start.

e.g. in the visual studio, I can drag one element with its content to the editor window:

9495

then i can drop this element there:

9496

I want my Qt App can be like the editor window, which reacts when an element comes to its area.
how i should start with Qt?

wagmare
29th August 2013, 08:31
http://qt-project.org/doc/qt-4.8/examples-draganddrop.html

especially draggable text
they use
void dragEnterEvent(QDragEnterEvent *event)
and
void dropEvent(QDropEvent *event)

cic
29th August 2013, 08:54
Thx :) thats what i need