@SGaist said in QAbstractItemDelegate.paint seems to be called with wrong option.rect:
Just thinking quickly, shouldn't you adjust the rect position based on the index row ?
In this case, images can have different aspect ratios, so I'd need ratio of each image before current one to calculate where to paint it. (It can be done, but seems to be going against design of delegate.)
More importantly, values of rect seem to still affect how mouse events are handled, so even if I'd adjust paintings, selecting element's would work on offsets defined by rect and click event's wouldn't work properly.
By the way, I think you should use QStyledItemDelegate as base class for your delegate since it's the default class used for the item views.
Thanks for the tip!