TreeView 成员

显示标记项的分层集合,每个标记项用一个 TreeNode 来表示。

下表列出了由 TreeView 类型公开的成员。

公共构造函数

  名称 说明
Public method Supported by the .NET Compact Framework TreeView 初始化 TreeView 类的新实例。

页首

公共属性

(请参见 受保护的属性 )

  名称 说明
Public property AccessibilityObject  获取分配给该控件的 AccessibleObject。(从 Control 继承。)
Public property AccessibleDefaultActionDescription  获取或设置控件的默认操作说明,供辅助功能客户端应用程序使用。(从 Control 继承。)
Public property AccessibleDescription  获取或设置辅助功能客户端应用程序使用的控件说明。(从 Control 继承。)
Public property AccessibleName  获取或设置辅助功能客户端应用程序所使用的控件名称。(从 Control 继承。)
Public property AccessibleRole  获取或设置控件的辅助性角色 (从 Control 继承。)
Public property AllowDrop  获取或设置一个值,该值指示控件是否可以接受用户拖放到它上面的数据。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Anchor  获取或设置控件绑定到的容器的边缘并确定控件如何随其父级一起调整大小。 (从 Control 继承。)
Public property AutoScrollOffset  获取或设置一个值,该值指示在 ScrollControlIntoView 中将控件滚动到何处。(从 Control 继承。)
Public property AutoSize  此属性与此类无关。(从 Control 继承。)
Public property Supported by the .NET Compact Framework BackColor 已重写。 
Public property BackgroundImage 已重写。获取或设置 TreeView 控件的背景图像。
Public property BackgroundImageLayout 已重写。获取或设置 TreeView 控件的背景图像的布局。
Public property Supported by the .NET Compact Framework BindingContext  获取或设置控件的 BindingContext。(从 Control 继承。)
Public property BorderStyle 获取或设置树视图控件的边框样式。
Public property Supported by the .NET Compact Framework Bottom  获取控件下边缘与其容器的工作区上边缘之间的距离(以像素为单位)。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Bounds  获取或设置控件(包括其非工作区元素)相对于其父控件的大小和位置(以像素为单位)。(从 Control 继承。)
Public property CanFocus  获取一个值,该值指示控件是否可以接收焦点。(从 Control 继承。)
Public property CanSelect  获取一个值,该值指示是否可以选中控件。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Capture  获取或设置一个值,该值指示控件是否已捕获鼠标。(从 Control 继承。)
Public property CausesValidation  获取或设置一个值,该值指示控件是否会引起在任何需要在接收焦点时执行验证的控件上执行验证。(从 Control 继承。)
Public property Supported by the .NET Compact Framework CheckBoxes 获取或设置一个值,用以指示是否在树视图控件中的树节点旁显示复选框。
Public property Static CheckForIllegalCrossThreadCalls  获取或设置一个值,该值指示是否捕获对错误线程的调用,这些调用访问控件的 Handle 属性。(从 Control 继承。)
Public property Supported by the .NET Compact Framework ClientRectangle  获取表示控件的工作区的矩形。(从 Control 继承。)
Public property Supported by the .NET Compact Framework ClientSize  获取或设置控件的工作区的高度和宽度。(从 Control 继承。)
Public property CompanyName  获取包含控件的应用程序的公司名称或创建者。(从 Control 继承。)
Public property Container  获取 IContainer,它包含 Component。(从 Component 继承。)
Public property ContainsFocus  获取一个值,该值指示控件或它的一个子控件当前是否有输入焦点。(从 Control 继承。)
Public property Supported by the .NET Compact Framework ContextMenu  获取或设置与控件关联的快捷菜单。(从 Control 继承。)
Public property ContextMenuStrip  获取或设置与此控件关联的 ContextMenuStrip。(从 Control 继承。)
Public property Controls  获取包含在控件内的控件的集合。(从 Control 继承。)
Public property Created  获取一个值,该值指示控件是否已经创建。(从 Control 继承。)
Public property Cursor  获取或设置当鼠标指针位于控件上时显示的光标。(从 Control 继承。)
Public property Supported by the .NET Compact Framework DataBindings  为该控件获取数据绑定。(从 Control 继承。)
Public property Static DefaultBackColor  获取控件的默认背景色。(从 Control 继承。)
Public property Static DefaultFont  获取控件的默认字体。(从 Control 继承。)
Public property Static DefaultForeColor  获取控件的默认前景色。(从 Control 继承。)
Public property DisplayRectangle  获取表示控件的显示区域的矩形。(从 Control 继承。)
Public property Disposing  获取一个值,该值指示 Control 基类是否在释放进程中。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Dock  获取或设置哪些控件边框停靠到其父控件并确定控件如何随其父级一起调整大小。(从 Control 继承。)
Public property DrawMode 获取或设置绘制控件的模式。
Public property Supported by the .NET Compact Framework Enabled  获取或设置一个值,该值指示控件是否可以对用户交互作出响应。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Focused  获取一个值,该值指示控件是否有输入焦点。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Font  获取或设置控件显示的文字的字体。(从 Control 继承。)
Public property Supported by the .NET Compact Framework ForeColor 已重写。此控件的当前前景色,控件使用此颜色绘制文本。
Public property FullRowSelect 获取或设置一个值,用以指示选择突出显示是否跨越树视图控件的整个宽度。
Public property Supported by the .NET Compact Framework Handle  获取控件绑定到的窗口句柄。(从 Control 继承。)
Public property HasChildren  获取一个值,该值指示控件是否包含一个或多个子控件。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Height  获取或设置控件的高度。(从 Control 继承。)
Public property HideSelection 获取或设置一个值,用以指示选定的树节点是否即使在树视图已失去焦点时仍会保持突出显示。
Public property HotTracking 获取或设置一个值,用以指示当鼠标指针移过树节点标签时,树节点标签是否具有超链接的外观。
Public property Supported by the .NET Compact Framework ImageIndex 获取或设置树节点显示的默认图像的图像列表索引值。
Public property ImageKey 获取或设置 TreeView 控件中的每个节点在处于未选定状态时的默认图像的键。
Public property Supported by the .NET Compact Framework ImageList 获取或设置包含树节点所使用的 Image 对象的 ImageList
Public property ImeMode  获取或设置控件的输入法编辑器 (IME) 模式。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Indent 获取或设置每个子树节点级别的缩进距离。
Public property Supported by the .NET Compact Framework InvokeRequired  获取一个值,该值指示调用方在对控件进行方法调用时是否必须调用 Invoke 方法,因为调用方位于创建控件所在的线程以外的线程中。(从 Control 继承。)
Public property IsAccessible  获取或设置一个值,该值指示控件对辅助功能应用程序是否可见。(从 Control 继承。)
Public property IsDisposed  获取一个值,该值指示控件是否已经被释放。(从 Control 继承。)
Public property IsHandleCreated  获取一个值,该值指示控件是否有与它关联的句柄。(从 Control 继承。)
Public property IsMirrored  获取一个值,该值指示此控件是否为镜像控件。(从 Control 继承。)
Public property ItemHeight 获取或设置树视图控件中每个树节点的高度。
Public property LabelEdit 获取或设置一个值,用以指示是否可以编辑树节点的标签文本。
Public property LayoutEngine  获取控件的布局引擎的缓存实例。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Left  获取或设置控件左边缘与其容器的工作区左边缘之间的距离(以像素为单位)。(从 Control 继承。)
Public property LineColor 获取或设置连接 TreeView 控件的节点的线条的颜色。
Public property Supported by the .NET Compact Framework Location  获取或设置该控件的左上角相对于其容器的左上角的坐标。(从 Control 继承。)
Public property Margin  获取或设置控件之间的空间。(从 Control 继承。)
Public property MaximumSize  获取或设置大小,该大小是 GetPreferredSize 可以指定的上限。(从 Control 继承。)
Public property MinimumSize  获取或设置大小,该大小是 GetPreferredSize 可以指定的下限。(从 Control 继承。)
Public property Static ModifierKeys  获取一个值,该值指示哪一个修改键(Shift、Ctrl 和 Alt)处于按下的状态。(从 Control 继承。)
Public property Static Supported by the .NET Compact Framework MouseButtons  获取一个值,该值指示哪一个鼠标按钮处于按下的状态。(从 Control 继承。)
Public property Static Supported by the .NET Compact Framework MousePosition  获取鼠标光标的位置(以屏幕坐标表示)。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Name  获取或设置控件的名称。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Nodes 获取分配给树视图控件的树节点集合。
Public property Padding 获取或设置 TreeView 控件的内容和它的边缘之间的间距。
Public property Supported by the .NET Compact Framework Parent  获取或设置控件的父容器。(从 Control 继承。)
Public property Supported by the .NET Compact Framework PathSeparator 获取或设置树节点路径所使用的分隔符串。
Public property PreferredSize  获取可以容纳控件的矩形区域的大小。(从 Control 继承。)
Public property ProductName  获取包含控件的程序集的产品名称。(从 Control 继承。)
Public property ProductVersion  获取包含控件的程序集的版本。(从 Control 继承。)
Public property RecreatingHandle  获取一个值,该值指示控件当前是否在重新创建其句柄。(从 Control 继承。)
Public property Region  获取或设置与控件关联的窗口区域。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Right  获取控件右边缘与其容器的工作区左边缘之间的距离(以像素为单位)。(从 Control 继承。)
Public property RightToLeft  获取或设置一个值,该值指示是否将控件的元素对齐以支持使用从右向左的字体的区域设置。(从 Control 继承。)
Public property RightToLeftLayout 获取或设置一个值,该值指示 TreeView 是否应从右向左布局。
Public property Scrollable 获取或设置一个值,用以指示树视图控件是否在需要时显示滚动条。
Public property Supported by the .NET Compact Framework SelectedImageIndex 获取或设置当树节点选定时所显示的图像的图像列表索引值。
Public property SelectedImageKey 获取或设置 TreeNode 处于选定状态时显示的默认图像的键。
Public property Supported by the .NET Compact Framework SelectedNode 获取或设置当前在树视图控件中选定的树节点。
Public property Supported by the .NET Compact Framework ShowLines 获取或设置一个值,用以指示是否在树视图控件中的树节点之间绘制连线。
Public property ShowNodeToolTips 获取或设置一个值,该值指示当鼠标指针悬停在 TreeNode 上时显示的工具提示。
Public property Supported by the .NET Compact Framework ShowPlusMinus 获取或设置一个值,用以指示是否在包含子树节点的树节点旁显示加号 (+) 和减号 (-) 按钮。
Public property Supported by the .NET Compact Framework ShowRootLines 获取或设置一个值,用以指示是否在树视图根处的树节点之间绘制连线。
Public property Supported by the .NET Compact Framework Site  获取或设置控件的站点。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Size  获取或设置控件的高度和宽度。(从 Control 继承。)
Public property Sorted 获取或设置一个值,用以指示树视图中的树节点是否经过排序。
Public property StateImageList 获取或设置图像列表,该列表用于指示 TreeView 及其节点的状态。
Public property Supported by the .NET Compact Framework TabIndex  获取或设置在控件的容器的控件的 Tab 键顺序。(从 Control 继承。)
Public property Supported by the .NET Compact Framework TabStop  获取或设置一个值,该值指示用户能否使用 Tab 键将焦点放到该控件上。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Tag  获取或设置包含有关控件的数据的对象。(从 Control 继承。)
Public property Text 已重写。获取或设置 TreeView 的文本。
Public property Supported by the .NET Compact Framework Top  获取或设置控件上边缘与其容器的工作区上边缘之间的距离(以像素为单位)。(从 Control 继承。)
Public property Supported by the .NET Compact Framework TopLevelControl  获取没有另一个 Windows 窗体控件作为其父级的父控件。通常,这是控件所在的最外面的 Form。(从 Control 继承。)
Public property TopNode 获取树视图控件中第一个完全可见的树节点。
Public property TreeViewNodeSorter 获取或设置 IComparer 的实现以执行 TreeView 节点的自定义排序。
Public property UseWaitCursor  获取或设置一个值,该值指示是否将等待光标用于当前控件以及所有子控件。(从 Control 继承。)
Public property Supported by the .NET Compact Framework Visible  获取或设置一个值,该值指示是否显示该控件。(从 Control 继承。)
Public property VisibleCount 获取树视图控件中完全可见的树节点的数目。
Public property Supported by the .NET Compact Framework Width  获取或设置控件的宽度。(从 Control 继承。)
Public property WindowTarget  (从 Control 继承。)

