improve formatting in display.py