C# Класс 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.).
Наследование: FrameworkElement
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
ContentProperty DependencyProperty
ContentTemplateProperty DependencyProperty

Private Properties

Свойство Тип Описание
ClearRoot void
GetDefaultTemplate System.Windows.Controls.UIElement
InvokeLoaded void
OnContentPropertyChanged void
OnContentTemplatePropertyChanged void

Открытые методы

Метод Описание
ContentPresenter ( ) : Mono

Initializes a new instance of the ContentPresenter class.

Приватные методы

Метод Описание
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.

Описание методов

ContentPresenter() публичный Метод

Initializes a new instance of the ContentPresenter class.
public ContentPresenter ( ) : Mono
Результат Mono

Описание свойств

ContentProperty публичное статическое свойство

Identifies the Content dependency property.
public static DependencyProperty ContentProperty
Результат DependencyProperty

ContentTemplateProperty публичное статическое свойство

Identifies the ContentTemplate dependency property.
public static DependencyProperty ContentTemplateProperty
Результат DependencyProperty