Results 1 to 3 of 3

Thread: QListWidget signals?

  1. #1
    Join Date
    May 2008
    Posts
    25
    Thanks
    3
    Thanked 2 Times in 2 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QListWidget signals?

    Hi all,

    I'm having a weird problem, where none the QListWidget signals appear to be emitting

    Qt Code:
    1. connect(jobListLW,SIGNAL(itemClicked(QListWidgetItem * item)),this,SLOT(slotTest(QListWidgetItem * item)));
    To copy to clipboard, switch view to plain text mode 

    Should transfer me to the slotTest routine when I click or select an item in the List Widget, but nothing is happening.

    I checked and the item is Selectable and Enabled, but still nothing.

    Any thoughts as to what I've missed?

    R


    Added after 56 minutes:


    Actually, weirder still

    Only the currentRowChanged and itemSelectionChanged signals seem to be working.

    None of the ones that pass the item pointers seem to be working.

    R
    Last edited by cnbp173; 12th September 2012 at 19:17.

  2. #2
    Join Date
    Jul 2012
    Location
    Moscow
    Posts
    6
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: QListWidget signals?

    Quote Originally Posted by cnbp173 View Post
    Hi all,

    I'm having a weird problem, where none the QListWidget signals appear to be emitting

    Qt Code:
    1. connect(jobListLW,SIGNAL(itemClicked(QListWidgetItem * item)),this,SLOT(slotTest(QListWidgetItem * item)));
    To copy to clipboard, switch view to plain text mode 
    If I correctly understood, the signal doesn't reach the slot?
    In case of connection it is necessary to specify signals and slots with unnamed arguments, as it:
    Qt Code:
    1. connect(jobListLW, SIGNAL(itemClicked(QListWidgetItem*)), this, SLOT(slotTest(QListWidgetItem*)));
    To copy to clipboard, switch view to plain text mode 

    Look in an application output window, messages there are deduced if connection of the slot with a signal wasn't possible.
    War... war never changes...

  3. #3
    Join Date
    May 2008
    Posts
    25
    Thanks
    3
    Thanked 2 Times in 2 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QListWidget signals?

    Thanks.

    I had that, but wasn't working. Must have got lost along the way.

    Appreciate it.

    R

Similar Threads

  1. Replies: 4
    Last Post: 22nd March 2012, 17:07
  2. Replies: 2
    Last Post: 1st April 2011, 09:32
  3. Replies: 1
    Last Post: 24th October 2010, 11:09
  4. QListWidget and signals...
    By ouekah in forum Newbie
    Replies: 2
    Last Post: 2nd June 2010, 19:49
  5. QThread and signals (linux/UNIX signals not Qt Signals)
    By Micawber in forum Qt Programming
    Replies: 1
    Last Post: 28th November 2007, 22:18

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.