fix:修复DataGrid控件报错导致渲染卡顿的问题: Cannot get 'CornerRadius' value (type 'CornerRadius') from '' (type 'DataGridCell'). BindingExpression:Path=(0); DataItem='DataGridCell' (Name=''); target element is 'Border' (Name=''); target property is 'CornerRadius' (type 'CornerRadius') InvalidOperationException:'System.InvalidOperationException: “8,0,8,0”不是属性“CornerRadius”的有效值

This commit is contained in:
尹志芳 authored and NaBian committed 2025-11-05 23:09:44 +08:00
1 parent fb2784f1d2
commit 440297f83c
2 files changed
+4 -4

No files matched your search

@@ -1,4 +1,4 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" <ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:hc="clr-namespace:HandyControl.Controls" xmlns:hc="clr-namespace:HandyControl.Controls"
xmlns:system="clr-namespace:System;assembly=mscorlib"> xmlns:system="clr-namespace:System;assembly=mscorlib">
@@ -36,7 +36,7 @@
<Setter Property="VerticalContentAlignment" Value="Center"/> <Setter Property="VerticalContentAlignment" Value="Center"/>
<Setter Property="HorizontalContentAlignment" Value="Stretch"/> <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
<Setter Property="Padding" Value="{StaticResource DefaultControlPadding}"/> <Setter Property="Padding" Value="{StaticResource DefaultControlPadding}"/>
<Setter Property="hc:BorderElement.CornerRadius" Value="{StaticResource DefaultInputPadding}"/> <Setter Property="hc:BorderElement.CornerRadius" Value="{StaticResource DefaultCornerRadius}"/>
<Setter Property="Template"> <Setter Property="Template">
<Setter.Value> <Setter.Value>
<ControlTemplate TargetType="DataGridCell"> <ControlTemplate TargetType="DataGridCell">
@@ -1,4 +1,4 @@
<!-- <!--
This code was generated by a tool. This code was generated by a tool.
Changes to this file may cause incorrect behavior and will be lost if Changes to this file may cause incorrect behavior and will be lost if
@@ -11943,7 +11943,7 @@
<Setter Property="VerticalContentAlignment" Value="Center" /> <Setter Property="VerticalContentAlignment" Value="Center" />
<Setter Property="HorizontalContentAlignment" Value="Stretch" /> <Setter Property="HorizontalContentAlignment" Value="Stretch" />
<Setter Property="Padding" Value="{StaticResource DefaultControlPadding}" /> <Setter Property="Padding" Value="{StaticResource DefaultControlPadding}" />
<Setter Property="hc:BorderElement.CornerRadius" Value="{StaticResource DefaultInputPadding}" /> <Setter Property="hc:BorderElement.CornerRadius" Value="{StaticResource DefaultCornerRadius}" />
<Setter Property="Template"> <Setter Property="Template">
<Setter.Value> <Setter.Value>
<ControlTemplate TargetType="DataGridCell"> <ControlTemplate TargetType="DataGridCell">