fixing multi-line re-draw issue in the theme by printing first lines in the pre-cmd