dynamic height and font size for line chart