Beispiel #1
0
        public override void OnApplyTemplate()
        {
            base.OnApplyTemplate();

            SelectableTextBlock tbContent = this.Template.FindName("PART_Content", this) as SelectableTextBlock;

            if (tbContent != null)
            {
                tbContent.Inlines.AddRange(this.Content);

                this.TBContent = tbContent;
                //this.Content = _content = new ObservableCollection<Inline>();
            }
        }
Beispiel #2
0
        private static void OnContentPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            SelectableTextBlock target = d as SelectableTextBlock;

            target.LoadNewContent();
        }