From a0d154549a35bdf09647cb2f5e4e2a1aa0fcdec8 Mon Sep 17 00:00:00 2001 From: moculus Date: Sun, 29 Jul 2007 03:45:34 +0000 Subject: [PATCH] --HG-- branch : pmacs2 --- MODES | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/MODES b/MODES index cf7f717..595aec0 100644 --- a/MODES +++ b/MODES @@ -28,3 +28,11 @@ Loading a module involves the following (in Application.__init__): The last is for detecting scripts using the "#!/usr/bin/foo" syntax. 3. How do they work? + +The one thing every mode has in common is that they map key bindings to actions +to be taken. They do this via self.bindings, a dictionary mapping action names +(i.e. 'page-down') to a tuple of key bindings (i.e. ('C-v', 'PG_DN',)). + +Modes subclass mode2.Fundamental, and they call mode2.Fundamental.__init__ to +run the standard mode initialization (including building the default bindings +dictionary); they can later modify or overwrite this dictionary if they choose.