Libraries: Easy Canvas - page 7

 
Oleksii Chepurnyi:
Maybe it was different in different situations ) I had a recreated kanvas and it looked like blinking. i wanted to pay attention to this line but didn't have time )

If there are problems, it is better to inform me. Everyone is silent for some reason. It's easier for me to deal with my own creation.

 
Nikolai Semko:

if there's a problem, you better let me know. Everyone keeps quiet for some reason. It's easier for me to deal with my own creation.

I'm telling you, I wanted to report it, but I didn't have time - a new version came out, where it was already fixed.
 
Oleksii Chepurnyi:
I'm telling you, I wanted to inform you, but I didn't have time - a new version came out, where it was already fixed.

Ah, got it :)))

 

version 1.36
Now it will work more correctly in the tester.
But you should understand that in the tester the screen redrawing events do not work properly.
That's why in the tester mode it is better to redraw in OnCalculate, forcibly calling the ChartChanged() function.

For example:

int OnCalculate(const int rates_total,const int prev_calculated,const int begin,const double &price[]) {
   if (rates_total!=prev_calculated && MQLInfoInteger(MQL_TESTER)) {
      ChartChanged();    //  функция находится внутри iCanvas.mqh
      ReDrawMyCanvas();  // your canvass
   }
   return(rates_total);
}
Try this indicator in the tester together with the updated library.
Files:
3DMa.mq5  12 kb
 

There is a huge request. If you can, of course )

This array:

class iCanvas : public CCanvas
  {
private:
   datetime          T[1];

Rename it, for example, to Tm.

In one of the projects in the form as it is now, it produces such miracles.

'[' - name expected     iCanvas.mqh     112     20
declaration of '_Period' hides predefined variable      iCanvas.mqh     112     38
'(' - name expected     iCanvas.mqh     112     46
variable '_Period' not used     iCanvas.mqh     112     38
'[' - name expected     iCanvas.mqh     113     22
'[' - name expected     iCanvas.mqh     114     47
declaration of '_Period' hides predefined variable      iCanvas.mqh     114     65
'(' - name expected     iCanvas.mqh     114     73
variable '_Period' not used     iCanvas.mqh     114     65
'[' - name expected     iCanvas.mqh     115     13

I couldn't find the reason, tried to rename it, everything went fine ) Now I rename it every time in a new version.

 
Oleksii Chepurnyi:

In one of the projects as it is now, it produces such wonders.

I couldn't find the reason, tried renaming it, everything went fine ) Now I rename it every time in a new version.

You should look for #define T in this project;)

 
Andrey Khatimlianskii:

I should look for #define T in this project ;)

Well, there are no T's exactly, there are T's starting with T. It's in the scanner )

 
Oleksii Chepurnyi:

Well, there are no T's, there are T's that start with T. It's in the scanner.)

Well, there are no miracles!

Cut the project while the error is being reproduced. Localise the place, understand what the reason is.

It's a private member of aclass, it can't affect anything. It's more likely to be affected by other defines.

 
Andrey Khatimlianskii:

Well, there are no miracles!

Cut the project while the error is being reproduced. Localise the place, understand what the cause is.

It's a private member of aclass, it can't affect anything. Rather, it is other defines that affect it.

Finding the cause is interesting, but it's easier to rename )

If I'm not mistaken, these tricks appeared in new builds with new compilation rules.

 
Oleksii Chepurnyi:

Finding the cause is interesting, but easier to rename )

If I'm not mistaken, these tricks appeared in new builds with new compilation rules.

Renaming is not difficult. There is Ctrl+H


But I agree with Andrei. Look for #define T or #include <Canvas\iCanvas.mqh> put it first in the project