页首

受保护的属性

  名称 说明
Protected property CanRaiseEvents  确定是否可以在控件上引发事件。(从 Control 继承。)
Protected property CreateParams 已重写。重写 CreateParams
Protected property DefaultCursor  获取或设置控件的默认光标。(从 Control 继承。)
Protected property DefaultImeMode  获取控件支持的输入法编辑器 (IME) 模式。(从 Control 继承。)
Protected property DefaultMargin  获取以像素为单位的空间,此空间默认情况下被指定为控件之间的空间。(从 Control 继承。)
Protected property DefaultMaximumSize  获取以像素为单位的长度和高度,此长度和高度被指定为控件的默认最大大小。(从 Control 继承。)
Protected property DefaultMinimumSize  获取以像素为单位的长度和高度,此长度和高度被指定为控件的默认最小大小。(从 Control 继承。)
Protected property DefaultPadding  获取控件内容的内部间距(以像素为单位)。(从 Control 继承。)
Protected property DefaultSize 已重写。 
Protected property DesignMode  获取一个值,用以指示 Component 当前是否处于设计模式。(从 Component 继承。)
Protected property DoubleBuffered 已重写。获取或设置一个值,该值指示控件是否应使用次要缓冲区重绘其图面。DoubleBuffered 属性对 TreeView 控件不起任何作用。
Protected property Supported by the .NET Compact Framework Events  获取附加到此 Component 的事件处理程序的列表。(从 Component 继承。)
Protected property FontHeight  获取或设置控件的字体的高度。(从 Control 继承。)
Protected property RenderRightToLeft  (从 Control 继承。)
Protected property ResizeRedraw  获取或设置一个值,该值指示控件在调整大小时是否重绘自己。(从 Control 继承。)
Protected property Supported by the .NET Compact Framework ScaleChildren  获取一个值,该值确定子控件的缩放。 (从 Control 继承。)
Protected property ShowFocusCues  获取一个值,该值指示控件是否应显示聚焦框。(从 Control 继承。)
Protected property ShowKeyboardCues  获取一个值,该值指示用户界面是否处于适当的状态以显示或隐藏键盘快捷键。(从 Control 继承。)

