DataGrid 类

定义

表示用于在可自定义的网格中显示数据的控件。Represents a control that displays data in a customizable grid.

public ref class DataGrid : System::Windows::Controls::Primitives::MultiSelector
public class DataGrid : System.Windows.Controls.Primitives.MultiSelector
type DataGrid = class
    inherit MultiSelector
Public Class DataGrid
Inherits MultiSelector
继承

示例

下面的示例演示如何将 DataGrid 绑定到 DataTable 并使用自动生成列。The following example shows how to bind a DataGrid to a DataTable and use column auto-generation. DataTable 是使用 DataSetDataAdapterFill 方法填充的。The DataTable is populated by using the Fill method of a DataAdapter from a DataSet. 有关详细信息,请参阅创建数据集从 DataAdapter 填充数据集For more information, see Creating a DataSet and Populating a DataSet from a DataAdapter. 若要使用 适用于 Visual Studio 的 WPF 设计器WPF Designer for Visual Studio,请参阅在 Visual Studio 中将 WPF 控件绑定到数据To use the 适用于 Visual Studio 的 WPF 设计器WPF Designer for Visual Studio, see Bind WPF controls to data in Visual Studio.

<DataGrid x:Name="CustomerGrid" ItemsSource="{Binding}" AlternatingRowBackground="LightBlue" AlternationCount="2" />
//Set the DataGrid's DataContext to be a filled DataTable
CustomerGrid.DataContext = custDataTable;
'Set the DataGrid's DataContext to be a filled DataTable
CustomerGrid.DataContext = custDataTable

下面的示例演示如何使用自定义 Columns 集合创建 DataGridThe following example shows how to create a DataGrid with a customized Columns collection.

    <NavigationWindow x:Class="DataGrid_CustomColumns.Window1"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:core="clr-namespace:System;assembly=mscorlib"
        xmlns:local="clr-namespace:DataGrid_CustomColumns"
        Title="Customers" Height="300" Width="300" ShowsNavigationUI="False"  >
        
    <NavigationWindow.Resources>
        <!--Create list of enumeration values-->
        <ObjectDataProvider x:Key="myEnum" MethodName="GetValues" ObjectType="{x:Type core:Enum}">
            <ObjectDataProvider.MethodParameters>
                <x:Type Type="local:OrderStatus"/>
            </ObjectDataProvider.MethodParameters>
        </ObjectDataProvider>
        <!--Create an instance of the converter for Email-->
        <local:EmailConverter x:Key="EmailConverter" />
    </NavigationWindow.Resources>
    <NavigationWindow.Content>  
        
    <Grid>
        <DataGrid Name="DG1" ItemsSource="{Binding}" AutoGenerateColumns="False" >
            <DataGrid.Columns>
                <DataGridTextColumn Header="First Name"  Binding="{Binding FirstName}"/>
                <DataGridTextColumn Header="Last Name" Binding="{Binding LastName}" />
                <!--The Email property contains a URI.  For example "mailto:lucy0@adventure-works.com"-->
                <DataGridHyperlinkColumn Header="Email" Binding="{Binding Email}"  ContentBinding="{Binding Email, Converter={StaticResource EmailConverter}}" />
                <DataGridCheckBoxColumn Header="Member?" Binding="{Binding IsMember}" />
                <DataGridComboBoxColumn Header="Order Status"  SelectedItemBinding="{Binding Status}" ItemsSource="{Binding Source={StaticResource myEnum}}" />
            </DataGrid.Columns>
        </DataGrid>
    </Grid>
    </NavigationWindow.Content>
</NavigationWindow>
//Additional using statements
using System.Data;
using System.Collections.ObjectModel;
using System.Diagnostics;
'Additional using statements
Imports System.Data
Imports System.Collections.ObjectModel
Imports System.Diagnostics
public partial class Window1 : NavigationWindow
{
Class Window1
public Window1()
{
    InitializeComponent();

    //GetData() creates a collection of Customer data from a database
    ObservableCollection<Customer> custdata = GetData();
    
    //Bind the DataGrid to the customer data
    DG1.DataContext = custdata;
}
Public Sub New()
    ' This call is required by the Windows Form Designer.
    InitializeComponent()
    ' Add any initialization after the InitializeComponent() call.

    'GetData() creates a collection of Customer data from a database
    Dim custdata As ObservableCollection(Of Customer) = GetData()

    'Bind the DataGrid to the customer data
    DG1.DataContext = custdata

End Sub
//Defines the customer object
public class Customer
{
    public string FirstName { get; set; }
    public string LastName { get; set; }
    public Uri Email { get; set; }
    public bool IsMember { get; set; }
    public OrderStatus Status { get; set; }
}
'Defines the customer object
Public Class Customer
    Public Property FirstName() As String
    Public Property LastName() As String
    Public Property Email() As Uri
    Public Property IsMember() As Boolean
    Public Property Status() As OrderStatus
End Class
}
End Class
public enum OrderStatus { None, New, Processing, Shipped, Received };
Public Enum OrderStatus
    None
    [New]
    Processing
    Shipped
    Received
End Enum
//Converts the mailto uri to a string with just the customer alias
public class EmailConverter : IValueConverter
{
    public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
    {
        if (value != null)
        {
            string email = value.ToString();
            int index = email.IndexOf("@");
            string alias = email.Substring(7, index-7);
            return alias;
        }
        else
        {
            string email = "";
            return email;
        }
    }

    public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
    {
        Uri email = new Uri((string)value);
        return email;
    }
}
'Converts the mailto uri to a string with just the customer alias
Public Class EmailConverter
    Implements IValueConverter

    Public Function Convert(value As Object, targetType As System.Type, parameter As Object, culture As System.Globalization.CultureInfo) As Object Implements System.Windows.Data.IValueConverter.Convert
        If value IsNot Nothing Then
            Dim email As String = value.ToString()
            Dim index As Integer = email.IndexOf("@")
            Dim [alias] As String = email.Substring(7, index - 7)
            Return [alias]
        Else
            Dim email As String = ""
            Return email
        End If
    End Function

    Public Function ConvertBack(value As Object, targetType As System.Type, parameter As Object, culture As System.Globalization.CultureInfo) As Object Implements System.Windows.Data.IValueConverter.ConvertBack
        Dim email As New Uri(DirectCast(value, String))
        Return email
    End Function
End Class

注解

DataGrid 控件提供了一种灵活的方法,可在行和列中显示数据的集合。The DataGrid control provides a flexible way to display a collection of data in rows and columns. DataGrid 包括内置列类型和用于承载自定义内容的模板列。The DataGrid includes built-in column types and a template column for hosting custom content. 内置行类型包括下拉详细信息部分,可用于显示单元值下面的附加内容。The built-in row type includes a drop-down details section that you can use to display additional content below the cell values.

绑定到数据Binding to Data

若要将 DataGrid 绑定到数据,请将 ItemsSource 属性设置为 IEnumerable 实现。To bind the DataGrid to data, set the ItemsSource property to an IEnumerable implementation. 数据网格中的每一行都绑定到数据源中的某个对象,数据网格中的每一列都绑定到该数据对象的属性。Each row in the data grid is bound to an object in the data source, and each column in the data grid is bound to a property of the data object. 为了使 DataGrid 用户界面在源数据中添加或删除项时自动更新,DataGrid 必须绑定到实现 INotifyCollectionChanged 接口的集合,例如 ObservableCollection<T>In order for the DataGrid user interface to update automatically when items are added to or removed from the source data, the DataGrid must be bound to a collection that implements the INotifyCollectionChanged interface, such as an ObservableCollection<T>. 若要自动反映属性更改,源集合中的对象必须实现 INotifyPropertyChanged 接口。To automatically reflect property changes, the objects in the source collection must implement the INotifyPropertyChanged interface. 有关详细信息,请参阅数据绑定(WPF)For more information, see Data Binding (WPF).

Columns

默认情况下,当您设置 ItemsSource 属性时,DataGrid 控件将自动生成列。By default, the DataGrid control generates columns automatically when you set the ItemsSource property. 所生成的列的类型取决于列中数据的类型。The type of column that is generated depends on the type of data in the column. 下表列出了生成的列类型。The following table lists the generated columns types.

生成的列类型Generated Column Type 数据类型Data Type
DataGridTextColumn String
DataGridCheckBoxColumn Boolean
DataGridComboBoxColumn Enum
DataGridHyperlinkColumn Uri

下图显示了每个列类型。The following illustration shows each of the column types.

具有所有四种默认列类型的 DataGridDataGrid with all four default column types

自动生成列后,您可以处理 AutoGeneratingColumn 事件,以便在将列添加到 DataGrid之前对其进行自定义或取消。When columns are auto-generated, you can handle the AutoGeneratingColumn event to customize or cancel columns before they are added to the DataGrid. 如果将用户定义的列和自动生成的列添加到 DataGrid,则首先添加用户定义的列。If you add both user-defined columns and auto-generated columns to the DataGrid, the user-defined columns are added first. 若要重新排列列的显示顺序,可以设置单个列的 DisplayIndex 属性。To rearrange the display order of the columns, you can set the DisplayIndex property for individual columns.

可以通过将 AutoGenerateColumns 属性设置为 false来阻止自动生成列。You can prevent automatic column generation by setting the AutoGenerateColumns property to false. 如果要显式创建和配置所有列,这很有用。This is useful if you want to create and configure all columns explicitly.

如果内置列类型不能满足您的需要,请使用 DataGridTemplateColumn 类型定义自定义列。Use the DataGridTemplateColumn type to define a custom column if the built-in column types do not meet your needs. DataGridTemplateColumn 类型提供了 CellTemplateCellEditingTemplate 属性,使你能够为显示模式和编辑模式指定内容模板。The DataGridTemplateColumn type provides CellTemplate and CellEditingTemplate properties that enable you to specify content templates for both display and editing modes. 例如,您可以为日期定义自定义列。For example, you could define a custom column for dates. CellTemplate 可以定义一个 TextBlock 来显示日期,CellEditingTemplate 可以定义一个 DatePicker 控件以编辑该日期。The CellTemplate could define a TextBlock to display a date, and the CellEditingTemplate could define a DatePicker control to edit the date.

您可以使用 Columns 集合以编程方式在运行时添加、插入、删除和更改控件中的任何列。You can use the Columns collection to programmatically add, insert, remove, and change any columns in the control at run time. 检查 IsAutoGenerated 属性,以确定是否自动生成列或用户定义的列。Check the IsAutoGenerated property to determine whether a column is auto generated or user defined. ItemsSource 更改时,自动生成的列将自动添加、删除或重新生成。Auto-generated columns will be automatically added, removed, or regenerated when the ItemsSource changes.

选择Selection

默认情况下,当用户单击 DataGrid中的单元格时,将选择整行,用户可以选择多个行。By default, the entire row is selected when a user clicks a cell in a DataGrid, and a user can select multiple rows. 您可以设置 "SelectionUnit" 属性以指定用户是否可以选择单元格、整行或同时选择两者。You can set the SelectionUnit property to specify whether a user can select cells, full rows, or both. 设置 "SelectionMode" 属性可指定是否可以选择多个行或单元,或只选择单个行或单元。Set the SelectionMode property to specify whether multiple rows or cells can be selected, or only single rows or cells.

可以从 SelectedCells 属性获取有关所选单元格的信息。You can get information about the cells that are selected from the SelectedCells property. 可以在 SelectedCellsChanged 事件的 SelectedCellsChangedEventArgs 中获取有关所选内容已更改的单元格的信息。You can get information about cells for which selection has changed in the SelectedCellsChangedEventArgs of the SelectedCellsChanged event. 调用 SelectAllCellsUnselectAllCells 方法以编程方式选择或取消选择所有单元格。Call the SelectAllCells or UnselectAllCells methods to programmatically select or unselect all cells. 有关详细信息,请参阅DataGrid 控件中的默认键盘和鼠标行为For more information, see Default Keyboard and Mouse Behavior in the DataGrid Control.

分组、排序和筛选Grouping, Sorting, and Filtering

默认情况下,您可以通过单击列标题对 DataGrid 中的项进行排序。By default, you can sort items in a DataGrid by clicking the column header. 可以通过处理 Sorting 事件自定义排序。You can customize sorting by handling the Sorting event. 若要取消默认排序,请将 Handled 属性设置为 trueTo cancel the default sort, set the Handled property to true. 还可以对源数据进行排序,然后将其显示在 DataGrid中。You can also sort the source data before it is displayed in the DataGrid.

若要在 DataGrid中对数据进行分组、排序和筛选,请将 DataGrid 绑定到支持这些操作的 ICollectionView 实现。To group, sort, and filter data in the DataGrid, you bind the DataGrid to an ICollectionView implementation that supports these operations. 然后,对集合视图执行操作。You then perform the operations on the collection view. DataGrid中对项进行分组时,可以定义一个指定每个组的外观的 GroupStyleWhen items are grouped in the DataGrid, you can define a GroupStyle that specifies the appearance of each group. 可以通过将 GroupStyle 添加到 DataGridGroupStyle 集合来应用该。You apply the GroupStyle by adding it to the GroupStyle collection of the DataGrid. 如果有多个级别的分组,则可以对每个组级别应用不同的样式。If you have multiple levels of grouping, you can apply different styles to each group level. 样式按其定义顺序进行应用。Styles are applied in the order in which they are defined. 有关详细信息,请参阅如何:在 DataGrid 控件中对数据进行分组、排序和筛选For more information, see How to: Group, Sort, and Filter Data in the DataGrid Control.

编辑Editing

默认情况下,你可以直接在 DataGrid中编辑项。By default, you can edit items directly in the DataGrid. 为了保证可以正确提交和取消编辑,DataGrid 中的对象必须实现 IEditableObject 接口。To guarantee that edits can be committed and canceled correctly, the objects in the DataGrid must implement the IEditableObject interface. 或者,你可以将 IsReadOnly 属性设置为 true 以禁用 DataGrid中的编辑。Alternatively, you can set the IsReadOnly property to true to disable editing in the DataGrid.

DataGrid 对以下编辑命令提供内置支持:The DataGrid has built-in support for the following editing commands:

CommandCommand 默认输入绑定Default Input Binding
BeginEditCommand F2F2
CancelEditCommand ESCESC
CommitEditCommand EnterENTER
DeleteCommand 删除DELETE

通过单击或按 F2,将当前的单元格置于编辑模式。You put the current cell into edit mode by clicking it or pressing F2. 当您移动到同一行中的另一个单元格,或在单元格处于编辑模式时按 ENTER 键时,将提交单元格级别的编辑。A cell-level edit is committed when you move to another cell in the same row or press ENTER while the cell is in edit mode. 如果行处于编辑模式,则在移到另一行或按 ENTER 键时,将提交行中的所有编辑。All edits in a row are committed when you move to another row or press ENTER while the row is in edit mode. 您可以通过按 ESC 一次来取消单元格编辑,并通过按 ESC 两次取消行中的所有编辑。You cancel a cell edit by pressing ESC one time, and cancel all edits in a row by pressing ESC two times. 有关以编程方式提交和取消编辑的详细信息,请参阅 BeginEditCommitEditCancelEdit 方法。For more information about programmatically committing and canceling edits, see the BeginEdit, CommitEdit, and CancelEdit methods. 有关编辑相关事件的详细信息,请参阅 BeginningEditPreparingCellForEditCellEditEndingRowEditEndingFor more information about edit-related events, see BeginningEdit, PreparingCellForEdit, CellEditEnding, and RowEditEnding.

设置 "CanUserAddRows" 和 "CanUserDeleteRows" 属性以指定用户是否可以添加或删除行。Set the CanUserAddRows and CanUserDeleteRows properties to specify whether a user can add or delete rows. 用户可以通过按 DELETE 键删除选定行。A user can delete selected rows by pressing the DELETE key. 如果 CanUserAddRows 属性设置为 true,则会将新的项行添加为 DataGrid中的最后一行。If the CanUserAddRows property is set to true, a new item row is added as the last row in the DataGrid. 可以通过处理 InitializingNewItem 事件来设置新项的默认值。You can set default values for new items by handling the InitializingNewItem event.

备注

是否允许编辑操作受到各种其他因素的影响,这些因素包括 DataGridIsReadOnlyIsEnabled 状态,以及基础数据集合是否允许操作。Whether editing actions are allowed is influenced by a variety of additional factors, including the IsReadOnly and IsEnabled state of the DataGrid, and whether the underlying data collection allows the action.

验证Validation

DataGrid 允许在单元和行级别执行验证。The DataGrid enables you to perform validation at both the cell and row level. 使用单元格级验证时,可以在用户更新值时验证绑定数据对象的各个属性。With cell-level validation, you validate individual properties of a bound data object when a user updates a value. 通过行级验证,用户将更改提交到行时,可以验证整个数据对象。With row-level validation, you validate entire data objects when a user commits changes to a row. 您可以通过设置 "RowValidationErrorTemplate" 属性为行级验证错误提供自定义的可视反馈,也可以使用默认的错误指示器。You can provide customized visual feedback for row-level validation errors by setting the RowValidationErrorTemplate property, or you can use the default error indicator. 若要创建自定义验证规则,请创建一个派生自 ValidationRule 类并实现 Validate 方法的类。To create a custom validation rule, create a class that derives from the ValidationRule class and implement the Validate method. 将自定义验证规则添加到 RowValidationRules 集合。Add the custom validation rule to the RowValidationRules collection.

自定义 DataGrid 控件Customizing the DataGrid Control

DataGrid 控件支持常用的表格式设置选项,如交替行背景以及显示或隐藏标题、网格线和滚动条的功能。The DataGrid control supports common table formatting options, such as alternating row backgrounds and the ability to show or hide headers, gridlines, and scroll bars. 此外,控件提供了若干样式和模板属性,您可以使用这些属性来完全更改控件及其行、列、标题和单元格的外观。Additionally, the control provides several style and template properties that you can use to completely change the appearance of the control and its rows, columns, headers, and cells.

