Fixed width bugs in terminal code.