Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Fixed plot in right margin area

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • NinjaTrader_ChelseaB
    replied
    Hello Cyph3r,

    While you cannot render in the price margin, you can render a line within the chart panel area on the right side.

    Draw.TextFixed() will allow you to draw text in the bottom right of the chart.


    OnRender() is the method run on each render pass where you can add objects to be rendered to the RenderTarget.

    Create a TextLayout object and set the text in the string text parameter, then draw the text with RenderTarget.DrawTextLayout().

    Included with NinjaTrader is the SampleCustomRender indicator that demonstrates how to render.

    I can also provide an example that renders text.
    Simple script that adds a background watermark of the instrument symbol (and expiry if a future) to the chart. (Updated July 10th, 2018 ‐ The opacity needed to be casted as a double and divided by 100 to be between 0 and 1) (Update: August 24th, 2021 – Subtracted the ChartPanel.Y so indicator can be […]



    The NinjaTrader Ecosystem website is for educational and informational purposes only and should not be considered a solicitation to buy or sell a futures contract or make any other type of investment decision. The add-ons listed on this website are not to be considered a recommendation and it is the reader's responsibility to evaluate any product, service, or company. NinjaTrader Ecosystem LLC is not responsible for the accuracy or content of any product, service or company linked to on this website.

    Leave a comment:


  • Cyph3r
    started a topic Fixed plot in right margin area

    Fixed plot in right margin area

    Does anyone know how to place a line/text in a fixed space on the right side margin on NT8? Meaning that as you horizontally scroll to the left, the indicator remains fixed in the extended/margin area on the right side of the chart.

    I *think* the OnRender() function is the key, but I'm not sure what to do with it. https://ninjatrader.com/support/help.../?onrender.htm

    Thanks!
    Last edited by Cyph3r; 11-21-2020, 02:07 PM.

Latest Posts

Collapse

Topics Statistics Last Post
Started by r68cervera, Today, 05:29 AM
0 responses
3 views
0 likes
Last Post r68cervera  
Started by geddyisodin, Today, 05:20 AM
0 responses
6 views
0 likes
Last Post geddyisodin  
Started by JonesJoker, 04-22-2024, 12:23 PM
6 responses
35 views
0 likes
Last Post JonesJoker  
Started by GussJ, 03-04-2020, 03:11 PM
12 responses
3,241 views
0 likes
Last Post Leafcutter  
Started by AveryFlynn, Today, 04:57 AM
0 responses
7 views
0 likes
Last Post AveryFlynn  
Working...
X