protected override void CreateChildElements() { base.CreateChildElements(); this.colorBox = new ColorEditorColorBox(); int num = (int)this.colorBox.SetDefaultValueOverride(RadElement.MarginProperty, (object)new Padding(2)); this.colorBox.BorderGradientStyle = GradientStyles.Solid; this.Children.Add((RadElement)this.colorBox); }
protected override void CreateChildElements() { base.CreateChildElements(); this.converter = TypeDescriptor.GetConverter(typeof(Color)); this.stack = new StackLayoutElement(); this.stack.StretchHorizontally = true; this.stack.StretchVertically = true; this.stack.Class = "ColorBoxLayout"; this.stack.FitInAvailableSize = true; this.stack.ShouldHandleMouseInput = false; this.Children.Add((RadElement)this.stack); this.colorBox = this.CreateColorBoxElement(); this.colorDialog = this.CreateColorDialog(); this.colorPickerButton = this.CreateColorPickerButtonElement(); this.WireEvents(); }
protected override void CreateChildElements() { base.CreateChildElements(); this.colorBox = new ColorEditorColorBox(); this.contentElement = new PropertyGridContentElement(); this.contentElement.DrawBorder = false; this.contentElement.DrawFill = false; this.contentElement.DrawText = true; this.contentElement.StretchHorizontally = true; StackLayoutElement stackLayoutElement = new StackLayoutElement(); stackLayoutElement.Orientation = Orientation.Horizontal; stackLayoutElement.FitInAvailableSize = true; stackLayoutElement.AutoSizeMode = RadAutoSizeMode.FitToAvailableSize; stackLayoutElement.Padding = new Padding(3); stackLayoutElement.Alignment = ContentAlignment.MiddleLeft; stackLayoutElement.Children.Add((RadElement)this.colorBox); stackLayoutElement.Children.Add((RadElement)this.contentElement); this.ValueElement.Children.Add((RadElement)stackLayoutElement); this.ValueElement.DrawText = false; }