discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Connecting file extensions to applications


From: Andreas Höschler
Subject: Connecting file extensions to applications
Date: Wed, 13 Sep 2006 16:53:12 +0200

Hi all,

how can I make my app to start automatically and open a document file when I doubleclick on a file with a specific extension, e.g. *.project? I have a file CustomInfo.plist in the project directory and listed all document types.

CFBundleIconFile = "ProjectBuilder.icns";
NSTypes = (
     {
        NSName = "h";
        NSHumanReadableName = "Header File";
        NSUnixExtensions = ("h");
        NSDOSExtensions = ("h");
        NSRole = Editor;
        NSIcon = "hfile.tiff";
      },
     {
        NSName = "c";
        NSHumanReadableName = "c File";
        NSUnixExtensions = ("c");
        NSDOSExtensions = ("c");
        NSRole = Editor;
        NSIcon = "cfile.tiff";
      },
     {
        NSName = "m";
        NSHumanReadableName = "m File";
        NSUnixExtensions = ("m");
        NSDOSExtensions = ("m");
        NSRole = Editor;
        NSIcon = "mfile.tiff";
      },
     {
        NSName = "sproject";
        NSHumanReadableName = "sproject File";
        NSUnixExtensions = ("sproject");
        NSDOSExtensions = ("sproject");
        NSRole = Editor;
        NSIcon = "projfile.tiff";
      },
     {
        NSName = "project";
        NSHumanReadableName = "project File";
        NSUnixExtensions = ("project");
        NSDOSExtensions = ("project");
        NSRole = Editor;
        NSIcon = "projfile.tiff";
      }
    );

But NSWorkspace does not seem to take care. Any ideas?

Thanks a lot!

Regards,

  Andreas





reply via email to

[Prev in Thread] Current Thread [Next in Thread]