private AttachFormatBarToRichtextBox ( global richTextBox, IRichTextBoxFormatBar formatBar ) : void | ||
richTextBox | global | The RichtextBox to attach to. |
formatBar | IRichTextBoxFormatBar | The Formatbar to attach. |
return | void |
private static void OnFormatBarPropertyChanged( DependencyObject d, DependencyPropertyChangedEventArgs e ) { global::System.Windows.Controls.RichTextBox rtb = d as global::System.Windows.Controls.RichTextBox; if( rtb == null ) throw new Exception( "A FormatBar can only be applied to a RichTextBox." ); RichTextBoxFormatBarManager manager = new RichTextBoxFormatBarManager(); manager.AttachFormatBarToRichtextBox( rtb, e.NewValue as IRichTextBoxFormatBar ); }
private static void OnFormatBarPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { global::System.Windows.Controls.RichTextBox rtb = d as global::System.Windows.Controls.RichTextBox; if (rtb == null) { throw new Exception("A FormatBar can only be applied to a RichTextBox."); } RichTextBoxFormatBarManager manager = new RichTextBoxFormatBarManager(); manager.AttachFormatBarToRichtextBox(rtb, e.NewValue as IRichTextBoxFormatBar); }