On Saturday 30 July 2011 22:05:41 Martin Airs wrote: > Good evening all, > > I'm trying to create a very simple chat window, with a QLineEdit at the > bottom and a box above for the text. > > however when enter is pressed in the QLineEdit, I would like the text to be > put into the box at the bottom just out of view, and then scrolled smoothly > upward into view, preferably with an easing curve. > > I thought about using a QGraphicsView and QGraphicsScene and having each > line of text as a QGraphicsSimpleTextItem or a QGraphicsTextItem whichever > supports word wrap, that way i could put the text on the scene just out > view. > > but then is it possible to move the whole scene up smoothly to bring the > text into view, or would it be better to select all the items on the scene > and move them up leaving the scene static. > > is there an even simpler way using a scrollview of some kind, or am I just > barking up the wrong tree completely. > > I hope this doesn't sound too confusing, but I wonder if someone with a bit > more experience than me could suggest and easy way of doing it. > > Thankyou very much in advance > > Martin
well I managed to achieve what I was after, I used a scene and graphicsTextItem's in the end here's a little vid, http://airs.me.uk/Videos/chatwindow.ogv its not 100% finished obviously, but you get the idea Martin _______________________________________________ PyQt mailing list PyQt@riverbankcomputing.com http://www.riverbankcomputing.com/mailman/listinfo/pyqt