public void InsertChild(Glyph glyph) { glyph.Parent = this; glyph.MainGlyph = MainGlyph; glyph.Redactor = Redactor; glyph.ParentVectorRedactor = ParentVectorRedactor; ParentVectorRedactor.Layout.AddFigure(glyph.Figure); Childs.Add(glyph); }
/* /// <summary> /// Загрузка конфигурации глифа /// </summary> /// <param name="config">Конфигурация</param> protected void LoadConfig(GlyphConfig config) { Redactor = config.Redactor; ParentVectorRedactor = config.VectorRedactor; } */ public void RemoveChild(Glyph glyph) { foreach (Glyph child in Childs.Where(child => child == glyph)) { child.ParentVectorRedactor.Layout.RemoveFigure(child.Figure); Childs.Remove(child); return; } throw new Exception("Child not exist"); }
private void Focus(Glyph glyph) { ActiveGlyph = glyph; Invalidate(); }