'<path d="M130,135 v60"',
# 2
'<path d="M100,135 h30 v30 h-30 v30 h30"',
'<path d="M130,135 v60"',
# 2
'<path d="M100,135 h30 v30 h-30 v30 h30"',
- f.write(digits["top"][top] + ' fill="none" stroke-width="5" ' + ('stroke="red"' if colorTop == "white" else 'stroke="orange"') + '/>')
- f.write("\n")
- f.write(digits["bottom"][bottom] + ' fill="none" stroke-width="5" ' + ('stroke="red"' if colorTop == "black" else 'stroke="orange"') + '/>')
- f.write("\n")
+ if top >= 1:
+ f.write(digits["top"][top] + ' fill="none" stroke-width="5" ' + ('stroke="red"' if colorTop == "white" else 'stroke="orange"') + '/>')
+ f.write("\n")
+ if bottom >= 1:
+ f.write(digits["bottom"][bottom] + ' fill="none" stroke-width="5" ' + ('stroke="red"' if colorTop == "black" else 'stroke="orange"') + '/>')
+ f.write("\n")