Changing a Gui Window Color Topic is solved

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
Alexander2
Posts: 348
Joined: 27 Apr 2019, 17:38

Changing a Gui Window Color

Post by Alexander2 » 23 Jan 2022, 12:43

Does anyone know why the window which is generated by the following code is white despite the fact that the code includes the command Gui, Color, Black?

Code: Select all

Gui, ContMenu1:New
Gui, -Caption +HwndContMenu1ID
Gui, Color, Black
Gui, Font, s17, Arial Black
Gui Add, Progress, Disabled BackgroundBlack
Gui Add, Text, xp yp wp hp BackgroundTrans cWhite -Wrap gExample, Example

User avatar
mikeyww
Posts: 26871
Joined: 09 Sep 2014, 18:38

Re: Changing a Gui Window Color  Topic is solved

Post by mikeyww » 23 Jan 2022, 12:52

Output here.

image220123-1252-001.png
GUI
image220123-1252-001.png (2.34 KiB) Viewed 525 times

amateur+
Posts: 655
Joined: 09 Oct 2021, 15:43

Re: Changing a Gui Window Color

Post by amateur+ » 23 Jan 2022, 12:54

Gui, Show

Code: Select all

Gui, ContMenu1:New
Gui, -Caption +HwndContMenu1ID
Gui, Color, Black
Gui, Font, s17, Arial Black
Gui Add, Progress, Disabled BackgroundBlack
Gui Add, Text, xp yp wp hp BackgroundTrans cWhite -Wrap gExample, Example
Gui, Show
return

Example:
MsgBox, Put your commands here.
return
Have found any drawback in my code or approach? Please, point it out. /The moderator ordered to remove the rest of the signature, I had obeyed.
And I really apologize for our russian president. Being a citizen of an aggressor country is very shameful. Personally I tried to avoid this trying to defend elections from fraud being a member of the election commission of one of the precincts but only was subjected to a hooligan attack and right before the vote count was illegally escorted from the polling station and spent the night behind bars (in jail) in a result of illegal actions of corrupt policemen.

Alexander2
Posts: 348
Joined: 27 Apr 2019, 17:38

Re: Changing a Gui Window Color

Post by Alexander2 » 23 Jan 2022, 13:36

Thank you. I can see that the script works as intended when it is run separately. I had copied it from a larger script which has other commands. Perhaps those other commands cause the color to be white rather than black.

User avatar
mikeyww
Posts: 26871
Joined: 09 Sep 2014, 18:38

Re: Changing a Gui Window Color

Post by mikeyww » 23 Jan 2022, 13:45

You guessed it. The actual script matters.

Alexander2
Posts: 348
Joined: 27 Apr 2019, 17:38

Re: Changing a Gui Window Color

Post by Alexander2 » 23 Jan 2022, 13:52

Yes, I have now found what the issue was. There was a command in another place within the larger script which set the color back to white.

Post Reply

Return to “Ask for Help (v1)”