add a bunch of changes, autoadjust, contour drawing