Bug fix for pdf display