Ejemplo n.º 1
0
        void Path_MouseEnter(object sender, MouseEventArgs e)
        {
            piePopup.Visibility = System.Windows.Visibility.Visible;
            PieSegment seg = pathDictionary[sender as Path];

            popupData.Text = seg.Name + " : " + ((seg.Value / Data.GetTotal()) * 100).ToString("N2") + "%";
            Point point = Mouse.GetPosition(this);

            piePopup.Margin = new Thickness(point.X - piePopup.ActualWidth / 4, point.Y - (18 + piePopup.ActualHeight), 0, 0);
        }
Ejemplo n.º 2
0
 void AddPathToDictionary(Path path, PieSegment ps)
 {
     pathDictionary.Add(path, ps);
     path.MouseEnter += new MouseEventHandler(Path_MouseEnter);
     path.MouseMove  += new MouseEventHandler(Path_MouseMove);
 }
Ejemplo n.º 3
0
 void AddPathToDictionary(Path path, PieSegment ps)
 {
     _pathDictionary.Add(path, ps);
     path.MouseEnter += Path_MouseEnter;
     path.MouseMove += Path_MouseMove;
 }