On 08/26/2010 01:18 PM, ZuLuuuuuu wrote:
>
> Hello,
>
> I have an application which uses an image as its icon. I included the image
> into the .star package I created for the application as:
>
> <file>Resources/logo.png</file>
>
> My question is, how can I refer to this file inside my source files? For
> example:
>
> GtkWindow setDefaultIconFromFile: ???
This is currently not possible because Gtk doesn't know about .star files.
Gtk bindings should provide its own implementation of
#setDefaultIconFromFile: that builds its own GdkPixbuf. It's not hard
to do.
When this is done, you would do this as
GtkWindow setDefaultIconFromFile:
(PackageLoader packageAt: 'YourPackage') / 'Resources/logo.png'
Note that VisualGST is already loading pixbufs from resources, so you
can take a look there as well.
Paolo
_______________________________________________
help-smalltalk mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/help-smalltalk