parent
966ad5afc8
commit
a0d154549a
8
MODES
8
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.
|
The last is for detecting scripts using the "#!/usr/bin/foo" syntax.
|
||||||
|
|
||||||
3. How do they work?
|
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.
|
||||||
|
|
Loading…
Reference in New Issue