若要自定义 DataGrid 行为,你可以处理更改所选内容、单元格编辑和列重新排序的事件。To customize DataGrid behavior, you can handle events for selection change, cell editing, and column re-ordering. DataGrid 还公开了若干行回收事件,您可以处理这些事件来自定义行。The DataGrid also exposes several events for row recycling that you can handle to customize rows.

若要对多个 DataGrid 控件应用相同的属性设置,请使用 Style 属性。To apply the same property settings to multiple DataGrid controls, use the Style property. 您可以修改默认 ControlTemplate 以使控件具有独特的外观。You can modify the default ControlTemplate to give the control a unique appearance. 有关创建 ControlTemplate的详细信息,请参阅通过创建 System.windows.controls.controltemplate> 自定义现有控件的外观For more information about creating a ControlTemplate, see Customizing the Appearance of an Existing Control by Creating a ControlTemplate. 若要查看特定于 DataGrid的部分和状态,请参阅DataGrid 样式和模板To see the parts and states that are specific to the DataGrid, see DataGrid Styles and Templates.

此控件的依赖属性可能由控件的默认样式设置。Dependency properties for this control might be set by the control's default style. 如果按默认样式设置属性,则当控件出现在应用程序中时,属性可能会更改为默认值。If a property is set by a default style, the property might change from its default value when the control appears in the application. 默认样式取决于应用程序运行时使用的桌面主题。The default style is determined by which desktop theme is used when the application is running. 有关详细信息,请参阅默认的 WPF 主题For more information, see Default WPF Themes.

备注

只有视觉对象属性已存在于控件的默认模板中并且已使用 TemplateBinding 设置时,设置该属性才有效。Setting a visual property only has an effect if that property is both present in the control's default template and is set by using a TemplateBinding. 通过创建 ControlTemplate 自定义现有控件的外观一文的更改控件的视觉结构部分可以找到视觉属性列表。You can find a list of visual properties in the Changing the Visual Structure of a Control section in the Customizing the Appearance of an Existing Control by Creating a ControlTemplate article.

常见任务Common Tasks

下表提供了有关通常与 DataGrid相关联的任务的信息。The following table provides information about tasks that are typically associated with the DataGrid.

任务Task 实现Implementation
设置交替行背景色Set alternating row background colors AlternationIndex 属性设置为2或更大,然后将 Brush 分配到 RowBackgroundAlternatingRowBackground 属性。Set the AlternationIndex property to 2 or more, and then assign a Brush to the RowBackground and AlternatingRowBackground properties.
定义单元格和行选择行为Define cell and row selection behavior 设置 SelectionModeSelectionUnit 属性。Set the SelectionMode and SelectionUnit properties.
自定义标题、单元和行的视觉外观Customize the visual appearance of headers, cells and rows 将新 Style 应用于 ColumnHeaderStyleRowHeaderStyleCellStyleRowStyle 属性。Apply a new Style to the ColumnHeaderStyle, RowHeaderStyle, CellStyle, or RowStyle properties.
设置大小调整选项Set sizing options 设置 HeightMaxHeightMinHeightWidthMaxWidthMinWidth 属性。Set the Height, MaxHeight, MinHeight, Width, MaxWidth, or MinWidth properties. 有关详细信息,请参阅DataGrid 控件中的调整大小选项For more information, see Sizing Options in the DataGrid Control.
访问选定项Access selected items 检查 SelectedCells 属性以获取选定的单元格,并检查 SelectedItems 属性以获取选定的行。Check the SelectedCells property to get the selected cells and check the SelectedItems property to get the selected rows. 有关详细信息,请参阅 SelectedCells 属性。For more information, see the SelectedCells property.
自定义最终用户交互Customize end-user interactions 设置 CanUserAddRowsCanUserDeleteRowsCanUserReorderColumnsCanUserResizeColumnsCanUserResizeRowsCanUserSortColumns 属性。Set the CanUserAddRows, CanUserDeleteRows, CanUserReorderColumns, CanUserResizeColumns, CanUserResizeRows, and CanUserSortColumns properties.
取消或更改自动生成的列Cancel or change auto-generated columns 处理 AutoGeneratingColumn 事件。Handle the AutoGeneratingColumn event.
冻结列Freeze a column FrozenColumnCount 属性设置为1,并将 "DisplayIndex" 属性设置为 "0",将列移到最左侧的位置。Set the FrozenColumnCount property to 1 and move the column to the left-most position by setting the DisplayIndex property to 0.
使用 XML 数据作为数据源Use XML data as the data source DataGrid 上的 ItemsSource 绑定到表示项集合的 XPath 查询。Bind the ItemsSource on the DataGrid to the XPath query representing the collection of items. DataGrid中创建每个列。Create each column in the DataGrid. 绑定每一列,方法是将绑定上的 XPath 设置为可获取项源属性的查询。Bind each column by setting the XPath on the binding to the query that gets the property on the item source. 有关示例,请参阅DataGridTextColumnFor an example, see DataGridTextColumn.
组项Group items 绑定到支持分组的 CollectionViewCollectionViewSourceBind to a CollectionView or CollectionViewSource that supports grouping. 有关详细信息,请参阅如何:在 DataGrid 控件中对数据进行分组、排序和筛选For more information, see How to: Group, Sort, and Filter Data in the DataGrid Control.
显示行的详细信息部分Display the details section for a row 定义 RowDetailsTemplate 以指定详细信息部分的外观。Define a RowDetailsTemplate to specify the appearance of the details section. 设置 RowDetailsVisibilityMode 以指定显示详细信息部分的时间。Set the RowDetailsVisibilityMode to specify when the details section is shown. 有关详细信息,请参阅如何:向 DataGrid 控件添加行详细信息。For more information, see How to: Add Row Details to a DataGrid Control.

构造函数

DataGrid()

初始化 DataGrid 类的新实例。Initializes a new instance of the DataGrid class.

字段

AlternatingRowBackgroundProperty

标识 AlternatingRowBackground 依赖项属性。Identifies the AlternatingRowBackground dependency property.

AreRowDetailsFrozenProperty

标识 AreRowDetailsFrozen 依赖项属性。Identifies the AreRowDetailsFrozen dependency property.

AutoGenerateColumnsProperty

标识 AutoGenerateColumns 依赖项属性。Identifies the AutoGenerateColumns dependency property.

BeginEditCommand

表示命令,该命令指示开始编辑 DataGrid 的当前单元格或行的意图。Represents the command that indicates the intention to begin editing the current cell or row of the DataGrid.

CancelEditCommand

表示命令,该命令指示取消对当前单元格或行所做的任何挂起更改,并还原为执行 BeginEditCommand 命令前的状态的意图。Represents the command that indicates the intention to cancel any pending changes to the current cell or row and revert to the state before the BeginEditCommand command was executed.

CanUserAddRowsProperty

标识 CanUserAddRows 依赖项属性。Identifies the CanUserAddRows dependency property.

CanUserDeleteRowsProperty

标识 CanUserDeleteRows 依赖项属性。Identifies the CanUserDeleteRows dependency property.

CanUserReorderColumnsProperty

标识 CanUserReorderColumns 依赖项属性。Identifies the CanUserReorderColumns dependency property.

CanUserResizeColumnsProperty

标识 CanUserResizeColumns 依赖项属性。Identifies the CanUserResizeColumns dependency property.

CanUserResizeRowsProperty

标识 CanUserResizeRows 依赖项属性。Identifies the CanUserResizeRows dependency property.

CanUserSortColumnsProperty

标识 CanUserSortColumns 依赖项属性。Identifies the CanUserSortColumns dependency property.

CellsPanelHorizontalOffsetProperty

标识 CellsPanelHorizontalOffset 依赖项属性。Identifies the CellsPanelHorizontalOffset dependency property.

CellStyleProperty

标识 CellStyle 依赖项属性。Identifies the CellStyle dependency property.

ClipboardCopyModeProperty

标识 ClipboardCopyMode 依赖项属性。Identifies the ClipboardCopyMode dependency property.

ColumnHeaderHeightProperty

标识 ColumnHeaderHeight 依赖项属性。Identifies the ColumnHeaderHeight dependency property.

ColumnHeaderStyleProperty

标识 ColumnHeaderStyle 依赖项属性。Identifies the ColumnHeaderStyle dependency property.

ColumnWidthProperty

标识 ColumnWidth 依赖项属性。Identifies the ColumnWidth dependency property.

CommitEditCommand

表示命令,该命令指示提交对当前单元格或行所做的挂起更改并退出编辑模式的意图。Represents the command that indicates the intention to commit pending changes to the current cell or row and exit edit mode.

CurrentCellProperty

标识 CurrentCell 依赖项属性。Identifies the CurrentCell dependency property.

CurrentColumnProperty

标识 CurrentColumn 依赖项属性。Identifies the CurrentColumn dependency property.

CurrentItemProperty

标识 CurrentItem 依赖项属性。Identifies the CurrentItem dependency property.

DragIndicatorStyleProperty

标识 DragIndicatorStyle 依赖项属性。Identifies the DragIndicatorStyle dependency property.

DropLocationIndicatorStyleProperty

标识 DropLocationIndicatorStyle 依赖项属性。Identifies the DropLocationIndicatorStyle dependency property.

EnableColumnVirtualizationProperty

标识 EnableColumnVirtualization 依赖项属性。Identifies the EnableColumnVirtualization dependency property.

EnableRowVirtualizationProperty

标识 EnableRowVirtualization 依赖项属性。Identifies the EnableRowVirtualization dependency property.

FrozenColumnCountProperty

标识 FrozenColumnCount 依赖项属性。Identifies the FrozenColumnCount dependency property.

GridLinesVisibilityProperty

标识 GridLinesVisibility 依赖项属性。Identifies the GridLinesVisibility dependency property.

HeadersVisibilityProperty

标识 HeadersVisibility 依赖项属性。Identifies the HeadersVisibility dependency property.

HorizontalGridLinesBrushProperty

标识 HorizontalGridLinesBrush 依赖项属性。Identifies the HorizontalGridLinesBrush dependency property.

HorizontalScrollBarVisibilityProperty

标识 HorizontalScrollBarVisibility 依赖项属性。Identifies the HorizontalScrollBarVisibility dependency property.

IsReadOnlyProperty

标识 IsReadOnly 依赖项属性。Identifies the IsReadOnly dependency property.

MaxColumnWidthProperty

标识 MaxColumnWidth 依赖项属性。Identifies the MaxColumnWidth dependency property.

MinColumnWidthProperty

标识 MinColumnWidth 依赖项属性。Identifies the MinColumnWidth dependency property.

MinRowHeightProperty

标识 MinRowHeight 依赖项属性。Identifies the MinRowHeight dependency property.

NewItemMarginProperty

标识 NewItemMargin 依赖项属性。Identifies the NewItemMargin dependency property.

NonFrozenColumnsViewportHorizontalOffsetProperty

标识 NonFrozenColumnsViewportHorizontalOffset 依赖项属性。Identifies the NonFrozenColumnsViewportHorizontalOffset dependency property.

RowBackgroundProperty

标识 RowBackground 依赖项属性。Identifies the RowBackground dependency property.

RowDetailsTemplateProperty

标识 RowDetailsTemplate 依赖项属性。Identifies the RowDetailsTemplate dependency property.

RowDetailsTemplateSelectorProperty

标识 RowDetailsTemplateSelector 依赖项属性。Identifies the RowDetailsTemplateSelector dependency property.

RowDetailsVisibilityModeProperty

标识 RowDetailsVisibilityMode 依赖项属性。Identifies the RowDetailsVisibilityMode dependency property.

RowHeaderActualWidthProperty

标识 RowHeaderActualWidth 依赖项属性。Identifies the RowHeaderActualWidth dependency property.

RowHeaderStyleProperty

标识 RowHeaderStyle 依赖项属性。Identifies the RowHeaderStyle dependency property.

RowHeaderTemplateProperty

标识 RowHeaderTemplate 依赖项属性。Identifies the RowHeaderTemplate dependency property.

RowHeaderTemplateSelectorProperty

标识 RowHeaderTemplateSelector 依赖项属性。Identifies the RowHeaderTemplateSelector dependency property.

RowHeaderWidthProperty

标识 RowHeaderWidth 依赖项属性。Identifies the RowHeaderWidth dependency property.

RowHeightProperty

标识 RowHeight 依赖项属性。Identifies the RowHeight dependency property.

RowStyleProperty

标识 RowStyle 依赖项属性。Identifies the RowStyle dependency property.

RowStyleSelectorProperty

标识 RowStyleSelector 依赖项属性。Identifies the RowStyleSelector dependency property.

RowValidationErrorTemplateProperty

标识 RowValidationErrorTemplate 依赖项属性。Identifies the RowValidationErrorTemplate dependency property.

SelectionModeProperty

标识 SelectionMode 依赖项属性。Identifies the SelectionMode dependency property.

SelectionUnitProperty

标识 SelectionUnit 依赖项属性。Identifies the SelectionUnit dependency property.

VerticalGridLinesBrushProperty

标识 VerticalGridLinesBrush 依赖项属性。Identifies the VerticalGridLinesBrush dependency property.

VerticalScrollBarVisibilityProperty

标识 VerticalScrollBarVisibility 依赖项属性。Identifies the VerticalScrollBarVisibility dependency property.

属性

ActualHeight

获取此元素的呈现高度。Gets the rendered height of this element.

(继承自 FrameworkElement)
ActualWidth

获取此元素的呈现宽度。Gets the rendered width of this element.

(继承自 FrameworkElement)
AllowDrop

获取或设置一个值,该值指示此元素能否用作拖放操作的目标。Gets or sets a value indicating whether this element can be used as the target of a drag-and-drop operation. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
AlternatingRowBackground

获取或设置在可选行上使用的背景画笔。Gets or sets the background brush for use on alternating rows.

AlternationCount

获取或设置 ItemsControl 中的交替项容器的数目,该控件可使交替容器具有唯一外观。Gets or sets the number of alternating item containers in the ItemsControl, which enables alternating containers to have a unique appearance.

(继承自 ItemsControl)
AreAnyTouchesCaptured

获取一个值,该值指示在此元素上是否至少捕获了一次触摸。Gets a value that indicates whether at least one touch is captured to this element.

(继承自 UIElement)
AreAnyTouchesCapturedWithin

获取一个值,该值指示在此元素或其可视化树中的任何子元素上是否至少捕获了一次触摸。Gets a value that indicates whether at least one touch is captured to this element or to any child elements in its visual tree.

(继承自 UIElement)
AreAnyTouchesDirectlyOver

获取一个值,该值指示在此元素上是否至少按下了一次触摸设备。Gets a value that indicates whether at least one touch is pressed over this element.

(继承自 UIElement)
AreAnyTouchesOver

获取一个值,该值指示在此元素或其可视化树中的任何子元素上是否至少按下了一次触摸设备。Gets a value that indicates whether at least one touch is pressed over this element or any child elements in its visual tree.

(继承自 UIElement)
AreRowDetailsFrozen

获取或设置一个值,该值指示是否能水平滚动行详细信息。Gets or sets a value that indicates whether the row details can scroll horizontally.

AutoGenerateColumns

获取或设置一个值,该值指示是否自动创建列。Gets or sets a value that indicates whether the columns are created automatically.

Background

获取或设置一个用于描述控件背景的画笔。Gets or sets a brush that describes the background of a control.

(继承自 Control)
BindingGroup

获取或设置用于该元素的 BindingGroupGets or sets the BindingGroup that is used for the element.

(继承自 FrameworkElement)
BitmapEffect

获取或设置一个位图效果,该效果将直接应用到此元素所呈现的内容。Gets or sets a bitmap effect that applies directly to the rendered content for this element. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
BitmapEffectInput

获取或设置位图效果的输入源,该效果将直接应用到此元素所呈现的内容。Gets or sets an input source for the bitmap effect that applies directly to the rendered content for this element. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
BorderBrush

获取或设置一个用于描述控件的边框背景的画笔。Gets or sets a brush that describes the border background of a control.

(继承自 Control)
BorderThickness

获取或设置控件的边框宽度。Gets or sets the border thickness of a control.

(继承自 Control)
CacheMode

获取或设置 UIElement 的缓存表示形式。Gets or sets a cached representation of the UIElement.

(继承自 UIElement)
CanSelectMultipleItems

获取或设置一个值,该值指示是否可以一次选择 MultiSelector 中的多个项。Gets or sets a value that indicates whether the multiple items in the MultiSelector can be selected at a time.

(继承自 MultiSelector)
CanUserAddRows

获取或设置一个值,该值指示用户是否可在 DataGrid 中添加新行。Gets or sets a value that indicates whether the user can add new rows to the DataGrid.

CanUserDeleteRows

获取或设置一个值,该值指示用户是否可从 DataGrid 中删除行。Gets or sets a value that indicates whether the user can delete rows from the DataGrid.

CanUserReorderColumns

获取或设置一个值,该值指示用户能否通过用鼠标拖动列标题来更改列的显示顺序。Gets or sets a value that indicates whether the user can change the column display order by dragging column headers with the mouse.

CanUserResizeColumns

获取或设置一个值,该值指示用户是否可使用鼠标调整列宽。Gets or sets a value that indicates whether the user can adjust the width of columns by using the mouse.

CanUserResizeRows

获取或设置一个值,该值指示用户是否能使用鼠标调整行的高度。Gets or sets a value that indicates whether the user can adjust the height of rows by using the mouse.

CanUserSortColumns

获取或设置一个值,该值指示用户能否通过单击列标题对列进行排序。Gets or sets a value that indicates whether the user can sort columns by clicking the column header.

CellsPanelHorizontalOffset

获取 DataGridCellsPanel 的水平偏移量。Gets the horizontal offset for the DataGridCellsPanel.

CellStyle

获取或设置应用于 DataGrid 中的所有单元格的样式。Gets or sets the style applied to all cells in the DataGrid.

Clip

获取或设置用于定义元素内容轮廓的几何图形。Gets or sets the geometry used to define the outline of the contents of an element. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
ClipboardCopyMode

