PDA

View Full Version : QPointF == operator usage



sujan.dasmahapatra
3rd February 2010, 07:07
Dear Friends
I have two QPointF points and I want to compare them if they're equal....How can I use the non-member operator and check whether they're equal.

QPointF point1, point2;
QPointF::operator==(&point1,&point2);

is this correct ?

I'll appreciate if someone could help me !

high_flyer
3rd February 2010, 09:41
totally normal as you would with a natural type:
if(point1 == point2){
...
}

READ THE DOCS!
http://doc.trolltech.com/4.5/qpointf.html