|
@@ -119,7 +119,6 @@ namespace compdfkit_tools.Common
|
|
|
return false;
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
/// <summary>
|
|
|
/// 设置允许为空
|
|
|
/// </summary>
|
|
@@ -172,6 +171,41 @@ namespace compdfkit_tools.Common
|
|
|
private void OnColorChanged()
|
|
|
{
|
|
|
ColorChanged?.Invoke(this, null);
|
|
|
+ try
|
|
|
+ {
|
|
|
+ SolidColorBrush colorBrush = Brush as SolidColorBrush;
|
|
|
+ if (colorBrush != null)
|
|
|
+ {
|
|
|
+ if (colorBrush.Color == (TransparentBtn.Background as SolidColorBrush).Color)
|
|
|
+ {
|
|
|
+ TransparentBtn.IsChecked = true;
|
|
|
+ }
|
|
|
+
|
|
|
+ if (colorBrush.Color == (FirstBtn.Background as SolidColorBrush).Color)
|
|
|
+ {
|
|
|
+ FirstBtn.IsChecked = true;
|
|
|
+ }
|
|
|
+
|
|
|
+ if (colorBrush.Color == (SecondBtn.Background as SolidColorBrush).Color)
|
|
|
+ {
|
|
|
+ SecondBtn.IsChecked = true;
|
|
|
+ }
|
|
|
+
|
|
|
+ if (colorBrush.Color == (ThirdBtn.Background as SolidColorBrush).Color)
|
|
|
+ {
|
|
|
+ ThirdBtn.IsChecked = true;
|
|
|
+ }
|
|
|
+
|
|
|
+ if (colorBrush.Color == (FourthBtn.Background as SolidColorBrush).Color)
|
|
|
+ {
|
|
|
+ FourthBtn.IsChecked = true;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ catch (Exception ex)
|
|
|
+ {
|
|
|
+
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
private void ColorRadioButton_Click(object sender, RoutedEventArgs e)
|