AmigaOS4.1 Programm icon

Find quick help here to get you started with Hollywood
User avatar
fingus
Posts: 269
Joined: Fri Sep 16, 2011 9:53 am

AmigaOS4.1 Programm icon

Post by fingus »

I try to link some programm icon into my app-executable for the minimized state with this:

Code: Select all

@APPICON{Ic16x16 = "res/16icon.png",
Ic24x24 = "res/24icon.png",
Ic32x32 = "res/32icon.png",
Ic48x48 = "res/48icon.png"}  
But if minimized, Hollywoodplayer still shows the clapperboard, what's going on, why this not work on AmigaOS but on Windows like mentioned in the Helpfile?
User avatar
airsoftsoftwair
Posts: 5433
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: AmigaOS4.1 Programm icon

Post by airsoftsoftwair »

As the documentation says, @APPICON is only supported on Windows, Mac OS X and Linux because these systems use icons compiled into the executables directly. On AmigaOS, however, the icon is always kept externally. That's why you have to use the SetWBIcon() function instead.
User avatar
fingus
Posts: 269
Joined: Fri Sep 16, 2011 9:53 am

Re: AmigaOS4.1 Programm icon

Post by fingus »

That's why you have to use the SetWBIcon() function instead.
Suggestion:
Hmm, then it should be mentioned in the description for the @APPICON.

Or i´m total blind ;-)
User avatar
airsoftsoftwair
Posts: 5433
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: AmigaOS4.1 Programm icon

Post by airsoftsoftwair »

I added this piece of information to the @APPICON documentation now :)
User avatar
fingus
Posts: 269
Joined: Fri Sep 16, 2011 9:53 am

Re: AmigaOS4.1 Programm icon

Post by fingus »

Andreas wrote:I added this piece of information to the @APPICON documentation now :)
Thanks!

Another question/possible bug regarding setwbicon():

It seems SetWBIcon() only accept "projectname.info" for input.
If i try another name e.g. "minimized.info" for the minimized state, then the clapperboard will be displayed instead of the new one.
User avatar
airsoftsoftwair
Posts: 5433
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: AmigaOS4.1 Programm icon

Post by airsoftsoftwair »

That must be a bug in your code. Hollywood doesn't care about the filename of the icon passed to SetWBIcon().
User avatar
NubeCheCorre
Posts: 77
Joined: Mon Mar 19, 2012 1:24 am
Contact:

Re: AmigaOS4.1 Programm icon

Post by NubeCheCorre »

Hi :)

I browsed the forum and discovered this topic that talk about my problem..

I tried to set up a program icon for a windows app but for some unknown reason, at least for me, it doesn't work.. I also tried the SetWBIcon() function to set up a workbench icon for a program when iconified but it doesn't work..

About the windows problem, here you can see a grab.. there is always the Hollywood Icon but in the left bottom border you can see my custom icon..

http://www.os4games.it/immagini/seticon.png
User avatar
airsoftsoftwair
Posts: 5433
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: AmigaOS4.1 Programm icon

Post by airsoftsoftwair »

Did you really specify icons for all the different types? It's NOT enough to just specify a 48x48 icon for example. You also need to provide icons for ALL the other sizes. Otherwise the standard icon will be used for the other sizes...
User avatar
NubeCheCorre
Posts: 77
Joined: Mon Mar 19, 2012 1:24 am
Contact:

Re: AmigaOS4.1 Programm icon

Post by NubeCheCorre »

Thanks Andreas, the problem was that, I only specified one size of icon and not all the sizes, now it works :-)

What about SetWBIcon() ?

I converted a png image using FXPaint saving it as GlowIcon (it is an option of FXPaint) with extension ".info". Then I put this line in my code:

SetWBIcon("Data/Icons/wb_icon.info")

But when i try to iconify my program I always have the Hollywood icon..

Here is a grab, where you can see, the code of my program, the glowicon icon and the iconify program on the left..

www.os4games.it/immagini/grab_018.png
User avatar
airsoftsoftwair
Posts: 5433
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: AmigaOS4.1 Programm icon

Post by airsoftsoftwair »

Code: Select all

SetWBIcon("Data/Icons/wb_icon.info")
Are you sure that this relative path can be resolved correctly, i.e. is the current directory relative to this directory? Also, are you sure that "wb_icon.info" is a valid icon file? Try to open it with an icon editor.

I tested the following here and it works fine:

Code: Select all

SetWBIcon("SYS:Disk.info")
Post Reply