C# Class System.Windows.Controls.ContentPresenter

Displays the content of a ContentControl.
Typically, you the ContentPresenter directly within the ControlTemplate of a ContentControl to mark where the content should be displayed. Every type derived from ContentControl should have a ContentPrenter in its ControlTemplate (although it may not necessarily be a TemplatePart). The ContentPresenter in the ControlTemplate should use a TemplateBinding to associate ContentControl.Content with ContentPresenter.Content (and an other relevant properties like FontSize, VeriticalAlignment, etc.).
Inheritance: FrameworkElement
ファイルを表示 Open project: shana/moon Class Usage Examples

Public Properties

Property Type Description
ContentProperty DependencyProperty
ContentTemplateProperty DependencyProperty

Private Properties

Property Type Description
ClearRoot void
GetDefaultTemplate System.Windows.Controls.UIElement
InvokeLoaded void
OnContentPropertyChanged void
OnContentTemplatePropertyChanged void

Public Methods

Method Description
ContentPresenter ( ) : Mono

Initializes a new instance of the ContentPresenter class.

Private Methods

Method Description
ClearRoot ( ) : void
GetDefaultTemplate ( ) : System.Windows.Controls.UIElement
InvokeLoaded ( ) : void
OnContentPropertyChanged ( DependencyObject d, DependencyPropertyChangedEventArgs e ) : void

ContentProperty property changed handler.

OnContentTemplatePropertyChanged ( DependencyObject d, DependencyPropertyChangedEventArgs e ) : void

ContentTemplateProperty property changed handler.

Method Details

ContentPresenter() public method

Initializes a new instance of the ContentPresenter class.
public ContentPresenter ( ) : Mono
return Mono

Property Details

ContentProperty public_oe static_oe property

Identifies the Content dependency property.
public static DependencyProperty ContentProperty
return DependencyProperty

ContentTemplateProperty public_oe static_oe property

Identifies the ContentTemplate dependency property.
public static DependencyProperty ContentTemplateProperty
return DependencyProperty