Edit control does not accept all window styles in declarations
Issue #38
closed
Test code:
MyGui := Gui(, "KEYSHARP TESTS")
e1 := MyGui.Add("Edit", "w200 +0x20")
e2 := MyGui.Add("Edit", "w200 Password*")
e3 := MyGui.Add("Edit", "w200 h50")
ControlSetStyle("+0x8", e3.Hwnd)
e4 := MyGui.Add("Edit", "w200 h50 +0x8")
MyGui.Show()
For AHK V2, you can often either set a control style in the declaration (e1 above) or use ControlSetStyle (e3).
With AHK, e1 and e2 show password-masked. With Keysharp only e2 is masked.
With AHK, e3 and e4 are restricted to uppercase. With Keysharp only e3 is restricted to uppercase.
Partial workaround is to use ControlSetStyle if the Style set in the declaration does not work.
This has not been exhaustively tested.
Comments (3)
-
reporter -
repo owner - changed status to resolved
-
repo owner - changed status to closed
- Log in to comment
Following commits 87fdb62, 38dce2c, and bdd7678, tested the code above, which works without problem.
Please mark as resolved and close if you feel it appropriate. Thanks!