Results 1 to 3 of 3

Thread: QTableWidget + cellChanged(...)

  1. #1
    Join Date
    Jul 2008
    Posts
    9
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Question QTableWidget + cellChanged(...)

    Hi

    How can I determine the the two situations:
    - the content of QTableWidgetItem is changed from the code;
    - the content of QTableWidgetItem is changed by the user;

    I both situations I got cellChanged(int,int) signal.
    I want to get that signal only when user is changing the content by editing the item.

    I'm using QT 4.4.0.

    thx

    Ryszard

  2. #2
    Join Date
    Aug 2008
    Posts
    60
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: QTableWidget + cellChanged(...)

    > I both situations I got cellChanged(int,int) signal.
    > I want to get that signal only when user is changing the content by editing the item.

    You can use the 'notify' mechanism.
    When it calls the cellchanged() programmatically set notify flag to false, else let it be true.

    Hope it will help.

  3. #3
    Join Date
    Jul 2008
    Posts
    9
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QTableWidget + cellChanged(...)

    I made that mechanism already.
    But this is so uncomfortable.

    Really not exist any special signal emmited after user editing the item ?
    Some kind of 'EndEdit' ?

    thx
    Ryszard

    >> I both situations I got cellChanged(int,int) signal.
    >> I want to get that signal only when user is changing the content by editing the item.

    >You can use the 'notify' mechanism.
    >When it calls the cellchanged() programmatically set notify flag to false, else let it be true.

    >Hope it will help.

Similar Threads

  1. Crash in QTableWidget
    By ghorwin in forum Qt Programming
    Replies: 3
    Last Post: 29th October 2007, 16:57
  2. QComboBox in QTableWidget : display troubles.
    By Nyphel in forum Qt Programming
    Replies: 2
    Last Post: 13th October 2007, 23:29
  3. QTableWidget (resizing rows, turning off selection, etc.)
    By kiss-o-matic in forum Qt Programming
    Replies: 6
    Last Post: 11th January 2007, 01:57
  4. QTableWidget editing question
    By Trasmeister in forum Qt Programming
    Replies: 1
    Last Post: 20th September 2006, 18:46
  5. Replies: 6
    Last Post: 5th March 2006, 21:05

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.