Any questions from newcomers on MQL4 and MQL5, help and discussion on algorithms and codes - page 958
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Got it. Thank you!
Got it. Thank you!
The code I showed you is not optimal. It's just an example. Method Update(true) works in loop there - it's unreasonable to redraw the chart when drawing each new object in loop. Need to update all of the created objects after the loop - they are all stacked in list_canvas - after the passage of the main loop to go through all of the objects in list_canvas, and already from there for each of them to call the method update. For all of them, Update(false) should be called, and for the most recent one, Update(true).
Got it. Thank you!
https://www.mql5.com/ru/docs/standardlibrary/canvasgraphics/ccanvas/ccanvastextout
How do I change the font size in Canvas TextOut?
https://www.mql5.com/ru/docs/standardlibrary/canvasgraphics/ccanvas/ccanvastextout
How do I change the font size in Canvas TextOut?
Completely redraw it.
A canvas is a canvas, and the text in it is the brushwork painted on the canvas. To change the painting, you have to paint over the entire canvas with the background and redraw it again.
Or you can create a text on your own canvas and overlay it on top of the main canvas. Then you don't have to erase and re-paint the whole painting, just the canvas with the text.
Completely repaint it.
The canvas is the canvas and the text in it is the brushwork painted on the canvas. To change the painting, you have to paint over the background of the whole canvas and redraw it.
Or you could create text on your canvass and overlay it on top of the main canvas. Then you wouldn't have to erase and redraw the entire painting, but only the canvas with the text.
Got it. But I don't see a function for changing the font size of the text or font size options when creating text.
Got it. But I don't see a function for changing the text font size or font size options when creating text.
There's a reason I gave you links to the documentation - there's a list of all the methods. Just read it.
There's a reason I'm giving you links to documentation - there's a list of all the methods. Just read it.
You can only specify the font size there. That's why I'm asking, where are the other parameters? How does the system know which text to change. Hmm. Maybe I don't quite understand how Canvas works...
What period of testing is considered acceptable? Is ten years enough?
At least since 2013.