draw a frame with a text together
Forums › ProRealTime English forum › ProRealTime platform support › draw a frame with a text together
- This topic has 5 replies, 3 voices, and was last updated 2 years ago by ZeroCafeine.
-
-
10/13/2022 at 5:26 PM #202492
Hi everyone
is it possible to draw a rectangle with a text at the same time so that the text moves automatically ?
you can see on the photo, I have to move the text all the time, or maybe I can draw a rectangle with a name ?
Is it possible to have the values of the rectangle on the cursor detail ?
10/13/2022 at 6:05 PM #202499for the picture 1, I found this solution for now, I draw 2 resistance with the value and write it right side, and on one of them I write the word “Weakly”, and I use a rectangle between this 2 resistance for colored the space between in red, if some one have other best solution because I have to draw 3 object with my solution
10/14/2022 at 7:51 AM #202514Tips for using only 2 objects:
- Draw a rectangle
- Add text in it.
Or, just create rectangles of different color for each of your zone type: example blue for weekly, red for monthly, ..
1 user thanked author for this post.
10/14/2022 at 11:45 AM #202553tks you Nicolas, your idea is good, but I prefer write some think inside, it’s better for me then many different color (Now as a beginner I prefer the very clear chart), and Also with your solution I can’t see the upper and lowest value of my rectangle even with curser information, maybe for next update with PRT, I will wait some days, if they haven’t other Tips from other, I will change the thread to Solved
10/14/2022 at 6:55 PM #202584Mix a little bit of all of the above, with a custom indicator drawing 2 lines, writing text in the middle of these lines, refreshing at each new bar thanks to drawonlastbaronly=true, and with both values w1 and w2 in the return line so that they appear in your cursor details.
All you have to do is customise your w1 and w2 values and add as many occurences of the custom indicator as you need on the graph, you can also create variation of it for text “monthly”, and change color. And to use it even more easily, you can make w1 and w2 as two entry parameters to set from properties window instead of changing their value in the code script:
12345678910defparam drawonlastbaronly = truew1=1.22w2=1.23ytext=(w1+w2)/2DRAWTEXT("weekly", barindex, ytext)COLORBETWEEN(w1,w2,"blue",80)return w1 as "w1", w2 as "w2"1 user thanked author for this post.
10/18/2022 at 5:03 PM #202793tks for all for your answers, at this time I will do like this with 2 line for drawing like a rectangle, and using red for resistance, blue for middle and Green for support, I will see if it’s help me in the future
-
AuthorPosts
Find exclusive trading pro-tools on