Quote Originally Posted by jpn View Post
You shouldn't call QAbstractItemView::setDirtyRegion() inside paintEvent() because it schedules an update so you've got an infinite loop there. And QAbstractItemView:aintEvent() doesn't paint anything for you...

About the indexAt() crash, could you run the application via debugger and get a backtrace so that we know where the call comes from, please?

PS. What kind of view are you going to implement? Is it really something which cannot be achieved by customizing already existing views?
Ok I have deleted both undesirable calls above, which of course did not change the situation regarding the crash.
As for the crash, I tested my application on Ubuntu and...it does not crash! So probably an issue with my Mac Leopard version (I have Qt 4.3). So for the debugger trace which gdb command do you expect me to run and send you the trace? (I am not familiar with gdb). As I launch gdb I get the following output, which seems to exhibit somme problem in reading symbol information for Qt, may be due to the fact I did not build Qt with debugger options?

GNU gdb 6.3.50-20050815 (Apple version gdb-768) (Tue Oct 2 04:07:49 UTC 2007)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i386-apple-darwin"...
warning: Unable to read symbols for "QtGui.framework/Versions/4/QtGui" (file not found).

warning: Unable to read symbols for "QtCore.framework/Versions/4/QtCore" (file not found).
Reading symbols for shared libraries ........ done