When user resizes TreeControl or uses some of Zoom functions, graph is repainted . Graph changes its scale while beeing resized. Functions responsible for resizing are: ZoomIn(), ZoomOut(),ZoomInX(),ZoomOutX(),ZoomInY(),ZoomOutY(), FitToWindow(),SetFitWhenResize() in TreeControl class. These functions use treeStructure.SetSizeOfControl() method to count new dimensions of graph.