I've seen a gelding try to mount a mare from the other side of a fence before and he was not proud cut. (ha ha, it was my Cobbers >.< ) So like everyone else has said if he hasn't got his dangley bits than he's a gelding.

Some geldings are just a bit more studdish than others.