Re: [Interest] draw text and shape on an image using QGraphicsView

2012-07-16 Thread Mehmet İpek
I suggest you to create a QGraphicsTextItem in mousePressEvent function. Don't use QPainter to draw graphics if you are using QGraphicsView. Btw, your code shouldn't be compiled. QPainter constructor takes QPaintDevice* and you are giving QGraphicsScene* which is derived from QObject. On Sun, Jul

[Interest] draw text and shape on an image using QGraphicsView

2012-07-15 Thread Arun Kumar
Hello, I am trying to create a simple image editing tool using Qt GraphocsView I can load any image file to QGraphicsView now I am trying to add some text in loaded image. For that I subclass QGraphicsView and override mousePressEvent(QMouseEvent* event) I tried this code to draw a string o