获取或设置一个值,该值指示如何将内容复制到剪贴板。Gets or sets a value that indicates how content is copied to the clipboard.

ClipToBounds

获取或设置一个值,该值指示是否剪切此元素的内容(或来自此元素的子元素的内容)使其适合包含元素的大小。Gets or sets a value indicating whether to clip the content of this element (or content coming from the child elements of this element) to fit into the size of the containing element. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
ColumnHeaderHeight

获取或设置列标题行的高度。Gets or sets the height of the column headers row.

ColumnHeaderStyle

获取或设置应用于 DataGrid 中所有列标题的样式。Gets or sets the style applied to all column headers in the DataGrid.

Columns

获取一个集合,该集合包含 DataGrid 中的所有列。Gets a collection that contains all the columns in the DataGrid.

ColumnWidth

获取或设置 DataGrid 中列和标题的标准宽度和大小调整模式。Gets or sets the standard width and sizing mode of columns and headers in the DataGrid.

CommandBindings

获取与此元素关联的 CommandBinding 对象的集合。Gets a collection of CommandBinding objects associated with this element. CommandBinding 为此元素启用命令处理,并声明命令、命令的事件和由此元素附加的处理程序之间的链接。A CommandBinding enables command handling for this element, and declares the linkage between a command, its events, and the handlers attached by this element.

(继承自 UIElement)
ContextMenu

获取或设置通过 用户界面 (UI)user interface (UI) 从此元素内部请求上下文菜单时应该显示的上下文菜单元素。Gets or sets the context menu element that should appear whenever the context menu is requested through 用户界面 (UI)user interface (UI) from within this element.

(继承自 FrameworkElement)
CurrentCell

获取或设置具有焦点的单元格。Gets or sets the cell that has focus.

CurrentColumn

获取或设置包含当前单元格的列。Gets or sets the column that contains the current cell.

CurrentItem

获取与包含当前单元格的行绑定的数据项。Gets the data item bound to the row that contains the current cell.

Cursor

获取或设置在鼠标指针位于此元素上时显示的光标。Gets or sets the cursor that displays when the mouse pointer is over this element.

(继承自 FrameworkElement)
DataContext

获取或设置元素参与数据绑定时的数据上下文。Gets or sets the data context for an element when it participates in data binding.

(继承自 FrameworkElement)
DefaultStyleKey

获取或设置在使用或定义主题样式时要用于引用此控件样式的键。Gets or sets the key to use to reference the style for this control, when theme styles are used or defined.

(继承自 FrameworkElement)
DeleteCommand

表示命令,该命令指示删除当前行的意图。Represents the command that indicates the intention to delete the current row.

DependencyObjectType

获取对此实例的 DependencyObjectType 类型进行包装的 CLRCLRGets the DependencyObjectType that wraps the CLRCLR type of this instance.

(继承自 DependencyObject)
DesiredSize

获取在布局流程的度量传递过程中此元素计算所得的大小。Gets the size that this element computed during the measure pass of the layout process.

(继承自 UIElement)
Dispatcher

获取与此 Dispatcher 关联的 DispatcherObjectGets the Dispatcher this DispatcherObject is associated with.

(继承自 DispatcherObject)
DisplayMemberPath

获取或设置源对象上的值的路径,以用作对象的可视表示形式。Gets or sets a path to a value on the source object to serve as the visual representation of the object.

(继承自 ItemsControl)
DragIndicatorStyle

获取或设置在呈现拖动列标题时显示的拖动指示器时使用的样式。Gets or sets the style that is used when rendering the drag indicator that is displayed while dragging a column header.

DropLocationIndicatorStyle

获取或设置在拖动列标题时应用以指示放置位置的样式。Gets or sets the style that is applied to indicate the drop location when dragging a column header.

Effect

获取或设置要应用于 UIElement 的位图效果。Gets or sets the bitmap effect to apply to the UIElement. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
EnableColumnVirtualization

获取或设置一个值,该值指示是否启用列虚拟化。Gets or sets a value that indicates whether column virtualization is enabled.

EnableRowVirtualization

获取或设置一个值,该值指示是否启用行虚拟化。Gets or sets a value that indicates whether row virtualization is enabled.

FlowDirection

获取或设置方向,文本和其他 用户界面 (UI)user interface (UI) 元素在任何控制其布局的父元素中都按此方向流动。Gets or sets the direction that text and other 用户界面 (UI)user interface (UI) elements flow within any parent element that controls their layout.

(继承自 FrameworkElement)
Focusable

获取或设置一个值,该值指示元素能否得到焦点。Gets or sets a value that indicates whether the element can receive focus. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
FocusBorderBrushKey

获取用于引用带焦点单元格的默认边框画笔的键。Gets the key that references the default border brush for a focused cell.

FocusVisualStyle

获取或设置一个属性,该属性允许自定义此元素在捕获到键盘焦点时要应用于此元素的外观、效果或其他样式特征。Gets or sets a property that enables customization of appearance, effects, or other style characteristics that will apply to this element when it captures keyboard focus.

(继承自 FrameworkElement)
FontFamily

获取或设置控件的字体系列。Gets or sets the font family of the control.

(继承自 Control)
FontSize

获取或设置字号。Gets or sets the font size.

(继承自 Control)
FontStretch

获取或设置字体在屏幕上紧缩或加宽的程度。Gets or sets the degree to which a font is condensed or expanded on the screen.

(继承自 Control)
FontStyle

获取或设置字形。Gets or sets the font style.

(继承自 Control)
FontWeight

获取或设置指定字体的粗细。Gets or sets the weight or thickness of the specified font.

(继承自 Control)
ForceCursor

获取或设置一个值,该值指示此 FrameworkElement 是否应该强制用户界面 (UI)user interface (UI) 按照 Cursor 属性所声明的方式呈现光标。Gets or sets a value that indicates whether this FrameworkElement should force the 用户界面 (UI)user interface (UI) to render the cursor as declared by the Cursor property.

(继承自 FrameworkElement)
Foreground

获取或设置一个用于描述前景色的画笔。Gets or sets a brush that describes the foreground color.

(继承自 Control)
FrozenColumnCount

获取或设置非滚动列的数目。Gets or sets the number of non-scrolling columns.

GridLinesVisibility

获取或设置一个值,该值指示显示哪些网格线。Gets or sets a value that indicates which grid lines are shown.

GroupStyle

获取定义每个级别的组的外观的 GroupStyle 对象集合。Gets a collection of GroupStyle objects that define the appearance of each level of groups.

(继承自 ItemsControl)
GroupStyleSelector

获取或设置一个方法,通过此方法您可以为 GroupStyle 提供自定义选择逻辑,以便将此样式应用到集合中的每个组。Gets or sets a method that enables you to provide custom selection logic for a GroupStyle to apply to each group in a collection.

(继承自 ItemsControl)
HandlesScrolling

获取一个值,该值指示 DataGrid 是否支持自定义键盘滚动。Gets a value that indicates whether the DataGrid supports custom keyboard scrolling.

HasAnimatedProperties

获取一个值,该值指示此元素是否具有任何进行动画处理的属性。Gets a value indicating whether this element has any animated properties.

(继承自 UIElement)
HasEffectiveKeyboardFocus

获取一个值,该值指示 UIElement 是否具有焦点。Gets a value that indicates whether the UIElement has focus.

(继承自 UIElement)
HasItems

获取一个值,该值指示 ItemsControl 是否包含项。Gets a value that indicates whether the ItemsControl contains items.

(继承自 ItemsControl)
HeadersVisibility

获取或设置用于指定行和列标题可见性的值。Gets or sets the value that specifies the visibility of the row and column headers.

HeadersVisibilityConverter

获取用于将 DataGridHeadersVisibility 转换为 Visibility 的转换器。Gets the converter that converts a DataGridHeadersVisibility to a Visibility.

Height

获取或设置元素的建议高度。Gets or sets the suggested height of the element.

(继承自 FrameworkElement)
HorizontalAlignment

获取或设置在父元素(如 Panel 或项控件)中组合此元素时所应用的水平对齐特征。Gets or sets the horizontal alignment characteristics applied to this element when it is composed within a parent element, such as a panel or items control.

(继承自 FrameworkElement)
HorizontalContentAlignment

获取或设置控件内容的水平对齐方式。Gets or sets the horizontal alignment of the control's content.

(继承自 Control)
HorizontalGridLinesBrush

获取或设置用于绘制水平网格线的画笔。Gets or sets the brush that is used to draw the horizontal grid lines.

HorizontalScrollBarVisibility

获取或设置一个指示如何在 DataGrid 中显示水平滚动条的值。Gets or sets a value that indicates how horizontal scroll bars are displayed in the DataGrid.

InheritanceBehavior

获取或设置属性值继承、资源键查找和RelativeSource FindAncestor 查找的范围限制。Gets or sets the scope limits for property value inheritance, resource key lookup, and RelativeSource FindAncestor lookup.

(继承自 FrameworkElement)
InputBindings

获取与此元素关联的输入绑定的集合。Gets the collection of input bindings associated with this element.

(继承自 UIElement)
InputScope

获取或设置此 FrameworkElement 使用的输入的上下文。Gets or sets the context for input used by this FrameworkElement.

(继承自 FrameworkElement)
IsArrangeValid

获取一个值,该值指示此元素布局中的子元素的计算大小和位置是否有效。Gets a value indicating whether the computed size and position of child elements in this element's layout are valid.

(继承自 UIElement)
IsEnabled

获取或设置一个值,该值指示是否 用户界面 (UI)user interface (UI) 中启用此元素。Gets or sets a value indicating whether this element is enabled in the 用户界面 (UI)user interface (UI). 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
IsEnabledCore

获取一个值,该值成为派生类中 IsEnabled 的返回值。Gets a value that becomes the return value of IsEnabled in derived classes.

(继承自 UIElement)
IsFocused

获取一个值,该值确定此元素是否具有逻辑焦点。Gets a value that determines whether this element has logical focus. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
IsGrouping

获取一个值,该值指示控件是否正在使用分组。Gets a value that indicates whether the control is using grouping.

(继承自 ItemsControl)
IsHitTestVisible

获取或设置一个值,该值声明是否可以返回此元素作为其呈现内容的某些部分的点击测试结果。Gets or sets a value that declares whether this element can possibly be returned as a hit test result from some portion of its rendered content. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
IsInitialized

获取一个值,该值表示该元素是否在由 XAMLXAML 处理器进行处理时,或者通过显式调用其 EndInit() 方法被初始化。Gets a value that indicates whether this element has been initialized, either during processing by a XAMLXAML processor, or by explicitly having its EndInit() method called.

(继承自 FrameworkElement)
IsInputMethodEnabled

获取一个值,该值指示是否启用输入法系统(如 输入法编辑器 (IME)Input Method Editor (IME))来处理此元素的输入。Gets a value indicating whether an input method system, such as an 输入法编辑器 (IME)Input Method Editor (IME), is enabled for processing the input to this element.

(继承自 UIElement)
IsKeyboardFocused

获取一个值,该值表示该元素是否具有键盘焦点。Gets a value indicating whether this element has keyboard focus. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
IsKeyboardFocusWithin

获取一个值,该值指示键盘焦点是否位于元素或其可视化树子元素内的任意位置。Gets a value indicating whether keyboard focus is anywhere within the element or its visual tree child elements. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
IsLoaded

获取一个值,该值指示是否已加载此元素以供呈现。Gets a value that indicates whether this element has been loaded for presentation.

(继承自 FrameworkElement)
IsManipulationEnabled

获取或设置一个值,该值指示是否对此 UIElement 启用操作事件。Gets or sets a value that indicates whether manipulation events are enabled on this UIElement.

(继承自 UIElement)
IsMeasureValid

获取一个值,该值指示布局测量返回的当前大小是否有效。Gets a value indicating whether the current size returned by layout measure is valid.

(继承自 UIElement)
IsMouseCaptured

获取一个值,该值指示此元素是否捕获了鼠标。Gets a value indicating whether the mouse is captured to this element. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
IsMouseCaptureWithin

获取一个值,该值确定鼠标捕获是由此元素还是其可视化树中的子元素持有。Gets a value that determines whether mouse capture is held by this element or by child elements in its visual tree. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
IsMouseDirectlyOver

获取一个值,该值指示在考虑元素组合的情况下,鼠标指针的位置是否对应于命中测试结果。Gets a value that indicates whether the position of the mouse pointer corresponds to hit test results, which take element compositing into account. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
IsMouseOver

获取一个值,该值指示鼠标指针是否位于此元素(包括可视化树中的子元素)的上方。Gets a value indicating whether the mouse pointer is located over this element (including child elements in the visual tree). 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
IsReadOnly

获取或设置一个值,该值指示用户是否可在 DataGrid 中的编辑值。Gets or sets a value that indicates whether the user can edit values in the DataGrid.

IsSealed

获取一个值,该值指示此实例当前是否为密封的(只读)。Gets a value that indicates whether this instance is currently sealed (read-only).

(继承自 DependencyObject)
IsStylusCaptured

获取一个值,该值表示此元素是否捕获了触笔。Gets a value indicating whether the stylus is captured by this element. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
IsStylusCaptureWithin

获取一个值,该值确定触笔捕获是由此元素还是由元素边界内的元素及其可视化树持有。Gets a value that determines whether stylus capture is held by this element, or an element within the element bounds and its visual tree. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
IsStylusDirectlyOver

获取一个值,该值指示在考虑元素组合的情况下,触笔的位置是否与命中测试结果相对应。Gets a value that indicates whether the stylus position corresponds to hit test results, which take element compositing into account. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
IsStylusOver

获取一个值,该值指示触笔指针是否位于此元素(包括可视化子元素)的上方。Gets a value indicating whether the stylus cursor is located over this element (including visual child elements). 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
IsSynchronizedWithCurrentItem

获取或设置指示 Selector 是否应当使 SelectedItemItems 属性中的当前项保持同步的值。Gets or sets a value that indicates whether a Selector should keep the SelectedItem synchronized with the current item in the Items property.

(继承自 Selector)
IsTabStop

获取或设置一个值,该值指示是否将某个控件包含在 Tab 导航中。Gets or sets a value that indicates whether a control is included in tab navigation.

(继承自 Control)
IsTextSearchCaseSensitive

获取或设置一个值,该值指示搜索项时大小写是否为条件。Gets or sets a value that indicates whether case is a condition when searching for items.

(继承自 ItemsControl)
IsTextSearchEnabled

获取或设置一个值,该值指示是否在 TextSearch 实例上启用 ItemsControlGets or sets a value that indicates whether TextSearch is enabled on the ItemsControl instance.

(继承自 ItemsControl)
IsUpdatingSelectedItems

获取一个值,该值指示 MultiSelector 当前是否正在对 SelectedItems 集合执行批量更新。Gets a value that indicates whether the MultiSelector is currently performing a bulk update to the SelectedItems collection.

(继承自 MultiSelector)
IsVisible

获取一个值,该值指示此元素在用户界面 (UI)user interface (UI) 中是否可见。Gets a value indicating whether this element is visible in the 用户界面 (UI)user interface (UI). 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
ItemBindingGroup

获取或设置复制到 BindingGroup 中每个项的 ItemsControlGets or sets the BindingGroup that is copied to each item in the ItemsControl.

(继承自 ItemsControl)
ItemContainerGenerator

获取与控件关联的 ItemContainerGeneratorGets the ItemContainerGenerator that is associated with the control.

(继承自 ItemsControl)
ItemContainerStyle

获取或设置应用于为每个项生成的容器元素的 StyleGets or sets the Style that is applied to the container element generated for each item.

(继承自 ItemsControl)
ItemContainerStyleSelector

获取或设置可应用于每个所生成容器元素的样式的自定义样式选择逻辑。Gets or sets custom style-selection logic for a style that can be applied to each generated container element.

(继承自 ItemsControl)
Items

获取用于生成 ItemsControl 的内容的集合。Gets the collection used to generate the content of the ItemsControl.

(继承自 ItemsControl)
ItemsPanel

获取或设置模板,该模板定义对项的布局进行控制的面板。Gets or sets the template that defines the panel that controls the layout of items.

(继承自 ItemsControl)
ItemsSource

获取或设置用于生成 ItemsControl 的内容的集合。Gets or sets a collection used to generate the content of the ItemsControl.

(继承自 ItemsControl)
ItemStringFormat

获取或设置一个复合字符串,如果 ItemsControl 中的项显示为字符串,则用于指定如何格式化这些项。Gets or sets a composite string that specifies how to format the items in the ItemsControl if they are displayed as strings.

(继承自 ItemsControl)
ItemTemplate

获取或设置用来显示每个项的 DataTemplateGets or sets the DataTemplate used to display each item.

(继承自 ItemsControl)
ItemTemplateSelector

获取或设置用于选择用来显示每个项的模板的自定义逻辑。Gets or sets the custom logic for choosing a template used to display each item.

(继承自 ItemsControl)
Language

获取或设置应用于某个元素的本地化/全球化语言信息。Gets or sets localization/globalization language information that applies to an element.

(继承自 FrameworkElement)
LayoutTransform

获取或设置在执行布局时应该应用于此元素的图形转换方式。Gets or sets a graphics transformation that should apply to this element when layout is performed.

(继承自 FrameworkElement)
LogicalChildren

获取 ItemsControl 对象的逻辑子对象的枚举器。Gets an enumerator for the logical child objects of the ItemsControl object.

(继承自 ItemsControl)
Margin

获取或设置元素的外边距。Gets or sets the outer margin of an element.

(继承自 FrameworkElement)
MaxColumnWidth

获取或设置 DataGrid 中列和标题的最大宽度约束。Gets or sets the maximum width constraint of the columns and headers in the DataGrid.

MaxHeight

获取或设置元素的最大高度约束。Gets or sets the maximum height constraint of the element.

(继承自 FrameworkElement)
MaxWidth

获取或设置元素的最大宽度约束。Gets or sets the maximum width constraint of the element.

