If I walk or run while I'm catching a Pokémon my character moves to the new location very quickly after the catch sequence is over, similarly as when moving by train or recovering from lost GPS. Are the meters I walked while catching still counted towards the Jogger medal, eggs and the 200m increased incense spawn rate?
To add onto the accepted answer, egg incubation will continue to progress when a menu, Pokestop, or egg-hatching screen is open, as well as during catching.
From this post, the way distance is calculated is it checks every minute. As long as you have moved less than 175 meters, the distance travelled will be accepted.