EvenMore textviewer plugins source
- Size
- 297K (303,959 bytes)
- Added
- 2026-11-20 17:14
- Downloads
- 2
- Long Description
- These are the source code for the plugins for EvenMore. They are written in the AmigaE and ECX programming languages, but there is no reason why you should not be able to create plugins using any programming language. USAGE ===== These source codes have been uploaded to Aminet so that others can see how to create their own plugins for EvenMore. You are free to use and modify this code for your own personal use. The only thing I would ask is, if you are interested in writing a plugin for EvenMore, to let me know so I can put it up on my website. If you do want to use some of this code for your own programming, I have no objection to that, so long as you mention where you got it from in your documentation. Apart from some example code taken from the ROM Kernel manuals, this is all my own work, and represents many years work. I also take no responsibility for any bugs left in it! THE PLUGIN SYSTEM ================= The old EvenMore plugin system used the Amiga library system. EvenMore would open these libraries sequentially and check to see if the plugin criteria matched those of the open file. If a match was found, EvenMore passed the file onto the plugin, which then processed the file and returned the results. This system worked well for AmigaE, but when I moved onto the ECX compiler to make a MorphOS version of EvenMore, I found it was not able to compile Amiga libraries. So I had to come up with an alternative method of creating the plugins. Now each plugin is compiled as an executable file. When EvenMore opens, it launches these plugins. Each plugin opens a port through which it communicates with the main program, and passes information to and from it as necessary. While this uses up a little more memory than your average plugin system, it is quite fast as the plugin code is always resident in memory. The only real processor power being used is to convert the file. PLUGIN TYPES ============ There are several main types of file plugin that can be created for EvenMore. Each of these has a specific ID tag. They are as follows, and are called by EvenMore in this order. FTYP | No-+-Yes | ARCH | No-+-Yes | | PACK | | | FILE | | | No-+-Yes-+ | | DTYP | | | No-+-Yes----+ | | GENE | | | No-+-Yes-------+ | | +--------------+ | FRMT FTYP The FTYP plugins will be called before the file is opened by EvenMore. These plugins just check the extension name of the file to see if it needs to be passed onto another program specified in the filetypes.txt file rather than opened in EvenMore. For example, PDF files, picture or sound files. ARCH ARCH plugins can be used for browsing archived files and directories. EvenMore does not open the file at this stage, but passes only the name of the file onto the plugin. It is then up to the plugin to analyze the file and construct a textual version of its contents if necessary. There is a subfilename string which can be set in order to extract and browse a particular file in the archive. PACK PACK plugins enable EvenMore to open compressed files such as XPK and PowerPacker. They are called before the main file conversion plugins. EvenMore opens the file and passes it onto these plugins. The plugin then analyzes it, performs any necessary operations and returns the buffer back to the main program. EvenMore then passes the updated buffer onto the file conversion plugins. FILE The FILE plugins are used to convert one document format into another. For example, MSWord files, AmigaGuide, etc into plain text. If the file does not match the criteria