Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

How to set border brush to Rectangle?

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

    How to set border brush to Rectangle?

    Hi,

    im trying to draw a rectangle, but in the documentation https://ninjatrader.com/es/support/h..._rectangle.htm there is no constructor with Brush and isGlobal parameters.

    I try to use this constructor Draw.Rectangle(NinjaScriptBase owner, string tag, DateTime startTime, double startY, DateTime endTime, double endY, Brush brush), this draws ok my rectangle with area and border same color, but need to set after the isGlobal but it doesnot work, i found just an attribute called IsGlobalDrawingTool but it is readonly.

    So i try to use the constructor Draw.Rectangle(NinjaScriptBase owner, string tag, DateTime startTime, double startY, DateTime endTime, double endY, bool isGlobal, string templateName) to set after the brush attribute, but only found AreaBrush to set, but i want to set the brush of the border too, because it draws the area with a color and the border with other color and does not know how to assign it.

    Click image for larger version

Name:	Rectangle.PNG
Views:	247
Size:	17.3 KB
ID:	1212019

    Thank you for your help!
    Attached Files

    #2
    arbeydario To change the Rectangle's border/outline colour, have you tried setting the Rectangle's OutlineStroke: https://ninjatrader.com/es/support/h.../rectangle.htm

    Thanks.
    Multi-Dimensional Managed Trading
    jeronymite
    NinjaTrader Ecosystem Vendor - Mizpah Software

    Comment


      #3
      Thank you jeronymite, it works!!

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Geovanny Suaza, 02-11-2026, 06:32 PM
      0 responses
      637 views
      0 likes
      Last Post Geovanny Suaza  
      Started by Geovanny Suaza, 02-11-2026, 05:51 PM
      0 responses
      366 views
      1 like
      Last Post Geovanny Suaza  
      Started by Mindset, 02-09-2026, 11:44 AM
      0 responses
      107 views
      0 likes
      Last Post Mindset
      by Mindset
       
      Started by Geovanny Suaza, 02-02-2026, 12:30 PM
      0 responses
      569 views
      1 like
      Last Post Geovanny Suaza  
      Started by RFrosty, 01-28-2026, 06:49 PM
      0 responses
      572 views
      1 like
      Last Post RFrosty
      by RFrosty
       
      Working...
      X