[Lazarus] Cross platform 'open file with default program'

dmitry boyarintsev skalogryz.lists at gmail.com
Sun Jan 24 12:06:29 CET 2010


On Sun, Jan 24, 2010 at 2:08 PM, Juha Manninen <juha.manninen at phnet.fi> wrote:
> One thing is missing though. There is no portable way of getting application's
> icon like ExtractAssociatedIcon does in Windows? This is somewhat related to
> opening the file.

It depends on what you exactly need.
If you need just to get an icon associated with a file extension,
you'll need to use ShellAPI functions in Windows, and different API in
OSX. I guess there should some similar API in Gtk/Qt for Linux, too.

If you just need to extract an Icon of the program's exectuable...
well you can use Application.Icon.

thanks,
dmitry




More information about the Lazarus mailing list