Most has already been answered but as my name was invoked for some odd reason (wouldn't Pyro or HT the better ones for such questions?), I will still go through it.
Is machine guns and cannon rounds counted the same way?
Almost. The practical difference is that cannon rounds are also creating a blast damage, so that you also can get a 'hit' when not hitting your target directly, which comes into play at vulching.
If you die do the rounds left in your plane count? If I land do the the rounds left count?
Hell no. You think anybody would ever fly the P-47 again?

Is it simply rounds fired versus rounds hitting the target?
Basically yes.
In fighter mode do rounds hitting ground targets or objects count like they do in attack mode or only rounds hitting planes?
Objects do not count in fighter mode.
However, I
think that hit's on player driven ground targets (=vehicles)
do count, but don't quote me on that

If I hit a bomber or plane , I chop their wing off but they are still in the plane do rounds hitting that plane after critical damage has been done but before kill has been registered count?
I don't think so.