emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: What is emacs architecture ?


From: Eli Zaretskii
Subject: Re: What is emacs architecture ?
Date: Thu, 08 Jul 2010 10:06:00 +0300

> Date: Wed, 7 Jul 2010 15:28:42 -0700
> From: Fren Zeee <address@hidden>
> Cc: Stephen Berman <address@hidden>, address@hidden
> 
> Where do you get the very minimal of the emacs code ? For anyone to
> contribute to emacs, there has to be some very minimal code to be read
> and understood and also documenting the journey for future reference
> when the person starts forgetting.

As you probably already understood, there's no single document that
includes what you want.  Here's some stuff that does exist and can be
used instead:

 . The top-level Emacs processing loop is described in the "Command
   Loop" chapter of the ELisp manual.

 . Some information about the internals and the Emacs build system is
   in the "GNU Emacs Internals" appendix of the ELisp manual.  This
   includes sections about writing Emacs primitives, garbage
   collection, object internals, etc.

 . The basic building blocks of the Emacs architecture are spelled out
   as names of the chapters you see in the top-level menu of the ELisp
   manual (when you read it on-line).  If you _really_ want a thorough
   understanding of the architecture, you will have to read at least
   the introductory portions of each of these chapters, as preparation
   for the next step (below).  Without a good understanding of each of
   the basic objects used by Emacs, you will have hard time studying
   the code.

 . "Use the source, Luc!"  Basic parts of the Emacs architecture are
   roughly represented by its C source files.  In a few cases, several
   files constitute one part; a notable example is the display engine
   (which takes 3 files, not counting the bidi reordering engine and
   terminal-specific back ends).  Each of these source files has a
   large commentary at the beginning which documents its top-level
   design.  Read those comments, then decide whether you want to read
   the rest of the module.

I agree with a few people here who told you not to bite too much at
once, lest you'll be unable to chew that.  It is best to concentrate
on some specific aspect of the design, after getting some general idea
by reading the "Command Loop" chapter.  What you select depends on
your interests.  After selecting the aspect you want to study, read
everything related to it in the ELisp manual, and only after that read
the corresponding C code.  You can easily find which C code to read by
looking up the implementation of the primitives described in the ELisp
manual.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]