[PyQt] Issue with selected cells in a QTableView

Vicent Mas uvemas at gmail.com
Fri Mar 11 11:27:19 GMT 2011


the attached script exhibits a strange behaviour which can be reproduced as 

- run the script and enlarge the table. Keep the vertical scrollbar visible
- select a range of cells with the mouse, for instance top_left=(0,2) and
- now drag the slider downwards until the selection disappears *completely* 
and upwards until it appears again
- now click on any unselected cell (or select a new range of cells). By doing 
it I expected that the complete selection would be cleared and the clicked 
cell would become current and selected. Instead only the previous current cell 
is deselected. The rest of the old selection remains selected and also the new 
clicked cell is selected and current
- repeat the previous step as many times as you want. The behaviour is always 
the same

Is this a bug or am I doing something wrong?

I'm using PyQt4.8.3 and Python 2.7 on a Debian testing box.




	Share what you know, learn what you don't

-------------- next part --------------
A non-text attachment was scrubbed...
Name: tableView.py
Type: text/x-python
Size: 2474 bytes
Desc: not available
URL: <http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20110311/0e52839b/attachment.py>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20110311/0e52839b/attachment.pgp>

More information about the PyQt mailing list