Errors, bugs, questions - page 2038

 

text alignment does not work in the strategy tester

ObjectSetInteger(chart_ID,name,OBJPROP_ALIGN,ALIGN_CENTER);


 

There are two graphical objects - vertical lines. You need to make it so that by moving one line with the mouse, the other will pull up behind it at a constant distance.

It is clear that OnChartEvent+OnTimer is done. But the only thing is that the pulled line twitches noticeably to the eye - a lag. One millisecond timer and ChartRedraw don't help.

Is it possible to solve this primitive task smoothly in MT5? Or do architectural peculiarities make it impossible?

Interestingly, smoothness is achieved in no time at all on canvas. But it fails with graphical objects.


When I set "Fibonacci Time Zones" object all its vertical lines move smoothly when moved with a mouse. The graphical object mapping system copes with this without any problems. But as soon as MQL is used to pull up one object after another, the smoothness is gone.

 
fxsaber:

Is it possible to solve this primitive task smoothly in MT5? Or do architectural features make it impossible?

In-house or in-house DND and redrawing on MouseMove event during pulling.

You cannot get rid of lag 100% of course, but you can get rid of it 99

 
Комбинатор:

In-house or in-house DND and redraw on MouseMove event while pulling.

You can't get rid of lag 100% of course, but you can get rid of it 99

The question is: why? It seems that something is either unfinished in mt5 or on the contrary, it has been cut off for productivity. I cannot use the terminal with stiff graphics for manual trading, it is suitable only for machines. The terminal itself is good, tester again for certain tasks, but it does not hold charting at all. Cons and pros are 50/50.

Maybe they will improve the situation sometime in the future.

 
Vitaly Muzichenko:

A terminal with tight graphics is not suitable for manual trading

As if everyone is sitting on the first Pentiums. The idea is that anyone who trades with at least 10k zel will have a computer from at least this year. The point is to improve the performance of the terminal.

Maybe we should make two terminals - for the rich and for the poor, otherwise it would be unfair.

 
Anton Ohmat:

As if everyone is sitting on the first Pentiums. The idea is that anyone who trades with at least 10k zel will have a computer from at least this year. The point is to improve the performance of the terminal.

Maybe we should make two terminals - for the rich and for the poor, otherwise it would be unfair.

I have a computer not from last century.

 
fxsaber:

Is it possible to solve this primitive task smoothly in MT5? Or do architectural peculiarities make it impossible?

It is possible if you move the lines using mql, an example from my practice:
 
Yury Kulikov:
Maybe if you move the lines with mql tools, an example from my practice:
So not with pictures, but with code. As an extreme case, an algorithm.
 
Artyom Trishkin:
So, not with pictures, with code. As a last resort, it's an algorithm.

So combinator already told :), track the event MouseMove and then simultaneously move the set lines and then ChartRedraw, it turns out smoothly and without lags.

 
Yury Kulikov:

So combinator already told :), track the event MouseMove and on it simultaneously move the set lines and then ChartRedraw, it turns out smoothly and without lags.

And how in this case, MouseMove is principally different from the millisecond timer? Besides, the parameters MouseMove (x, y) are not used. I think that you have smoothness due to a small number of graphical objects. For example, in MetaTrader 4, I looped a script and it somehow worked even faster

Reason: