diff options
| author | Roy Ben Shabat <Roy.mail.net@gmail.com> | 2020-12-28 00:50:47 +0200 |
|---|---|---|
| committer | Roy Ben Shabat <Roy.mail.net@gmail.com> | 2020-12-28 00:50:47 +0200 |
| commit | 028cca5fd51b4e5edb183e41e4e6831028a39e44 (patch) | |
| tree | eda1e3ac087073eaba532ddb3a977dd51cccd853 /Software/Visual_Studio/Tango.SharedUI/Controls/FastTextBlock.cs | |
| parent | ad969db71a39b4854d744412eb6482c0391a4dd9 (diff) | |
| parent | 0fdbc932838bb6e007cfa8a0079d1880c800ed81 (diff) | |
| download | Tango-028cca5fd51b4e5edb183e41e4e6831028a39e44.tar.gz Tango-028cca5fd51b4e5edb183e41e4e6831028a39e44.zip | |
Merged Urgent-Color-Space Branch.
Diffstat (limited to 'Software/Visual_Studio/Tango.SharedUI/Controls/FastTextBlock.cs')
| -rw-r--r-- | Software/Visual_Studio/Tango.SharedUI/Controls/FastTextBlock.cs | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/Software/Visual_Studio/Tango.SharedUI/Controls/FastTextBlock.cs b/Software/Visual_Studio/Tango.SharedUI/Controls/FastTextBlock.cs index 141fa6e27..07005a0f4 100644 --- a/Software/Visual_Studio/Tango.SharedUI/Controls/FastTextBlock.cs +++ b/Software/Visual_Studio/Tango.SharedUI/Controls/FastTextBlock.cs @@ -1,5 +1,6 @@ using System; using System.Collections.Generic; +using System.ComponentModel; using System.Globalization; using System.Linq; using System.Text; @@ -30,6 +31,23 @@ namespace Tango.SharedUI.Controls public FastTextBlock() { Loaded += FastTextBlock_Loaded; + + DependencyPropertyDescriptor fontFamilyPropertyDescriptor = DependencyPropertyDescriptor.FromProperty(FastTextBlock.FontFamilyProperty, typeof(FastTextBlock)); + fontFamilyPropertyDescriptor.AddValueChanged(this, OnPropertyChangedInit); + + DependencyPropertyDescriptor fontSizePropertyDescriptor = DependencyPropertyDescriptor.FromProperty(FastTextBlock.FontSizeProperty, typeof(FastTextBlock)); + fontSizePropertyDescriptor.AddValueChanged(this, OnPropertyChangedInit); + + DependencyPropertyDescriptor fontWeightPropertyDescriptor = DependencyPropertyDescriptor.FromProperty(FastTextBlock.FontWeightProperty, typeof(FastTextBlock)); + fontWeightPropertyDescriptor.AddValueChanged(this, OnPropertyChangedInit); + + DependencyPropertyDescriptor ForegroundPropertyDescriptor = DependencyPropertyDescriptor.FromProperty(FastTextBlock.ForegroundProperty, typeof(FastTextBlock)); + ForegroundPropertyDescriptor.AddValueChanged(this, OnPropertyChangedInit); + } + + private void OnPropertyChangedInit(object sender, EventArgs e) + { + Init(); } private void FastTextBlock_Loaded(object sender, RoutedEventArgs e) |
