Gravity is not the hardest thing to do... Take a look at a basic particle engine for 3D and find out how it works it's basically the same.

In theory you just have 2 variables, one is the force the catapult gave to the projectile, say 10px (per frame, would be much though), to make it move up. Then there is our normal earth-gravity, say 4 px. Every second (or less) you just substract the earth-gravity from the force the projectile got from the catapult.

So after 1 second it moves up 10 - 4 = 6 pixels
after 2 seconds it moves up 6 - 4 = 2 pixels
after 3 seconds it moves up 2 - 4 = -2 pixels (so it moves down)

and so on and so on until you hit something or a minimum height is
reached and the projectile is destroyed

Of course I would use smaller time frames than seconds!