Are you saying Templars are at the front of the queue?
As long as there are no hotkey clashes you can cast the skills regardless of what combination of units you have selected at the time. Which is nice as it means that for the typical protoss army, force fields, storms and blinks are always ready for instant use.