Free cookie consent management tool by TermsFeed Policy Generator

source: branches/HeuristicLab.Problems.GrammaticalOptimization/DynamicDataDisplay/Charts/LiveTooltips/LiveTooltip.cs @ 13398

Last change on this file since 13398 was 12503, checked in by aballeit, 10 years ago

#2283 added GUI and charts; fixed MCTS

File size: 1.6 KB
Line 
1using System;
2using System.Collections.Generic;
3using System.Linq;
4using System.Text;
5using System.Windows.Controls;
6using System.Windows;
7using System.Windows.Media;
8using System.Windows.Input;
9using System.Diagnostics;
10
11namespace Microsoft.Research.DynamicDataDisplay.Charts
12{
13  public class LiveToolTip : ContentControl
14  {
15    static int nameCounter = 0;
16    static LiveToolTip()
17    {
18      var thisType = typeof(LiveToolTip);
19
20      DefaultStyleKeyProperty.OverrideMetadata(thisType, new FrameworkPropertyMetadata(thisType));
21      FocusableProperty.OverrideMetadata(thisType, new FrameworkPropertyMetadata(false));
22      IsHitTestVisibleProperty.OverrideMetadata(thisType, new FrameworkPropertyMetadata(false));
23      BackgroundProperty.OverrideMetadata(thisType, new FrameworkPropertyMetadata(Brushes.White));
24      OpacityProperty.OverrideMetadata(thisType, new FrameworkPropertyMetadata(1.0));
25      BorderBrushProperty.OverrideMetadata(thisType, new FrameworkPropertyMetadata(Brushes.DarkGray));
26      BorderThicknessProperty.OverrideMetadata(thisType, new FrameworkPropertyMetadata(new Thickness(1.0)));
27    }
28
29    public LiveToolTip()
30    {
31      Name = "Microsoft_Research_Dynamic_Data_Display_Charts_LiveToolTip_" + nameCounter;
32      nameCounter++;
33    }
34
35    #region Properties
36
37    public FrameworkElement Owner
38    {
39      get { return (FrameworkElement)GetValue(OwnerProperty); }
40      set { SetValue(OwnerProperty, value); }
41    }
42
43    public static readonly DependencyProperty OwnerProperty = DependencyProperty.Register(
44      "Owner",
45      typeof(FrameworkElement),
46      typeof(LiveToolTip),
47      new FrameworkPropertyMetadata(null));
48
49    #endregion // end of Properties
50  }
51}
Note: See TracBrowser for help on using the repository browser.