- // WARNING: setGeometry and setHeight should not be used without either:
- // a) calling prepareGeometryChange() immediately before setColumns()
- // b) calling Chatline::setPos() immediately afterwards
- inline void setGeometry(qreal width, qreal height) {
- _boundingRect.setWidth(width);
- _boundingRect.setHeight(height);
- }
- inline void setHeight(const qreal &height) {
- _boundingRect.setHeight(height);
- }
- inline void setWidth(const qreal &width) {
- _boundingRect.setWidth(width);
- }
+ inline void setGeometry(qreal width, qreal height) { clearCache(); _boundingRect.setSize(QSizeF(width, height)); }
+ inline void setHeight(const qreal &height) { clearCache(); _boundingRect.setHeight(height); }
+ inline void setWidth(const qreal &width) { clearCache(); _boundingRect.setWidth(width); }
+ inline void setPos(const QPointF &pos) { _boundingRect.moveTopLeft(pos); }