My approach. The core is the engine. - page 73

 
Maxim Kuznetsov:
maybe he was directed to write the kernel-engine... so that he was not distracted by the forum :-)

The next task, as far as I remember, was to write on a kanvas.

"I'll write on a canvas after lying on a mattress" ))))

 
Реter Konow:

George, I don't understand - what does my approach have to do with it? I'm providing a GUI connection interface, which is created with a lightweight markup language. Who and why would want to learn my approach?

Everything I suggest is much simpler than the simplest MQL.

It's not. I've looked at it, and it's more complicated. It's because you have plenty of opportunities at once, where you have to remember what, where, where and how. And my memory is a lot worse than yours. So - for those who remember everything - it really isn't complicated. And for those who can't remember?

Your markup language is just an example of your approach, when "everything is always available".

But again - the question is not whether this markup language is good, whether the approach is good, whether the implementation is good.

The main question should be who needs it, who the target audience is.

I've said it more than once - I don't see it. You objected that "it will appear". Well... we wait...

 
The system can malfunction. I know from my job. :) Thank you for your support. Now I'll be demanding that everyone be unbanned, too. (Just in case. Just in case by mistake. :))
 
Georgiy Merts:

No, it's not. I've looked - and I see it's more complicated than that. Precisely because a lot of opportunities are presented at once, where you have to remember what, where, where and how. And my memory is far worse than yours. So - for those who remember everything - it really isn't complicated. And for those who can't remember?

Your markup language is just an example of your approach, when "everything is always available".

But again - the question is not whether this markup language is good, whether the approach is good, whether the implementation is good.

The main question should be who needs it, who the target audience is.

I've said it more than once - I don't see it. You objected that "it will appear". Well... we wait...

Vasiliy Sokolov:

Sorry Piotr, but all you've presented so far is some hellish lines of MQL program with dozens of parameters and calls of unknown things. If this is a prototype of your markup language, I'm already scared.

Well, here's a solution with two windows yesterday. Here's an example of their code in the markup language:

(What's so hellishly complicated here, I honestly don't see it).

//-------------------------------------------------------------------------------------------------------------------- 
NEW_WINDOW,  W_NAME, "Window 1",  W_ICON,98,   W_TYPE, SETTINGS,  OOI,
//====================================================================================================================
GROUP,A, 

__,BUTTON, "Button 1", GAP,30,  BUTTON, "Button 2", 

__, CHECKBOX, "Checkbox 1",  GAP,100,  EDIT, "Edit box 1",  W,130,
__, CHECKBOX, "Checkbox 2",
__, CHECKBOX, "Checkbox 3",

END_GROUP,
//----------------------------------
i,AT,_X2X,"MF",10,  _Y2Y,"MF",10,
//----------------------------------
i,Y_GAP,20,
//----------------------------------
i,BUTTONS,  PARAM_TYPE,_BOOL, W,150,  H,100,   N_COLOR,(int)C'235,235,235', END,
//----------------------------------


//-----------------------------------------------------------------
GROUP,A, 

__, BOARD,"Enter text",   

END_GROUP,
//----------------------------------
"Enter text", H_C2C,  "Edit box 1", 0,
"Enter text", ON_LEFT,"Edit box 1", -20,
//-----------------------------------------------------------------


//====================================================================================================================
END_WINDOW,


//-------------------------------------------------------------------------------------------------------------------- 
NEW_WINDOW,  W_NAME, "Window 2",  W_ICON,99,   W_TYPE, SETTINGS,  OOI,
//====================================================================================================================

GROUP, A,

__, T_BOX,"T_1",
             "This window's",
             "appearance controlled",
             "by user's programm.",
             END,

END_GROUP,
//----------------------------
i,AT,_X2X,"MF",10,  _Y2Y,"MF",10,
"T_1",FONT_SIZE,20,
"T_1",text,N_COLOR,(int)C'255,110,10',
"T_1",text,TEXT_FONT,"Arial Bold",
"T_1",N_COLOR,(int)C'240,240,240',

//====================================================================================================================
END_WINDOW,

Of course, not everything is clear without explanations, but even without them you can understand a lot at once (as it seems to me...).

 

And the result:


 
Реter Konow:

What's so hellishly complicated about it, I honestly don't see it.

I didn't say "hell of a lot". I said that you have to memorise a lot.

As long as you're working on the project, you look at the description, and it's not so critical. You keep everything in your head. But now you have made the interface, you switch to other areas. And then, a month later - you need to change something. You open it up and realize that you don't understand anything, and you have to figure it out all over again.

