Support Board
Date/Time: Sat, 10 May 2025 14:00:27 +0000
Post From: How large can SCString be?
[2016-02-01 21:23:13] |
Al SC Developer - Posts: 434 |
No, there are no changes required in SC. In the next version, we have added a simple sample study "UseTool Example: Multiline Text" which shows how this works. It is located in routine scsf_UseToolExampleMultilineText in studies.cpp. Here is a portion of that code: s_UseTool Tool; Tool.ChartNumber = sc.ChartNumber; int &LineNumber = sc.GetPersistentInt(1); if(LineNumber != 0) Tool.LineNumber = LineNumber; Tool.Region = 0; Tool.DrawingType = DRAWING_TEXT; Tool.AddMethod = UTAM_ADD_OR_ADJUST; Tool.Text = "Text Example\nSecond Line\nThird Line\nForth Line"; Tool.BeginIndex = BarIndex; Tool.BeginValue = sc.Close[BarIndex]; Tool.Color = COLOR_YELLOW; Tool.MultiLineLabel = 1; Tool.FontFace = sc.GetChartTextFontFaceName(); Tool.FontSize = 14; Tool.FontBold = 1; sc.UseTool(Tool); LineNumber = Tool.LineNumber; This code will draw four lines of text 20 bars back. Date Time Of Last Edit: 2016-02-01 21:25:18
|