(继承自 FrameworkElement)
MinColumnWidth

获取或设置 DataGrid 中列和标题的最小宽度约束。Gets or sets the minimum width constraint of the columns and headers in the DataGrid.

MinHeight

获取或设置元素的最小高度约束。Gets or sets the minimum height constraint of the element.

(继承自 FrameworkElement)
MinRowHeight

获取或设置 DataGrid 中行和标题的最小高度约束。Gets or sets the minimum height constraint of the rows and headers in the DataGrid.

MinWidth

获取或设置元素的最小宽度约束。Gets or sets the minimum width constraint of the element.

(继承自 FrameworkElement)
Name

获取或设置元素的标识名称。Gets or sets the identifying name of the element. 该名称提供引用,以便代码隐藏(如事件处理程序代码)可以引用标记元素(在 XAMLXAML 处理器的处理过程中构造该元素之后)。The name provides a reference so that code-behind, such as event handler code, can refer to a markup element after it is constructed during processing by a XAMLXAML processor.

(继承自 FrameworkElement)
NewItemMargin

获取或设置新项行的边距。Gets or sets the margin for the new item row.

NonFrozenColumnsViewportHorizontalOffset

获取视区中可滚动列的水平偏移量。Gets the horizontal offset of the scrollable columns in the view port.

Opacity

获取或设置当 UIElement用户界面 (UI)user interface (UI) 中呈现时为其整体应用的不透明度因子。Gets or sets the opacity factor applied to the entire UIElement when it is rendered in the 用户界面 (UI)user interface (UI). 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
OpacityMask

获取或设置一个作为 Brush 实现的不透明蒙板,该蒙板可应用到此元素所呈现内容的任何 Alpha 通道蒙板。Gets or sets an opacity mask, as a Brush implementation that is applied to any alpha-channel masking for the rendered content of this element. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
OverridesDefaultStyle

获取或设置一个值,该值指示此元素是否并入主题样式中的样式属性。Gets or sets a value that indicates whether this element incorporates style properties from theme styles.

(继承自 FrameworkElement)
Padding

获取或设置控件内部的填充边距。Gets or sets the padding inside a control.

(继承自 Control)
Parent

获取此元素的逻辑父元素。Gets the logical parent element of this element.

(继承自 FrameworkElement)
PersistId

获取一个唯一标识此元素的值。Gets a value that uniquely identifies this element.

(继承自 UIElement)
RenderSize

获取(或设置)此元素的最终呈现大小。Gets (or sets) the final render size of this element.

(继承自 UIElement)
RenderTransform

获取或设置影响此元素的呈现位置的转换信息。Gets or sets transform information that affects the rendering position of this element. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
RenderTransformOrigin

获取或设置由 RenderTransform 声明的任何可能呈现转换的中心点,相对于元素的边界。Gets or sets the center point of any possible render transform declared by RenderTransform, relative to the bounds of the element. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
Resources

获取或设置本地定义的资源字典。Gets or sets the locally-defined resource dictionary.

(继承自 FrameworkElement)
RowBackground

获取或设置行背景的默认画笔。Gets or sets the default brush for the row background.

RowDetailsScrollingConverter

获取用于将布尔值转换为 SelectiveScrollingOrientation 的转换器。Gets the converter that converts a Boolean value to a SelectiveScrollingOrientation.

RowDetailsTemplate

获取或设置用于显示行详细信息的模板。Gets or sets the template that is used to display the row details.

RowDetailsTemplateSelector

获取或设置用于行详细信息的模板选择器。Gets or sets the template selector that is used for the row details.

RowDetailsVisibilityMode

获取或设置一个值,该值指示何时显示行的详细信息部分。Gets or sets a value that indicates when the details section of a row is displayed.

RowHeaderActualWidth

获取行标题列的呈现宽度。Gets the rendered width of the row headers column.

RowHeaderStyle

获取或设置应用于所有行标题的样式。Gets or sets the style applied to all row headers.

RowHeaderTemplate

获取或设置行标题的模板。Gets or set the template for the row headers.

RowHeaderTemplateSelector

获取或设置行标题的模板选择器。Gets or sets the template selector for row headers.

RowHeaderWidth

获取或设置行标题列的宽度。Gets or sets the width of the row header column.

RowHeight

获取或设置所有行的建议高度。Gets or sets the suggested height for all rows.

RowStyle

获取或设置应用于所有行的样式。Gets or sets the style applied to all rows.

RowStyleSelector

获取或设置行的样式选择器。Gets or sets the style selector for the rows.

RowValidationErrorTemplate

获取或设置用来以可视方式指示行验证中的错误的模板。Gets or sets the template that is used to visually indicate an error in row validation.

RowValidationRules

获取用于验证每个行中的数据的规则。Gets the rules that are used to validate the data in each row.

SelectAllCommand

表示命令,该命令指示在 DataGrid 中选择所有单元格的意图。Represents the command that indicates the intention to select all cells in the DataGrid.

SelectedCells

获取当前选定单元格的列表。Gets the list of cells that are currently selected.

SelectedIndex

获取或设置当前选择中第一项的索引,如果选择为空,则返回负一(-1)。Gets or sets the index of the first item in the current selection or returns negative one (-1) if the selection is empty.

(继承自 Selector)
SelectedItem

获取或设置当前选择中的第一项,或者,如果选择为空,则返回 null。Gets or sets the first item in the current selection or returns null if the selection is empty.

(继承自 Selector)
SelectedItems

获取在 MultiSelector 中选定的项。Gets the items in the MultiSelector that are selected.

(继承自 MultiSelector)
SelectedValue

获取或设置通过使用 SelectedItem 而获取的 SelectedValuePath 的值。Gets or sets the value of the SelectedItem, obtained by using SelectedValuePath.

(继承自 Selector)
SelectedValuePath

获取或设置用于从 SelectedValue 获取 SelectedItem 的路径。Gets or sets the path that is used to get the SelectedValue from the SelectedItem.

(继承自 Selector)
SelectionMode

获取或设置一个值,该值指示如何在 DataGrid 中选择行和单元格。Gets or sets a value that indicates how rows and cells are selected in the DataGrid.

SelectionUnit

获取或设置一个值,该值指示是否可以在 DataGrid 中选择行、单元格或两者。Gets or sets a value that indicates whether rows, cells, or both can be selected in the DataGrid.

SnapsToDevicePixels

获取或设置一个值,该值确定在呈现过程中,此元素的呈现是否应使用特定于设备的像素设置。Gets or sets a value that determines whether rendering for this element should use device-specific pixel settings during rendering. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
Style

获取或设置此元素呈现时所使用的样式。Gets or sets the style used by this element when it is rendered.

(继承自 FrameworkElement)
StylusPlugIns

获取与此元素关联的所有触笔插件(自定义)对象的集合。Gets a collection of all stylus plug-in (customization) objects associated with this element.

(继承自 UIElement)
TabIndex

获取或设置一个值,该值决定在用户使用 Tab 键在控件中导航时元素接收焦点的顺序。Gets or sets a value that determines the order in which elements receive focus when the user navigates through controls by using the TAB key.

(继承自 Control)
Tag

获取或设置任意对象值,该值可用于存储关于此元素的自定义信息。Gets or sets an arbitrary object value that can be used to store custom information about this element.

(继承自 FrameworkElement)
Template

获取或设置控件模板。Gets or sets a control template.

(继承自 Control)
TemplatedParent

获取对此元素的模板父级的引用。Gets a reference to the template parent of this element. 如果该元素不是通过模板创建的,则此属性无关。This property is not relevant if the element was not created through a template.

(继承自 FrameworkElement)
ToolTip

获取或设置在用户界面 (UI)user interface (UI) 中为此元素显示的工具提示对象。Gets or sets the tool-tip object that is displayed for this element in the 用户界面 (UI)user interface (UI).

(继承自 FrameworkElement)
TouchesCaptured

获取在此元素上捕获的所有触摸设备。Gets all touch devices that are captured to this element.

(继承自 UIElement)
TouchesCapturedWithin

获取在此元素或其可视化树中的任何子元素上捕获的所有触摸设备。Gets all touch devices that are captured to this element or any child elements in its visual tree.

(继承自 UIElement)
TouchesDirectlyOver

获取此元素上的所有触摸设备。Gets all touch devices that are over this element.

(继承自 UIElement)
TouchesOver

获取在此元素或其可视化树中的任何子元素上的所有触摸设备。Gets all touch devices that are over this element or any child elements in its visual tree.

(继承自 UIElement)
Triggers

获取直接在此元素上或在子元素中建立的触发器的集合。Gets the collection of triggers established directly on this element, or in child elements.

(继承自 FrameworkElement)
Uid

获取或设置此元素的唯一标识符(用于本地化)。Gets or sets the unique identifier (for localization) for this element. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
UseLayoutRounding

获取或设置一个值,该值指示是否应向此元素的大小和位置布局应用布局舍入。Gets or sets a value that indicates whether layout rounding should be applied to this element's size and position during layout.

(继承自 FrameworkElement)
VerticalAlignment

获取或设置在父元素(如面板或项控件)中组合此元素时所应用的垂直对齐特征。Gets or sets the vertical alignment characteristics applied to this element when it is composed within a parent element such as a panel or items control.

(继承自 FrameworkElement)
VerticalContentAlignment

获取或设置控件内容的垂直对齐方式。Gets or sets the vertical alignment of the control's content.

(继承自 Control)
VerticalGridLinesBrush

获取或设置用于绘制垂直网格线的画笔。Gets or sets the brush that is used to draw the vertical grid lines.

VerticalScrollBarVisibility

获取或设置一个指示如何在 DataGrid 中显示垂直滚动条的值。Gets or sets a value that indicates how vertical scroll bars are displayed in the DataGrid.

Visibility

获取或设置此元素的 用户界面 (UI)user interface (UI) 可见性。Gets or sets the 用户界面 (UI)user interface (UI) visibility of this element. 这是依赖项属性。This is a dependency property.

(继承自 UIElement)
VisualBitmapEffect

获取或设置 BitmapEffectVisual 值。Gets or sets the BitmapEffect value for the Visual.

(继承自 Visual)
VisualBitmapEffectInput

获取或设置 BitmapEffectInputVisual 值。Gets or sets the BitmapEffectInput value for the Visual.

(继承自 Visual)
VisualBitmapScalingMode

获取或设置 BitmapScalingModeVisualGets or sets the BitmapScalingMode for the Visual.

(继承自 Visual)
VisualCacheMode

获取或设置 Visual 的缓存表示形式。Gets or sets a cached representation of the Visual.

(继承自 Visual)
VisualChildrenCount

获取此元素内可视子元素的数目。Gets the number of visual child elements within this element.

(继承自 FrameworkElement)
VisualClearTypeHint

获取或设置 ClearTypeHint,它确定在 Visual 中呈现 ClearType 的方式。Gets or sets the ClearTypeHint that determines how ClearType is rendered in the Visual.

(继承自 Visual)
VisualClip

获取或设置 Visual 的剪辑区域作为 Geometry 值。Gets or sets the clip region of the Visual as a Geometry value.

(继承自 Visual)
VisualEdgeMode

获取或设置 Visual 的边缘模式作为 EdgeMode 值。Gets or sets the edge mode of the Visual as an EdgeMode value.

(继承自 Visual)
VisualEffect

获取或设置要应用于 Visual 的位图效果。Gets or sets the bitmap effect to apply to the Visual.

(继承自 Visual)
VisualOffset

获取或设置可视对象的偏移量值。Gets or sets the offset value of the visual object.

(继承自 Visual)
VisualOpacity

获取或设置 Visual 的不透明度。Gets or sets the opacity of the Visual.

(继承自 Visual)
VisualOpacityMask

获取或设置 Brush 值,该值表示 Visual 的不透明蒙板。Gets or sets the Brush value that represents the opacity mask of the Visual.

(继承自 Visual)
VisualParent

获取可视对象的可视化树父级。Gets the visual tree parent of the visual object.

(继承自 Visual)
VisualScrollableAreaClip

获取或设置 Visual 的剪辑的可滚动区域。Gets or sets a clipped scrollable area for the Visual.

(继承自 Visual)
VisualTextHintingMode

获取或设置 TextHintingModeVisualGets or sets the TextHintingMode of the Visual.

(继承自 Visual)
VisualTextRenderingMode

获取或设置 TextRenderingModeVisualGets or sets the TextRenderingMode of the Visual.

(继承自 Visual)
VisualTransform

获取或设置 TransformVisual 值。Gets or sets the Transform value for the Visual.

(继承自 Visual)
VisualXSnappingGuidelines

获取或设置 x 坐标(垂直)准线集合。Gets or sets the x-coordinate (vertical) guideline collection.

(继承自 Visual)
VisualYSnappingGuidelines

获取或设置 Y 坐标(水平)准线集合。Gets or sets the y-coordinate (horizontal) guideline collection.

(继承自 Visual)
Width

获取或设置元素的宽度。Gets or sets the width of the element.

(继承自 FrameworkElement)

方法

AddChild(Object)

将指定的对象作为 ItemsControl 对象的子级添加。Adds the specified object as the child of the ItemsControl object.

(继承自 ItemsControl)
AddHandler(RoutedEvent, Delegate)

为指定的路由事件添加路由事件处理程序,并将该处理程序添加到当前元素的处理程序集合中。Adds a routed event handler for a specified routed event, adding the handler to the handler collection on the current element.

(继承自 UIElement)
AddHandler(RoutedEvent, Delegate, Boolean)

为指定的路由事件添加路由事件处理程序,并将该处理程序添加到当前元素的处理程序集合中。Adds a routed event handler for a specified routed event, adding the handler to the handler collection on the current element. handledEventsToo 指定为 true,可为已标记为由事件路由中的其他元素处理的路由事件调用所提供的处理程序。Specify handledEventsToo as true to have the provided handler be invoked for routed event that had already been marked as handled by another element along the event route.

(继承自 UIElement)
AddLogicalChild(Object)

将提供的对象添加到此元素的逻辑树。Adds the provided object to the logical tree of this element.

(继承自 FrameworkElement)
AddText(String)

将指定文本字符串添加到 ItemsControl 对象。Adds the specified text string to the ItemsControl object.

(继承自 ItemsControl)
AddToEventRoute(EventRoute, RoutedEventArgs)

将处理程序添加到当前 EventRoute 事件处理程序集合的指定 UIElement 中。Adds handlers to the specified EventRoute for the current UIElement event handler collection.

(继承自 UIElement)
AddVisualChild(Visual)

定义两个可视对象之间的父子关系。Defines the parent-child relationship between two visuals.

(继承自 Visual)
ApplyAnimationClock(DependencyProperty, AnimationClock)

将动画应用到此元素的指定依赖属性。Applies an animation to a specified dependency property on this element. 任何现有动画均停止并替换为新动画。Any existing animations are stopped and replaced with the new animation.

(继承自 UIElement)
ApplyAnimationClock(DependencyProperty, AnimationClock, HandoffBehavior)

向此元素的指定依赖属性应用动画,并且可以指定当该属性已有正在运行的动画时所要执行的操作。Applies an animation to a specified dependency property on this element, with the ability to specify what happens if the property already has a running animation.

(继承自 UIElement)
ApplyTemplate()

在必要时生成当前模板的可视化树,然后返回一个值,该值指示可视化树是否由此调用重新生成。Builds the current template's visual tree if necessary, and returns a value that indicates whether the visual tree was rebuilt by this call.

(继承自 FrameworkElement)
Arrange(Rect)

定位子元素,并确定 UIElement 的大小。Positions child elements and determines a size for a UIElement. 父元素从它们的 ArrangeCore(Rect) 实现(或者是 WPF 框架级别等效项)调用此方法,以便形成递归布局更新。Parent elements call this method from their ArrangeCore(Rect) implementation (or a WPF framework-level equivalent) to form a recursive layout update. 此方法产生第二次布局更新。This method constitutes the second pass of a layout update.

(继承自 UIElement)
ArrangeCore(Rect)

实现 ArrangeCore(Rect)(在 UIElement 中定义为虚拟对象)并密封实现。Implements ArrangeCore(Rect) (defined as virtual in UIElement) and seals the implementation.

(继承自 FrameworkElement)
ArrangeOverride(Size)

调用以排列 Control 对象的内容并调整其大小。Called to arrange and size the content of a Control object.

(继承自 Control)
BeginAnimation(DependencyProperty, AnimationTimeline)

为此元素的指定要进行动画处理的属性启动动画。Starts an animation for a specified animated property on this element.

(继承自 UIElement)
BeginAnimation(DependencyProperty, AnimationTimeline, HandoffBehavior)

为此元素的指定要进行动画处理的属性启动特定的动画,并可以指定当该属性已有正在运行的动画时所要执行的操作。Starts a specific animation for a specified animated property on this element, with the option of specifying what happens if the property already has a running animation.

(继承自 UIElement)
BeginEdit()

调用 BeginEdit() 命令,该命令将当前单元格或行置于编辑模式。Invokes the BeginEdit() command, which will place the current cell or row into edit mode.

BeginEdit(RoutedEventArgs)

调用 BeginEdit() 命令,该命令将当前单元格或行置于编辑模式。Invokes the BeginEdit() command, which will place the current cell or row into edit mode.

BeginInit()

指示 ItemsControl 对象的初始化即将开始。Indicates that the initialization of the ItemsControl object is about to start.

(继承自 ItemsControl)
BeginStoryboard(Storyboard)

开始所提供的演示图板中包含的操作序列。Begins the sequence of actions that are contained in the provided storyboard.

(继承自 FrameworkElement)
BeginStoryboard(Storyboard, HandoffBehavior)

开始所提供的演示图板中包含的操作序列,并指定选项来指明当已对属性进行动画处理时应发生的行为。Begins the sequence of actions contained in the provided storyboard, with options specified for what should happen if the property is already animated.

(继承自 FrameworkElement)
BeginStoryboard(Storyboard, HandoffBehavior, Boolean)

