Jump to content

Filetype plugin using multiple extensions


midora

Recommended Posts

I created a filetype plugin for .xcf, .xcfgz, and .xcfbz2. Load and save works fine.

The issue is that I don't know how to allow the user to select (on save) one of the three file extensions (means the type of compression).

Is the only solution to implement three different filetype classes in the plugin?

Any other proposal?

midoras signature.gif

Link to comment
Share on other sites

The default extension is simply the first one you provide. If the user wants to use a different extension, they can type it in the Save dialog. This is how the JPEG handler works, since it needs to support .jpg, .jpe, .jpeg.

The Paint.NET Blog: https://blog.getpaint.net/

Donations are always appreciated! https://www.getpaint.net/donate.html

forumSig_bmwE60.jpg

Link to comment
Share on other sites

If they are being saved differently, then yes you should create separate classes for each type.

I guess you are right. In the moment this is the best way to do it for the user.

OK, I derived the packed variants from the standard one.

And there are three entries in the file selector.

midoras signature.gif

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...