Would it be possible to implement basic dll plugin support for PSPad? I have
several extensions in mind
([url=http://forum.pspad.com/read.php?2,43187,43579#msg-43579]and one
implemented![/url]) - but they require external dlls to be loaded, and loading
COM objects through a script is proving to be too unstable. :-/

A similar system to the Filetype plugins would be great, but instead of only
loading the dlls when files are opened/saved, just load/unload them when the
application starts and ends.

I know this would be really simple to implement (I've done it myself but it
requires adding a registry entry which loads a dll into every system process -
quite an inefficient way to do things), and I'm positive it would spawn a whole
load of good extensions from the programmers among us.

Suggested path for generic plugins:
/{PSPad Install}/Plugins/Generic
(only .dll files are loaded)

Suggested DLL interface (v1):
[all functions are stdcall]

_PSP_Version()_
- No parameters, returns Long (4 bytes)
- Should return the plugin interface version

_PSP_Startup()_
- Called when the application has started and the main window is created.
Possible parameter: Handle to the main window (HWND). Should return true or
false - false means it will get unloaded immediately.

_PSP_Shutdown()_
- Called when the application is about to shut down. No parameters, no return
value.

It would also be nice (though not strictly necessary) to receive notifications
of the following events:

- Editor activated
- Editor deactivated
- Editor content changed

So, what do people think? More importantly, what do you think _Jan_? Can it
happen?

-- 
<http://forum.pspad.com/read.php?2,43580,43580>
PSPad freeware editor http://www.pspad.com

Odpovedet emailem