Пример #1
0
        public override String GetString(BaseStyleWindow window, int position)
        {
            StringBuilder builder = new StringBuilder();

            builder.Append("Color=");
            if (rbColorTypeFormat.IsChecked == true)
            {
                builder.Append("Format-");
                if (cbColorFormatType.SelectedIndex == 0)
                {
                    builder.Append("Green;");
                }
                else if (cbColorFormatType.SelectedIndex == 1)
                {
                    builder.Append("Blue;");
                }
                else if (cbColorFormatType.SelectedIndex == 2)
                {
                    builder.Append("Pink;");
                }
                else if (cbColorFormatType.SelectedIndex == 3)
                {
                    builder.Append("Diy-");
                    if (tbColorFormatDiy.Text.Trim().Equals(String.Empty))
                    {
                        tbColorFormatDiy.Focus();
                        return(null);
                    }
                    builder.Append(tbColorFormatDiy.Text.Trim() + ";");
                }
            }
            else if (rbColorTypeShape.IsChecked == true)
            {
                builder.Append("Shape-");
                if (cbColorShapeType.SelectedIndex == 0)
                {
                    if (cbColorShapeRadialOrientation.SelectedIndex == 0)
                    {
                        builder.Append("RadialVertical-");
                    }
                    else if (cbColorShapeRadialOrientation.SelectedIndex == 1)
                    {
                        builder.Append("RadialHorizontal-");
                    }
                }
                else if (cbColorShapeType.SelectedIndex == 1)
                {
                    builder.Append("Square-");
                }
                if (tbColorShapeNumber.Text.Trim().Equals(String.Empty))
                {
                    tbColorShapeNumber.Focus();
                    return(null);
                }
                builder.Append(tbColorShapeNumber.Text.Trim() + ";");
            }
            return(builder.ToString());
        }
Пример #2
0
 public virtual string GetString(BaseStyleWindow window, int position)
 {
     return("");
 }