Skip to content

ColorThemeChangeEventArgs

Summary

Provides data for the color theme change event.

Signature

1
public class ColorThemeChangeEventArgs

Namespace

cAlgo.API

Properties

Name Description
ColorTheme { get; } Gets the color theme.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
 using cAlgo.API;
 namespace cAlgo
 {
     // This example shows how to use the Chart ColorThemeChangeEventArgs
     [Indicator(IsOverlay = true, TimeZone = TimeZones.UTC, AccessRights = AccessRights.None)]
     public class ColorThemeChangeEventArgsSample : Indicator
     {
         protected override void Initialize()
         {
             Application.ColorThemeChanged += Application_ColorThemeChanged;
         }
         private void Application_ColorThemeChanged(ColorThemeChangeEventArgs obj)
         {
             var text = string.Format("Theme Changed To: {0}", obj.ColorTheme);
             Chart.DrawStaticText("text", text, VerticalAlignment.Top, HorizontalAlignment.Right, Color.Red);
         }
         public override void Calculate(int index)
         {
         }
     }
 }

See Also


Last update: July 1, 2022

Comments