     h = symbol.textWidth(pin.name, 'pin') + space
     x1 = x - dx
     x2 = x + dx
-    if y > (-h - space) then y = -h - space
     x += step
     topRects.push
       x1: x1,

    h = symbol.textWidth(pin.name, 'pin') + space
    x1 = x - dx
    x2 = x + dx
    if y < (h + space) then y = h + space
    x += step
    bottomRects.push
      x1: x1,

  x = leftX
  dy = settings.fontSize.pin/2 + space
  leftPins = []
  leftRects = []
  y = -step * left.length/2 + step/2
  for i in left
    if i is '-'
