PDA

View Full Version : Checking for intersect of QPainterPath OUTLINE?



SonOfGuest
10th May 2009, 21:58
Is there any way to check for the intersection of a point and a QPainterPath. This is a very basic function that should be provided by Qt.

The intesects() method says:

"Also returns true if the current path contains or is contained by any part of p."

I am creating a graphics editor and need to know if the mouse hovers ONLY OVER THE OUTLINE.

GDI+ has this. It is called IsOutlineVisible.

Also (bonus question!), is there a flatten() method available for QPainterPath which gives me the set of POINTS that make up the path, like in GDI+:

http://msdn.microsoft.com/en-us/library/system.drawing.drawing2d.graphicspath.flatten.aspx


Any ideas?

SonOfGuest
12th May 2009, 01:30
Anyone have any ideas...?