/// <summary> Draws the branches from this node to its children. /// </summary> /// <param name="canvas">The graphic canvas.</param> public override void DrawBranches(DrawingContext dc) { foreach (NodeView child in _childNodes) { Geodesic __geod = _geodesics[child]; if (__geod != null) { __geod.Draw(dc); } child.DrawBranches(dc); } }
/// <summary> Restores the hyperbolic tree to its origin. /// </summary> public override void Restore() { base.Restore(); foreach (NodeView child in _childNodes) { child.Restore(); Geodesic __geodesic = _geodesics[child]; if (__geodesic != null) { __geodesic.Rebuild(); } } }
/// <summary> Transform this node by the given transformation. /// </summary> /// <param name="t">The transformation.</param> public override void Transform(HyperbolicTransformation t) { base.Transform(t); foreach (NodeView child in _childNodes) { child.Transform(t); Geodesic __geodesic = _geodesics[child]; if (__geodesic != null) { __geodesic.Rebuild(); } } }
/// <summary> Translates this node by the given vector. /// </summary> /// <param name="t">The translation vector.</param> public override void Translate(EuclidianVector t) { base.Translate(t); foreach (NodeView child in _childNodes) { child.Translate(t); Geodesic __geodesic = _geodesics[child]; if (__geodesic != null) { __geodesic.Rebuild(); } } }
/// <summary> Refresh the screen coordinates of this node and recurse on children. /// </summary> /// <param name="origin">The origin of the screen plane.</param> /// <param name="max">The (xMax, yMax) point in the screen plane.</param> public override void RefreshScreenCoordinates(ScreenVector origin, ScreenVector max) { base.RefreshScreenCoordinates(origin, max); foreach (NodeView child in _childNodes) { child.RefreshScreenCoordinates(origin, max); Geodesic geod = _geodesics[child]; if (geod != null) { geod.RefreshScreenCoordinates(origin, max); } } }