Hi there, I've implementing a "zoom area" tool on a QGraphicsView, while dragging the mouse it draws the zoom area in a (visually) similar way as the RubberBandDrag selection area. I've looked into the source code of QGraphicsView but couldn't find which color is used to draw it. I've pinned down the QStyleOptionRubberBand and QStyleOption::OptionType but I don't get how I should use it. My naive implementation draws the area using a QGraphicsRectItem, but I've discovered that QGraphicsView draws the selection area using a painter in paintEvent() (after calling drawForeground()). What is the best way to draw the zoom area, should I handle this in drawForeground()? The code in QGraphicsView looks over-complicated to me compared with using a QGraphicsRectItem.
Any thought or advice? Chris _______________________________________________ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest