cleared the bug where Polylines would disappear
merging
reworked rectangle implementation, using matplotlib as backend now.