页首

公共方法

(请参见 受保护的方法 )

  名称 说明
Public method Supported by the .NET Compact Framework BeginInvoke  已重载。 在创建控件的基础句柄所在线程上异步执行委托。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework BeginUpdate 禁用任何树视图重绘。
Public method Supported by the .NET Compact Framework BringToFront  将控件带到 Z 顺序的前面。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework CollapseAll 折叠所有树节点。
Public method Contains  检索一个值,该值指示指定控件是否为一个控件的子控件。 (从 Control 继承。)
Public method CreateControl  强制创建控件,包括创建句柄和任何子控件。 (从 Control 继承。)
Public method CreateGraphics  为控件创建 Graphics。 (从 Control 继承。)
Public method CreateObjRef  创建一个对象,该对象包含生成用于与远程对象进行通信的代理所需的全部相关信息。 (从 MarshalByRefObject 继承。)
Public method Supported by the .NET Compact Framework Dispose 已重载。 释放 TreeView 使用的非托管资源。
Public method DoDragDrop  开始拖放操作。 (从 Control 继承。)
Public method DrawToBitmap  支持呈现到指定的位图。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework EndInvoke  检索由传递的 IAsyncResult 表示的异步操作的返回值。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework EndUpdate 启用树视图的重绘。
Public method Supported by the .NET Compact Framework Equals  已重载。 确定两个 Object 实例是否相等。 (从 Object 继承。)
Public method Supported by the .NET Compact Framework ExpandAll 展开所有树节点。
Public method FindForm  检索控件所在的窗体。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework Focus  为控件设置输入焦点。 (从 Control 继承。)
Public method Static FromChildHandle  检索包含指定句柄的控件。 (从 Control 继承。)
Public method Static FromHandle  返回当前与指定句柄关联的控件。 (从 Control 继承。)
Public method GetChildAtPoint  已重载。 检索指定位置的子控件。 (从 Control 继承。)
Public method GetContainerControl  沿着控件的父控件链向上,返回下一个 ContainerControl。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework GetHashCode  用作特定类型的哈希函数。GetHashCode 适合在哈希算法和数据结构(如哈希表)中使用。 (从 Object 继承。)
Public method GetLifetimeService  检索控制此实例的生存期策略的当前生存期服务对象。 (从 MarshalByRefObject 继承。)
Public method GetNextControl  按照子控件的 Tab 键顺序向前或向后检索下一个控件。 (从 Control 继承。)
Public method GetNodeAt 已重载。 检索位于指定位置的树节点。
Public method Supported by the .NET Compact Framework GetNodeCount 检索分配给树视图控件的树节点数(可以选择性地包括所有子树中的树节点)。
Public method GetPreferredSize  检索可以容纳控件的矩形区域的大小。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework GetType  获取当前实例的 Type。 (从 Object 继承。)
Public method Supported by the .NET Compact Framework Hide  对用户隐藏控件。 (从 Control 继承。)
Public method HitTest 已重载。 在给定一个点的情况下,提供节点信息。
Public method InitializeLifetimeService  获取控制此实例的生存期策略的生存期服务对象。 (从 MarshalByRefObject 继承。)
Public method Supported by the .NET Compact Framework Invalidate  已重载。 使控件的特定区域无效并向控件发送绘制消息。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework Invoke  已重载。 在拥有此控件的基础窗口句柄的线程上执行委托。 (从 Control 继承。)
Public method Static IsKeyLocked  确定 Caps Lock、Num Lock 或 Scroll Lock 键是否有效。 (从 Control 继承。)
Public method Static IsMnemonic  搜索指定的字符串,以确定指定字符是否是分配给此控件的助记键字符。 (从 Control 继承。)
Public method PerformLayout  已重载。 强制控件将布局逻辑应用于子控件。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework PointToClient  将指定屏幕点的位置计算成工作区坐标。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework PointToScreen  将指定工作区点的位置计算成屏幕坐标。 (从 Control 继承。)
Public method PreProcessControlMessage  在调度键盘或输入消息之前,在消息循环内对它们进行预处理。 (从 Control 继承。)
Public method PreProcessMessage  在调度键盘或输入消息之前,在消息循环内对它们进行预处理。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework RectangleToClient  计算指定屏幕矩形的大小和位置(以工作区坐标表示)。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework RectangleToScreen  计算指定工作区矩形的大小和位置(以屏幕坐标表示)。 (从 Control 继承。)
Public method Static Supported by the .NET Compact Framework ReferenceEquals  确定指定的 Object 实例是否是相同的实例。 (从 Object 继承。)
Public method Supported by the .NET Compact Framework Refresh  强制控件使其工作区无效并立即重绘自己和任何子控件。 (从 Control 继承。)
Public method ResetBackColor  BackColor 属性重置为其默认值。 (从 Control 继承。)
Public method ResetBindings  使绑定到 BindingSource 的控件重新读取列表中的所有项,并刷新这些项的显示值。 (从 Control 继承。)
Public method ResetCursor  Cursor 属性重置为其默认值。 (从 Control 继承。)
Public method ResetFont  Font 属性重置为其默认值。 (从 Control 继承。)
Public method ResetForeColor  ForeColor 属性重置为其默认值。 (从 Control 继承。)
Public method ResetImeMode  ImeMode 属性重置为其默认值。 (从 Control 继承。)
Public method ResetRightToLeft  RightToLeft 属性重置为其默认值。 (从 Control 继承。)
Public method ResetText  Text 属性重置为其默认值。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework ResumeLayout  已重载。 恢复正常的布局逻辑。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework Scale  已重载。 缩放控件和任何子控件。 (从 Control 继承。)
Public method Select  已重载。 激活控件。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework SelectNextControl  激活下一个控件。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework SendToBack  将控件发送到 Z 顺序的后面。 (从 Control 继承。)
Public method SetBounds  已重载。 设置控件的边界。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework Show  向用户显示控件。 (从 Control 继承。)
Public method Sort 如果 TreeViewNodeSorter 属性的值不是 空引用(在 Visual Basic 中为 Nothing),则对各项进行排序。
Public method Supported by the .NET Compact Framework SuspendLayout  临时挂起控件的布局逻辑。 (从 Control 继承。)
Public method Supported by the .NET Compact Framework ToString 已重写。 重写 ToString
Public method Supported by the .NET Compact Framework Update  使控件重绘其工作区内的无效区域。 (从 Control 继承。)

