以ChildWindow为例: /// <summary> /// Gets or sets the title that is displayed in the frame of the /// <see cref="T:System.Windows.Controls.ChildWindow" />. /// </summary> /// <value> /// The title displayed at the top of the window. The default is null. /// </value> public object Title { get { return GetValue(TitleProperty); } set { SetValue(TitleProperty, value); } } /// <summary> /// Identifies the /// <see cref="P:System.Windows.Controls.ChildWindow.Title" /> /// dependency property. /// </summary> /// <value> /// The identifier for the /// <see cref="P:System.Windows.Controls.ChildWindow.Title" /> /// dependency property. /// </value> public static readonly DependencyProperty TitleProperty = DependencyProperty.Register( "Title", typeof(object), typeof(ChildWindow), null);