开始所提供的演示图板中包含的操作序列,并使动画控件在动画开始后具有指定的状态。Begins the sequence of actions contained in the provided storyboard, with specified state for control of the animation after it is started.

(继承自 FrameworkElement)
BeginUpdateSelectedItems()

启动新的选择事务。Starts a new selection transaction.

(继承自 MultiSelector)
BringIntoView()

尝试将此元素放入其所在的任何可滚动区域内的视图中。Attempts to bring this element into view, within any scrollable regions it is contained within.

(继承自 FrameworkElement)
BringIntoView(Rect)

尝试将此元素的提供区域大小放入其所在的任何可滚动区域内的视图中。Attempts to bring the provided region size of this element into view, within any scrollable regions it is contained within.

(继承自 FrameworkElement)
CancelEdit()

为当前处于编辑模式的单元格或行调用 CancelEditCommand 命令。Invokes the CancelEditCommand command for the cell or row currently in edit mode.

CancelEdit(DataGridEditingUnit)

为处于编辑模式的指定单元格或行调用 CancelEditCommand 命令。Invokes the CancelEditCommand command for the specified cell or row in edit mode.

CaptureMouse()

尝试将鼠标强制捕获到此元素。Attempts to force capture of the mouse to this element.

(继承自 UIElement)
CaptureStylus()

尝试将触笔强制捕获到此元素。Attempts to force capture of the stylus to this element.

(继承自 UIElement)
CaptureTouch(TouchDevice)

尝试将触摸屏输入强制捕获到此元素。Attempts to force capture of a touch to this element.

(继承自 UIElement)
CheckAccess()

确定调用线程是否可以访问此 DispatcherObjectDetermines whether the calling thread has access to this DispatcherObject.

(继承自 DispatcherObject)
ClearContainerForItemOverride(DependencyObject, Object)

为指定项卸载行。Unloads the row for the specified item.

ClearDetailsVisibilityForItem(Object)

清除表示所指定数据项的 DetailsVisibilityDataGridRow 属性。Clears the DetailsVisibility property for the DataGridRow that represents the specified data item.

ClearValue(DependencyProperty)

清除属性的本地值。Clears the local value of a property. 要清除的属性由 DependencyProperty 标识符指定。The property to be cleared is specified by a DependencyProperty identifier.

(继承自 DependencyObject)
ClearValue(DependencyPropertyKey)

清除只读属性的本地值。Clears the local value of a read-only property. 要清除的属性由 DependencyPropertyKey 指定。The property to be cleared is specified by a DependencyPropertyKey.

(继承自 DependencyObject)
CoerceValue(DependencyProperty)

对指定依赖属性的值进行强制。Coerces the value of the specified dependency property. 通过对调用方 CoerceValueCallback 上存在的依赖属性的属性元数据中所指定的任何 DependencyObject 函数进行调用来完成此操作。This is accomplished by invoking any CoerceValueCallback function specified in property metadata for the dependency property as it exists on the calling DependencyObject.

(继承自 DependencyObject)
ColumnFromDisplayIndex(Int32)

获取位于指定索引处的 DataGridColumnGets the DataGridColumn at the specified index.

CommitEdit()

为当前处于编辑模式的单元格或行调用 CommitEditCommand 命令。Invokes the CommitEditCommand command for the cell or row currently in edit mode.

CommitEdit(DataGridEditingUnit, Boolean)

为当前处于编辑模式的指定单元格或行调用 CommitEditCommand 命令。Invokes the CommitEditCommand command for the specified cell or row currently in edit mode.

ContainerFromElement(DependencyObject)

返回属于拥有给定元素的当前 ItemsControl 的容器。Returns the container that belongs to the current ItemsControl that owns the given element.

(继承自 ItemsControl)
EndInit()

表示对象 ItemsControl 的初始化已完成。Indicates that the initialization of the ItemsControl object is complete.

(继承自 ItemsControl)
EndUpdateSelectedItems()

将所选项提交到 MultiSelectorCommits the selected items to the MultiSelector.

(继承自 MultiSelector)
Equals(Object)

确定提供的 DependencyObject 是否等效于当前 DependencyObjectDetermines whether a provided DependencyObject is equivalent to the current DependencyObject.

(继承自 DependencyObject)
FindCommonVisualAncestor(DependencyObject)

返回两个可视对象的公共上级。Returns the common ancestor of two visual objects.

(继承自 Visual)
FindName(String)

查找具有提供的标识符名的元素。Finds an element that has the provided identifier name.

(继承自 FrameworkElement)
FindResource(Object)

搜索具有指定密钥的资源,如果未找到请求的资源,则会引发异常。Searches for a resource with the specified key, and throws an exception if the requested resource is not found.

(继承自 FrameworkElement)
Focus()

尝试将焦点设定到此元素上。Attempts to set focus to this element.

(继承自 UIElement)
GenerateColumns(IItemProperties)

生成对象指定属性的列。Generates columns for the specified properties of an object.

GetAnimationBaseValue(DependencyProperty)

为此元素上的指定属性返回基属性值,忽略任何可能来自正在运行或已停止的动画的动画值。Returns the base property value for the specified property on this element, disregarding any possible animated value from a running or stopped animation.

(继承自 UIElement)
GetBindingExpression(DependencyProperty)

返回表示指定属性的绑定的 BindingExpressionReturns the BindingExpression that represents the binding on the specified property.

(继承自 FrameworkElement)
GetContainerForItemOverride()

实例化一个新的 DataGridRowInstantiates a new DataGridRow.

GetDetailsVisibilityForItem(Object)

获取表示指定的数据项的 DetailsVisibilityDataGridRow 属性。Gets the DetailsVisibility property for the DataGridRow that represents the specified data item.

GetHashCode()

获取此 DependencyObject 的哈希代码。Gets a hash code for this DependencyObject.

(继承自 DependencyObject)
GetLayoutClip(Size)

返回剪切蒙版的形状。Returns a geometry for a clipping mask. 如果布局系统尝试排列的元素大小超过可用显示空间,将会应用蒙版。The mask applies if the layout system attempts to arrange an element that is larger than the available display space.

(继承自 FrameworkElement)
GetLocalValueEnumerator()

创建一个专用的枚举数,用于确定哪些依赖项属性在此 DependencyObject 上具有以本地方式设置的值。Creates a specialized enumerator for determining which dependency properties have locally set values on this DependencyObject.

(继承自 DependencyObject)
GetTemplateChild(String)

返回实例化的 ControlTemplate 可视化树中的命名元素。Returns the named element in the visual tree of an instantiated ControlTemplate.

(继承自 FrameworkElement)
GetType()

获取当前实例的 TypeGets the Type of the current instance.

(继承自 Object)
GetUIParentCore()

如果没有视觉父级,则返回此元素的备用逻辑父级。Returns an alternative logical parent for this element if there is no visual parent.

(继承自 FrameworkElement)
GetValue(DependencyProperty)

DependencyObject 的此实例返回依赖属性的当前有效值。Returns the current effective value of a dependency property on this instance of a DependencyObject.

(继承自 DependencyObject)
GetVisualChild(Int32)

重写 GetVisualChild(Int32),并从子元素集合中返回指定索引处的子元素。Overrides GetVisualChild(Int32), and returns a child at the specified index from a collection of child elements.

(继承自 FrameworkElement)
HitTestCore(GeometryHitTestParameters)

实现 HitTestCore(GeometryHitTestParameters) 以提供基元素命中测试行为(返回 GeometryHitTestResult)。Implements HitTestCore(GeometryHitTestParameters) to supply base element hit testing behavior (returning GeometryHitTestResult).

(继承自 UIElement)
HitTestCore(PointHitTestParameters)

实现 HitTestCore(PointHitTestParameters) 以提供基元素命中测试行为(返回 HitTestResult)。Implements HitTestCore(PointHitTestParameters) to supply base element hit testing behavior (returning HitTestResult).

(继承自 UIElement)
InputHitTest(Point)

返回指定坐标上的当前元素中的输入元素(相对于当前元素的源)。Returns the input element within the current element that is at the specified coordinates, relative to the current element's origin.

(继承自 UIElement)
InvalidateArrange()

使元素排列状态(布局)无效。Invalidates the arrange state (layout) for the element. 排列状态失效后,该元素将更新其布局,更新将以异步方式发生,除非随后由 UpdateLayout() 强制执行。After the invalidation, the element will have its layout updated, which will occur asynchronously unless subsequently forced by UpdateLayout().

(继承自 UIElement)
InvalidateMeasure()

使元素度量状态(布局)无效。Invalidates the measurement state (layout) for the element.

(继承自 UIElement)
InvalidateProperty(DependencyProperty)

重新评估指定依赖属性的有效值。Re-evaluates the effective value for the specified dependency property.

(继承自 DependencyObject)
InvalidateVisual()

使元素的呈现失效,并强制执行完整的新布局处理过程。Invalidates the rendering of the element, and forces a complete new layout pass. 完成布局循环后调用 OnRender(DrawingContext)OnRender(DrawingContext) is called after the layout cycle is completed.

(继承自 UIElement)
IsAncestorOf(DependencyObject)

确定可视对象是否为后代可视对象的上级。Determines whether the visual object is an ancestor of the descendant visual object.

(继承自 Visual)
IsDescendantOf(DependencyObject)

确定可视对象是否为上级可视对象的后代。Determines whether the visual object is a descendant of the ancestor visual object.

(继承自 Visual)
IsItemItsOwnContainer(Object)

确定指定项是否是(或者是否可以作为)其自己的容器。Determines if the specified item is (or is eligible to be) its own container.

(继承自 ItemsControl)
IsItemItsOwnContainerOverride(Object)

确定项是否为 DataGridRowDetermines if an item is a DataGridRow.

Measure(Size)

更新 DesiredSizeUIElementUpdates the DesiredSize of a UIElement. 父元素从其自身的 MeasureCore(Size) 实现调用此方法以形成递归布局更新。Parent elements call this method from their own MeasureCore(Size) implementations to form a recursive layout update. 调用此方法构成布局更新的第一个处理过程(“测量”处理过程)。Calling this method constitutes the first pass (the "Measure" pass) of a layout update.

(继承自 UIElement)
MeasureCore(Size)

实现 FrameworkElement 的基本度量传递布局系统行为。Implements basic measure-pass layout system behavior for FrameworkElement.

(继承自 FrameworkElement)
MeasureOverride(Size)

确定 DataGrid 的所需大小。Determines the desired size of the DataGrid.

MemberwiseClone()

创建当前 Object 的浅表副本。Creates a shallow copy of the current Object.

(继承自 Object)
MoveFocus(TraversalRequest)

以提供的遍历方向将键盘焦点从此元素移到其他元素上。Moves the keyboard focus away from this element and to another element in a provided traversal direction.

(继承自 FrameworkElement)
OnAccessKey(AccessKeyEventArgs)

在调用对于此元素有意义的访问键时提供类处理。Provides class handling for when an access key that is meaningful for this element is invoked.

(继承自 UIElement)
OnAddingNewItem(AddingNewItemEventArgs)

引发 AddingNewItem 事件。Raises the AddingNewItem event.

OnAlternationCountChanged(Int32, Int32)

AlternationCount 属性更改时调用。Invoked when the AlternationCount property changes.

(继承自 ItemsControl)
OnApplyTemplate()

每次应用程序代码或内部进程调用 ApplyTemplate() 时,都将调用此方法。Invoked whenever application code or internal processes call ApplyTemplate().

OnAutoGeneratedColumns(EventArgs)

引发 AutoGeneratedColumns 事件。Raises the AutoGeneratedColumns event.

OnAutoGeneratingColumn(DataGridAutoGeneratingColumnEventArgs)

引发 AutoGeneratingColumn 事件。Raises the AutoGeneratingColumn event.

OnBeginningEdit(DataGridBeginningEditEventArgs)

引发 BeginningEdit 事件。Raises the BeginningEdit event.

OnCanExecuteBeginEdit(CanExecuteRoutedEventArgs)

为与 CanExecute 命令关联的 BeginEditCommand 事件提供处理。Provides handling for the CanExecute event associated with the BeginEditCommand command.

OnCanExecuteCancelEdit(CanExecuteRoutedEventArgs)

为与 CanExecute 命令关联的 CancelEditCommand 事件提供处理。Provides handling for the CanExecute event associated with the CancelEditCommand command.

OnCanExecuteCommitEdit(CanExecuteRoutedEventArgs)

为与 CanExecute 命令关联的 CommitEditCommand 事件提供处理。Provides handling for the CanExecute event associated with the CommitEditCommand command.

OnCanExecuteCopy(CanExecuteRoutedEventArgs)

为与 CanExecute 命令关联的 Copy 事件提供处理。Provides handling for the CanExecute event associated with the Copy command.

OnCanExecuteDelete(CanExecuteRoutedEventArgs)

为与 CanExecute 命令关联的 DeleteCommand 事件提供处理。Provides handling for the CanExecute event associated with the DeleteCommand command.

OnCellEditEnding(DataGridCellEditEndingEventArgs)

引发 CellEditEnding 事件。Raises the CellEditEnding event.

OnChildDesiredSizeChanged(UIElement)

重新调整子元素的大小时支持布局行为。Supports layout behavior when a child element is resized.

(继承自 UIElement)
OnColumnDisplayIndexChanged(DataGridColumnEventArgs)

引发 ColumnDisplayIndexChanged 事件。Raises the ColumnDisplayIndexChanged event.

OnColumnHeaderDragCompleted(DragCompletedEventArgs)

引发 ColumnHeaderDragCompleted 事件。Raises the ColumnHeaderDragCompleted event.

OnColumnHeaderDragDelta(DragDeltaEventArgs)

引发 ColumnHeaderDragDelta 事件。Raises the ColumnHeaderDragDelta event.

OnColumnHeaderDragStarted(DragStartedEventArgs)

引发 ColumnHeaderDragStarted 事件。Raises the ColumnHeaderDragStarted event.

OnColumnReordered(DataGridColumnEventArgs)

引发 ColumnReordered 事件。Raises the ColumnReordered event.

OnColumnReordering(DataGridColumnReorderingEventArgs)

引发 ColumnReordering 事件。Raises the ColumnReordering event.

OnContextMenuClosing(ContextMenuEventArgs)

每当未处理的 ContextMenuClosing 路由事件在其路由中到达此类时调用。Invoked whenever an unhandled ContextMenuClosing routed event reaches this class in its route. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 FrameworkElement)
OnContextMenuOpening(ContextMenuEventArgs)

如果单元格上下文菜单已打开,则选择该单元格。Selects a cell if its context menu is opened.

OnCopyingRowClipboardContent(DataGridRowClipboardEventArgs)

引发 CopyingRowClipboardContent 事件。Raises the CopyingRowClipboardContent event.

OnCreateAutomationPeer()

返回此 DataGrid 的自动化对等方。Returns the automation peer for this DataGrid.

OnCurrentCellChanged(EventArgs)

引发 CurrentCellChanged 事件。Raises the CurrentCellChanged event.

OnDisplayMemberPathChanged(String, String)

DisplayMemberPath 属性更改时调用。Invoked when the DisplayMemberPath property changes.

(继承自 ItemsControl)
OnDpiChanged(DpiScale, DpiScale)

呈现此视图时所使用的 DPI 发生变化时进行调用。Called when the DPI at which this View is rendered changes.

(继承自 Visual)
OnDragEnter(DragEventArgs)

当某个未处理的 DragEnter 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled DragEnter attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnDragLeave(DragEventArgs)

当某个未处理的 DragLeave 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled DragLeave attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnDragOver(DragEventArgs)

当某个未处理的 DragOver 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled DragOver attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnDrop(DragEventArgs)

当某个未处理的 DragEnter 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled DragEnter attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnExecutedBeginEdit(ExecutedRoutedEventArgs)

为与 Executed 命令关联的 BeginEditCommand 事件提供处理。Provides handling for the Executed event associated with the BeginEditCommand command.

OnExecutedCancelEdit(ExecutedRoutedEventArgs)

为与 Executed 命令关联的 CancelEditCommand 事件提供处理。Provides handling for the Executed event associated with the CancelEditCommand command.

OnExecutedCommitEdit(ExecutedRoutedEventArgs)

为与 Executed 命令关联的 CommitEditCommand 事件提供处理。Provides handling for the Executed event associated with the CommitEditCommand command.

OnExecutedCopy(ExecutedRoutedEventArgs)

为与 Executed 命令关联的 Copy 事件提供处理。Provides handling for the Executed event associated with the Copy command.

OnExecutedDelete(ExecutedRoutedEventArgs)

为与 Executed 命令关联的 DeleteCommand 事件提供处理。Provides handling for the Executed event associated with the DeleteCommand command.

OnGiveFeedback(GiveFeedbackEventArgs)

当某个未处理的 GiveFeedback 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled GiveFeedback attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnGotFocus(RoutedEventArgs)

每当未处理的 GotFocus 事件在其路由中到达此元素时调用。Invoked whenever an unhandled GotFocus event reaches this element in its route.

(继承自 FrameworkElement)
OnGotKeyboardFocus(KeyboardFocusChangedEventArgs)

当某个未处理的 GotKeyboardFocus 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled GotKeyboardFocus attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnGotMouseCapture(MouseEventArgs)

当某个未处理的 GotMouseCapture 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled GotMouseCapture attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnGotStylusCapture(StylusEventArgs)

当某个未处理的 GotStylusCapture 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled GotStylusCapture attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnGotTouchCapture(TouchEventArgs)

为在此元素上捕获触摸屏输入时发生的 GotTouchCapture 路由事件提供类处理。Provides class handling for the GotTouchCapture routed event that occurs when a touch is captured to this element.

(继承自 UIElement)
OnGroupStyleSelectorChanged(GroupStyleSelector, GroupStyleSelector)

GroupStyleSelector 属性更改时调用。Invoked when the GroupStyleSelector property changes.

(继承自 ItemsControl)
OnInitialized(EventArgs)

引发 Initialized 事件。Raises the Initialized event. 每当在内部将 IsInitialized 设置为 true 时调用此方法。This method is invoked whenever IsInitialized is set to true internally.