页首

受保护的方法

  名称 说明
Protected method AccessibilityNotifyClients  已重载。 向具有辅助功能的客户端应用程序通知 AccessibleEvents。 (从 Control 继承。)
Protected method CreateAccessibilityInstance  为该控件创建一个新的辅助功能对象。 (从 Control 继承。)
Protected method Supported by the .NET Compact Framework CreateControlsInstance  为控件创建控件集合的新实例。 (从 Control 继承。)
Protected method CreateHandle 已重写。 
Protected method DefWndProc  向默认窗口过程发送指定消息。 (从 Control 继承。)
Protected method DestroyHandle  毁坏与该控件关联的句柄。 (从 Control 继承。)
Protected method Supported by the .NET Compact Framework Dispose 已重载。 已重写。 释放 TreeView 使用的非托管资源。
Protected method Supported by the .NET Compact Framework Finalize  在通过垃圾回收将 Component 回收之前,释放非托管资源并执行其他清理操作。 (从 Component 继承。)
Protected method GetAccessibilityObjectById  检索指定的 AccessibleObject。 (从 Control 继承。)
Protected method GetAutoSizeMode  检索一个值,该值指示当启用控件的 AutoSize 属性时控件的行为方式。 (从 Control 继承。)
Protected method GetItemRenderStyles 返回指定 TreeNodeOwnerDrawPropertyBag
Protected method Supported by the .NET Compact Framework GetScaledBounds  检索缩放控件时的边界。 (从 Control 继承。)
Protected method GetService  返回一个对象,该对象表示由 Component 或它的 Container 提供的服务。 (从 Component 继承。)
Protected method GetStyle  为控件检索指定控件样式位的值。 (从 Control 继承。)
Protected method GetTopLevel  确定控件是否是顶级控件。 (从 Control 继承。)
Protected method InitLayout  在将控件添加到另一个容器之后调用。 (从 Control 继承。)
Protected method InvokeGotFocus  为指定的控件引发 GotFocus 事件。 (从 Control 继承。)
Protected method InvokeLostFocus  为指定的控件引发 LostFocus 事件。 (从 Control 继承。)
Protected method InvokeOnClick  为指定的控件引发 Click 事件。 (从 Control 继承。)
Protected method InvokePaint  为指定的控件引发 Paint 事件。 (从 Control 继承。)
Protected method InvokePaintBackground  为指定的控件引发 PaintBackground 事件。 (从 Control 继承。)
Protected method IsInputChar  确定一个字符是否是控件可识别的输入字符。 (从 Control 继承。)
Protected method IsInputKey 已重写。 确定指定的键是常规输入键还是需要预处理的特殊键。
Protected method Supported by the .NET Compact Framework MemberwiseClone  已重载。 (从 MarshalByRefObject 继承。)
Protected method NotifyInvalidate  引发 Invalidated 事件,其中带有要使之无效的控件的指定区域。 (从 Control 继承。)
Protected method Supported by the .NET Compact Framework OnAfterCheck 引发 AfterCheck 事件。
Protected method Supported by the .NET Compact Framework OnAfterCollapse 引发 AfterCollapse 事件。
Protected method Supported by the .NET Compact Framework OnAfterExpand 引发 AfterExpand 事件。
Protected method OnAfterLabelEdit 引发 AfterLabelEdit 事件。
Protected method Supported by the .NET Compact Framework OnAfterSelect 引发 AfterSelect 事件。
Protected method OnAutoSizeChanged  引发 AutoSizeChanged 事件。 (从 Control 继承。)
Protected method OnBackColorChanged  引发 BackColorChanged 事件。 (从 Control 继承。)
Protected method OnBackgroundImageChanged  引发 BackgroundImageChanged 事件。 (从 Control 继承。)
Protected method OnBackgroundImageLayoutChanged  引发 BackgroundImageLayoutChanged 事件。 (从 Control 继承。)
Protected method OnBeforeCheck 引发 BeforeCheck 事件。
Protected method Supported by the .NET Compact Framework OnBeforeCollapse 引发 BeforeCollapse 事件。
Protected method Supported by the .NET Compact Framework OnBeforeExpand 引发 BeforeExpand 事件。
Protected method OnBeforeLabelEdit 引发 BeforeLabelEdit 事件。
Protected method OnBeforeSelect 引发 BeforeSelect 事件。
Protected method Supported by the .NET Compact Framework OnBindingContextChanged  引发 BindingContextChanged 事件。 (从 Control 继承。)
Protected method OnCausesValidationChanged  引发 CausesValidationChanged 事件。 (从 Control 继承。)
Protected method OnChangeUICues  引发 ChangeUICues 事件。 (从 Control 继承。)
Protected method OnClick  引发 Click 事件。 (从 Control 继承。)
Protected method OnClientSizeChanged  引发 ClientSizeChanged 事件。 (从 Control 继承。)
Protected method OnContextMenuChanged  引发 ContextMenuChanged 事件。 (从 Control 继承。)
Protected method OnContextMenuStripChanged  引发 ContextMenuStripChanged 事件。 (从 Control 继承。)
Protected method OnControlAdded  引发 ControlAdded 事件。 (从 Control 继承。)
Protected method OnControlRemoved  引发 ControlRemoved 事件。 (从 Control 继承。)
Protected method OnCreateControl  引发 CreateControl 事件。 (从 Control 继承。)
Protected method OnCursorChanged  引发 CursorChanged 事件。 (从 Control 继承。)
Protected method OnDockChanged  引发 DockChanged 事件。 (从 Control 继承。)
Protected method OnDoubleClick  引发 DoubleClick 事件。 (从 Control 继承。)
Protected method OnDragDrop  引发 DragDrop 事件。 (从 Control 继承。)
Protected method OnDragEnter  引发 DragEnter 事件。 (从 Control 继承。)
Protected method OnDragLeave  引发 DragLeave 事件。 (从 Control 继承。)
Protected method OnDragOver  引发 DragOver 事件。 (从 Control 继承。)
Protected method OnDrawNode 引发 DrawNode 事件。
Protected method Supported by the .NET Compact Framework OnEnabledChanged  引发 EnabledChanged 事件。 (从 Control 继承。)
Protected method OnEnter  引发 Enter 事件。 (从 Control 继承。)
Protected method OnFontChanged  引发 FontChanged 事件。 (从 Control 继承。)
Protected method OnForeColorChanged  引发 ForeColorChanged 事件。 (从 Control 继承。)
Protected method OnGiveFeedback  引发 GiveFeedback 事件。 (从 Control 继承。)
Protected method Supported by the .NET Compact Framework OnGotFocus  引发 GotFocus 事件。 (从 Control 继承。)
Protected method Supported by the .NET Compact Framework OnHandleCreated 已重写。 重写 OnHandleCreated
Protected method Supported by the .NET Compact Framework OnHandleDestroyed 已重写。 重写 OnHandleDestroyed
Protected method OnHelpRequested  引发 HelpRequested 事件。 (从 Control 继承。)
Protected method OnImeModeChanged  引发 ImeModeChanged 事件。 (从 Control 继承。)
Protected method OnInvalidated  引发 Invalidated 事件。 (从 Control 继承。)
Protected method OnItemDrag 引发 ItemDrag 事件。
Protected method Supported by the .NET Compact Framework OnKeyDown 已重写。 引发 KeyDown 事件。
Protected method Supported by the .NET Compact Framework OnKeyPress 已重写。 引发 KeyPress 事件。
Protected method Supported by the .NET Compact Framework OnKeyUp 已重写。 重写 OnKeyUp
Protected method OnLayout  引发 Layout 事件。 (从 Control 继承。)
Protected method OnLeave  引发 Leave 事件。 (从 Control 继承。)
Protected method OnLocationChanged  引发 LocationChanged 事件。 (从 Control 继承。)
Protected method Supported by the .NET Compact Framework OnLostFocus  引发 LostFocus 事件。 (从 Control 继承。)
Protected method OnMarginChanged  引发 MarginChanged 事件。 (从 Control 继承。)
Protected method OnMouseCaptureChanged  引发 MouseCaptureChanged 事件。 (从 Control 继承。)
Protected method OnMouseClick  引发 MouseClick 事件。 (从 Control 继承。)
Protected method OnMouseDoubleClick  引发 MouseDoubleClick 事件。 (从 Control 继承。)
Protected method OnMouseDown  引发 MouseDown 事件。 (从 Control 继承。)
Protected method OnMouseEnter  引发 MouseEnter 事件。 (从 Control 继承。)
Protected method OnMouseHover 已重写。 引发 MouseHover 事件。
Protected method OnMouseLeave 已重写。 引发 MouseLeave 事件。
Protected method OnMouseMove  引发 MouseMove 事件。 (从 Control 继承。)
Protected method OnMouseUp  引发 MouseUp 事件。 (从 Control 继承。)
Protected method OnMouseWheel  引发 MouseWheel 事件。 (从 Control 继承。)
Protected method OnMove  引发 Move 事件。 (从 Control 继承。)
Protected method OnNodeMouseClick 引发 NodeMouseClick 事件。
Protected method OnNodeMouseDoubleClick 引发 NodeMouseDoubleClick 事件。
Protected method OnNodeMouseHover 引发 NodeMouseHover 事件。
Protected method OnNotifyMessage  向控件通知 Windows 消息。 (从 Control 继承。)
Protected method OnPaddingChanged  引发 PaddingChanged 事件。 (从 Control 继承。)
Protected method OnPaint  引发 Paint 事件。 (从 Control 继承。)
Protected method OnPaintBackground  绘制控件的背景。 (从 Control 继承。)
Protected method OnParentBackColorChanged  当控件容器的 BackColor 属性值更改时,将引发 BackColorChanged 事件。 (从 Control 继承。)
Protected method OnParentBackgroundImageChanged  当控件容器的 BackgroundImage 属性值更改时,将引发 BackgroundImageChanged 事件。 (从 Control 继承。)
Protected method OnParentBindingContextChanged  当控件容器的 BindingContext 属性值更改时,将引发 BindingContextChanged 事件。 (从 Control 继承。)
Protected method Supported by the .NET Compact Framework OnParentChanged  引发 ParentChanged 事件。 (从 Control 继承。)
Protected method OnParentCursorChanged  引发 CursorChanged 事件。 (从 Control 继承。)
Protected method OnParentEnabledChanged  当控件容器的 Enabled 属性值更改时,将引发 EnabledChanged 事件。 (从 Control 继承。)
Protected method OnParentFontChanged  当控件容器的 Font 属性值更改时,将引发 FontChanged 事件。 (从 Control 继承。)
Protected method OnParentForeColorChanged  当控件容器的 ForeColor 属性值更改时,将引发 ForeColorChanged 事件。 (从 Control 继承。)
Protected method OnParentRightToLeftChanged  当控件容器的 RightToLeft 属性值更改时,将引发 RightToLeftChanged 事件。 (从 Control 继承。)
Protected method OnParentVisibleChanged  当控件容器的 Visible 属性值更改时,将引发 VisibleChanged 事件。 (从 Control 继承。)
Protected method OnPreviewKeyDown  引发 PreviewKeyDown 事件。 (从 Control 继承。)
Protected method OnPrint  引发 Paint 事件。 (从 Control 继承。)
Protected method OnQueryContinueDrag  引发 QueryContinueDrag 事件。 (从 Control 继承。)
Protected method OnRegionChanged  引发 RegionChanged 事件。 (从 Control 继承。)
Protected method OnResize  引发 Resize 事件。 (从 Control 继承。)
Protected method OnRightToLeftChanged  引发 RightToLeftChanged 事件。 (从 Control 继承。)
Protected method OnRightToLeftLayoutChanged 引发 RightToLeftLayoutChanged 事件。
Protected method OnSizeChanged  引发 SizeChanged 事件。 (从 Control 继承。)
Protected method OnStyleChanged  引发 StyleChanged 事件。 (从 Control 继承。)
Protected method OnSystemColorsChanged  引发 SystemColorsChanged 事件。 (从 Control 继承。)
Protected method OnTabIndexChanged  引发 TabIndexChanged 事件。 (从 Control 继承。)
Protected method OnTabStopChanged  引发 TabStopChanged 事件。 (从 Control 继承。)
Protected method OnTextChanged  引发 TextChanged 事件。 (从 Control 继承。)
Protected method OnValidated  引发 Validated 事件。 (从 Control 继承。)
Protected method OnValidating  引发 Validating 事件。 (从 Control 继承。)
Protected method OnVisibleChanged  引发 VisibleChanged 事件。 (从 Control 继承。)
Protected method ProcessCmdKey  处理命令键。 (从 Control 继承。)
Protected method ProcessDialogChar  处理对话框字符。 (从 Control 继承。)
Protected method ProcessDialogKey  处理对话框键。 (从 Control 继承。)
Protected method ProcessKeyEventArgs  处理键消息并生成适当的控件事件。 (从 Control 继承。)
Protected method ProcessKeyMessage  处理键盘消息。 (从 Control 继承。)
Protected method ProcessKeyPreview  预览键盘消息。 (从 Control 继承。)
Protected method ProcessMnemonic  处理助记键字符。 (从 Control 继承。)
Protected method RaiseDragEvent  引发适当的拖动事件。 (从 Control 继承。)
Protected method RaiseKeyEvent  引发适当的键事件。 (从 Control 继承。)
Protected method RaiseMouseEvent  引发适当的鼠标事件。 (从 Control 继承。)
Protected method RaisePaintEvent  引发适当的绘画事件。 (从 Control 继承。)
Protected method RecreateHandle  强制为控件重新创建句柄。 (从 Control 继承。)
Protected method Static ReflectMessage  向绑定到指定句柄的控件反映指定消息。 (从 Control 继承。)
Protected method ResetMouseEventArgs  重置控件以处理 MouseLeave 事件。 (从 Control 继承。)
Protected method RtlTranslateAlignment  已重载。 将当前对齐方式转换为适当的对齐方式以支持从右向左的文本。 (从 Control 继承。)
Protected method RtlTranslateContent  将指定的 ContentAlignment 转换为相应的 ContentAlignment 以支持从右向左的文本。 (从 Control 继承。)
Protected method RtlTranslateHorizontal  将指定的 HorizontalAlignment 转换为相应的 HorizontalAlignment 以支持从右向左的文本。 (从 Control 继承。)
Protected method RtlTranslateLeftRight  将指定的 LeftRightAlignment 转换为相应的 LeftRightAlignment 以支持从右向左的文本。 (从 Control 继承。)
Protected method Supported by the .NET Compact Framework ScaleControl  缩放控件的位置、大小、空白和边距。 (从 Control 继承。)
Protected method ScaleCore  (从 Control 继承。)
Protected method Select  已重载。 激活控件。 (从 Control 继承。)
Protected method SetAutoSizeMode  设置一个值,该值指示当启用控件的 AutoSize 属性时控件的行为方式。 (从 Control 继承。)
Protected method SetBoundsCore  执行设置该控件的指定边界的工作。 (从 Control 继承。)
Protected method SetClientSizeCore  设置控件的工作区的大小。 (从 Control 继承。)
Protected method SetStyle  将指定的样式位设置为指定值。 (从 Control 继承。)
Protected method SetTopLevel  将控件设置为顶级控件。 (从 Control 继承。)
Protected method SetVisibleCore  将控件设置为指定的可见状态。 (从 Control 继承。)
Protected method SizeFromClientSize  确定整个控件(从控件工作区的高度和宽度起计算)的大小。 (从 Control 继承。)
Protected method UpdateBounds  已重载。 更新控件的边界。 (从 Control 继承。)
Protected method UpdateStyles  强制将分配的样式重新应用到控件。 (从 Control 继承。)
Protected method UpdateZOrder  按控件的父级的 Z 顺序更新控件。 (从 Control 继承。)
Protected method WndProc 已重写。 重写 WndProc

