[Qt] qt tshapes arm
Paul Ishenin
ip at kmiac.ru
Wed Jun 18 02:31:15 CEST 2008
Terry Kemp wrote:
> Hi,
> can anyone help me understand a bit more about the GetWindowOrgEx and
> QMatrix stuff in qtwinapi.inc.
>
> I am trying to find out why TShapes are always drawn at 0,0 of the
> parent on arm machine (using project -qws not qtopia).
> its OK on host x11.
> If I have one (tshape) center of screen it gets drawn correct shape and
> size but at 0, 0. if I put one in the middle of a groupbox it goes to
> 0,0 of the groupbox.
>
> the extracts from enabling -dVerboseQtWinAPI -dVerboseQt are below. The
> problem is obviously the QMatrix_Dx and QMatrix_Dy returning garbage on
> arm but what is the likely cause of this?
>
> Any clues - anybody?
SetWindowOrgEx is a winapi compatibility function which moves your (0,0)
coord to another point. So all your drawings after that will be shifted
by that offset. Qt do the same by QPainter.translate method. We can
query offsets by accessing QPainter.Matrix which is QMatrix class. On
your arm QMatrix.dx and QMatrix.dy returns values which are very close
to zero - and I dont see any problem here. But maybe qt dont do matrix
transforms properly on arm? Or maybe we are passing incorrect values.
Is it possible to install emulator of your arm device and repeat the
same on usual pc?
Best regards,
Paul Ishenin.
More information about the Qt
mailing list