made trees adjust the width of containing elements

Added option for configuring autoadjust behavior