News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests

Main Menu

The color changing bug.

Started by AssemblyChallenge, February 16, 2015, 11:30:27 PM

Previous topic - Next topic

AssemblyChallenge

Greetings.

I find this one from time to time and figure out a possible way to generate it:

Open EasyCode, load any project.
Let it open for a very long time.
Suspend the computer for several hours.

If you are lucky, the result will be as the attached example. The only solution is to close EasyCode and reopen it.

Regards.

rsala

Hi,

Sorry for this issue and thanks for reporting it.

Please give some time to see whether I can find the bug and fix it.

Regards!
EC coder

AssemblyChallenge

Thank you Ramon, and please don't be; we are only human  ;) :t

The two most interesting elements are:

* Only the background color changes, not the letters.
* So far it only seems to happen is you suspend the computer.

A humble theory: Does EasyCode read the background color from some Windows variable/structure that may change after suspending ??

Best regards.

rsala

Hi again,

Actually, the only thing I can think of is that Easy Code processes de WM_SYSCOLORCHANGE message, which is only sent by Windows when a system color changes. The point is I do not know whether the windows background system color changes when Windows is suspended. I will try to find it out.

Regards,

Ramon
EC coder

rsala

Hi AssemblyChallenge,

Would you please do me a favor?

I attach a slightly modified version of EC. It will show a message box if the WM_SYSCOLORCHANGE has been sent to Easy Code, so that I can know if it is the responsible of the "whiteness".

Please replace your EasyCode.exe file, in the \EasyCode.Ms\Bin folder with the one attached to this post.

Thanks for your help,

Ramon
EC coder

AssemblyChallenge

Hi,

Testing in progress, will let you know ASAP.  :biggrin:

Regards.

rsala

EC coder

AssemblyChallenge

So far, not so good  :(

For several days with no luck. Still waiting for changes or messages.

Still trying, Master.

rsala

EC coder

AssemblyChallenge

Finally! After so many days trying the new exe I got some movement  :lol:

Loaded two different projects and both failed (color changed) without messages or errors.

Attached images from both.

rsala

Thank you very much! I really appreciate your help!

However, I have no idea why color changes but I will try to find it out.

Regards,

Ramon
EC coder

AssemblyChallenge

Ok.

The projects with the new exe were open (and failed) at the same time, just in case it may be useful to know about it.

More humble ideas: The editor part (Edit control, right?) is mounted on MDI window. Is there any chance this could be related? How about WMPaint or something AFTER resuming from standby? Is it only the Edit's background color who is changing and, so far, never on runtime.

AssemblyChallenge

Even more ideas!

Please take a look at this this. It doesnt looks like our case but, who knows  :lol:

Whatever, as long as it gives you some light/inspiration  ;)

AssemblyChallenge

Feedback continues:

* Took note from background colors before and after the bug.
* In Preferences, Editor, there is no change (it's default, Background, System colors). Even after bug, Preferences are fine.
* With affected EasyCode still open, opened new instance: It does with normal colors.

What else:

* Just in case will keep bugged EasyCode opened (as it is hard to replicate problem). If you need any info let me know (ej. attach Ollydbg, look into memory, etc) :bgrin:
* Will make a simple experiment with very small project checking background colors. Who knows, maybe it's Windows Policies the problem's source.

Regards, Master.

rsala

Hi AssemblyChallenge,

Once again thank you very much! I really appreciate your useful help.

I will study all this informatio to see whether I can find the problem.

Regards,

Ramon
EC coder