delete redundant parts from tooltip code