How to create a new filetype

Hello guys,

how i can create a own fieltype for my applications?

Greetings Lelldorin

You can find an example how i did it (also its completly outdated because it dont use hvif )

but it should give you maybe a starting point :slight_smile:

If you want to set the filetype of a data file your application creates maybe my code at: will be of help.

it’s in the documentation:

If you can get hold of a copy of Hacker’s “BeOS Bible”, there’s a lot more detail there. Also his app TrackerGrep, which consists mostly of bash scripts, makes extensive use of new filetypes IIRC. It might be worth studying.

Give your files their own mime type, and register the mime-type with your application.

FileTypes is your friend.

Thanks for all your help, i will take a look.

Greetings lelldorin


Programmatically, have a look at DarkWyrm’s lesson 15. It’s C++ of course.
Otherwise, there’s the Terminal command “mimeset” to register a MIME type and “settype” to assign a file type to a file. I guess there’s a system() function to invoke those from within yab.