There is a complete editor written in wxPython here:
http://wiki.wxpython.org/WxHowtoSmallEditor
Only 104 lines, should be easy to customize.
EDIT:
To address some of your requirements, here is a copy and paste from the wxPython wiki:
A GUI Toolkit
wxPython is a GUI toolkit for the Python programming language. It allows Python programmers to create programs with a robust, highly functional graphical user interface, simply and easily. It is implemented as a Python extension module (native code) that wraps the popular wxWindows cross platform GUI library, which is written in C++.
Open Source
Like Python and wxWindows, wxPython is Open Source which means that it is free for anyone to use and the source code is available for anyone to look at and modify. Anyone can contribute fixes or enhancements to the project.
Cross Platform
wxPython is a cross-platform toolkit. This means that with a little care that the same program will run on multiple platforms without modification. Currently supported platforms are Microsoft Windows, and most Unix or unix-like systems with GTK available, and OS X 10.3.9 or above.