Quoting Randy Kramer <[EMAIL PROTECTED]>:

> Is there anything like a book ;-) or other documentation that tries to
> explain how nedit works other than the code and comments in the code?
>
> I don't know if a Nedit "internals" document is the right description, but
> it sounded good ;-)

Not really. As ever, it depends what you want to do. Some places that might
get you into the code are the more functionally restricted areas, say menu.c
to see how the menus are built (you can then use the same techniques to adapt
them yourself), and macros.c, many of whose functions are the embodiment of
the built-ins described in the macro subroutines help, so it's easy to
understand what's happening. Again, modifying or adding macro built-ins
teaches you about the macro data structure (DataValue) and how that's
manipulated. The actual language is implemented in parse.y (which describes
how the language is compiled to instructions) and interpret.c (which
implements those instructions and the execution machine).

More complicated, and X/Motif specific, are the main files nedit.[ch] and
windows.[ch]. If you want to add more properties to NEdit's windows, you'll be
playing with these, in particular adjusting the WindowInfo structure. Opening
and closing files is managed in file.c.

The actual text manipulation is handled in textBuf.c and its display by the
widget textDisp.c and text.c. X resource preferences and the nedit.rc
read/write are handled in preferences.c, regex stuff in refexConvert.c and
regularExp.c, highlighting in highlight.c, searching in search.c and so on.

As you can see the file names are a guide. NEdit is generally well commented
so, although it's often hard to see the wood for the trees, you shouldn't be
too led astray by reading them.

Tony
-- 
NEdit Develop mailing list - [email protected]
http://www.nedit.org/mailman/listinfo/develop

Reply via email to