[prev in list] [next in list] [prev in thread] [next in thread] 

List:       pykde
Subject:    Re: [PyQt] QTableView in Editingstate
From:       Andreas Pakulat <apaku () gmx ! de>
Date:       2012-01-20 10:41:52
Message-ID: 20120120104152.GC21300 () neo ! apaku ! dnsalias ! org
[Download RAW message or body]

On 20.01.12 11:15:17, Daniel Benden wrote:
> Hi,
> 
> I hope to get some help with the following problem.
> 
> First a little situation sketch:
> I have a QTableView with a custom model (subclass from QAbstractTableModel) and a \
> custom itemdelegate(subclassed from QItemDelegate). The QItemDelegate provides for \
> two of the 5 columns an custom editor. For the other columns the default QLineEdit \
> is returned. The tableview is show using a QGraphicsProxyWidget is  QGrapicsView.
> 
> Now the problem:
> The problem is that after an editor is returned and the user can happely start to \
> input data. However while the QTableView is in EditingState it starts to poll the \
> model aggressivly by calling it's data method. This polling causes the editing to \
> slow down to a crawl ( Noticable because the keyboard input becomes more or less  \
> unresponsive). Is there a way to stop the polling while QtableView is in \
> EditingState ? Or am i doing something else horribly wrong ?

Without a crystal ball or some example code nobody can really tell :|

Things I'd suggest: Reduce your code to a small example still exhibiting
the problem and post that. Maybe replace the custom model with a
QStandardItemModel if possible. Try it without the graphicsview
rendering your table. Use the modeltest class on your model to see
wether it maybe returns wrong information that may cause the polling.
The modeltest is part of the Qt sources in the tests/auto directory.

Andreas

_______________________________________________
PyQt mailing list    PyQt@riverbankcomputing.com
http://www.riverbankcomputing.com/mailman/listinfo/pyqt


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic