Skip to content

ChartTemplateDisplaySettings.PriceScaleMode

property · ChartTemplateDisplaySettings · cAlgo.API Since 5.10

DesktopCLICloud

Gets or sets the price scale mode for chart template. While the template price to bar ratio is locked only Regular can be set, and setting any other mode is ignored.

Environment behaviour

Cloud — not supported. Never available in the cloud: it is only returned by members that do not work there (ChartTemplate.DisplaySettings).

Definition

ChartPriceScaleMode PriceScaleMode {get; set;}
chartTemplateDisplaySettings.PriceScaleMode: ChartPriceScaleMode

Returns ChartPriceScaleMode

Examples

var template = ChartTemplates.Get("Template Name");

if (template is null)
{
    Print("Template not found");
    return;
}

template.DisplaySettings.PriceScaleMode = ChartPriceScaleMode.Percent;

Print("Template price scale mode: {0}", template.DisplaySettings.PriceScaleMode);
template = api.ChartTemplates.Get("Template Name")

if template is None:
    print("Template not found")
    return

template.DisplaySettings.PriceScaleMode = ChartPriceScaleMode.Percent

print(f"Template price scale mode: {template.DisplaySettings.PriceScaleMode}")