def format(self, x, y, width):
        leftGap, rightGap = determineGaps(width, self.width)

        # Hook up the two sides if self is narrower than its stated width.
        Path(x, y).h(leftGap).addTo(self)
        Path(x + leftGap + self.width, y).h(rightGap).addTo(self)
        x += leftGap

        # Draw item
        Path(x, y).right(ARC_RADIUS).addTo(self)
        self.item.format(x + ARC_RADIUS, y, self.width - (ARC_RADIUS * 2))
        Path(x + self.width - ARC_RADIUS, y + self.yAdvance).right(ARC_RADIUS).addTo(self)

        # Draw repeat arc
        distanceFromY = max(ARC_RADIUS * 2, self.item.down + VERTICAL_SEPARATION + self.rep.up)
        Path(x + ARC_RADIUS, y).arc('nw').down(distanceFromY - (ARC_RADIUS * 2)) \
            .arc('ws').addTo(self)
        self.rep.format(x + ARC_RADIUS, y + distanceFromY, self.width - (ARC_RADIUS * 2))
        Path(x + self.width - ARC_RADIUS, y + distanceFromY).arc('se') \
            .up(self.yAdvance - (ARC_RADIUS * 2) - distanceFromY).arc('en').addTo(self)
        self.item.addTo(self)
        self.rep.addTo(self)

        return self
dataset/ETHPy150Open tabatkins/bikeshed/bikeshed/railroaddiagrams.py/OneOrMore.format/swapped operands of `-`