What the variables contain
Code: Select all
LineColor = FFD80C
TextColor = FFD80C
BackgroundColor = 333437
Code: Select all
;GUI
Gui,S1: Add, Text, x5 y20, Lines color:
Gui,S1: Add, Edit, x5 y35 w60 vLineColor Disabled Center, %LineColor%
HB_Button.Push(New Buttons_1(x:=70, y:=32, w:=30, h:=30, window:="S1", Label:="LineColor", Text:="Set", Font:= ButtonFont, Font_Size:="10 Bold", Font_Color_Top:= ButtonTextColorTop, Font_Color_Bottom:= ButtonTextColorBottom, Background_Color:= ButtonBackgroundColor , y_Offset:=0, Type:="" ))
Gui,S1: Add, Text, x5 y70, Text color:
Gui,S1: Add, Edit, x5 y85 w60 vTextColor Disabled Center, %TextColor%
HB_Button.Push(New Buttons_1(x:=70, y:=82, w:=30, h:=30, window:="S1", Label:="TextColor", Text:="Set", Font:= ButtonFont, Font_Size:="10 Bold", Font_Color_Top:= ButtonTextColorTop, Font_Color_Bottom:= ButtonTextColorBottom, Background_Color:= ButtonBackgroundColor , y_Offset:=0, Type:="" ))
Gui,S1: Add, Text, x5 y120, Background color:
Gui,S1: Add, Edit, x5 y135 w60 vBackgroundColor Disabled Center, %BackgroundColor%
HB_Button.Push(New Buttons_1(x:=70, y:=132, w:=30, h:=30, window:="S1", Label:="BackgroundColor", Text:="Set", Font:= ButtonFont, Font_Size:="10 Bold", Font_Color_Top:= ButtonTextColorTop, Font_Color_Bottom:= ButtonTextColorBottom, Background_Color:= ButtonBackgroundColor , y_Offset:=0, Type:="" ))
Code: Select all
LineColor(){
SetColorTheme(LineColor)
}
TextColor(){
SetColorTheme(TextColor)
}
BackgroundColor(){
SetColorTheme(BackgroundColor)
}
Code: Select all
SetColorTheme(Var){
SetTimer,ToolTipFollowMouse, On
GuiControl,S1:Enable,% Var
GuiControl,S1:Focus,% Var
ToolTip, Enter to Confirm
Loop{
If GetKeyState("Enter"){
ToolTip,
GUI,S1:Submit, NoHide
GuiControl,S1:Disabled,% Var
Gui,2:destroy
Gui,3:destroy
Gui,4:destroy
Gui,5:destroy
Gui,SubSetting:destroy
Gui,S1:destroy
Create_Main_Window() ;Gui 1
Create_SubTop_Window() ;Gui 2
Create_SubBottom_Window() ;Gui 3
Create_SubLeft_Window() ;Gui 4
Create_SubRight_Window() ;Gui 5
Create_SubSetting_Window() ;Gui SubSeting
Create_Setting1_Window() ;Gui S1
break
}
sleep, 25
}
SetTimer,ToolTipFollowMouse, Off
return
}
My problem is that when the second label is called "TextColor" the first GUI Edit box changes. I set the edit box var to "TextColor" and the GUI control is also set to change the "TextColor" but instead, the GUI control changes the "LineColor" Edit box. I'm thinking this is because both var is = to "FFD80C", that's a guess I really don't know. can anyone help to fix it?