Jump to content

Sky Slate Blueberry Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate
Photo

[How To] Animate a GUI Window


  • Please log in to reply
16 replies to this topic
morphingstar
  • Members
  • 52 posts
  • Last active: Sep 07 2011 03:47 AM
  • Joined: 15 Jul 2011
Skan
your hexconvertor buttons did not show properly.
Below is corrected code, which works on my WinXPh.


https://ahknet.autoh...eShow/TeAdd.ahk

;https://ahknet.autohotkey.com/~goyyah/CrazyScripts/SlideShow/TeAdd.ahk
; Integer to Hex Convertor by Goyyah 03-Jun-2006
Gui, +ToolWindow +AlwaysOnTop
Gui, Margin, 10,5
Gui, Add, GroupBox, w210 h155
Gui, Font, s10, Courier New
Gui, Add, Text, x18 y13,1      = LEFT to RIGHT
Gui, Add, Text,     y+0,2      = RIGHT to LEFT
Gui, Add, Text,     y+0,4      = TOP to BOTTOM
Gui, Add, Text,     y+0,8      = BOTTOM to TOP
Gui, Add, Text,     y+0,16     = CENTER
Gui, Add, Text,     y+0,65536  = HIDE 
Gui, Add, Text,     y+0,131072 = SHOW
Gui, Add, Text,     y+0,262144 = SLIDE
Gui, Add, Text,     y+0,524288 = FADE
; ez Gui, Font, s10, Verdana
Gui, Font, s8, Verdana
Gui, Add, Edit  , x15 y+10 r6 w200 vExp 0x2000
Gui, Add, Edit  , x15 y+5 ReadOnly w98 h25 +0x8000 vResult1, 0
Gui, Add, Edit  , x+5 ReadOnly w98 h25 +0x8000 Right vResult2, 0x0
; ez Gui, Add, Button, x15 y+5 w80 h25 +0x8000 gCalc, &Calculate
; ez this mod corrects bad button display
Gui, Add, Button, x15 y+10 w80 h25 +0x8000 gCalc, &Calculate
Gui, Add, Button, x+5 w55 h25 +0x8000 gClear, Clea&r
Gui, Add, Button, x+5 w55 h25 +0x8000 gCopy, Cop&y
Gui, Show, , Integer to Hex Convertor
Return

Copy:
 GoSub, Calc
 Clipboard:=Total
Return

Clear:
 GuiControl,,Exp    , % Null
 GuiControl,,Result1, % 0
 GuiControl,,Result2, % 0x0
Return

Calc:
 Gui, Submit, NoHide
 Exp=%Exp%
 Total=0
 Loop, Parse,Exp, `n
   Total+=%A_loopField%  
 GuiControl,,Result1, % Total
 SetFormat, Integer, Hex
 Total+=0
 GuiControl,,Result2, % Total
 SetFormat, Integer, d
Return

GuiEscape:
Guiclose:
 ExitApp
Return

the corrected line are marked ez, for easy.
WinXPh SP3. AutoHotkey.exe, Application, AutoHotkey_L, 854 KB (875'008 bytes), 30. April 2011, 23:06:30, Version 1.1.0.0,

Skrell
  • Members
  • 384 posts
  • Last active: Jul 07 2016 05:03 PM
  • Joined: 23 Aug 2011

Skan,

I just came across this INCREDIBLY informative post!  Can you please repost the files you link to in the sample code?  I'd like to play with them :)