Recently a problem with GMT time was reported to me and I changed some things. The person who got the problem replied that it was solved, so it looks that I fixed it for him... but maybe I broke it for others.
The situation is a little bit... depends on the way we look at it. Whether we want to display the GMT time, or we want to convert one time into another. What do I mean...
I'm talking about the time if we select it from Components by the way. Let's say we want to draw an arrow at 20:00. If we select the Server time, all candles are timed by this time, so we draw the arrow over the 20:00 candle directly. But what happens if we select GMT? Well, let's say there is a difference of 3 hours and GMT is 3 hours ahead of the Server time. So, if the Server time is 20:00, then GMT is 23:00. If we select GMT as the source time, the arrow will be printed at 23:00 on the chart, but the chart is supposed to show Server times.
This is how it worked until I changed it these days. Now it works in a little bit different way - if we select GMT and we write 23:00, it should print the arrow over the 20:00 candle, because 20:00 Server time equals 23:00 GMT. In other words, the GMT time is converted to Server time and then the arrow is printed.
Back in the days when I made Components, I don't even know if I had a vision of how it should be, I think I juts added Server, GMT and Local just because there are such functions in MQL.
What about the "Now" time mode. Well, it says "Now". The Source selector became useless.
But again, it depends whether we want to just get the GMT as is, or we want to do something on the chart (which requires conversion). Now the Sourse selector is useless, because when GMT is selected, it converts it back to Server time. In other words, not the block assumes that we want to do something on the chart, not that we want to print the time in GMT format.
You may say "But it worked one way for years and now after you changed it, you broke it". Well, I broke the ability to see what is the actual GMT time, but I fixed the ability to use the GMT time as an input, and let the program convert it to Server time.
I guess the best would be to somehow make it work in both ways. But do we really want to just display the GMT time, or we want to use it as an input value?


