Jump to content
Paint.NET 5.1 is now available! ×

Recommended Posts

Posted

How much parts of a plugin needs to be public? Like, what needs to be public so paint.net can see it from the assembly?
As in:
SaveConfigWidget: public or can be internal?
SaveConfigToken: public or can be internal?
IPluginSupportInfo: public or can be internal?
IFileTypeFactory: public or can be internal?
FileType: public or can be internal?

  • 2 weeks later...
Posted

IFileTypeFactory , FileType , IPluginSupportInfo constructors must be public, classes can be internal. But I would leave classes as public too, just to make sure Paint.NET is able to create instances of these if its plugin loading logic changes in the future for some reason. Why are we developing these plugins if Paint.NET won't be able to see them, right? 😀

 

I haven't used SaveConfig* classes so far but SaveConfigWidget is a user control and its instance created by you on OnCreateSaveConfigWidgetT method, not by Paint.NET. So, I assume, it can be public/private/internal. Same for SaveConfigToken, it's instance created by you on OnCreateDefaultSaveConfigTokenT, not by Paint.NET.

  • Upvote 1

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...