|
|
如何让输入框 锁定后 让字体颜色依然显示为 红色 。。。。。。。。
代码如下 INPUT锁定后 原本红色的字体也变成了灰色。。。。。。。。。。。。。- #include <ButtonConstants.au3>
- #include <EditConstants.au3>
- #include <GUIConstantsEx.au3>
- #include <WindowsConstants.au3>
- #Include <GuiEdit.au3>
- #Region ### START Koda GUI section ### Form=
- $Form1 = GUICreate("Form1", 322, 99, 192, 124)
- $Input1 = GUICtrlCreateInput("测试显示", 16, 16, 289, 21)
- GUICtrlSetColor(-1, 0xff0000) ; Red
- $Button1 = GUICtrlCreateButton("保存", 64, 56, 75, 25)
- $Button2 = GUICtrlCreateButton("重置", 168, 56, 75, 25)
- GUISetState(@SW_SHOW)
- #EndRegion ### END Koda GUI section ###
- While 1
- $nMsg = GUIGetMsg()
- Switch $nMsg
- Case $GUI_EVENT_CLOSE
- Exit
- Case $Button1
- GUICtrlSetState($Input1, $GUI_DISABLE)
- Case $Button2
- GUICtrlSetState($Input1, $GUI_ENABLE)
- GUICtrlSetData($Input1,"测试显示")
- EndSwitch
- WEnd
复制代码 |
|