Incorporating plug-ins at runtime

To give access to functions of external objects, SimplyHTML adds a plug-in menu to its menu bar. For each plug-in one menu item is added to the plug-in menu. The menu item is to be provided by the plug-in and typically would contain one or more submenus with the functionality delivered by the plug-in.

In the same way SimplyHTML creates a new menu item in the help menu so that the plug-in can provide documentation about the way it is working.

If the plug-in delivers a component to SimplyHTML, it is displayed by SimplyHTML either as a new window or as a panel inside a section of SimplyHTML's main window, whatever is requested by the plug-in.

Plug-in initialization

Upon construction class FrmMain uses method initPlugins to add all plug-ins present to the application. Method initPlugins uses class PluginManager to locate and load plug-ins. In method initPlugins a new instance of class PluginManager is created. All plug-ins returned by method plugins of PluginManager are iterated and their parts (plug-in menu, help menu and component so far) are added to SimplyHTML as described above.