def setTopRight(self, loc):
        """ Move this region so its top right corner is on ``loc`` """
        offset = self.getTopRight().getOffset(loc) # Calculate offset from current top right
        return self.setLocation(self.getTopLeft().offset(offset)) # Move top left corner by the same offset
def setTopRight ( self , loc ) : offset = self . getTopRight ( ) . getOffset ( loc ) return self . setLocation ( self . getTopLeft ( ) . offset ( offset ) )
Move this region so its top right corner is on ``loc``