Skip to content

ChartObjectHoverChangedEventArgs

Summary

Provides data for the mouse hover over a chart object event.

Signature

1
public class ChartObjectHoverChangedEventArgs : ChartObjectEventArgs

Namespace

cAlgo.API

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
 using cAlgo.API;
 namespace cAlgo
 {
     // This example shows how to use the Chart ChartObjectHoverChangedEventArgs
     // ChartObjectHoverChangedEventArgs is derived from ChartObjectsEventArgs
     // Draw an object and move mouse over it
     [Indicator(IsOverlay = true, TimeZone = TimeZones.UTC, AccessRights = AccessRights.None)]
     public class ChartObjectHoverChangedEventArgsSample : Indicator
     {
         protected override void Initialize()
         {
             Chart.ObjectHoverChanged += Chart_ObjectHoverChanged; ;
         }
         private void Chart_ObjectHoverChanged(ChartObjectHoverChangedEventArgs obj)
         {
             Chart.DrawStaticText("hover", string.Format("Is Object Hovered: {0}", obj.IsObjectHovered), VerticalAlignment.Top, HorizontalAlignment.Right, Color.Red);
         }
         public override void Calculate(int index)
         {
         }
     }
 }

Properties

IsObjectHovered

Summary

Defines if the mouse is hovered over the chart object.

Signature

1
public bool IsObjectHovered {get;}

Return Value

bool