replace deprecated convertBaseToScreen with convertRectToScreen