页首

公共事件

  名称 说明
Public event Supported by the .NET Compact Framework AfterCheck 在选中树节点复选框后发生。
Public event Supported by the .NET Compact Framework AfterCollapse 在折叠树节点后发生。
Public event Supported by the .NET Compact Framework AfterExpand 在展开树节点后发生。
Public event AfterLabelEdit 在编辑树节点标签文本后发生。
Public event Supported by the .NET Compact Framework AfterSelect 在选定树节点后发生。
Public event AutoSizeChanged  此事件与此类无关。(从 Control 继承。)
Public event BackColorChanged  BackColor 属性的值更改时发生。(从 Control 继承。)
Public event BackgroundImageChanged BackgroundImage 属性更改时发生。
Public event BackgroundImageLayoutChanged BackgroundImageLayout 属性更改时发生。
Public event BeforeCheck 在选中树节点复选框前发生。
Public event Supported by the .NET Compact Framework BeforeCollapse 在折叠树节点前发生。
Public event Supported by the .NET Compact Framework BeforeExpand 在展开树节点前发生。
Public event BeforeLabelEdit 在编辑树节点标签前发生。
Public event BeforeSelect 在选定树节点前发生。
Public event BindingContextChanged  BindingContext 属性的值更改时发生。(从 Control 继承。)
Public event CausesValidationChanged  CausesValidation 属性的值更改时发生。(从 Control 继承。)
Public event ChangeUICues  在焦点或键盘用户界面 (UI) 提示更改时发生。(从 Control 继承。)
Public event Click  在单击控件时发生。(从 Control 继承。)
Public event ClientSizeChanged  ClientSize 属性的值更改时发生。 (从 Control 继承。)
Public event ContextMenuChanged  ContextMenu 属性的值更改时发生。(从 Control 继承。)
Public event ContextMenuStripChanged  ContextMenuStrip 属性的值更改时发生。 (从 Control 继承。)
Public event ControlAdded  在将新控件添加到 Control.ControlCollection 时发生。(从 Control 继承。)
Public event ControlRemoved  在从 Control.ControlCollection 移除控件时发生。(从 Control 继承。)
Public event CursorChanged  Cursor 属性的值更改时发生。(从 Control 继承。)
Public event Supported by the .NET Compact Framework Disposed  添加事件处理程序以侦听组件上的 Disposed 事件。(从 Component 继承。)
Public event DockChanged  Dock 属性的值更改时发生。(从 Control 继承。)
Public event DoubleClick  在双击控件时发生。(从 Control 继承。)
Public event DragDrop  在完成拖放操作时发生。(从 Control 继承。)
Public event DragEnter  在将对象拖入控件的边界时发生。(从 Control 继承。)
Public event DragLeave  在将对象拖出控件的边界时发生。(从 Control 继承。)
Public event DragOver  在将对象拖到控件的边界上发生。(从 Control 继承。)
Public event DrawNode 当绘制了 TreeViewDrawMode 属性设置为 Normal 以外的 TreeViewDrawMode 值时发生。
Public event Supported by the .NET Compact Framework EnabledChanged  Enabled 属性值更改后发生。(从 Control 继承。)
Public event Enter  进入控件时发生。(从 Control 继承。)
Public event FontChanged  Font 属性值更改时发生。(从 Control 继承。)
Public event ForeColorChanged  ForeColor 属性值更改时发生。(从 Control 继承。)
Public event GiveFeedback  在执行拖动操作期间发生。(从 Control 继承。)
Public event Supported by the .NET Compact Framework GotFocus  在控件接收焦点时发生。(从 Control 继承。)
Public event Supported by the .NET Compact Framework HandleCreated  在为控件创建句柄时发生。(从 Control 继承。)
Public event Supported by the .NET Compact Framework HandleDestroyed  在控件的句柄处于销毁过程中时发生。(从 Control 继承。)
Public event HelpRequested  当用户请求控件的帮助时发生。(从 Control 继承。)
Public event ImeModeChanged  ImeMode 属性更改后发生。(从 Control 继承。)
Public event Invalidated  在控件的显示需要重绘时发生。(从 Control 继承。)
Public event ItemDrag 当用户开始拖动节点时发生。
Public event Supported by the .NET Compact Framework KeyDown  在控件有焦点的情况下按下键时发生。(从 Control 继承。)
Public event Supported by the .NET Compact Framework KeyPress  在控件有焦点的情况下按下键时发生。(从 Control 继承。)
Public event Supported by the .NET Compact Framework KeyUp  在控件有焦点的情况下释放键时发生。(从 Control 继承。)
Public event Layout  在控件应重新定位其子控件时发生。(从 Control 继承。)
Public event Leave  在输入焦点离开控件时发生。(从 Control 继承。)
Public event LocationChanged  Location 属性值更改后发生。(从 Control 继承。)
Public event Supported by the .NET Compact Framework LostFocus  当控件失去焦点时发生。(从 Control 继承。)
Public event MarginChanged  在控件边距更改时发生。(从 Control 继承。)
Public event MouseCaptureChanged  当控件失去鼠标捕获时发生。(从 Control 继承。)
Public event MouseClick  在鼠标单击该控件时发生。(从 Control 继承。)
Public event MouseDoubleClick  当用鼠标双击控件时发生。(从 Control 继承。)
Public event MouseDown  当鼠标指针位于控件上并按下鼠标键时发生。(从 Control 继承。)
Public event MouseEnter  在鼠标指针进入控件时发生。(从 Control 继承。)
Public event MouseHover  在鼠标指针停放在控件上时发生。(从 Control 继承。)
Public event MouseLeave  在鼠标指针离开控件时发生。(从 Control 继承。)
Public event MouseMove  在鼠标指针移到控件上时发生。(从 Control 继承。)
Public event MouseUp  在鼠标指针在控件上并释放鼠标键时发生。(从 Control 继承。)
Public event MouseWheel  在移动鼠标轮并且控件有焦点时发生。(从 Control 继承。)
Public event Move  在移动控件时发生。(从 Control 继承。)
Public event NodeMouseClick 当用户使用鼠标单击 TreeNode 时发生。
Public event NodeMouseDoubleClick 当用户使用鼠标双击 TreeNode 时发生。
Public event NodeMouseHover 当鼠标悬停在 TreeNode 上时发生。
Public event PaddingChanged Padding 属性的值更改时发生。
Public event Paint 绘制 TreeView 时发生。
Public event Supported by the .NET Compact Framework ParentChanged  Parent 属性值更改时发生。(从 Control 继承。)
Public event PreviewKeyDown  在焦点位于此控件上的情况下,当有按键动作时发生(在 KeyDown 事件之前发生)。(从 Control 继承。)
Public event QueryAccessibilityHelp  AccessibleObject 为辅助功能应用程序提供帮助时发生。(从 Control 继承。)
Public event QueryContinueDrag  在拖放操作期间发生,并且允许拖动源确定是否应取消拖放操作。(从 Control 继承。)
Public event RegionChanged  Region 属性的值更改时发生。(从 Control 继承。)
Public event Resize  在调整控件大小时发生。(从 Control 继承。)
Public event RightToLeftChanged  RightToLeft 属性值更改时发生。(从 Control 继承。)
Public event RightToLeftLayoutChanged RightToLeftLayout 属性的值更改时发生。
Public event SizeChanged  Size 属性值更改时发生。(从 Control 继承。)
Public event StyleChanged  在控件样式更改时发生。(从 Control 继承。)
Public event SystemColorsChanged  系统颜色更改时发生。(从 Control 继承。)
Public event TabIndexChanged  TabIndex 属性值更改时发生。(从 Control 继承。)
Public event TabStopChanged  TabStop 属性值更改时发生。(从 Control 继承。)
Public event TextChanged Text 属性更改时发生。
Public event Supported by the .NET Compact Framework Validated  在控件完成验证时发生。(从 Control 继承。)
Public event Supported by the .NET Compact Framework Validating  在控件正在验证时发生。(从 Control 继承。)
Public event VisibleChanged  Visible 属性值更改时发生。(从 Control 继承。)

页首

请参见

参考

TreeView 类
System.Windows.Forms 命名空间
TreeNode 类