Btw, inside getRect(qreal) you are calling getRect() without using its return value.
The OP is using the side effects of getRect() to set the member variables used later. This will be problematic for declaring these methods as const...

On the other hand, this can't be the real code, because most of the methods implemented in the "Source code" don't even appear in the header.