Busti Posted April 4, 2006 Share Posted April 4, 2006 hi all! this is a UDF working with "SplashText", its really nice to draw Menus or something like this and you make make as much menus as you want ! Current Commands YET : _CreateSplashMenu() _ChangeSplashSelection() Comming : _EditSplashText() ++ expandcollapse popupFunc _CreateSplashMenu($MenuName, $MenuNameARRAY, $MenuItemARRAY, $Holder = "-", $w = 100, $h = 100, $x = 100, $y = 100) Local $i_CreateCount = 0 If IsArray($MenuNameARRAY) And IsArray($MenuItemARRAY) Then $Menu = _SearchRows($MenuNameARRAY) Dim $CreateArray[$Menu[0]+1] $Item = _SearchRows($MenuItemARRAY) ;$NormMenu = SplashTextOn($MenuName, $Menu[1] & " " & $Holder & " " & $Item[1], $w, $h, $x, $y, 1) SplashTextOn($MenuName, "", $w, $h, $x, $y, 1) For $i_CreateCount = 1 To $Menu[0] $CreateArray[$i_CreateCount] = $Menu[$i_CreateCount] & $Holder & $Item[$i_CreateCount] & @CRLF Next $NewMenu = $CreateArray[1] For $i_CreateCount = 2 To $Menu[0] $NewMenu = $NewMenu & $CreateArray[$i_CreateCount] Next ControlSetText($MenuName, "", "Static1", $NewMenu) Dim $Ret[4] $Ret[0] = $MenuName $Ret[1] = $MenuNameARRAY $Ret[2] = $Holder $Ret[3] = $MenuItemARRAY Return $Ret Else Return 0 EndIf EndFunc;==>_CreateSplashMenu Func _ChangeSplashSelection( $_CreateSplashMenu , $Selection ) If IsArray($_CreateSplashMenu) Then Local $i_CreateCount = 0 $Menu = _SearchRows($_CreateSplashMenu[1]) $Item = _SearchRows($_CreateSplashMenu[3]) Dim $CreateArray[$Menu[0]+1] If $Selection > $Menu[0] Then $Selection = 1 ElseIf $Selection < 0 Then $Selection = $Menu[0] EndIf For $i_CreateCount = 1 To $Menu[0] If $i_CreateCount = $Selection Then $CreateArray[$i_CreateCount] = "-> "&$Menu[$i_CreateCount] & $_CreateSplashMenu[2] & $Item[$i_CreateCount] & @CRLF Else $CreateArray[$i_CreateCount] = $Menu[$i_CreateCount] & $_CreateSplashMenu[2] & $Item[$i_CreateCount] & @CRLF EndIf Next $NewMenu = $CreateArray[1] For $i_CreateCount = 2 To $Menu[0] $NewMenu = $NewMenu & $CreateArray[$i_CreateCount] Next ControlSetText($_CreateSplashMenu[0], "", "Static1", $NewMenu) Return $Selection Else Return 0 EndIf EndFunc Func _SearchRows($Array) Dim $ReturnArray[100] Local $i_Index = 0 Local $i_Index2 If IsArray($Array) Then For $i_Index = 0 To 101 If $Array[$i_Index] = "" Then $ReturnArray[0] = $i_Index ExitLoop EndIf $ReturnArray[$i_Index + 1] = $Array[$i_Index] Next Else Return 0 EndIf Return $ReturnArray EndFunc;==>_SearchRows here is an Example of this ! #include <misc.au3> Dim $Menu[10] = ["test1", "test2", "test3"] Dim $Item[10] = ["1", "2", "3"] $MenuItem = _CreateSplashMenu( "Test", $Menu, $Item) $Down = 1 While 1 Sleep(20) If _IsPressed( 01 ) = 1 Then $Cur = _ChangeSplashSelection( $MenuItem , $Down ) $Down = $Cur + 1 While _IsPressed( 01 ) = 1 Sleep(1) WEnd EndIf WEnd thx to cyclops ! by Busti HF My UDF's : Startet on : 06.06.2006_CaseSearchOrReplaceStr();~> Searches OR Replaces a String,;~> With or Without Casesensivity Link to comment Share on other sites More sharing options...
Valuater Posted April 4, 2006 Share Posted April 4, 2006 nice first post... Busti I look forward to seeing great achivements from you 8) Link to comment Share on other sites More sharing options...
Busti Posted April 4, 2006 Author Share Posted April 4, 2006 hai thanX =) im long time here in the forum, but not posting, only lookin =) My UDF's : Startet on : 06.06.2006_CaseSearchOrReplaceStr();~> Searches OR Replaces a String,;~> With or Without Casesensivity Link to comment Share on other sites More sharing options...
RazerM Posted April 4, 2006 Share Posted April 4, 2006 well done, this will be very useful with a little improvement My Programs:AInstall - Create a standalone installer for your programUnit Converter - Converts Length, Area, Volume, Weight, Temperature and Pressure to different unitsBinary Clock - Hours, minutes and seconds have 10 columns each to display timeAutoIt Editor - Code Editor with Syntax Highlighting.Laserix Editor & Player - Create, Edit and Play Laserix LevelsLyric Syncer - Create and use Synchronised Lyrics.Connect 4 - 2 Player Connect 4 Game (Local or Online!, Formatted Chat!!)MD5, SHA-1, SHA-256, Tiger and Whirlpool Hash Finder - Dictionary and Brute Force FindCool Text Client - Create Rendered ImageMy UDF's:GUI Enhance - Enhance your GUIs visually.IDEA File Encryption - Encrypt and decrypt files easily! File Rename - Rename files easilyRC4 Text Encryption - Encrypt text using the RC4 AlgorithmPrime Number - Check if a number is primeString Remove - remove lots of strings at onceProgress Bar - made easySound UDF - Play, Pause, Resume, Seek and Stop. Link to comment Share on other sites More sharing options...
Busti Posted April 4, 2006 Author Share Posted April 4, 2006 (edited) its yet a beta im still working on it Edited April 4, 2006 by Busti My UDF's : Startet on : 06.06.2006_CaseSearchOrReplaceStr();~> Searches OR Replaces a String,;~> With or Without Casesensivity Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now