(继承自 Selector)
OnInitializingNewItem(InitializingNewItemEventArgs)

引发 InitializingNewItem 事件。Raises the InitializingNewItem event.

OnIsKeyboardFocusedChanged(DependencyPropertyChangedEventArgs)

当针对此元素引发未处理的 IsKeyboardFocusedChanged 事件时调用。Invoked when an unhandled IsKeyboardFocusedChanged event is raised on this element. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnIsKeyboardFocusWithinChanged(DependencyPropertyChangedEventArgs)

IsKeyboardFocusWithin 属性更改时调用。Called when the IsKeyboardFocusWithin property has changed.

(继承自 Selector)
OnIsMouseCapturedChanged(DependencyPropertyChangedEventArgs)

在此元素的 IsMouseCaptured 属性更改时调用。Called when the IsMouseCaptured property changes on this element.

OnIsMouseCaptureWithinChanged(DependencyPropertyChangedEventArgs)

当针对此元素引发未处理的 IsMouseCaptureWithinChanged 事件时调用。Invoked when an unhandled IsMouseCaptureWithinChanged event is raised on this element. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnIsMouseDirectlyOverChanged(DependencyPropertyChangedEventArgs)

当针对此元素引发未处理的 IsMouseDirectlyOverChanged 事件时调用。Invoked when an unhandled IsMouseDirectlyOverChanged event is raised on this element. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnIsStylusCapturedChanged(DependencyPropertyChangedEventArgs)

当针对此元素引发未处理的 IsStylusCapturedChanged 事件时调用。Invoked when an unhandled IsStylusCapturedChanged event is raised on this element. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnIsStylusCaptureWithinChanged(DependencyPropertyChangedEventArgs)

当针对此元素引发未处理的 IsStylusCaptureWithinChanged 事件时调用。Invoked when an unhandled IsStylusCaptureWithinChanged event is raised on this element. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnIsStylusDirectlyOverChanged(DependencyPropertyChangedEventArgs)

当针对此元素引发未处理的 IsStylusDirectlyOverChanged 事件时调用。Invoked when an unhandled IsStylusDirectlyOverChanged event is raised on this element. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnItemBindingGroupChanged(BindingGroup, BindingGroup)

ItemBindingGroup 属性更改时调用。Invoked when the ItemBindingGroup property changes.

(继承自 ItemsControl)
OnItemContainerStyleChanged(Style, Style)

ItemContainerStyle 属性更改时调用。Invoked when the ItemContainerStyle property changes.

(继承自 ItemsControl)
OnItemContainerStyleSelectorChanged(StyleSelector, StyleSelector)

ItemContainerStyleSelector 属性更改时调用。Invoked when the ItemContainerStyleSelector property changes.

(继承自 ItemsControl)
OnItemsChanged(NotifyCollectionChangedEventArgs)

当项更改时执行列的自动生成并更新验证标志。Performs column auto generation and updates validation flags when items change.

OnItemsPanelChanged(ItemsPanelTemplate, ItemsPanelTemplate)

ItemsPanel 属性更改时调用。Invoked when the ItemsPanel property changes.

(继承自 ItemsControl)
OnItemsSourceChanged(IEnumerable, IEnumerable)

ItemsSource 属性更改时调用。Invoked when the ItemsSource property changes.

OnItemStringFormatChanged(String, String)

ItemStringFormat 属性更改时调用。Invoked when the ItemStringFormat property changes.

(继承自 ItemsControl)
OnItemTemplateChanged(DataTemplate, DataTemplate)

ItemTemplate 属性更改时调用。Invoked when the ItemTemplate property changes.

(继承自 ItemsControl)
OnItemTemplateSelectorChanged(DataTemplateSelector, DataTemplateSelector)

ItemTemplateSelector 属性更改时调用。Invoked when the ItemTemplateSelector property changes.

(继承自 ItemsControl)
OnKeyDown(KeyEventArgs)

在接收到 KeyDown 事件时调用。Invoked when the KeyDown event is received.

OnKeyUp(KeyEventArgs)

当某个未处理的 KeyUp 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled KeyUp attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnLoadingRow(DataGridRowEventArgs)

引发 LoadingRow 事件。Raises the LoadingRow event.

OnLoadingRowDetails(DataGridRowDetailsEventArgs)

引发 LoadingRowDetails 事件。Raises the LoadingRowDetails event.

OnLostFocus(RoutedEventArgs)

使用提供的事件数据引发 LostFocus 路由事件。Raises the LostFocus routed event by using the event data that is provided.

(继承自 UIElement)
OnLostKeyboardFocus(KeyboardFocusChangedEventArgs)

当某个未处理的 LostKeyboardFocus 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled LostKeyboardFocus attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnLostMouseCapture(MouseEventArgs)

当某个未处理的 LostMouseCapture 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled LostMouseCapture attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnLostStylusCapture(StylusEventArgs)

当某个未处理的 LostStylusCapture 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled LostStylusCapture attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnLostTouchCapture(TouchEventArgs)

为在此元素失去触摸屏输入捕获时发生的 LostTouchCapture 路由事件提供类处理。Provides class handling for the LostTouchCapture routed event that occurs when this element loses a touch capture.

(继承自 UIElement)
OnManipulationBoundaryFeedback(ManipulationBoundaryFeedbackEventArgs)

ManipulationBoundaryFeedback 事件发生时调用。Called when the ManipulationBoundaryFeedback event occurs.

(继承自 UIElement)
OnManipulationCompleted(ManipulationCompletedEventArgs)

ManipulationCompleted 事件发生时调用。Called when the ManipulationCompleted event occurs.

(继承自 UIElement)
OnManipulationDelta(ManipulationDeltaEventArgs)

ManipulationDelta 事件发生时调用。Called when the ManipulationDelta event occurs.

(继承自 UIElement)
OnManipulationInertiaStarting(ManipulationInertiaStartingEventArgs)

ManipulationInertiaStarting 事件发生时调用。Called when the ManipulationInertiaStarting event occurs.

(继承自 UIElement)
OnManipulationStarted(ManipulationStartedEventArgs)

ManipulationStarted 事件发生时调用。Called when the ManipulationStarted event occurs.

(继承自 UIElement)
OnManipulationStarting(ManipulationStartingEventArgs)

为在首次创建操作处理器时发生的 ManipulationStarting 路由事件提供类处理。Provides class handling for the ManipulationStarting routed event that occurs when the manipulation processor is first created.

(继承自 UIElement)
OnMouseDoubleClick(MouseButtonEventArgs)

引发 MouseDoubleClick 路由事件。Raises the MouseDoubleClick routed event.

(继承自 Control)
OnMouseDown(MouseButtonEventArgs)

当某个未处理的 MouseDown 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled MouseDown attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnMouseEnter(MouseEventArgs)

当此元素引发未处理的 MouseEnter 附加事件时调用。Invoked when an unhandled MouseEnter attached event is raised on this element. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnMouseLeave(MouseEventArgs)

当此元素引发未处理的 MouseLeave 附加事件时调用。Invoked when an unhandled MouseLeave attached event is raised on this element. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnMouseLeftButtonDown(MouseButtonEventArgs)

当此元素引发未处理的 MouseLeftButtonDown 路由事件时调用。Invoked when an unhandled MouseLeftButtonDown routed event is raised on this element. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnMouseLeftButtonUp(MouseButtonEventArgs)

当某个未处理的 MouseLeftButtonUp 路由事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled MouseLeftButtonUp routed event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnMouseMove(MouseEventArgs)

更新由于用户在 DataGrid 中拖动鼠标而选定的项的集合。Updates the collection of items that are selected due to the user dragging the mouse in the DataGrid.

OnMouseRightButtonDown(MouseButtonEventArgs)

当某个未处理的 MouseRightButtonDown 路由事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled MouseRightButtonDown routed event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnMouseRightButtonUp(MouseButtonEventArgs)

当某个未处理的 MouseRightButtonUp 路由事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled MouseRightButtonUp routed event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnMouseUp(MouseButtonEventArgs)

当某个未处理的 MouseUp 路由事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled MouseUp routed event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnMouseWheel(MouseWheelEventArgs)

当某个未处理的 MouseWheel 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled MouseWheel attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreparingCellForEdit(DataGridPreparingCellForEditEventArgs)

引发 PreparingCellForEdit 事件。Raises the PreparingCellForEdit event.

OnPreviewDragEnter(DragEventArgs)

当某个未处理的 PreviewDragEnter 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewDragEnter attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewDragLeave(DragEventArgs)

当某个未处理的 PreviewDragLeave 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewDragLeave attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewDragOver(DragEventArgs)

当某个未处理的 PreviewDragOver 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewDragOver attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewDrop(DragEventArgs)

当某个未处理的 PreviewDrop 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewDrop attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewGiveFeedback(GiveFeedbackEventArgs)

当某个未处理的 PreviewGiveFeedback 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewGiveFeedback attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewGotKeyboardFocus(KeyboardFocusChangedEventArgs)

当某个未处理的 PreviewGotKeyboardFocus 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewGotKeyboardFocus attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewKeyDown(KeyEventArgs)

当某个未处理的 PreviewKeyDown 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewKeyDown attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewKeyUp(KeyEventArgs)

当某个未处理的 PreviewKeyUp 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewKeyUp attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewLostKeyboardFocus(KeyboardFocusChangedEventArgs)

当某个未处理的 PreviewKeyDown 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewKeyDown attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewMouseDoubleClick(MouseButtonEventArgs)

引发 PreviewMouseDoubleClick 路由事件。Raises the PreviewMouseDoubleClick routed event.

(继承自 Control)
OnPreviewMouseDown(MouseButtonEventArgs)

当某个未处理的 PreviewMouseDown 附加路由事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewMouseDown attached routed event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewMouseLeftButtonDown(MouseButtonEventArgs)

当某个未处理的 PreviewMouseLeftButtonDown 路由事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewMouseLeftButtonDown routed event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewMouseLeftButtonUp(MouseButtonEventArgs)

当某个未处理的 PreviewMouseLeftButtonUp 路由事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewMouseLeftButtonUp routed event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewMouseMove(MouseEventArgs)

当某个未处理的 PreviewMouseMove 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewMouseMove attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewMouseRightButtonDown(MouseButtonEventArgs)

当某个未处理的 PreviewMouseRightButtonDown 路由事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewMouseRightButtonDown routed event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewMouseRightButtonUp(MouseButtonEventArgs)

当某个未处理的 PreviewMouseRightButtonUp 路由事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewMouseRightButtonUp routed event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewMouseUp(MouseButtonEventArgs)

当某个未处理的 PreviewMouseUp 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewMouseUp attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewMouseWheel(MouseWheelEventArgs)

当某个未处理的 PreviewMouseWheel 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewMouseWheel attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewQueryContinueDrag(QueryContinueDragEventArgs)

当某个未处理的 PreviewQueryContinueDrag 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewQueryContinueDrag attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewStylusButtonDown(StylusButtonEventArgs)

当某个未处理的 PreviewStylusButtonDown 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewStylusButtonDown attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewStylusButtonUp(StylusButtonEventArgs)

当某个未处理的 PreviewStylusButtonUp 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewStylusButtonUp attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewStylusDown(StylusDownEventArgs)

当某个未处理的 PreviewStylusDown 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewStylusDown attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewStylusInAirMove(StylusEventArgs)

当某个未处理的 PreviewStylusInAirMove 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewStylusInAirMove attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewStylusInRange(StylusEventArgs)

当某个未处理的 PreviewStylusInRange 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewStylusInRange attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewStylusMove(StylusEventArgs)

当某个未处理的 PreviewStylusMove 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewStylusMove attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewStylusOutOfRange(StylusEventArgs)

当某个未处理的 PreviewStylusOutOfRange 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewStylusOutOfRange attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewStylusSystemGesture(StylusSystemGestureEventArgs)

当某个未处理的 PreviewStylusSystemGesture 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewStylusSystemGesture attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewStylusUp(StylusEventArgs)

当某个未处理的 PreviewStylusUp 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewStylusUp attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewTextInput(TextCompositionEventArgs)

当某个未处理的 PreviewTextInput 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled PreviewTextInput attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnPreviewTouchDown(TouchEventArgs)

为在触摸屏输入按下此元素时发生的 PreviewTouchDown 路由事件提供类处理。Provides class handling for the PreviewTouchDown routed event that occurs when a touch presses this element.

(继承自 UIElement)
OnPreviewTouchMove(TouchEventArgs)

为在此元素内部移动触摸屏输入时发生的 PreviewTouchMove 路由事件提供类处理。Provides class handling for the PreviewTouchMove routed event that occurs when a touch moves while inside this element.

(继承自 UIElement)
OnPreviewTouchUp(TouchEventArgs)

为在此元素内部释放触摸屏输入时发生的 PreviewTouchUp 路由事件提供类处理。Provides class handling for the PreviewTouchUp routed event that occurs when a touch is released inside this element.

(继承自 UIElement)
OnPropertyChanged(DependencyPropertyChangedEventArgs)

每当更新此 FrameworkElement 的任何依赖属性的有效值时调用。Invoked whenever the effective value of any dependency property on this FrameworkElement has been updated. 将在实参形参中报告已更改的特定依赖属性。The specific dependency property that changed is reported in the arguments parameter. 重写 OnPropertyChanged(DependencyPropertyChangedEventArgs)Overrides OnPropertyChanged(DependencyPropertyChangedEventArgs).

(继承自 FrameworkElement)
OnQueryContinueDrag(QueryContinueDragEventArgs)

当某个未处理的 QueryContinueDrag 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled QueryContinueDrag attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnQueryCursor(QueryCursorEventArgs)

当某个未处理的 QueryCursor 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled QueryCursor attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnRender(DrawingContext)

在派生类中重写时,会参与由布局系统控制的呈现操作。When overridden in a derived class, participates in rendering operations that are directed by the layout system. 调用此方法时,不直接使用此元素的呈现指令,而是将其保留供布局和绘制在以后异步使用。The rendering instructions for this element are not used directly when this method is invoked, and are instead preserved for later asynchronous use by layout and drawing.

(继承自 UIElement)
OnRenderSizeChanged(SizeChangedInfo)

引发 SizeChanged 事件,将指定的信息用作最终事件数据的一部分。Raises the SizeChanged event, using the specified information as part of the eventual event data.

(继承自 FrameworkElement)
OnRowDetailsVisibilityChanged(DataGridRowDetailsEventArgs)

引发 RowDetailsVisibilityChanged 事件。Raises the RowDetailsVisibilityChanged event.

OnRowEditEnding(DataGridRowEditEndingEventArgs)

引发 RowEditEnding 事件。Raises the RowEditEnding event.

OnSelectedCellsChanged(SelectedCellsChangedEventArgs)

引发 SelectedCellsChanged 事件。Raises the SelectedCellsChanged event.

OnSelectionChanged(SelectionChangedEventArgs)

当选择更改时调用。Invoked when the selection changes.

OnSorting(DataGridSortingEventArgs)

引发 Sorting 事件。Raises the Sorting event.

OnStyleChanged(Style, Style)

当此元素上使用的样式更改时(将使布局失效)调用。Invoked when the style in use on this element changes, which will invalidate the layout.

(继承自 FrameworkElement)
OnStylusButtonDown(StylusButtonEventArgs)

当某个未处理的 StylusButtonDown 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled StylusButtonDown attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnStylusButtonUp(StylusButtonEventArgs)

当某个未处理的 StylusButtonUp 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled StylusButtonUp attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnStylusDown(StylusDownEventArgs)

当某个未处理的 StylusDown 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled StylusDown attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnStylusEnter(StylusEventArgs)

当此元素引发未处理的 StylusEnter 附加事件时调用。Invoked when an unhandled StylusEnter attached event is raised by this element. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnStylusInAirMove(StylusEventArgs)

当某个未处理的 StylusInAirMove 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled StylusInAirMove attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnStylusInRange(StylusEventArgs)

当某个未处理的 StylusInRange 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled StylusInRange attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnStylusLeave(StylusEventArgs)

当此元素引发未处理的 StylusLeave 附加事件时调用。Invoked when an unhandled StylusLeave attached event is raised by this element. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnStylusMove(StylusEventArgs)

当某个未处理的 StylusMove 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled StylusMove attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnStylusOutOfRange(StylusEventArgs)

当某个未处理的 StylusOutOfRange 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled StylusOutOfRange attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnStylusSystemGesture(StylusSystemGestureEventArgs)

当某个未处理的 StylusSystemGesture 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled StylusSystemGesture attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnStylusUp(StylusEventArgs)

当某个未处理的 StylusUp 附加事件在其路由中到达派生自此类的某个元素时调用。Invoked when an unhandled StylusUp attached event reaches an element in its route that is derived from this class. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 UIElement)
OnTemplateChanged(ControlTemplate, ControlTemplate)

每当 DataGrid 的模板发生更改时调用。Called whenever the template of the DataGrid changes.

OnTextInput(TextCompositionEventArgs)

提供用于 TextInput 路由事件的类处理。Provides class handling for the TextInput routed event.

OnToolTipClosing(ToolTipEventArgs)

每当未处理的 ToolTipClosing 路由事件在其路由中到达此类时调用。Invoked whenever an unhandled ToolTipClosing routed event reaches this class in its route. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 FrameworkElement)
OnToolTipOpening(ToolTipEventArgs)

每当 ToolTipOpening 路由事件在其路由中到达此类时调用。Invoked whenever the ToolTipOpening routed event reaches this class in its route. 实现此方法可为此事件添加类处理。Implement this method to add class handling for this event.

(继承自 FrameworkElement)
OnTouchDown(TouchEventArgs)

为在此元素内按下触摸屏输入时发生的 TouchDown 路由事件提供类处理。Provides class handling for the TouchDown routed event that occurs when a touch presses inside this element.

