Kinetic-energy spectroscopy of high-rydberg fragments from keV collisions of H2+, D2+, N2+ and C2+ ions with rare-gas atoms