It's one thing when the structure of the description itself is such that you simply cannot physically mix something up. Simply because if you do something "wrong", the project won't compile. And it's quite another thing when you can easily mix things up, but no one will stop you, you go through the code - "everything seems fine", and then the error is found at the most inopportune moment.


But these are not really serious problems. Your main problem, Peter, is the target audience. There isn't one.

 
Georgiy Merts:

....

But, none of this is really a big problem. Your main problem, Peter, is the target audience. There isn't one.

You know, George, I had a project in mind where I decided to do something massive. That is, I hoped for a target audience of all MQL users.

Maybe I was wrong. Maybe not so many people need it. Who knows... Life will show...))

 
Реter Konow:

Maybe I was wrong. Maybe not many people need it. Who knows... Life will tell...))

That's what "option B" is for.

As always, I can cite my own League as an example - at first I thought they would take an interest in it and help me with optimizing it. Only two people responded. But I have had "option B" - I've bought a new computer, and no longer need anyone's help, because I've created the League for myself in no small measure - to always have a "pool of TSs", which have been working on the demo for some time. And I have it now, studying the possibility of selecting the best of them for real.

In the same way you need it - so that the result of your project could be useful to you. Then you use it and brag about it to the participants. If someone shows interest, you share with them (or sell). If they don't show up - you need it yourself. In any case, you win.

 
Реter Konow:

(What's so hellishly complicated about it, I honestly don't see it.)

//+------------------------------------------------------------------+
//|                                               Forum sample 2.mqh |
//|                                                      Peter Konow |
//|                                             https://www.mql5.com |
//+------------------------------------------------------------------+
//-------------------------------------------------------------------------------------------------------------------- 
NEW_WINDOW,  W_NAME, "Window 1",  W_ICON,98,   W_TYPE, SETTINGS,  OOI,
//====================================================================================================================
GROUP,A, 

__,BUTTON, "Button 1", GAP,30,  BUTTON, "Button 2", 

__, CHECKBOX, "Checkbox 1",  GAP,100,  EDIT, "Edit box 1",  W,130,
__, CHECKBOX, "Checkbox 2",
__, CHECKBOX, "Checkbox 3",

END_GROUP,
//----------------------------------
i,AT,_X2X,"MF",10,  _Y2Y,"MF",10,
//----------------------------------
i,Y_GAP,20,
//----------------------------------
i,BUTTONS,  PARAM_TYPE,_BOOL, W,150,  H,100,   N_COLOR,(int)C'235,235,235', END,
//----------------------------------

...

Are you really asking, or are you just kidding? You have some hellish string of hundreds of variable definitions that you want to pass off as some kind of table. The pseudo-table itself is crooked, with no structure, containing obscure acronyms.

And that's what it is:

void Sync_params(int ID){for(int a1 = 0; a1 < All_params; a1++){if((int)P_CORE[a1][_SYNC_ID] == ID){P_CORE[a1][_LAST_VALUE]    = P_CORE[a1][_CURRENT_VALUE];P_CORE[a1][_CURRENT_VALUE] = P_CORE[a1][_NEW_VALUE];}}}
void Sync_P_CORE(){for(int a1 = 0; a1 < All_params; a1++){if(P_CORE[a1][_CURRENT_VALUE] != P_CORE[a1][_NEW_VALUE]){P_CORE[a1][_LAST_VALUE]    = P_CORE[a1][_CURRENT_VALUE];P_CORE[a1][_CURRENT_VALUE] = P_CORE[a1][_NEW_VALUE];if(P_CORE[a1][_SYNC_ID] != NULL)Sync_params((int)P_CORE[a1][_SYNC_ID]);EventChartCustom(0,_SYNC_P_CORE,(int)P_CORE[a1][_ELEMENT],0,P_CORE[a1][_CURRENT_VALUE]);}}}

Did you come up with this formatting yourself? Good for you, you have every chance of taking first place in ioccc.org.

But mate, you don't write like that. AT ALL. No one can use this code.

The International Obfuscated C Code Contest
  • ioccc.org
International Obfuscated C Code Contest
 
Vasiliy Sokolov:

But mate, you don't write like that. AT ALL. No one can use that code.

Vasiliy, hands off Peter !!!

Don't get in the way of the man.

I want to see the target audience!!! Someone will say "I attached this library to my Expert Advisor and use it"!

Reason: