Discussion of article "Graphical Interfaces X: Updates for Easy And Fast Library (Build 2)" - page 4

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
http://prntscr.com/tmjkm3
Hi. I'm working with MT4, so unfortunately I'm stock with this last version of MT4. Here is a bug that no matter what I tried won't fix itself. As you see in the picture above, there is a horizontal line "near" the caption. In case that horizontal line is selected, if you click inside the caption, it will jump to the middle of the caption and start moving with the caption. Also, if there is a horizontal line somewhere in the window background that is selected, if you click and drag inside the window when you are near the line, it will start dragging the line around. This happens to all objects on chart not only the line, only when they are selected this will happen.
In other words, the panel and caption is not "capturing" the mouse event and let it pass through to objects bellow them. How to fix this issue?
Please someone help
Hi,
I understand this article is the latest update for mql4 EasyAndFastGUI?
Can you please tell me how to fix the "expresion not boolen" warning.
Hi,
I understand this article is the latest update for mql4 EasyAndFastGUI?
Can you please tell me how to fix the "expresion not boolen" warning.
What type ism_show_flags ? If not bool, then this is how: return((bool)m_show_flags);
What type doesm_show_flags have? If not bool, then return((bool)m_show_flags);
uint m_show_flags. If I change it to bool, the warning will disappear, but because I am not sure that it will not damage some function somewhere in the chain, I will do as you advised. Thank you.
uint m_show_flags. If I change this to bool, the warning will go away, but because I'm not sure that it won't damage some function somewhere in the chain, I'll do as you advised. Thank you.
You cannot change it to bool because it is a set of flags. Accordingly, the variable's value can be greater than 1. If its value is equal to zero, it is equal to the value false of a variable with the bool type. Therefore, when the result of returning to the bool type is converted to the bool type, any value of a variable other than zero will give the value true. Accordingly, only 0 will give the value false.
And since the method (judging by its name) returns the flag of object visibility, then at any value other than zero, the method will return the flag that the object is visible on some timeframe. Only when the value of the variable is zero do we know for sure that the object is hidden on all timeframes.
I may be wrong about the purpose of this method. But I took my assumptions from the fact that it is this set of flags:
And, by the way, based on the above, you can write the method like this:
Then you won't have to convert the returned type of a non-boolean variable to a value with the bool type - the result of the check is returned anyway, which is bool.
But it's your choice - there is no difference.
But it's your choice - there is no difference.
Artem, in my opinion, it is better to change the function type to uint.
Then you will be able to check the visibility of the object on a particular TF by the value received from this function. After all, it is not a specific value, but a set of flags...
Artem, in my opinion it is better to change the function type to uint
Then it will be possible to check the visibility of the object on a particular TF by the value received from this function. After all, it is not a concrete value, but a set of flags...
We don't know the meaning of this method. Most likely, it is a flag - visible/not visible. And forging the necessary flags from the result is a complication of the library user's life.
We don't know the meaning of this method. Most likely it is a flag - visible/not visible. And forging the necessary flags from the result is complicating the life of the library user.
And if I, as a beginner, am interested in whether the object is visible on the chart of TF H1 and using this method I get that the object is visible on TF M15, respectively true, but I don't see it on the chart... Then how?
Maybe it would be better to add an incoming parameter and check visibility on the specified TF. Or somehow else, but in this form it is not very clear to me....
And if I, as a beginner, am interested in whether the object is visible on the chart of TF H1 and using this method I get that the object is visible on TF M15, respectively true, but I do not see it on the chart... Then how?
Maybe it would be better to add an incoming parameter and check visibility on the specified TF. Or somehow else, but in this form it is not very clear to me....
So you should ask Anatoly. Or read the article, where it will be written what the method under discussion is used for, and which one to use for the needs you describe.
The conversation was about a particular method and why the compiler generates a warning. Why - it is clear (wrong type), and how to fix it - I showed you two options.