swamptooth
Could be your preferences/project/clock ticks per quarter note isn't maxed out. Sonar only goes up to 960, so there may be some timing issues based on that as well.
960 ppq provides 500 microsecond resolution at 120 BPM, and I doubt keyboard players can play with that degree of accuracy. And even if they could, I think other variables in the computer (and the MIDI controller, assuming it has a scanned keyboard) would have greater impacts on resolution. With a hardware MIDI devices going through the 5-pin DIN connector, each note is about a millisecond apart so you'll get a minimum 10 ms spread among a chord played with both hands (plus more from the keyboard scanning times). Doing MIDI-over-USB gives much better results.
I did an interesting experiment on the Mac many, many years ago for
Keyboard magazine. Computer jitter increased linearly with higher resolution, so you had the same resolution whether you were recording at 48 ppqn or 1,024 ppqn! I'm sure things have improved since then...at least I hope so...