I don't want "Hello World" placed at a location relative to price values, bur rather at a specific pixel value above where "Bottom.Right" text would appear.
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Place text at a specific pixel location
Collapse
X
-
Place text at a specific pixel location
Could you give me an example of a Draw.Text() statement that will print the text "Hello World" right above where Draw.TextFixed( .. Bottom.Right) would be placed on a chart.
I don't want "Hello World" placed at a location relative to price values, bur rather at a specific pixel value above where "Bottom.Right" text would appear.Tags: None
-
Hello SilverSurfer1,
Unfortunately, drawing tools must be drawn over a bar or at a fixed corner in the case of Draw.TextFixed().
Instead of using a drawing tool, you will need to custom render the text in OnRender().
Included with NinjaTrader is the SampleCustomRender() script that demonstrates.
I am also including links to the help guide.
https://ninjatrader.com/support/help...8/onrender.htm
https://ninjatrader.com/support/help...t_drawtext.htm
And a link to a User App Share script that renders text in OnRender().
https://ninjatraderecosystem.com/use...bol-watermark/Chelsea B.NinjaTrader Customer Service
-
Thanks for the response. That is way too much work for a simple text. Maybe in a future release, there could be a Draw.TextCustom.( xAxisPixel, yAxisPixel) which will allow placing text anywhere on the X/Y axis.Last edited by SilverSurfer1; 09-20-2023, 01:18 PM.
- Likes 2
Comment
-
Hello SilverSurfer1,
This request is being tracked with ID # SFT-647.
Please note, we receive many requests and cannot reasonably implement all requested features or changes. Interest is tracked internally and if enough interest is tracked, it would be weighed against how feasible it would be to make those changes to consider implementing, so we cannot offer an ETA or promise of fulfillment.
When new features are implemented, they will be listed in the Release Notes page of the Help Guide. The ID number may be different than the internal feature request tracking ID, but the description of the feature will let you know if that feature has been implemented.
Release Notes - https://ninjatrader.com/support/help...ease_notes.htmChelsea B.NinjaTrader Customer Service
- Likes 1
Comment
-
You should certainly be using OnRender for this. A specific pixel location is not a good idea because what if they resize the window? What if their resolution differs? What about their text size being 150% vs. 100%? It's really not so simple unless you're always printing in the upper left and even then the distance from the corner will vary if you do not take these things into account. That's why OnRender is just a better solution - you can program in what you need.
- Likes 1
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Hwop38, 05-04-2026, 07:02 PM
|
0 responses
154 views
0 likes
|
Last Post
by Hwop38
05-04-2026, 07:02 PM
|
||
|
Started by CaptainJack, 04-24-2026, 11:07 PM
|
0 responses
306 views
0 likes
|
Last Post
by CaptainJack
04-24-2026, 11:07 PM
|
||
|
Started by Mindset, 04-21-2026, 06:46 AM
|
0 responses
244 views
0 likes
|
Last Post
by Mindset
04-21-2026, 06:46 AM
|
||
|
Started by M4ndoo, 04-20-2026, 05:21 PM
|
0 responses
345 views
0 likes
|
Last Post
by M4ndoo
04-20-2026, 05:21 PM
|
||
|
Started by M4ndoo, 04-19-2026, 05:54 PM
|
0 responses
176 views
0 likes
|
Last Post
by M4ndoo
04-19-2026, 05:54 PM
|

Comment