fix history text, selection text display bug