Hi kitKat,
this is not that trivial as far as i know, but I think i can show you everything you need to solve your problem.
First you will need to find out the direction of the collision, this information is stored in the “contactNormal” vector which is available within the “fixture.onBeginContact:” signal. You can find a code sample in Ball.qml of the VPong demo game.
If you know from which side the entity is approaching the target, you can compare the x and y values to find out the “length” of the collision.
Let me know if this helped you. Also if you produce some nice code that could help other developers, feel free to post it here 😀
Cheers,
Alex