'Swap current window with closest window to the up'

def cmd_swap_right(self):

    win = self.clients.current_client
    (x, y) = (win.x, win.y)
    candidates = [c for c in self.clients if (c.info()['y'] < y)]
    target = self._get_closest(x, y, candidates)
    self.cmd_swap(win, target)
