PDA

View Full Version : QRectF and drawText



aronsson
4th July 2006, 13:24
Hi
I was verry happy with Qt4 and it's posibilities to draw floats.
I have a widget where I'm painting coordinates that can be verry small so that the width of the bounding rect can be smaller that 1.0
But this has given me a fev problems.
First:
Drawing lines with a width of 2-3 pixels. if I set the width to 2 it covers the whole widget. The default is width = 0 and this makes the line 1 pixel wide.
Second and related:
If I draw text the text has a size of for example 8pt and this makes it cover the whole widget again. I want it to be 8 pixels in height.

thanks in advance for you answers.'

regards Andreas

jacek
4th July 2006, 17:05
QPainter::setWindow() might help you.