Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. I want to drag a image from ListWidget and Drop inside the view port of QVTKOpenGLWidget

I want to drag a image from ListWidget and Drop inside the view port of QVTKOpenGLWidget

Scheduled Pinned Locked Moved Solved General and Desktop
3 Posts 2 Posters 503 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    amarism
    wrote on last edited by amarism
    #1

    I have done the item clicked event for listWIdget but know i want to drag a image from listwidget and drop to QVTKOpenGLWidget.
    for item clicked i will write some code :-

    void mainwindow::onThumbItemClicked(QListWidgetItem* item)
    {
    for (int i = 0; i < 6; i++)
    	{
    		if (this->ui->m_ThumblistWidget->item(i) == item)
    		{
    			SeriesChange(i);
    			LoadViewerComponents(false);
    		}
    	}
    }
    

    Know the same thind i want to do for drag and drop when i select image then i will call the same function again to change the series of image.

    It would be great if someone could guide me regarding this.

    Thank you in advance

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      You should start by the Using Drag and Drop with Item Views chapter of Qt's documentation.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      A 1 Reply Last reply
      2
      • SGaistS SGaist

        Hi,

        You should start by the Using Drag and Drop with Item Views chapter of Qt's documentation.

        A Offline
        A Offline
        amarism
        wrote on last edited by
        #3

        @SGaist I will try this one but still this one not working for me

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved