Jump to content

Search the Community

Showing results for tags 'GUI label'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • General
    • Announcements and Site News
    • Administration
  • AutoIt v3
    • AutoIt Help and Support
    • AutoIt Technical Discussion
    • AutoIt Example Scripts
  • Scripting and Development
    • Developer General Discussion
    • Language Specific Discussion
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Categories

  • AutoIt Team
    • Beta
    • MVP
  • AutoIt
    • Automation
    • Databases and web connections
    • Data compression
    • Encryption and hash
    • Games
    • GUI Additions
    • Hardware
    • Information gathering
    • Internet protocol suite
    • Maths
    • Media
    • PDF
    • Security
    • Social Media and other Website API
    • Windows
  • Scripting and Development
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Member Title


Location


WWW


Interests

Found 1 result

  1. There are several problems: 1) the label (text) does not show on top of the GUI image. 2) when the label is applied the GUI image is trucated on the left by 5 pixels. 3) The task bar icon disppears when the mouse is over it and closes the window. I did not finish adding the required images for the buttons because I have to create them. #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #Include <GuiButton.au3> #include <StaticConstants.au3> #Include <GuiEdit.au3> #include <Misc.au3> Opt('MustDeclareVars', 1) Example() Func Example() Local $NewStyle = False, $hWnd, $hButSD, $hButRS, $hButLO, $hButLP,$hButS, $hButH, $Msg, $Style Local $x=5, $hBut, $hTxtOper $hWnd = GUICreate("Gui Style", 172, 101, -1, -1, $WS_POPUP) GUICtrlCreatePic(@ScriptDir & "\BG.bmp", 0, 0, 172, 101, -1, $GUI_WS_EX_PARENTDRAG) GUISetState(@SW_SHOW) $hTxtOper = GUICtrlCreateLabel($hWnd, "", $x, 5, 130, 20, $SS_CENTER) GUICtrlSetColor($hTxtOper, 0xffff00) $hButSD = GUICtrlCreateButton("test",$x , 25, 24, 24, $BS_BITMAP) _GUICtrlButton_SetImage($hButSD, @ScriptDir & "\ShutDownUp.bmp") $hButRS = GUICtrlCreateButton("", $x + 27, 25, 24, 24) $hButLO = GUICtrlCreateButton("", $x + 54, 25, 24, 24) $hButLP = GUICtrlCreateButton("", $x + 81, 25, 24, 24) $hButS = GUICtrlCreateButton("", $x + 108, 25, 24, 24) $hButH = GUICtrlCreateButton("", $x + 135, 25, 24, 24) While 1 $hBut = GUIGetCursorInfo() if $hBut[4] = $hButSD then ControlSetText("Power Options", "", $hTxtOper, "Shut down PC") if _IsPressed(1) Then _GUICtrlButton_SetImage($hButSD, @ScriptDir & "\ShutDownDn.bmp") else ControlSetText("Power Options", "", $hTxtOper, "Select an option...") EndIf if Not _IsPressed(1) or $hBut[4] <> $hButSD Then _GUICtrlButton_SetImage($hButSD, @ScriptDir & "\ShutDownUp.bmp") EndIf Sleep(100) $Msg = GUIGetMsg() Switch $Msg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd EndFunc
×
×
  • Create New...