Gallery of UIs written in MQL - page 36

 
Learned a lot more.
 

I am preparing an update and there will be no lesson today. Those interested in the material can take a day or two off. :)

We will continue on the new build of the builder.

 
A big request to people who are trying to create the interface or testing the constructor. Please report all the bugs you find. Your feedback is very important. Thank you in advance.
 
Реter Konow #:
A big request to people who are trying to create the interface or testing the constructor. Please report all the bugs you find. Feedback from you is very important. Thanks in advance.

I've been pondering whether I should, or wait until I find out.....

Well, here it is then. I don't know if it's a bug or if I wrote the code wrong.

Some rubbish fills the table's free space on V_BOX.

Also, on H_TAB, "Report", until I added the icon, there was some ghost of an icon distorting the title. It was disappearing after clicking on it.

I don't know if it's a bug, but the described TEXT_ALIGN_*s are missing.

There are still many questions about implementation, I'm still figuring it out on my own. I think we should wait for you to get to these topics. Unless you think otherwise.

NEW_WINDOW,
W_NAME, "CryptoPanel",
W_TYPE, SETTINGS,
OPEN_ON_INIT,
ALWAYS_ON_TOP,


GROUP, "Win",
        //__, G_FRAME, "Frame", _, W, 1580, _, H, 45, 
        __, V_BOX, "Tab", _, W, 1597, _, H, 610, 
        __, 
                H_TAB, "Report", ON, 
                        _, N_LABEL, "::Images\\16x16\\Briefcase.bmp", 
                H_TAB, "Options", N_LABEL, "::Images\\16x16\\Application.bmp", 
                GAP, 100, 
                TB_BUTTON, "Refresh", W, 100, _, text, N_COLOR, (uint)clrBlue, _, N_LABEL, "::Images\\16x16\\Refresh.bmp", 
END_GROUP,
i, AT, LEFT_TOP, 0, 0,
i, H_TABS, text, A_COLOR, (uint)clrGreen, 
i, SWITCH, "Report", "Options", END,


GROUP, "Frames",
        //__, G_FRAME, "Frame", _, W, 1580, _, H, 45, 
        __, V_BOX, "Frame1", _, W, 1593, _, H, 85, 
        __, V_BOX, "Frame2", _, W, 1593, _, H, 520, 
END_GROUP,
i, IN, "Tab",
i, AT, LEFT_TOP, 0, 0,


GROUP, "Balances", IS_TABLE, 
        __, T_HEADER, "Exchange", W, 110, C_HEADER, "$", W, 100, C_HEADER, "MX", W, 160, C_HEADER, "USDT", W, 130, C_HEADER, "USDC", W, 90, C_HEADER, "IRON", W, 120, 
        __, R_HEADER, "MEXC", CELL, A, TEXT, "5 625.59", CELL, A, TEXT, "1 198.10337776", CELL, A, TEXT, "281.0668527", CELL, A, TEXT, "12.6819", CELL, A, TEXT, "2.79368472", 
        __, R_HEADER, "Bybit", CELL, A, TEXT, "123.45", CELL, A, TEXT, " ", CELL, A, TEXT, "123.45", CELL, A, TEXT, " ", CELL, A, TEXT, " ", 
        __, R_HEADER, "Binance", CELL, A, TEXT, "123.45", CELL, A, TEXT, " ", CELL, A, TEXT, "123.45", CELL, A, TEXT, " ", CELL, A, TEXT, " ", 
END_GROUP,
i, IN, "Frame1",
i, AT, LEFT_TOP, 0, 0,
i, T_HEADERS, 
        TEXT_STYLE, (int)FW_BOLD, 
        FONT_SIZE, 10, 
        text, _A1_, _X2X, 
        text, _C1_, 20, 
        text, N_COLOR, (int)C'86,86,86', 
        NG_LINES, 30, NG_STEP, -1,
        POINTED, 0, 
        N_COLOR, (int)C'219,233,249', A_COLOR, (int)C'155,244,196', AH_COLOR, (int)C'155,244,196', 
        END,
i, C_HEADERS, 
        TEXT_STYLE, (int)FW_BOLD, 
        FONT_SIZE, 10, 
        text, _A1_, _X2X, 
        text, _C1_, 20, 
        text, N_COLOR, (int)C'86,86,86', 
        NG_LINES, 30, NG_STEP, -1,
        POINTED, 0, 
        N_COLOR, (int)C'219,233,249', A_COLOR, (int)C'155,244,196', AH_COLOR, (int)C'155,244,196', 
        END,
i, R_HEADERS, 
        TEXT_STYLE, (int)FW_BOLD, 
        FONT_SIZE, 10, 
        text, _A1_, _X2X, 
        text, _C1_, 20, 
        text, N_COLOR, (int)C'86,86,86', 
        NG_LINES, 30, NG_STEP, -1,
        POINTED, 0, 
        N_COLOR, (int)C'219,233,249', A_COLOR, (int)C'155,244,196', AH_COLOR, (int)C'155,244,196', 
        END,
