Fixed some replace tool GUI bugs