using Newtonsoft.Json; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows; using System.Windows.Media; namespace Tango.FSE.Diagnostics.Project.Widgets.Text { public class TextWidget : DiagnosticsConfigurableWidget { [JsonIgnore] public override string DisplayName { get { return Text; } } private String _text; public String Text { get { return _text; } set { _text = value; RaisePropertyChangedAuto(); RaisePropertyChanged(nameof(DisplayName)); } } private Color _color; public Color Color { get { return _color; } set { _color = value; RaisePropertyChangedAuto(); } } [JsonIgnore] public override bool HasSettings { get { return EditMode; } } public TextWidget() { Color = Colors.LightGray; Text = "press to edit text"; } public override FrameworkElement GetView() { return new TextWidgetView(); } } }