• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

ZOrder Issues

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

    ZOrder Issues

    Hi,

    I am drawing some fixed text using SharoDX in the OnRender void. The issue I am having is that the Draw.Line and the Draw.Text objects drawn in the OnBarUpdate are overlaying ontop of my text and rectangle which is drawn in OnRender. Please see attachment for the screenshot of this


    I have tried adding " ZOrderType = DrawingToolZOrder.AlwaysDrawnLast;" to the Set.Defauts as shown in the helpguide below in order to test the effect, however ZOrdeType doesnt seem to exist and therefor wont compile

    http://ninjatrader.com/support/helpG...zordertype.htm

    Any suggestions?
    Attached Files

    #2
    Hello,

    Thank you for the post.

    It appears that ZOrderType is a DrawingTool inherited property, are you currently using this outside of a drawing tool? If so that would explain why that is not compiling.

    Regarding your initial request, could you provide a simple example script that shows a render and drawing object used that overlap? I would like to see the structure you are using and use that going forward with the question. I am unsure by the context if the overlap as shown would simply be how the drawing is currently working or the order in which you are drawing so it would be good to start with a sample to work off of.


    I look forward to being of further assistance.
    Last edited by NinjaTrader_Jesse; 02-16-2016, 08:28 AM.
    JesseNinjaTrader Customer Service

    Comment


      #3
      Hi Jesse,

      Thanks for attending to this.

      Please see attached script along with a pic of the output.

      What I need to do is make the pink vertical lines go behind the rectangle and text just like the candles are doing.

      I am not a career coder, if you could give me an example of the ZOrderType in action, that you be appreciated.

      Cheers.
      Attached Files
      Last edited by marty087; 02-17-2016, 12:09 AM.

      Comment


        #4
        Hello,

        Thank you for the image and script, I now see what is happening.

        It looks like this property is accessable from the object its self:

        Code:
        Draw.VerticalLine(this,"Line"+x,x*5,Brushes.Fuchsia).ZOrderType = DrawingToolZOrder.AlwaysDrawnFirst;
        This seems to place the lines before the OnRender so OnRender items are placed over the draw objects.

        I look forward to being of further assistance.
        JesseNinjaTrader Customer Service

        Comment


          #5
          Works perfectly. Thanks

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by Conall, Today, 06:11 AM
          1 response
          9 views
          0 likes
          Last Post NinjaTrader_Kate  
          Started by CaptainAmericaXX, Today, 07:41 AM
          1 response
          3 views
          0 likes
          Last Post NinjaTrader_Jim  
          Started by Longhornmark, Today, 07:06 AM
          2 responses
          7 views
          0 likes
          Last Post Longhornmark  
          Started by 2sureshk, Today, 07:29 AM
          0 responses
          5 views
          0 likes
          Last Post 2sureshk  
          Started by uday12, Yesterday, 10:26 PM
          1 response
          5 views
          0 likes
          Last Post NinjaTrader_PaulH  
          Working...
          X