![]() |
This website will be down for maintenance from Friday May 24th at 6PM MDT until Saturday May 25th at 11AM MDT. We apologize for the inconvenience. If you need assistance during this time, please email sales@ninjatrader.com
|
|||||||
| Indicator Development Support for the development of custom indicators using NinjaScript. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Member
Join Date: Mar 2008
Posts: 33
Thanks: 2
Thanked 2 times in 2 posts
|
I have copied the NT7 "Pivots" indicator and amended it to only show the R1,S1 and mid pivots. However, the text is to the left of the lines and over the price bars. How do I move the text to the right side of the lines and away from the price bars (inside the margin)? (Please see screenshot) Thanks.
Wilson |
|
|
|
|
|
#2 |
|
NinjaTrader Customer Service
Join Date: Apr 2010
Location: Denver, CO, USA
Posts: 4,783
Thanks: 160
Thanked 566 times in 557 posts
|
Hello,
The area you're looking for is in the #regions Miscellaneous section. The exact line is around 508 and reads: graphics.DrawString(plot.Name, ChartControl.Font, brush, lastX, lastY - textHeight / 2, stringFormatFar); You'll want to change lastX to whichever X value you would like this to plot.
Matthew
NinjaTrader Customer Service |
|
|
|
|
|
#3 |
|
Member
Join Date: Mar 2008
Posts: 33
Thanks: 2
Thanked 2 times in 2 posts
|
Thanks Matthew for your reply. If I input a value for lastX, say "1500" the letters are placed to the right of the lines like I want, however if I reduce the chart dimensions, the letters are obscured. How can I place the letters at the end of the lines so they remain visable with the lines ?
|
|
|
|
|
|
#4 |
|
NinjaTrader Customer Service
Join Date: Dec 2011
Location: India
Posts: 3,286
Thanks: 580
Thanked 546 times in 541 posts
|
Hello Wi!s0n,
You can use properties exposed by the unsupported ChartControl class to do it. ChartControl.CanvasRight for example will give you the right parameter.
Joydeep M.
NinjaTrader Customer Service |
|
|
|
|
|
#5 |
|
Member
Join Date: Mar 2008
Posts: 33
Thanks: 2
Thanked 2 times in 2 posts
|
Thanks Joy, that works best
|
|
|
|
|
The following user says thank you to Wi!s0n for this post: |
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Left Margin? | chuckt101 | Miscellaneous Support | 6 | 03-24-2011 11:06 AM |
| Chart Trader: Request to move the X cancel button from right to the left of the line | cw30000 | Version 7 Beta General Questions & Bug Reports | 3 | 07-08-2010 09:14 AM |
| #region/endregion + / - boxes at left margin | zeller4 | General Programming | 2 | 06-11-2010 09:17 AM |
| plot not move with right side margin | kingfish88 | Indicator Development | 5 | 05-23-2008 08:15 AM |
| NT 6 How to move X box on open orders back to the left | nightowl | Charting | 1 | 01-16-2007 05:52 AM |