Handle character keys, 'q' to quit