Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 07/13/2020 in all areas

  1. Hi outthere here is my script-stuff to create ownerdrawn menuitems with icons and colors. It uses GUIRegisterMsg() and WM_DRAWITEM / WM_MEASUREITEM - messages proceeding. Holger Update 06.05.2008: !!! Warning: Script breaking !!! Please change the following commands to: _TrayCreateItem(Text, ...) _TrayCreateMenu(Text , ...) - Fixed: some old values (thanks to aGorilla) - Fixed: ..SetText() functions (thanks to MrCreatoR) - Added the following commands: _SetMenuIconBkGrdColor(Color) ; set icon background gradient color _SetTrayIconBkGrdColor(Color) ; set icon background gradient color New sidebar menu commands: _CreateSideMenu(MenuID) ; returns a SideMenuID/index _DeleteSideMenu(SideMenuID) ; delete a menu sidebar _SetSideMenuText(SideMenuID, Text) ; set a text for the sidebar _SetSideMenuColor(SideMenuID, Color) ; set text color _SetSideMenuBkColor(SideMenuID, Color) ; set text background color _SetSideMenuBkGradColor(SideMenuID, Color) ; set text background gradient color _SetSideMenuImage(SideMenuID, Bitmapfile [, Resourcename/number [, Expand/Compress Bitmap]]) Just take a look into the samples how to use them! At the moment there are some known issues: - missing 64bit compatibility (already in progress, to fully work with "AutoIt3_x64.exe") - moving the mouse cursor on the sidebar menu image/text also changes the current menu item selection - for sidebar menu image only bitmaps are supported at the moment (min.8bpp) Update 23.03.2008: !!! Warning: Please update all your scripts and add after _TrayIconCreate() the command _TrayIconSetState() - otherwise you will not see any tray icons!!! Also update your icon numbers like for GUI icons - Fixed: some things (thanks to nickston) - Changed: _TrayIconCreate() do not show automatically the icon - Changed: icon behaviour now more similar to GUI icons (I hope) - Added: command.txt - Removed: unicode macro History: CODEUpdate 21.03.2008: - Changed: dynamic array sizing of the saved menu items - Added: _TrayDeleteItem(menuID), _GUICtrlODMenuItemDelete($nID) - please delete menu (items) with these commands - Added: _TrayIconSetState() modes 4 and 8 for flashing and flashstopping of tray icons - Added: _SetFlashTimeOut([timeOut]) to set the flash timeout - Added: OnEvent sample Update 23.02.2008: - Fixed: GDI object overload while using bold font Update 22.02.2008: - Added: _TrayItemSetSelIcon(ItemID, IconFile, IconID) - set the icon if the item is selected - Added: _GUICtrlODMenuItemSetIcon(ItemID, IconFile, IconID) - set the icon of the item - Added: _GUICtrlODMenuItemSetSelIcon(ItemID, IconFile, IconID) - set the icon if the item is selected - Added: "ModernMenuRaw.au3" which only includes the unknown constants, should better work with 'Au3Check' now Update 12.01.2008-2: - Fixed: Missing underscore in "CreateMenuFontByName"-function (Font fallback function) (thanks to MsCreatoR and GEOSoft). - Changed: If a menuitem is disabled then the rect only is showing around the item - Added: Underscore in menutext only showing when pressing "Alt"-key Update 12.01.2008: - Changed: 'local' Dll calls to global DllOpen to speedup (some virusscanners sometimes slowdown the process cause of opening these Dll's again and again) - Added: Using of @Tab for accelerator showing/drawing Update 07.12.2007: - Changed: all stuff in only 1 ZIP file - Fixed: now works with 3.2.10.0 and 3.2.8.1 Update 03.08.2007 - Fixed: error in _TrayIconDelete() and new creation - Added: additional parameter to _TrayIconCreate(ToolTip, IconFile, IconID, Callback, Msg, hIcon) to use existing icon handles - Added: sample_Win2Tray: 'moves' all minimized windows to the tray Update 28.07.2007 - Fixed: wrong call of function CreateFont() - Thanks to SleepyExtreme for info - Changed: included samples to demonstrate using of icon clicks Update 26.07.2007 - Fixed: missing function: LoadIcon() Update 21.07.2007 - added bold item support - limited to menuitems only, menus are not supported Update 17.07.2007: - now you can also menu icons for the tray - added commands for Tray: _TrayIconCreate() _TrayCreateMenu() _TrayCreateItem() _TrayItemSetIcon() _TrayIconSetState() _TrayTip() So you can have more than 1 tray icon for 1 Autoit3-script. Update 01.07.2007: - now works with unicode (3.2.4.9) - new command: _GUICtrlODMenuItemSetText(ControlID, NewText) Update 21.08.2006: - delete 1 line in libs to work with current release 3.2.0.X (error: cannot redeclare constant...) - Thanks to Javascript_Freek for info Update 02.02.2006: - added Checked-state for normal menu items and radio menu items - added a like ModernMenuLib-script for easier create/use these menustuff (see sample in the ModernMenuLib-folder) ModernMenuLib_with_Tray.zip
    1 point
  2. AU3Text.au3 v1.0 An extensive UDF to ease the internationalization of AutoIt scripts and programs. Add multi-lingual support to your scripts and programs in a consistent and portable manner. Main features: Store messages in a human-readable INI format.Organize messages in different categories.Handle singular and plural string variants at run time.Expands meta-characters and all AutoIt macro's.Supports UTF-16 Little-Endian encoding.GUI Menu and Combo Create/Read helper functions.Command line utility to extract messages from AutoIt scripts.Fully portable!The download contains the following files:ReadMe.txt Instructions and information on the UDF. AU3Text-HowTo.txt Step by step instructions to convert programs for internationalization with AutoIt. AU3Text-Demo.au3 AU3Text demo. AU3Text-Extractor.au3 Source file for command line utility to extract AU3Text messages from scripts. You'll need to compile this script before you can use it. This is BETA software! LibAU3Text.au3 Main AU3Text library. LibAU3TextGUI.au3 AU3Text GUI helpers. LibAU3TextDev.au3 Additional developer functions. LibLocale.au3 Locale functions. Originally based on guinness' excellent _GetOSLanguage function, but has grown into a full stand-alone UDF. LibIni.au3 UTF-16 LE INI functions. LibStringFormatEx.au3 Modified StringFormat function. See http://www.autoitscript.com/forum/topic/139260-autoit-snippets/page__st__60#entry1010824 I18nAU3Text-Demo.en.lng English demo language file. I18nAU3Text-Demo.nl.lng Dutch demo language file. I18nAU3Text-Translation-HowTo.txt Basic translation instructions. ResAU3Text-Extractor.ico Pic unrelated :)A simple example of translating a string: #include 'LibAU3Text.au3' _AU3Text_BindTextSection('MESSAGES', 'nl') ; Set translations to dutch. ; ... Create a GUI. ; Translate a string: GUICtrlCreateLabel(_AU3Text('The flying dutchman flies again.', 'FLYING_DUTCHMAN'), -1, -1) ; De vliegende hollander vliegt alweer. ; Translate a string with plural variants: GUICtrlCreateLabel(StringFormat(_AU3Text_Plural('Deleted %i file.', 2, 'DELETED_FILES'), 2), -1, -1) ; 2 bestanden verwijdert. ; Using shorthand functions: GUICtrlCreateLabel(_('The flying dutchman flies again.', 'FLYING_DUTCHMAN'), -1, -1) GUICtrlCreateLabel(StringFormat(_P('Deleted %i file.', 2, 'DELETED_FILES'), 2), -1, -1) ; Let AU3Text generate the INI keys, keys are MD5 hashes of the messages. GUICtrlCreateLabel(_('The flying dutchman flies again.'), -1, -1) GUICtrlCreateLabel(StringFormat(_P('Deleted %i file.', 2), 2), -1, -1) ; ...The UDF: AU3Text.zip If you encounter any bugs or have any suggestions, requests or improvements, then please let me know. Happy coding! edit 1: zip added edit 2: If you compiled AU3Text-Extractor and want to test it, run it against AU3Text-Demo like this: AU3Text-Extractor.exe Au3Text-Demo.au3 beThis will create AU3Text-Demo.be.lng in the I18n directory.
    1 point
  3. @crazycrash That is what _WD_FindElement already does, but it isn't working correctly for some reason. I'll have to review the code to see if it's something that I've done wrong.
    1 point
  4. @Wh0Cares, Thought I was pretty clear in my post and closing the previous topic. Maybe the answer is in your name?
    1 point
  5. What's New v1.6.2 (2020-07-12) Added additional function parameter validation to prevent the issue, reported by RTFC, where passing empty strings to some functions was causing DllStructCreate failures. Reverted all DllStructGetData & DllStructSetData functions back to object-based dot-notation.
    1 point
  6. rysiora

    Status Bar

    A nice StatusBar window in AutoIT. Help me figure out how to Set and Get the StatusBar text. #include <GUIConstants.au3> Const $CCS_TOP = 0x1 Const $SBARS_SIZEGRIP = 0x100 Const $SB_SETTEXT = 0x0401 Const $SB_GETTEXT = 0x0402 $Main = GUICreate("StatusBar GUI") GUISetState (@SW_SHOW) $StatusBar = DllCall("comctl32.dll","long", "CreateStatusWindow", "long", BitOR($WS_CHILD,$WS_VISIBLE,$SBARS_SIZEGRIP), "str", "AutoIt Status Bar","hwnd",$Main,"int",0) MsgBox(0,'StatusBar Handle',$StatusBar[0]) GUICtrlSendMsg($StatusBar[0],$SB_SETTEXT,0,"New Text"); does not work. $ret = DllCall("user32.dll", "long", "SendMessage", "hwnd", $StatusBar[0], "int", $SB_SETTEXT, "int", 0, "str", "New Text"); does not work. $pet = DllCall("user32.dll", "long", "SendMessage", "hwnd", $StatusBar[0], "int", $SB_GETTEXT, "int", 0, "int", 0); does not work. While 1 $msg = GUIGetMsg() If $msg = $GUI_EVENT_CLOSE Then ExitLoop Wend
    1 point
  7. Valuater

    Status Bar

    a bit easier #include <GUIConstants.au3> $Main = GUICreate("StatusBar GUI") $in = GUICtrlCreateInput("type new StatusBar text here", 50, 50, 200, 20) $set = GUICtrlCreateButton("set text", 270, 50, 80, 20) $label = GUICtrlCreateLabel("StatusBar Text", 0, 380, 400, 20, $SS_SUNKEN + $SS_CENTER) GUISetState (@SW_SHOW) While 1 $msg = GUIGetMsg() If $msg = $set Then GUICtrlSetData($label, (GUICtrlRead($in))) If $msg = $GUI_EVENT_CLOSE Then ExitLoop Wend 8
    1 point
  8. I need to write a yara rule for a autoit malware (the binary itself not the decompiled script) As far as i know the actual script is in the resource section in the RCData, but how can i find the bytes that represent the variable names? for example lets say there is a variable $VeryObviousVariableName in the script and i want to make a yara rule for the name of the variable in the binary, where can i find this variable name in the binary?
    0 points
×
×
  • Create New...