Some refactoring: created a base class for chart layouts (ChartBaseLayout) to make drawing graphics a little easier and more consistent.