public LabeledControlComponent(IDrawingContext parent, string label, BaseRenderComponent component) : base(parent) { this.label = label.ToCharArray(); this.component = component; component.SetParent(this); Width = component.Width + PADDING_RIGHT; }
public void AddChild(BaseRenderComponent child, AlignVertical alignment) { child.Width = Width; children.Add(new ComponentChild { alignment = alignment, component = child }); child.SetParent(this); LayoutInvalidate(); }
public BaseRenderComponent AddChild(BaseRenderComponent child, AlignHorizontal alignment) { child.Height = Height; children.Add(new ComponentChild { alignment = alignment, component = child }); child.SetParent(this); LayoutInvalidate(); return(child); }