public ColorPickerDefinition(ToolboxLayoutDefinitionPaintToolsColorPickersColorPicker colorPickerDefinition, int scale)
{
this.Bounds = new Rectangle(
(int)colorPickerDefinition.Region.Location.X * scale,
(int)colorPickerDefinition.Region.Location.Y * scale,
colorPickerDefinition.Region.Size.Width * scale,
colorPickerDefinition.Region.Size.Height * scale);
this.BackgroundColor = new Color(
colorPickerDefinition.Region.BackgroundColor.Red,
colorPickerDefinition.Region.BackgroundColor.Green,
colorPickerDefinition.Region.BackgroundColor.Blue);
this.BorderColor = new Color(
colorPickerDefinition.Region.Border.Color.Red,
colorPickerDefinition.Region.Border.Color.Green,
colorPickerDefinition.Region.Border.Color.Blue);
this.BorderWidth = colorPickerDefinition.Region.Border.Width * scale;
}