GtkEditor is a source code editor widget for GTK+. The longterm goal of GtkEditor is to provide a framework for source code editing in GTK+ applications, whether just for editing macros or for full fledged IDEs. We try to achieve this through a highly configurable editor widget sub-classing the GtkText widget. After initialisation, the editor widget can be treated as the usual text widget, and all source-code editing features are taken care of by the widget itself. The behaviour of the editor is decided by dynamic libraries loaded during initialisation of the widget. These libraries can be hand-coded or created using tools supplied with GtkEditor.
The Next Generation (TNG) is the project name for the design and implementation taking place in the 0.1.x series. The 0.0.x series provided a flexible API for syntax highlighting making it applicable for a broad range of languages, but the API for other source editing facilities, such as automatic indenting, source browsing, and parenthesis matching ranged from poor to non-existing. The Next Generation is a total redesign and reimplementation, of the editor widget. The design and codebase from the 0.0.x series has been abandoned for what we consider a better and more flexible design.
This document describes the new design of the GtkEditor, GtkEditor - The Next Generation. Developers are encouraged to read through this document before diving into the source, and make sure to update it whenever they change the design or API. This document is considered canon on the GtkEditor design, and any design in the source not described here is considered wrong and is in danger of being removed.
The document is structured in two chapters. Chapter 1, describes the overall design of GtkEditor. It explains the different objects composing the editor design, describes their intended interaction, and how this interaction can be used to implement various editor features. This chapter should preferably be read by any developer before diving into the code. It is also recommended reading for any plugin developer. Chapter 2, lists the various structures and functions exported in the GtkEditor library. This chapter is intended as a reference manual for developers using the GtkEditor in their applications.