Re: Icon in input
"valery_vi" <[email protected]> Wed, 15 Aug 2007 10:47:16 -0000
| Newsgroups | gmane.comp.windows.autoit.user |
|---|---|
| Message-ID | <[email protected]> |
After Beta 3.2.5.2 (9th August 2007) (Beta):
"
..
- Changed: IconId in all GUI functions is coherent with the actual
GUICtrlSetImage() for icon control.
..
"
AutoIt Input Gui will have the following form:
#include <GuiConstants.au3>
$Gui = GuiCreate("Input Box", 260, 100)
$nId = 2
if $nId > 0 Then $nId = - $nId - 1
GUISetIcon(@AutoItExe,$nId)
GUICtrlCreateLabel("", 15, 39, 230, 20, $SS_SUNKEN)
GUICtrlSetState(-1, $GUI_DISABLE)
GUICtrlSetBkColor(-1, 0xFFFFFF)
GUICtrlCreateIcon(@AutoItExe, -1, 18, 41, 16, 16)
GUICtrlCreateInput("", 45, 42, 190, 14, -1, $WS_EX_TOOLWINDOW)
GUISetState()
While 1
$Msg = GUIGetMsg()
Switch $Msg
Case -3
Exit
Case Else
EndSwitch
WEnd
And Icon's "bug" mentioned is concerned with icon id:
$nId = 3
if $nId > 0 Then $nId = - $nId - 1
GUICtrlSetImage($root,"shell32.dll",$nId,4)
$nId = 4
GUICtrlSetImage($root,"shell32.dll",$nId,2)
Valery
--- In [email protected], "valery_vi" <shehrer1@...> wrote:
>
> magician13134 wrote:
> http://www.autoitscript.com/forum/index.php?showtopic=51183
> "
> Oh! I got it! It's an Exstyle... $WS_EX_TOOLWINDOW... Cool.
> "
>
> Really cool.
> Thus, AutoIt Input Gui can have the following form:
>
> #include <GuiConstants.au3>
> $Gui = GuiCreate("Input Box", 260, 100)
> ;set other GUI icon...
> GUISetIcon(@AutoItExe,2)
> GUICtrlCreateLabel("", 15, 39, 230, 20, $SS_SUNKEN)
> GUICtrlSetState(-1, $GUI_DISABLE)
> GUICtrlSetBkColor(-1, 0xFFFFFF)
> GUICtrlCreateIcon(@AutoItExe, -1, 18, 41, 16, 16)
> GUICtrlCreateInput("", 45, 42, 190, 14, -1, $WS_EX_TOOLWINDOW)
>
> GUISetState()
>
> While 1
> $Msg = GUIGetMsg()
> Switch $Msg
> Case -3
> Exit
> Case Else
> EndSwitch
> WEnd
>
> Valery
>