def shift_selected_points_y(glyph, delta, anchors=False, bPoints=True):
    # shift bPoints
    if bPoints:
        for c in glyph.contours:
            for p in c.bPoints:
                if p.selected:
                    # shift anchor point
                    px, py = p.anchor
                    py += delta
                    p.anchor = px, py
                    # shift handles
                    bcpIn_x, bcpIn_y = p.bcpIn
                    bcpOut_x, bcpOut_y = p.bcpOut
                    bcpIn_y += delta
                    bcpOut_y += delta
                    p.bcpIn = bcpIn_x, bcpIn_y
                    p.bcpOut = bcpOut_x, bcpOut_y
    # shift points
    else:
        for c in glyph.contours:
            for p in c.points:
                if p.selected:
                    p.y = p.y + delta
    # shift anchors
    if anchors:
        if len(glyph.anchors) > 0:
            for a in glyph.anchors:
                if mode is 1:
                    if a.y >= linePos:
                        a.y = a.y + delta
                else:
                    if a.y <= linePos:
                        a.y = a.y + delta
    # done
    glyph.update()

#---------------
# center glyphs
#---------------
Generator returning combinations of items from sequence <seq>
dataset/ETHPy150Open gferreira/hTools2/Lib/hTools2/modules/glyphutils.py/shift_selected_points_y--crossover with--dataset/ETHPy150Open muricoca/crab/scikits/crab/utils/extmath.py/combinations