更新:2007 年 11 月
UIElement3D is a base class for WPF core level implementations building on Windows Presentation Foundation (WPF) elements and basic presentation characteristics.
命名空间:
System.Windows 程序集:
PresentationCore(在 PresentationCore.dll 中)
Public MustInherit Class UIElement3D _
Inherits Visual3D _
Implements IInputElement
Dim instance As UIElement3D
public abstract class UIElement3D : Visual3D,
IInputElement
public ref class UIElement3D abstract : public Visual3D,
IInputElement
public abstract class UIElement3D extends Visual3D implements IInputElement
public abstract class UIElement3D extends Visual3D implements IInputElement
该类为抽象类;有关 XAML 中可用的派生的非抽象类,请参见 继承层次结构。
UIElement3D is an abstract base class from which you can derive classes to represent specific 3D elements.
Much of the input, focusing, and eventing behavior for 3D elements in general is defined in the UIElement3D class. This includes the events for keyboard, mouse, and stylus input, and related status properties. Many of these events are routed events, and many of the input-related events have both a bubbling routing version as well as a tunneling version of the event. These paired events are typically the events of greatest interest to control authors.
UIElement3D also includes API that relate to the WPF event model, including methods that can raise specified routed events that are sourced from an element instance.
A UIElement3D has the following capabilities that are specifically defined by the UIElement3D class:
重要说明: |
|---|
Visibility state affects all input handling by that element. Elements that are not visible do not participate in hit testing and do not receive input events, even if the mouse is over the bounds of where the element would be if were visible. |
Unlike the UIElement class, the UIElement3D class does not include layout. Therefore, the UIElement3D class does not include Measure or Arrange methods.
A class that derives from UIElement3D and maintains its own collection of Visual3D objects by overriding GetVisual3DChild and Visual3DChildrenCount must still pass new Visual3D objects to AddVisual3DChild.
UIElement3D is introduced in the .NET Framework version 3.5. For more information, see .NET Framework 3.5 体系结构.
The following example shows how to derive from the UIElement3D class to create a Sphere class:
For the complete sample, see UIElement3D 球体示例.
System..::.Object
System.Windows.Threading..::.DispatcherObject
System.Windows..::.DependencyObject
System.Windows.Media.Media3D..::.Visual3D
System.Windows..::.UIElement3D
System.Windows.Media.Media3D..::.ContainerUIElement3D
System.Windows.Media.Media3D..::.ModelUIElement3D
此类型的任何公共 static(在 Visual Basic 中为 Shared) 成员都是线程安全的。但不保证所有实例成员都是线程安全的。
.NET Framework 和 .NET Compact Framework 并不是对每个平台的所有版本都提供支持。有关支持的版本的列表,请参见.NET Framework 系统要求。
.NET Framework
受以下版本支持:3.5 SP1、3.0 SP1
参考
其他资源