i, CELLS, 
        N_FRAME_COLOR, (int)C'177,194,214', 
        text, _A1_, _X2X, 
        text, _C1_, 10, 
        FONT_SIZE, 10, 
        TEXT_FONT, "Courier New", 
        //TEXT_ALIGN_RIGHT, 
        END,


GROUP, "Log", IS_TABLE, 
        __, C_HEADER, "Time", W, 210, C_HEADER, "Exch", W, 90, C_HEADER, "Op", W, 60, C_HEADER, "Message", W, 520, 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
END_GROUP,
i, IN, "Frame2",
i, AT, LEFT_TOP, 0, 0, 
i, C_HEADERS, 
        TEXT_STYLE, (int)FW_BOLD, 
        FONT_SIZE, 10, 
        text, _A1_, _X2X, 
        text, _C1_, 20, 
        text, N_COLOR, (int)C'86,86,86', 
        NG_LINES, 30, NG_STEP, -1,
        POINTED, 0, 
        N_COLOR, (int)C'219,233,249', A_COLOR, (int)C'155,244,196', AH_COLOR, (int)C'155,244,196', 
        END,
i, CELLS, 
        N_FRAME_COLOR, (int)C'177,194,214', 
        text, _A1_, _X2X, 
        text, _C1_, 10, 
        FONT_SIZE, 10, 
        TEXT_FONT, "Courier New", 
        END,


END_WINDOW,
 
Edgar Akhmadeev #:

I was contemplating whether I should, or wait until I find out.....

Well, here we go. I don't know if it's a bug or if I wrote the code wrong.

Some rubbish fills the table's free space on V_BOX.

Also, on H_TAB, "Report", until I added the icon, there was some ghost of an icon distorting the title. It was disappearing after clicking on it.

I don't know if it's a bug, but the described TEXT_ALIGN_*s are missing.

There are still many questions about implementation, I'm still figuring it out on my own. I think we should wait for you to get to these topics. Unless you think otherwise.

Thanks for the feedback.

On the code:

1. V-box(es) and tabs are always written in separate groups. It is more convenient. It is desirable not to add anything else to these groups. Otherwise, the"positioning jungle" begins. Of course you can do it this way, but it is not worth it....

2. The enumeration is not finished. There is no k.word END in this line.

('Quite a rude error for a constructor. It may glitch a lot.)

i, H_TABS, text, A_COLOR, (uint)clrGreen, ....?


3. In the tables you put the word 'TEXT'. This is unnecessary. CELL cells have their own parameter that gets a value from the user application when connected. Or, use the word V_CURRENT to set the value .

For example:

CELL, A, V_CURRENT, 123,


And cells of type "T_CELL" are used to display unchanging text in tables. They pass the name text to the table. For example:

T_CELL, "12341234123",

//или

T_CELL, "Profit",


4. Try to remove the word TEXT from the tables.


5. Let me know what you get. I will be glad to help you.

 

Question:

There is a catalogue "Include\(1) KIB 1.0\(1) BASE\(1) DOCUMENTATION\"

Are these just code samples, or is this intended to be compiled together as a demo programme? What is the correct way to use it?

 

Another important nuance. In the header of all tables the element T_HEADER is written:

GROUP, "Log", IS_TABLE, 

        __, T_HEADER, "LOG",   C_HEADER, "Time", W, 210, C_HEADER, "Exch", W, 90, C_HEADER, "Op", W, 60, C_HEADER, "Message", W, 520, 

        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
        __, CELL, A, TEXT, "2024.07.01 16:00:06", CELL, A, TEXT, "Binance", CELL, A, TEXT, "Conv", CELL, A, TEXT, "BABYTRAMPTOKEN @0.0516400000 USDT >> 0.09968574 MX", 
 
Edgar Akhmadeev #:

Question:

There is a catalogue "Include\(1) KIB 1.0\(1) BASE\(1) DOCUMENTATION\".

Are these just code samples, or is this intended to be compiled together as a demo programme? What is the correct way to use it?

These are just examples of different codes written at different times and at different stages of the designer's evolution. Some of them may no longer be relevant, some of them may not work, some of them may not need to be written at all, and some of them may be quite suitable. It's hard to say...

In the next build I will clean this code base and leave only working variants.

 

Very important nuance. Tabs control the switching of V_BOX(a) canvas images. They must be declared above. Tabs first, then V_BOX(es ).

 
Edgar Akhmadeev #:

Question:

There is a catalogue "Include\(1) KIB 1.0\(1) BASE\(1) DOCUMENTATION\".

Are these just code samples, or is this intended to be compiled together as a demo programme? What is the correct way to use it?

The most working codes are in the folder "Include\(1) KIB 1.0\(1) BASE\(2) STATE KIB-CODE"

There are codes of windows of the designer. You can study them.