(继承自 UIElement)
OnTouchEnter(TouchEventArgs)

为在触摸屏输入从此元素边界外部移动到其内部时发生的 TouchEnter 路由事件提供类处理。Provides class handling for the TouchEnter routed event that occurs when a touch moves from outside to inside the bounds of this element.

(继承自 UIElement)
OnTouchLeave(TouchEventArgs)

为在触摸屏输入从此 TouchLeave 边界内部移动到其外部时发生的 UIElement 路由事件提供类处理。Provides class handling for the TouchLeave routed event that occurs when a touch moves from inside to outside the bounds of this UIElement.

(继承自 UIElement)
OnTouchMove(TouchEventArgs)

为在此元素内部移动触摸屏输入时发生的 TouchMove 路由事件提供类处理。Provides class handling for the TouchMove routed event that occurs when a touch moves while inside this element.

(继承自 UIElement)
OnTouchUp(TouchEventArgs)

为在此元素内部释放触摸屏输入时发生的 TouchUp 路由事件提供类处理。Provides class handling for the TouchUp routed event that occurs when a touch is released inside this element.

(继承自 UIElement)
OnUnloadingRow(DataGridRowEventArgs)

引发 UnloadingRow 事件。Raises the UnloadingRow event.

OnUnloadingRowDetails(DataGridRowDetailsEventArgs)

引发 UnloadingRowDetails 事件。Raises the UnloadingRowDetails event.

OnVisualChildrenChanged(DependencyObject, DependencyObject)

修改可视对象的 VisualCollection 时调用。Called when the VisualCollection of the visual object is modified.

(继承自 Visual)
OnVisualParentChanged(DependencyObject)

当此元素父级在可视化树中发生更改时进行了调用。Invoked when the parent of this element in the visual tree is changed. 重写 OnVisualParentChanged(DependencyObject)Overrides OnVisualParentChanged(DependencyObject).

(继承自 FrameworkElement)
ParentLayoutInvalidated(UIElement)

支持 FrameworkElement 的专用子类中的增量布局实现。Supports incremental layout implementations in specialized subclasses of FrameworkElement. 如果子元素包含无效属性,且该属性在元数据中标记为影响布局过程中父元素的测量或排列过程的因素,则调用 ParentLayoutInvalidated(UIElement)ParentLayoutInvalidated(UIElement) is invoked when a child element has invalidated a property that is marked in metadata as affecting the parent's measure or arrange passes during layout.

(继承自 FrameworkElement)
PointFromScreen(Point)

将屏幕坐标中的 Point 转换为表示 Point 的当前坐标系的 VisualConverts a Point in screen coordinates into a Point that represents the current coordinate system of the Visual.

(继承自 Visual)
PointToScreen(Point)

将表示 Point 的当前坐标系的 Visual 转换为屏幕坐标中的 PointConverts a Point that represents the current coordinate system of the Visual into a Point in screen coordinates.

(继承自 Visual)
PredictFocus(FocusNavigationDirection)

根据提供的焦点移动方向,确定在此元素之后接收焦点的下一个元素,但不实际移动焦点。Determines the next element that would receive focus relative to this element for a provided focus movement direction, but does not actually move the focus.

(继承自 FrameworkElement)
PrepareContainerForItemOverride(DependencyObject, Object)

为指定项准备新行。Prepares a new row for the specified item.

RaiseEvent(RoutedEventArgs)

引发特定路由事件。Raises a specific routed event. 在提供的 RoutedEvent 实例内标识将引发的 RoutedEventArgs(作为该事件数据的 RoutedEvent 属性)。The RoutedEvent to be raised is identified within the RoutedEventArgs instance that is provided (as the RoutedEvent property of that event data).

(继承自 UIElement)
ReadLocalValue(DependencyProperty)

如果存在,则返回依赖属性的本地值。Returns the local value of a dependency property, if it exists.

(继承自 DependencyObject)
RegisterName(String, Object)

提供一个可简化对 NameScope 注册方法访问的访问器。Provides an accessor that simplifies access to the NameScope registration method.

(继承自 FrameworkElement)
ReleaseAllTouchCaptures()

从此元素中释放所有捕获的触摸设备。Releases all captured touch devices from this element.

(继承自 UIElement)
ReleaseMouseCapture()

如果此元素具有鼠标捕获,则释放该捕获。Releases the mouse capture, if this element held the capture.

(继承自 UIElement)
ReleaseStylusCapture()

如果此元素具有触笔设备捕获,则释放该捕获。Releases the stylus device capture, if this element held the capture.

(继承自 UIElement)
ReleaseTouchCapture(TouchDevice)

尝试从此元素释放指定触摸设备。Attempts to release the specified touch device from this element.

(继承自 UIElement)
RemoveHandler(RoutedEvent, Delegate)

从此元素中删除指定的路由事件处理程序。Removes the specified routed event handler from this element.

(继承自 UIElement)
RemoveLogicalChild(Object)

从此元素的逻辑树中删除所提供的对象。Removes the provided object from this element's logical tree. FrameworkElement 将更新受影响的逻辑树父指针,以便与此删除操作保持同步。FrameworkElement updates the affected logical tree parent pointers to keep in sync with this deletion.

(继承自 FrameworkElement)
RemoveVisualChild(Visual)

移除两个可视对象之间的父子关系。Removes the parent-child relationship between two visuals.

(继承自 Visual)
ScrollIntoView(Object)

DataGrid 垂直滚动,以显示指定数据项的行。Scrolls the DataGrid vertically to display the row for the specified data item.

ScrollIntoView(Object, DataGridColumn)

DataGrid 垂直和水平滚动,以显示指定数据项和列的单元格。Scrolls the DataGrid vertically and horizontally to display a cell for the specified data item and column.

SelectAll()

选择 MultiSelector 中的所有项。Selects all of the items in the MultiSelector.

(继承自 MultiSelector)
SelectAllCells()

选择 DataGrid 中的所有单元格。Selects all the cells in the DataGrid.

SetBinding(DependencyProperty, BindingBase)

基于已提供的绑定对象将一个绑定附加到此元素上。Attaches a binding to this element, based on the provided binding object.

(继承自 FrameworkElement)
SetBinding(DependencyProperty, String)

将提供的源属性名作为数据源的路径限定,从而将绑定附加到此元素上。Attaches a binding to this element, based on the provided source property name as a path qualification to the data source.

(继承自 FrameworkElement)
SetCurrentValue(DependencyProperty, Object)

设置依赖属性的值而不更改其值源。Sets the value of a dependency property without changing its value source.

(继承自 DependencyObject)
SetDetailsVisibilityForItem(Object, Visibility)

为包含指定对象的 DetailsVisibility 设置 DataGridRow 属性的值。Sets the value of the DetailsVisibility property for the DataGridRow that contains the specified object.

SetResourceReference(DependencyProperty, Object)

搜索具有指定名称的资源,并且为指定的属性设置一个指向该资源的资源引用。Searches for a resource with the specified name and sets up a resource reference to it for the specified property.

(继承自 FrameworkElement)
SetValue(DependencyProperty, Object)

设置依赖属性的本地值,该值由其依赖属性标识符指定。Sets the local value of a dependency property, specified by its dependency property identifier.

(继承自 DependencyObject)
SetValue(DependencyPropertyKey, Object)

设置一个只读依赖属性的本地值,该值由依赖属性的 DependencyPropertyKey 标识符指定。Sets the local value of a read-only dependency property, specified by the DependencyPropertyKey identifier of the dependency property.

(继承自 DependencyObject)
ShouldApplyItemContainerStyle(DependencyObject, Object)

返回一个值,该值表示是否将属性 ItemContainerStyleItemContainerStyleSelector 的样式应用到指定的项的容器元素。Returns a value that indicates whether to apply the style from the ItemContainerStyle or ItemContainerStyleSelector property to the container element of the specified item.

(继承自 ItemsControl)
ShouldSerializeCommandBindings()

返回序列化进程是否应在此类的实例上序列化 CommandBindings 属性的内容。Returns whether serialization processes should serialize the contents of the CommandBindings property on instances of this class.

(继承自 UIElement)
ShouldSerializeGroupStyle()

返回一个值,该值指示序列化进程是否应序列化 GroupStyle 属性的有效值。Returns a value that indicates whether serialization processes should serialize the effective value of the GroupStyle property.

(继承自 ItemsControl)
ShouldSerializeInputBindings()

返回序列化进程是否应在此类的实例上序列化 InputBindings 属性的内容。Returns whether serialization processes should serialize the contents of the InputBindings property on instances of this class.

(继承自 UIElement)
ShouldSerializeItems()

返回一个值,该值指示序列化进程是否应序列化 Items 属性的有效值。Returns a value that indicates whether serialization processes should serialize the effective value of the Items property.

(继承自 ItemsControl)
ShouldSerializeProperty(DependencyProperty)

返回一个值,该值指示序列化进程是否应序列化所提供的依赖属性的值。Returns a value that indicates whether serialization processes should serialize the value for the provided dependency property.

(继承自 DependencyObject)
ShouldSerializeResources()

返回一个值,该值指示序列化过程是否应该序列化 Resources 属性的内容。Returns whether serialization processes should serialize the contents of the Resources property.

(继承自 FrameworkElement)
ShouldSerializeStyle()

返回一个值,该值指示序列化过程是否应该序列化 Style 属性的内容。Returns whether serialization processes should serialize the contents of the Style property.

(继承自 FrameworkElement)
ShouldSerializeTriggers()

返回一个值,该值指示序列化过程是否应该序列化 Triggers 属性的内容。Returns whether serialization processes should serialize the contents of the Triggers property.

(继承自 FrameworkElement)
ToString()

提供 ItemsControl 对象的字符串表示形式。Provides a string representation of the ItemsControl object.

(继承自 ItemsControl)
TransformToAncestor(Visual)

返回一个转换,该转换可用于将 Visual 中的坐标转换为可视对象的指定 Visual 上级。Returns a transform that can be used to transform coordinates from the Visual to the specified Visual ancestor of the visual object.

(继承自 Visual)
TransformToAncestor(Visual3D)

返回一个转换,该转换可用于将 Visual 中的坐标转换为可视对象的指定 Visual3D 上级。Returns a transform that can be used to transform coordinates from the Visual to the specified Visual3D ancestor of the visual object.

(继承自 Visual)
TransformToDescendant(Visual)

返回一个转换,该转换可用于将 Visual 中的坐标转换为指定的可视对象后代。Returns a transform that can be used to transform coordinates from the Visual to the specified visual object descendant.

(继承自 Visual)
TransformToVisual(Visual)

返回一个转换,该转换可用于将 Visual 中的坐标转换为指定的可视对象。Returns a transform that can be used to transform coordinates from the Visual to the specified visual object.

(继承自 Visual)
TranslatePoint(Point, UIElement)

将相对于此元素的点转换为相对于指定元素的坐标。Translates a point relative to this element to coordinates that are relative to the specified element.

(继承自 UIElement)
TryFindResource(Object)

搜索具有指定键的资源,如果找到,则返回该资源。Searches for a resource with the specified key, and returns that resource if found.

(继承自 FrameworkElement)
UnregisterName(String)

简化对 NameScope 注销方法的访问。Simplifies access to the NameScope de-registration method.

(继承自 FrameworkElement)
UnselectAll()

取消选择 MultiSelector 中的所有项。Unselects all of the items in the MultiSelector.

(继承自 MultiSelector)
UnselectAllCells()

取消选择 DataGrid 中的所有单元格。Unselects all the cells in the DataGrid.

UpdateDefaultStyle()

将默认样式重新应用至当前 FrameworkElementReapplies the default style to the current FrameworkElement.

(继承自 FrameworkElement)
UpdateLayout()

请确保此元素的所有可视子元素都正确地进行了布局更新。Ensures that all visual child elements of this element are properly updated for layout.

(继承自 UIElement)
VerifyAccess()

强制调用线程具有此 DispatcherObject 的访问权限。Enforces that the calling thread has access to this DispatcherObject.

(继承自 DispatcherObject)

事件

AddingNewItem

在将项添加到 DataGrid 前发生。Occurs before a new item is added to the DataGrid.

AutoGeneratedColumns

在完成所有列的自动生成操作时发生。Occurs when auto generation of all columns is completed.

AutoGeneratingColumn

在自动生成了单独的列时发生。Occurs when an individual column is auto-generated.

BeginningEdit

在行或单元格进入编辑模式之前发生。Occurs before a row or cell enters edit mode.

CellEditEnding

在提交或取消单元格编辑之前发生。Occurs before a cell edit is committed or canceled.

ColumnDisplayIndexChanged

在某一列的 DisplayIndex 属性更改时发生。Occurs when the DisplayIndex property on one of the columns changes.

ColumnHeaderDragCompleted

在用户使用鼠标拖动列标题后释放列标题时发生。Occurs when the user releases a column header after dragging it by using the mouse.

ColumnHeaderDragDelta

每次当鼠标位置在用户拖动列标题时发生更改时发生。Occurs every time the mouse position changes while the user drags a column header.

ColumnHeaderDragStarted

在用户使用鼠标开始拖动列标题时发生。Occurs when the user begins dragging a column header by using the mouse.

ColumnReordered

在列移至显示顺序中的新位置时发生。Occurs when a column moves to a new position in the display order.

ColumnReordering

在列移至显示顺序中的新位置之前发生。Occurs before a column moves to a new position in the display order.

ContextMenuClosing

在元素上的任何上下文菜单关闭之前发生。Occurs just before any context menu on the element is closed.

(继承自 FrameworkElement)
ContextMenuOpening

在元素上的任何上下文菜单打开时发生。Occurs when any context menu on the element is opened.

(继承自 FrameworkElement)
CopyingRowClipboardContent

在默认行内容准备好之后发生。Occurs after the default row content is prepared.

CurrentCellChanged

CurrentCell 属性的值更改后发生。Occurs when the value of the CurrentCell property has changed.

DataContextChanged

在此元素的数据上下文更改时发生。Occurs when the data context for this element changes.

(继承自 FrameworkElement)
DragEnter

在输入系统报告出现以此元素为拖动目标的基础拖动事件时发生。Occurs when the input system reports an underlying drag event with this element as the drag target.

(继承自 UIElement)
DragLeave

在输入系统报告出现以此元素为拖动起点的基础拖动事件时发生。Occurs when the input system reports an underlying drag event with this element as the drag origin.

(继承自 UIElement)
DragOver

在输入系统报告出现以此元素为可能放置目标的基础拖动事件时发生。Occurs when the input system reports an underlying drag event with this element as the potential drop target.

(继承自 UIElement)
Drop

在输入系统报告出现将此元素作为放置目标的基础放置事件时发生。Occurs when the input system reports an underlying drop event with this element as the drop target.

(继承自 UIElement)
FocusableChanged

Focusable 属性的值更改时发生。Occurs when the value of the Focusable property changes.

(继承自 UIElement)
GiveFeedback

在输入系统报告出现涉及此元素的基础拖放操作时发生。Occurs when the input system reports an underlying drag-and-drop event that involves this element.

(继承自 UIElement)
GotFocus

在此元素获得逻辑焦点时发生。Occurs when this element gets logical focus.

(继承自 UIElement)
GotKeyboardFocus

在此元素聚焦于键盘时发生。Occurs when the keyboard is focused on this element.

(继承自 UIElement)
GotMouseCapture

在此元素捕获鼠标时发生。Occurs when this element captures the mouse.

(继承自 UIElement)
GotStylusCapture

在此元素捕获触笔时发生。Occurs when this element captures the stylus.

(继承自 UIElement)
GotTouchCapture

在此元素上捕获触摸屏输入时发生。Occurs when a touch is captured to this element.

(继承自 UIElement)
Initialized

初始化此 FrameworkElement 时发生。Occurs when this FrameworkElement is initialized. 此事件与 IsInitialized 属性的值从 false(或未定义)更改为 true 的情况相符。This event coincides with cases where the value of the IsInitialized property changes from false (or undefined) to true.

(继承自 FrameworkElement)
InitializingNewItem

在创建新项时发生。Occurs when a new item is created.

IsEnabledChanged

在此元素的 IsEnabled 属性值更改时发生。Occurs when the value of the IsEnabled property on this element changes.

(继承自 UIElement)
IsHitTestVisibleChanged

在此元素的 IsHitTestVisible 依赖项属性值更改时发生。Occurs when the value of the IsHitTestVisible dependency property changes on this element.

(继承自 UIElement)
IsKeyboardFocusedChanged

在此元素的 IsKeyboardFocused 属性值更改时发生。Occurs when the value of the IsKeyboardFocused property changes on this element.

(继承自 UIElement)
IsKeyboardFocusWithinChanged

在此元素的 IsKeyboardFocusWithin 属性值更改时发生。Occurs when the value of the IsKeyboardFocusWithin property changes on this element.

(继承自 UIElement)
IsMouseCapturedChanged

在此元素的 IsMouseCaptured 属性值更改时发生。Occurs when the value of the IsMouseCaptured property changes on this element.

(继承自 UIElement)
IsMouseCaptureWithinChanged

在此元素的 IsMouseCaptureWithinProperty 值更改时发生。Occurs when the value of the IsMouseCaptureWithinProperty changes on this element.

(继承自 UIElement)
IsMouseDirectlyOverChanged

在此元素的 IsMouseDirectlyOver 属性值更改时发生。Occurs when the value of the IsMouseDirectlyOver property changes on this element.

(继承自 UIElement)
IsStylusCapturedChanged

在此元素的 IsStylusCaptured 属性值更改时发生。Occurs when the value of the IsStylusCaptured property changes on this element.

(继承自 UIElement)
IsStylusCaptureWithinChanged

在此元素的 IsStylusCaptureWithin 属性值更改时发生。Occurs when the value of the IsStylusCaptureWithin property changes on this element.

(继承自 UIElement)
IsStylusDirectlyOverChanged

在此元素的 IsStylusDirectlyOver 属性值更改时发生。Occurs when the value of the IsStylusDirectlyOver property changes on this element.

(继承自 UIElement)
IsVisibleChanged

在此元素的 IsVisible 属性值更改时发生。Occurs when the value of the IsVisible property changes on this element.

(继承自 UIElement)
KeyDown

当焦点在该元素上时按下某个键后发生。Occurs when a key is pressed while focus is on this element.

(继承自 UIElement)
KeyUp

当焦点在该元素上时松开某个键后发生。Occurs when a key is released while focus is on this element.

(继承自 UIElement)
LayoutUpdated

在与当前 Dispatcher 关联的各种可视元素的布局更改时发生。Occurs when the layout of the various visual elements associated with the current Dispatcher changes.

(继承自 UIElement)
Loaded

当对元素进行布局、呈现,且可将其用于交互时发生。Occurs when the element is laid out, rendered, and ready for interaction.

(继承自 FrameworkElement)
LoadingRow

当实例化 DataGridRow 之后发生,以便您可以在使用它之前先进行自定义。Occurs after a DataGridRow is instantiated, so that you can customize it before it is used.

LoadingRowDetails

当新的行详细信息模板应用到行时发生。Occurs when a new row details template is applied to a row.

LostFocus

在此元素丢失逻辑焦点时发生。Occurs when this element loses logical focus.

(继承自 UIElement)
LostKeyboardFocus

在键盘焦点不再位于此元素上时发生。Occurs when the keyboard is no longer focused on this element,.

(继承自 UIElement)
LostMouseCapture

在此元素丢失鼠标捕获时发生。Occurs when this element loses mouse capture.

(继承自 UIElement)
LostStylusCapture

在此元素丢失触笔捕获时发生。Occurs when this element loses stylus capture.

(继承自 UIElement)
LostTouchCapture

在此元素失去触摸屏输入捕获时发生。Occurs when this element loses a touch capture.

(继承自 UIElement)
ManipulationBoundaryFeedback

当操作遇到边界时发生。Occurs when the manipulation encounters a boundary.

(继承自 UIElement)
ManipulationCompleted

对于 UIElement 对象的操作和延时完毕时发生。Occurs when a manipulation and inertia on the UIElement object is complete.

(继承自 UIElement)
ManipulationDelta

当输入设备在操作期间更改位置时发生。Occurs when the input device changes position during a manipulation.

(继承自 UIElement)
ManipulationInertiaStarting

当输入设备在操作期间与 UIElement 对象失去联系且延时开始时发生。Occurs when the input device loses contact with the UIElement object during a manipulation and inertia begins.

(继承自 UIElement)
ManipulationStarted

当输入设备对 UIElement 对象开始操作时发生。Occurs when an input device begins a manipulation on the UIElement object.

(继承自 UIElement)
ManipulationStarting

在首次创建操作处理器时发生。Occurs when the manipulation processor is first created.

(继承自 UIElement)
MouseDoubleClick

在双击或多次单击鼠标按钮时发生。Occurs when a mouse button is clicked two or more times.

(继承自 Control)
MouseDown

在指针位于此元素上并且按下任意鼠标按钮时发生。Occurs when any mouse button is pressed while the pointer is over this element.

(继承自 UIElement)
MouseEnter

在鼠标指针进入此元素的边界时发生。Occurs when the mouse pointer enters the bounds of this element.

(继承自 UIElement)
MouseLeave

在鼠标指针离开此元素的边界时发生。Occurs when the mouse pointer leaves the bounds of this element.

(继承自 UIElement)
MouseLeftButtonDown

在鼠标指针位于此元素上并且按下鼠标左键时发生。Occurs when the left mouse button is pressed while the mouse pointer is over this element.

(继承自 UIElement)
MouseLeftButtonUp

在鼠标指针位于此元素上并且松开鼠标左键时发生。Occurs when the left mouse button is released while the mouse pointer is over this element.

(继承自 UIElement)
MouseMove

在鼠标指针位于此元素上并且移动鼠标指针时发生。Occurs when the mouse pointer moves while over this element.

(继承自 UIElement)
MouseRightButtonDown

在鼠标指针位于此元素上并且按下鼠标右键时发生。Occurs when the right mouse button is pressed while the mouse pointer is over this element.

(继承自 UIElement)
MouseRightButtonUp

在鼠标指针位于此元素上并且松开鼠标右键时发生。Occurs when the right mouse button is released while the mouse pointer is over this element.

(继承自 UIElement)
MouseUp

在鼠标指针位于此元素上并且松开任意鼠标按钮时发生。Occurs when any mouse button is released over this element.

(继承自 UIElement)
MouseWheel

在鼠标指针位于此元素上并且用户滚动鼠标滚轮时发生。Occurs when the user rotates the mouse wheel while the mouse pointer is over this element.

(继承自 UIElement)
PreparingCellForEdit

在单元格进入编辑模式时发生。Occurs when a cell enters edit mode.

PreviewDragEnter

在输入系统报告出现以此元素为拖动目标的基础拖动事件时发生。Occurs when the input system reports an underlying drag event with this element as the drag target.

(继承自 UIElement)
PreviewDragLeave

在输入系统报告出现以此元素为拖动起点的基础拖动事件时发生。Occurs when the input system reports an underlying drag event with this element as the drag origin.

(继承自 UIElement)
PreviewDragOver

在输入系统报告出现以此元素为可能放置目标的基础拖动事件时发生。Occurs when the input system reports an underlying drag event with this element as the potential drop target.

(继承自 UIElement)
PreviewDrop

在输入系统报告出现将此元素作为放置目标的基础放置事件时发生。Occurs when the input system reports an underlying drop event with this element as the drop target.

(继承自 UIElement)
PreviewGiveFeedback

在开始拖放操作时发生。Occurs when a drag-and-drop operation is started.

(继承自 UIElement)
PreviewGotKeyboardFocus

在此元素聚焦于键盘时发生。Occurs when the keyboard is focused on this element.

(继承自 UIElement)
PreviewKeyDown

当焦点在该元素上时按下某个键后发生。Occurs when a key is pressed while focus is on this element.

(继承自 UIElement)
PreviewKeyUp

当焦点在该元素上时松开某个键后发生。Occurs when a key is released while focus is on this element.

(继承自 UIElement)
PreviewLostKeyboardFocus

在此元素不再聚焦于键盘时发生。Occurs when the keyboard is no longer focused on this element.

(继承自 UIElement)
PreviewMouseDoubleClick

在用户单击鼠标按钮两次或更多次时发生。Occurs when a user clicks the mouse button two or more times.

(继承自 Control)
PreviewMouseDown

在指针位于此元素上并且按下任意鼠标按钮时发生。Occurs when any mouse button is pressed while the pointer is over this element.

(继承自 UIElement)
PreviewMouseLeftButtonDown

在鼠标指针位于此元素上并且按下鼠标左键时发生。Occurs when the left mouse button is pressed while the mouse pointer is over this element.

(继承自 UIElement)
PreviewMouseLeftButtonUp

在鼠标指针位于此元素上并且松开鼠标左键时发生。Occurs when the left mouse button is released while the mouse pointer is over this element.

(继承自 UIElement)
PreviewMouseMove

在鼠标指针位于此元素上并且移动鼠标指针时发生。Occurs when the mouse pointer moves while the mouse pointer is over this element.

(继承自 UIElement)
PreviewMouseRightButtonDown

在鼠标指针位于此元素上并且按下鼠标右键时发生。Occurs when the right mouse button is pressed while the mouse pointer is over this element.

(继承自 UIElement)
PreviewMouseRightButtonUp

在鼠标指针位于此元素上并且松开鼠标右键时发生。Occurs when the right mouse button is released while the mouse pointer is over this element.

(继承自 UIElement)
PreviewMouseUp

在鼠标指针位于此元素上并且松开任意鼠标按钮时发生。Occurs when any mouse button is released while the mouse pointer is over this element.

(继承自 UIElement)
PreviewMouseWheel

在鼠标指针位于此元素上并且用户滚动鼠标滚轮时发生。Occurs when the user rotates the mouse wheel while the mouse pointer is over this element.

(继承自 UIElement)
PreviewQueryContinueDrag

在拖放操作期间键盘或鼠标按钮的状态改变时发生。Occurs when there is a change in the keyboard or mouse button state during a drag-and-drop operation.

(继承自 UIElement)
PreviewStylusButtonDown

在指针位于此元素上并且按下触笔按钮时发生。Occurs when the stylus button is pressed while the pointer is over this element.

(继承自 UIElement)
PreviewStylusButtonUp

在指针位于此元素上并且松开触笔按钮时发生。Occurs when the stylus button is released while the pointer is over this element.

(继承自 UIElement)
PreviewStylusDown

当触笔位于元素上且触及数字化器时发生。Occurs when the stylus touches the digitizer while it is over this element.

(继承自 UIElement)
PreviewStylusInAirMove

在触笔掠过元素但并未实际接触数字化器时发生。Occurs when the stylus moves over an element without actually touching the digitizer.

(继承自 UIElement)
PreviewStylusInRange

在触笔位于此元素上并且触笔与数字化器之间的距离近到足以检测到触笔时发生。Occurs when the stylus is close enough to the digitizer to be detected, while over this element.

(继承自 UIElement)
PreviewStylusMove

在触笔位于元素上并且移动触笔时发生。Occurs when the stylus moves while over the element. 数字化器在检测触笔时,触笔必须处于移动状态才会引发此事件,否则将改为引发 PreviewStylusInAirMoveThe stylus must move while being detected by the digitizer to raise this event, otherwise, PreviewStylusInAirMove is raised instead.

(继承自 UIElement)
PreviewStylusOutOfRange

在触笔与数字化仪之间的距离太远以致无法检测到触笔时发生。Occurs when the stylus is too far from the digitizer to be detected.

(继承自 UIElement)
PreviewStylusSystemGesture

在用户采用某一种触笔笔势时发生。Occurs when a user performs one of several stylus gestures.

(继承自 UIElement)
PreviewStylusUp

当触笔位于此元素上并且用户将触笔抬离数字化器时发生。Occurs when the user raises the stylus off the digitizer while the stylus is over this element.

(继承自 UIElement)
PreviewTextInput

在此元素以设备无关模式获取文本时发生。Occurs when this element gets text in a device-independent manner.

(继承自 UIElement)
PreviewTouchDown

当悬停在此元素上方的手指触摸屏幕时发生。Occurs when a finger touches the screen while the finger is over this element.

(继承自 UIElement)
PreviewTouchMove

当悬停在此元素上方的手指在屏幕上移动时发生。Occurs when a finger moves on the screen while the finger is over this element.

(继承自 UIElement)
PreviewTouchUp

当悬停在此元素上方的手指从屏幕上移开时发生。Occurs when a finger is raised off of the screen while the finger is over this element.

(继承自 UIElement)
QueryContinueDrag

在拖放操作期间键盘或鼠标按钮的状态改变时发生。Occurs when there is a change in the keyboard or mouse button state during a drag-and-drop operation.

(继承自 UIElement)
QueryCursor

当请求显示光标时发生。Occurs when the cursor is requested to display. 每次鼠标指针移至新位置时都会在一个元素上引发此事件,这意味着光标对象可能需要根据其新位置进行更改。This event is raised on an element each time that the mouse pointer moves to a new location, which means the cursor object might need to be changed based on its new position.

(继承自 UIElement)
RequestBringIntoView

当在此元素上调用 BringIntoView(Rect) 时发生。Occurs when BringIntoView(Rect) is called on this element.

(继承自 FrameworkElement)
RowDetailsVisibilityChanged

在行详细信息元素的可见性更改时发生。Occurs when the visibility of a row details element changes.

RowEditEnding

在提交或取消行编辑之前发生。Occurs before a row edit is committed or canceled.

SelectedCellsChanged

SelectedCells 集合更改时发生。Occurs when the SelectedCells collection changes.

SelectionChanged

Selector 的选择更改时发生。Occurs when the selection of a Selector changes.

(继承自 Selector)
SizeChanged

当此元素上的 ActualHeightActualWidth 属性的值发生更改时发生。Occurs when either the ActualHeight or the ActualWidth properties change value on this element.

(继承自 FrameworkElement)
Sorting

对列进行排序时发生。Occurs when a column is being sorted.

SourceUpdated

当此元素上的任何现有属性绑定的源值发生更改时发生。Occurs when the source value changes for any existing property binding on this element.

(继承自 FrameworkElement)
StylusButtonDown

在指针位于此元素上并且按下触笔按钮时发生。Occurs when the stylus button is pressed while the pointer is over this element.

(继承自 UIElement)
StylusButtonUp

在指针位于此元素上并且松开触笔按钮时发生。Occurs when the stylus button is released while the pointer is over this element.

(继承自 UIElement)
StylusDown

在触笔位于此元素上且同时触及数字化器时发生。Occurs when the stylus touches the digitizer while the stylus is over this element.

(继承自 UIElement)
StylusEnter

在触笔进入此元素的边界时发生。Occurs when the stylus enters the bounds of this element.

(继承自 UIElement)
StylusInAirMove

在触笔掠过元素但并未实际接触数字化器时发生。Occurs when the stylus moves over an element without actually touching the digitizer.

(继承自 UIElement)
StylusInRange

在触笔位于此元素上并且触笔与数字化器之间的距离近到足以检测到触笔时发生。Occurs when the stylus is close enough to the digitizer to be detected, while over this element.

(继承自 UIElement)
StylusLeave

在触笔离开元素的边界时发生。Occurs when the stylus leaves the bounds of the element.

(继承自 UIElement)
StylusMove

在触笔移到此元素上时发生。Occurs when the stylus moves over this element. 触笔必须在位于数字化器上时移动,才会引发此事件。The stylus must move while on the digitizer to raise this event. 否则将改为引发 StylusInAirMoveOtherwise, StylusInAirMove is raised instead.

(继承自 UIElement)
StylusOutOfRange

在触笔位于此元素上并且触笔与数字化器之间的距离太远以致无法检测到触笔时发生。Occurs when the stylus is too far from the digitizer to be detected, while over this element.

(继承自 UIElement)
StylusSystemGesture

在用户采用某一种触笔笔势时发生。Occurs when a user performs one of several stylus gestures.

(继承自 UIElement)
StylusUp

当触笔位于此元素上并且用户将触笔抬离数字化器时发生。Occurs when the user raises the stylus off the digitizer while it is over this element.

(继承自 UIElement)
TargetUpdated

当此元素上的任何属性绑定的目标值发生更改时发生。Occurs when the target value changes for any property binding on this element.

(继承自 FrameworkElement)
TextInput

在此元素以设备无关模式获取文本时发生。Occurs when this element gets text in a device-independent manner.

(继承自 UIElement)
ToolTipClosing

在元素上的任何工具提示关闭之前发生。Occurs just before any tooltip on the element is closed.

(继承自 FrameworkElement)
ToolTipOpening

在元素上的任何工具提示打开时发生。Occurs when any tooltip on the element is opened.

(继承自 FrameworkElement)
TouchDown

当悬停在此元素上方的手指触摸屏幕时发生。Occurs when a finger touches the screen while the finger is over this element.

(继承自 UIElement)
TouchEnter

在触摸屏输入从此元素边界外部移动到其内部时发生。Occurs when a touch moves from outside to inside the bounds of this element.

(继承自 UIElement)
TouchLeave

在触摸屏输入从此元素边界内部移动到其外部时发生。Occurs when a touch moves from inside to outside the bounds of this element.

(继承自 UIElement)
TouchMove

当悬停在此元素上方的手指在屏幕上移动时发生。Occurs when a finger moves on the screen while the finger is over this element.

(继承自 UIElement)
TouchUp

当悬停在此元素上方的手指从屏幕上移开时发生。Occurs when a finger is raised off of the screen while the finger is over this element.

(继承自 UIElement)
Unloaded

当从加载的元素的元素树中移除元素时发生。Occurs when the element is removed from within an element tree of loaded elements.

(继承自 FrameworkElement)
UnloadingRow

DataGridRow 对象变得可供重用时发生。Occurs when a DataGridRow object becomes available for reuse.

UnloadingRowDetails

当行详细信息元素变得可供重用时发生。Occurs when a row details element becomes available for reuse.

显式接口实现

IAddChild.AddChild(Object)

此成员支持 Windows Presentation Foundation (WPF)Windows Presentation Foundation (WPF) 基础结构,但不能在代码中直接使用。This member supports the Windows Presentation Foundation (WPF)Windows Presentation Foundation (WPF) infrastructure and is not intended to be used directly from your code.

(继承自 ItemsControl)
IAddChild.AddText(String)

此成员支持 Windows Presentation Foundation (WPF)Windows Presentation Foundation (WPF) 基础结构,但不能在代码中直接使用。This member supports the Windows Presentation Foundation (WPF)Windows Presentation Foundation (WPF) infrastructure and is not intended to be used directly from your code.

(继承自 ItemsControl)
IContainItemStorage.Clear()

清除所有的属性关联。Clears all property associations.

(继承自 ItemsControl)
IContainItemStorage.ClearItemValue(Object, DependencyProperty)

删除指定项和属性之间的关联。Removes the association between the specified item and property.

(继承自 ItemsControl)
IContainItemStorage.ClearValue(DependencyProperty)

从所有属性列表中删除指定属性。Removes the specified property from all property lists.

(继承自 ItemsControl)
IContainItemStorage.ReadItemValue(Object, DependencyProperty)

返回与指定项关联的指定属性的值。Returns the value of the specified property that is associated with the specified item.

(继承自 ItemsControl)
IContainItemStorage.StoreItemValue(Object, DependencyProperty, Object)

存储指定的属性和值,并将它们与指定的项相关联。Stores the specified property and value and associates them with the specified item.

(继承自 ItemsControl)
IQueryAmbient.IsAmbientPropertyAvailable(String)

有关此成员的说明,请参见 IsAmbientPropertyAvailable(String) 方法。For a description of this member, see the IsAmbientPropertyAvailable(String) method.

(继承自 FrameworkElement)

适用于