AviSynth seems to be the tool that directly answers your needs on Windows. This is a completely script-based editing approach, with quite powerful instruments (built-in or as plug-ins) for reading, processing, generating titles and general editing.
Coupled with a dedicated editor such as AVSEdit or AvsP, you can have previews, context help, parameter ...
Your requirements, as stated, are minimal.
WinMerge will accomplish what you want. Specifically, it allows comparing three text files.
It is open-source, with the source code located here.
It is freeware and donations are accepted here.
CudaText editor is almost what you need. It has plugin Sort which is called by menu item "Plugins / Sort", there you see several menu items, including "Remove duplicate lines".
"Almost what you need" because "Remove duplicate lines" removes also duplicate blank lines. Try to ask at support forum, maybe this can be changed, ie blanks can be left.
kDIFF3 will, as its name suggests, allow you to diff 3 files.
It is free, open source, well supported and :
compares or merges two or three text input files or directories,
shows the differences line by line and character by character (!),
provides an automatic merge-facility and an integrated editor for - comfortable solving of merge-conflicts,
Meld allows three-way comparison of files.
It is free and open source. There is an installer for Windows. Not that you need it, but others stumbling on this question might be interested in other platforms: It can be installed using the package manager on common Linux distributions; and though Mac isn't officially supported, there are some installers ...
sed is the tool you're looking for. You can get it from GnuWin32: http://gnuwin32.sourceforge.net/packages/sed.htm. A sed script file can be created that contains the batch of find/replace operations that you want to carry out. The sed commands are all text, so the script file can be easily maintained in a version control system.
The built in TextEdit seems to fit quite a few of your requirements just fine. Have you tried it out?
Command-shift-t puts it in to plain text mode (instead of rich text) which makes it monospaced, and it has most of the other features you are looking for in that mode.
Requirements (all met):
Support for UTF-8, UTF-16, Mac OS Roman, Mac Japanese, Windows ...
CudaText editor (free, cross platform) allows this. Using plugin "Insert Pics".
Install plugin from menu: Plugins / Addon Manager / Install, enter "insert pics".
Call plugin commands from menu: Plugins / Insert Pics.
Readme is at https://github.com/CudaText-addons/cuda_insert_pics/tree/master/readme
Example screenshot of text with pictures:
You can try the CudaText editor (written in Lazarus). But better don’t fork it, rather make a plugin, which does all the functionality for hotkeys. Plugin can handle on_key, on_key_up events, so it can perform any actions after key presses. Refer to CudaText API wiki for info.
Together with a plugin you will need to make the lexer, for you syntax, and bind ...