[Qt-interest] Fixe text on a graphics view

Jan janusius at gmx.net
Wed Sep 16 20:50:09 CEST 2009


Hi,

you could install an eventFilter and when the parent receives a 
ResizeEvent in its eventFilter function you could move the Text item.

Bye
Jan

Vincent PREVOST schrieb:
> Hello,
> 
> I need to display a fixe text which I need to update each time the mousse
> move on the view. I need this text to be on a corner of the view, being all
> the time visible whenever I resize the view or scroll in the view. and
> finaly I need this text to be unchange when I change the scale of my view.
> 
> I've create a QGraphicsItem with the flag
> QGraphicsItem.ItemIgnoresTransformations set to True.
> 
> On my view, I update this item in the mousseMoveEvent but how can I manage
> to have this item in a corner whenever I change my view?
> 
> Thanks for your Help.
> 
> Vincent
> 
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest



More information about the Qt-interest-old mailing list