auto resizing the gradient view programatically ref #6