def find_next_sel(trans_sels, current_sel):
    for i, sel in enumerate(trans_sels):
        if sel.end() > current_sel.end():
            return i, trans_sels[i]

    # Rotate to the beginning if `current_sel` is after all other selections
    return 0, trans_sels[0]


#### Commands ####
Find the region in `trans_sels` that is right after `current_sel`.
dataset/ETHPy150Open MaokaiLin/PowerCursors/power_cursors.py/find_next_sel