Hi,all

I am haveing a push button on which i want to print a text which is a 90* rotated.

i have tried using the QPainterPath and QPainter class as below.

QFont Times("times","30");
QPainter *painter;
QMatrix mat;
QPainterPath path,newpath,textpath;

textpath.addText(30,70,Times,tr('rotated TEXT"));
mat.rotate(90);
newpath.addPath(mat.map(textpath));
painter->drwaPath(newpath);


but its giving me 2 error:
(1)QPainter:Widget ,painting can only begin as a result og paint event;
(2)QPOinter ainter is not active


I have read the earlier problem like this ,but i am not able to find out the partilcular souluition.
please help.thanks to all.