added correction of x and y for being in panel

added correction of x and y for being in panel