Replace control codes with friendly equivalents