Login Page - Create Account

Support Board


Date/Time: Sun, 01 Jun 2025 16:51:36 +0000



Time Line study and custom text label background color

View Count: 87

[2025-05-29 12:46:44]
tokauo - Posts: 40
Hello,
I'm trying to have full colored background and white text in Time Line study, but custom text label subgraphs is not reacting to "label" background color option (next to Auto coloring). Is possible to color background?

Thanks you
Tom
[2025-05-29 13:43:33]
John - SC Support - Posts: 40127
The text that is displayed with the Time Line study is actually a drawing, it is not the Name or Value label. As such, there is no control to allow for a background with text through the subgraphs.

The only way to get what you are wanting would be to modify the source code for the study and setup the drawing as you want it. The code is in the Studies2.cpp file in the ACS_Source folder under your main Sierra Chart installation folder.

Refer to the following:
How to Build an Advanced Custom Study from Source Code

Using Drawing Tools From an Advanced Custom Study: s_UseTool::ReverseTextColor

https://www.sierrachart.com/index.php?page=doc/SierraChartStudyAndSystemProgrammers.php
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2025-05-29 13:52:48]
tokauo - Posts: 40
OK, thanks you.
Is there a study/way that would allow to have a box (with text or without) pinned to the timeline (like the label from the Time Line study) with ability to be shown at time range (e.g. from 9:30-10:00)?
[2025-05-29 16:01:14]
John - SC Support - Posts: 40127
There are a number of ways to have an indicator that would be near the time axis that gives a visual representation for a certain time period. The simplest would be to use the "Spreadsheet Formula" and use a formula like the following to show the bars between 09:30 and 10:30 (including 09:30 and excluding 10:30):
=AND(BARTIME >= TIME(09, 30, 00), BARTIME < TIME(10, 30, 00))

Then set the Input for "Draw Zeros" to "No" and set the subgraph Draw Style to whatever works best for you. Also make sure the study is in the lowest region and then adjust the region height to get it displayed as you want.

You might also want to remove the display of the study name and parameters, so you just see the line, bar, whatever.

Refer to the following:
Spreadsheet Formula

Study/Chart Alerts And Scanning: Available Main Price Graph Identifiers/Variables

Chart Studies: Subgraphs Tab >> Draw Style
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2025-05-30 17:37:01]
tokauo - Posts: 40
Thanks you, it is great!
Is there way to have box in forward projection area (I mean drawn forward)?

I've tried to use "Text with background", if I type "TEST" into "Text to draw" it shows !TTTTTTTTTTTTTTTTTTTTTTTTTTEST" and box overlap time range from formula, is it posible to fix it like: to have text centered (without box overlaping time range from formula) and without extra letters (I found out that if I type 2x spacebar before and after text a line of "TTTT..." disapear)?

Thanks you
Date Time Of Last Edit: 2025-05-30 18:32:56
[2025-05-30 18:41:47]
John - SC Support - Posts: 40127
Is there way to have box in forward projection area (I mean drawn forward)?

There is not a way to do this using the built-in tools. It would require a modification of an existing study or a new study to specifically put the information into the forward projection area.

I've tried to use "Text with background", if I type "TEST" into "Text to draw" it shows !TTTTTTTTTTTTTTTTTTTTTTTTTTEST" and box overlap time range from formula, is it posible to fix it like: to have text centered (without box overlaping time range from formula) and without extra letters (I found out that if I type 2x spacebar before and after text a line of "TTTT..." disapear)?

The reason this does not work is that it is trying to put that text for every bar. There is no option for the solution we gave above, to have text centered across the time frame as you want it.

The only way to do something like this would be to use the "Type Text" tool to draw the text as you want and where you want. Refer to the following:
Chart Drawing Tools: Type Text | Stationary Text
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2025-05-30 22:09:29]
User688525 - Posts: 290
Hi John,
As the text of the Time Line study is a drawing, is this why the text looks different to the text of a label or value? I've noticed the Time Line study text is bold, or thicker, than label or value text.

If a custom study is created from the source code, is there a way for the text to be the same as a label or value?

Thank you
[2025-05-31 08:55:34]
tokauo - Posts: 40
There is not a way to do this using the built-in tools. It would require a modification of an existing study or a new study to specifically put the information into the forward projection area.

OK, thanks you.

For anyone else, who would like to do this as well, I have used a "Time Range Highlight" study with "Display in forward projection area" in the 2nd region of chart, than I disabled "Adjust Regions Tool Always Active with Current Tool" in Tool settings so as I can not to accidentally move the region.

One problem is, that it looks like if region include study, there is an minimal high (about 5px) or padding etc. (I've already tried to play with region data lines - it didn't help)?
Is there way to make region height (let's say extremely) 1px?

Thanks you
Date Time Of Last Edit: 2025-05-31 11:22:48

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account