Create class Chart. Refactor all code. Increase flexibility the settings.
BugFix, add Tooltip
Preview commit
Fixed a bug with sub-chart and fixed other minor bugs.