HwndSource Members

Presents Windows Presentation Foundation (WPF) content within a Win32 window.

The following tables list the members exposed by the HwndSource type.

  Name Description
Public method HwndSource Overloaded. Initializes a new instance of the HwndSource class.
Top

  Name Description
Public property CompositionTarget Gets the visual manager for the hosted window.
Public property Static CurrentSources  Returns a list of sources. This list supports an enumerator over a readonly threadsafe copy of the list of sources as added with AddSource.(inherited from PresentationSource)
Public property Dispatcher  Gets the Dispatcher this DispatcherObject is associated with. (inherited from DispatcherObject)
Public property Handle Gets the window handle for this HwndSource.
Public property IsDisposed Gets a value that indicates whether Dispose has been called on this HwndSource.
Public property RootVisual Gets or sets the RootVisual of the window.
Public property SizeToContent Get or sets whether and how the window is sized to its content.
Public property UsesPerPixelOpacity Gets a value that declares whether the per-pixel opacity of the source window content is respected.
Top

(see also Protected Methods )
  Name Description
Public method AddHook Adds an event handler that receives all window messages.
Public method Static AddSourceChangedHandler  Adds a handler for the SourceChanged event to the provided element. (inherited from PresentationSource)
Public method CheckAccess  Determines whether the calling thread has access to this DispatcherObject. (inherited from DispatcherObject)
Public method CreateHandleRef Gets the window handle for the HwndSource. The window handle is packaged as part of a HandleRef structure.
Public method Dispose Releases all managed resources used by the HwndSource, and raises the Disposed event.
Public method Equals  Overloaded. Determines whether two Object instances are equal. (inherited from Object)
Public method Static FromHwnd Returns the HwndSource object of the specified window.
Public method Static FromVisual  Returns the source in which a provided Visual is presented. (inherited from PresentationSource)
Public method GetHashCode  Serves as a hash function for a particular type. (inherited from Object)
Public method GetType  Gets the Type of the current instance. (inherited from Object)
Public method Static ReferenceEquals  Determines whether the specified Object instances are the same instance. (inherited from Object)
Public method RemoveHook Removes the event handlers that were added by AddHook.
Public method Static RemoveSourceChangedHandler  Removes a handler for the SourceChanged event from the provided element. (inherited from PresentationSource)
Public method ToString  Returns a String that represents the current Object. (inherited from Object)
Public method VerifyAccess  Enforces that the calling thread has access to this DispatcherObject. (inherited from DispatcherObject)
Top

  Name Description
Protected method AddSource  Adds a PresentationSource derived class instance to the list of known presentation sources. (inherited from PresentationSource)
Protected method ClearContentRenderedListeners  Sets the list of listeners for the ContentRendered event to a null reference (Nothing in Visual Basic). (inherited from PresentationSource)
Protected method Finalize  Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection. (inherited from Object)
Protected method GetCompositionTargetCore Overridden. Gets the visual target of the window.
Protected method MemberwiseClone  Creates a shallow copy of the current Object. (inherited from Object)
Protected method RemoveSource  Removes a PresentationSource derived class instance from the list of known presentation sources. (inherited from PresentationSource)
Protected method RootChanged  Provides notification that the root Visual has changed. (inherited from PresentationSource)
Top

  Name Description
Public event AutoResized Occurs when layout causes the HwndSource to automatically resize.
Public event ContentRendered  Occurs when content is rendered and ready for user interaction. (inherited from PresentationSource)
Public event Disposed Occurs when the Dispose method is called on this object.
Public event SizeToContentChanged Occurs when the value of the SizeToContent property changes.
Top

  Name Description
Explicit interface implementation Method System.Windows.Interop.IKeyboardInputSink.HasFocusWithin This member supports the WPF infrastructure and is not intended to be called from your code.
Explicit interface implementation Method System.Windows.Interop.IKeyboardInputSink.OnMnemonic This member supports the WPF infrastructure and is not intended to be called from your code.
Explicit interface implementation Method System.Windows.Interop.IKeyboardInputSink.RegisterKeyboardInputSink This member supports the WPF infrastructure and is not intended to be called from your code.
Explicit interface implementation Method System.Windows.Interop.IKeyboardInputSink.TabInto Attempts to set focus on a specified tab stop (either the first or last tab stop).
Explicit interface implementation Method System.Windows.Interop.IKeyboardInputSink.TranslateAccelerator Processes keyboard input at the input message level.
Explicit interface implementation Method System.Windows.Interop.IKeyboardInputSink.TranslateChar Processes WM_CHAR, WM_SYSCHAR, WM_DEADCHAR, and WM_SYSDEADCHAR input messages before System.Windows.Interop.IKeyboardInputSink.OnMnemonic is called.
Explicit interface implementation Property System.Windows.Interop.IKeyboardInputSink.KeyboardInputSite Gets or sets the keyboard input site. .
Top

Community Additions

ADD
Show: