[Qt-interest] Unnecessary Rounding from QRectF to GCRect?
Stephen Chu
stephen at ju-ju.com
Tue Mar 29 22:23:38 CEST 2011
In article <201103291411.p2TEBckx019752 at risley.esrtechnology.com>,
Sean Harmer <sean.harmer at maps-technology.com> wrote:
> On Tuesday 29 March 2011 09:44:43 Stephen Chu wrote:
> > Just find out this has much more impact than I originally thought.
> >
> > One part of my project is using QGraphicsScene with inches as the unit.
> > That is QPointF(1, 0) is 1 inch to the right of the origin. This makes
> > conversion between pixels and physical length simple since all
> > conversions are done inside of the items.
> >
> > That all works great until I tried it on the Mac. This rounding is
> > causing error up to 0.5 inch which in my case is typically 1200 pixels.
> >
> > I did file a bug for this and hope for a quick solution:
> > <http://bugreports.qt.nokia.com/browse/QTBUG-18416>
> >
> > Right now I am testing for graphics engine at runtime and switch to
> > QImage if it's Core Graphics. QImage doesn't have this rounding.
>
> Why not just patch your build of Qt if you already have a solution to the
> problem? You could also file a merge request on gitorious and mention it in
> your bug report. Bugs get fixed much more quickly if you also supply a fix ;-)
I don't really know how to do the patch/merger thing. git is still quite
new to me.
I also asked first to see if there's a know reason for it. Every thing
happens for a reason. :)
BTW. It's marked as fixed in the bug. Probably not pushed into the
public git yet.
--
Stephen Chu
More information about the Qt-interest-old
mailing list