Jump to content

Traymenuex Udf. Add Icon Or Bmp To Trayitem


Uten
 Share

Recommended Posts

Thank You Uten for your udf ,exactly what I was looking for :P

I made my custom icons and stored them as a new icon resource in my autoit compiled scripts exe , works awesome. (of coarse I set the address of the icon in the script before compiling)

Just un upx the compiled scripts exe before adding the new icon resouce with reshacker.

upx the exe back up after it's edited. :)

(as long as you don't upx -brute or set the upx level to high it works fine)

I notice that as long as you substitute your icon transparency for true white (255,255,255) then transparency works in the tray menu.

I hope you keep going with this udf Uten , maybe it's not a needed udf , but it does add some spice to an otherwise boring tray menu ... All Good

Cheers m8

Link to comment
Share on other sites

  • 6 months later...

Please, any help is great appreciated.

i need help with the tray menu icons, they wont display correctly.

see attached images, the extracted icons are not transparent, and they are not sized correctly.

part of my code is underneath the image.

Posted Image

$extract[0] = _LoadImage($sirsi_icon, $IMAGE_ICON)
$extract[1] = _IconExtractFromFile($iepath, 0)
$extract[2] = _IconExtractFromFile($ffpath, 0)
$extract[3] = _IconExtractFromFile("\\svr2\commapps\Office2003\FILES\PFILES\MSOFFICE\OFFICE11\OSA.EXE", 0)
$extract[4] = _IconExtractFromFile($wordpath, 0)
$extract[5] = _IconExtractFromFile($remote_icon, 0)
;~ $extract[6] = _IconExtractFromFile("shell32.dll", 2)
$extract[7] = _IconExtractFromFile("shell32.dll", 166)
$extract[8] = _LoadImage($classreg_icon, $IMAGE_ICON)
;~ $extract[9] = _IconExtractFromFile("\\wkcadesk1\cadesk\Program Files\Pharos\Bin\PsDomain.dll", 0)
$extract[9] = _LoadImage(@ScriptDir & "\pharos.ico", $IMAGE_ICON)
$extract[10] = _IconExtractFromFile("shell32.dll", 146)
$extract[11] = _IconExtractFromFile("shell32.dll", 144)
$extract[12] = _IconExtractFromFile(@systemdir & "\cleanmgr.exe", 0)

_TrayMenuAddIcon($extract[2],0)
_TrayMenuAddIcon($extract[1],1)
_TrayMenuAddIcon($extract[3],2)
_TrayMenuAddIcon($extract[0],3)
_TrayMenuAddIcon($extract[4],0,$settingsitem2)
_TrayMenuAddIcon($extract[1],0,$settingsitem1)
_TrayMenuAddIcon($extract[9],1,$settingsitem1)
_TrayMenuAddIcon($extract[2],0,$settingsitem)
_TrayMenuAddIcon($extract[9],1,$settingsitem)
_TrayMenuAddIcon($extract[5],4)
Link to comment
Share on other sites

  • 2 months later...

can anyone explain the commands for me I think I'm too stupid

[quote]Baby you're all that I want, When you're lyin' here in my armsI'm findin' it hard to believe, We're in heavenAnd love is all that I need , And I found it there in your heartIt isn't too hard to see, We're in heaven .Bryan Adams[/quote].............................................................................[u]AUTOIT[/u]

Link to comment
Share on other sites

can anyone explain the commands for me I think I'm too stupid

Did you take a look at the sample?

I'm probably stupide to as I can't remeber any of this..:rolleyes:

Link to comment
Share on other sites

Hey Uten , are you going to add scaling and transparency to this udf, so icons from resources will look right without having to put them through another process ?

I see the comments in your script, and every time I use it I think.. 'Maybe one day, fingers crossed'.

I'd do it myself but I'm to noob when it comes to anything more then the basic of what's in the help file.

BTW , I use your script quite often as I haven't seen another example of creating icons in a tray menu on the forums as of yet.

Funny as I've seen icons for combo boxes, file menus and just about any other control you can think of.

Maybe PaulIA can work his magic with AU3Lib to accomplish tray menu icons scaled and trans in the tray. (that's if it's not possible already with his lib).

Once again thank you for a udf I enjoy the end results of using.

All the best

Cheers

Link to comment
Share on other sites

I'm happy to here you like it @smashly. I'm also sorry to tell you that it's not high on my priority list (don't need it myselfe so...) I'll give it an hour during the week. At the moment I don't even remember how this works so I will have to download and read my own code and comments. Don't look forward to that..:rolleyes:

Link to comment
Share on other sites

  • 3 months later...

Just a note if you monitor this topic. I have not done anything with this. But you will probably find @Holgers work wort a study.

Link to comment
Share on other sites

  • 5 months later...

On icons, I usually GIMP mine, and use the Iconify feature...

it makes an icon set with scaled icons from the tiniest to the largest and lets you save it that way as if it was a single icon. Transparency isn't a problem either.

Just thought I'd point this out.

01000001 01110101 01110100 01101111 01001001 01110100 00100000
An immortal object must be copied, so that we get a mortal copy of it, since we try not to destroy immortal objects.
Link to comment
Share on other sites

  • 3 years later...

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...