Icons

Klaus Major k_major at osnabrueck.netsurf.de
Wed Mar 20 15:54:13 EST 2002


Hi Dar,

> I'm a little confused about icons.  I know some sort of reference to 
> icons can be in button properties.  And I know there is some sort of 
> way to work with icons in the development environment.

in fact icons ARE images that are displayed inside a button.

You can do so by setting the property "Icon" of the button to the id of 
the image.

Check it out:

Import an image, note its id, create a button, set its "icon"-property 
to the noted id, et voila...

You might have to adjust the buttons size etc...

And you can hide the image now, if you don't need it otherwise.

> But...  Where are they stored?

If you use your own images, they are stored with the stack.

> (Is there some global property?  Are there commands to manipulate the 
> icon db?  Is there a stack with a special name that contains them?  If 
> I use an icon and make a standalone, do I get all icons added to the 
> standalone, or just the one I use?)

Check the "help" about "Building standalones".

You can check to add all rev-icons you use in your buttons to your final 
standalone.
>
> If I use an image n times and don't want to consume n times the memory 
> for one image, would an icon be the way to go?

Yes, definitively.

You can display one image in 10000 buttons (in the same stack!)

The image is loaded into memory just once.

>   Can I refer to an icon in an image?

No, since they are identic.

> Is there another way to share images?  Using players in some way?

No.

> Or are images automatically shared?

See above...

> Dar Scott

Hope that helps...


Best

Klaus Major
k_major at osnabrueck.netsurf.de




More information about the use-livecode mailing list