Lugaru's Epsilon
Programmer's
Editor

Context:
Epsilon User's Manual and Reference
   . . .
   General Concepts
      Buffer Concepts
      Window Concepts
      Epsilon's Screen Layout
      . . .
      The Menu Bar
   Commands by Topic
      . . .
      Moving Around
      Changing Text
      Language Modes
         Asm Mode
         C Mode
         Configuration File Mode
         . . .
         Visual Basic Mode
      More Programming Features
      Fixing Mistakes
      . . .
   Command Reference
      abort
      about-epsilon
      alt-prefix
      . . .
      zoom-window
   . . .

Previous   Up    Next
Hex Mode  Commands by Topic   Asm Mode


Epsilon User's Manual and Reference > Commands by Topic >

Language Modes

When you use the find-file command to read in a file, Epsilon looks at the file's extension to see if it has a mode appropriate for editing that type of file. For example, when you read a .h file, Epsilon goes into C mode. Specifically, whenever you use find-file and give it a file name "foo.ext", after find-file reads in the file, it executes a command named "suffix_ext", if such a command exists. The find-file command constructs a subroutine name from the file extension to allow you to customize what happens when you begin editing a file with that extension. For example, if you want to enter C mode automatically whenever you use find-file on a ".x" file, you simply create a command (a keyboard macro would do) called "suffix_x", and have that command call c-mode. For another example, you can easily stop Epsilon from automatically entering C mode on a ".h" file by using the delete-name command to delete the subroutine "suffix-h". (You can interchange the - and _ characters in Epsilon command names.)

In addition to the language-specific modes described in the following sections, Epsilon includes modes that support various Epsilon features. For example, the buffer listing generated by the bufed command on Ctrl-X Ctrl-B is actually in an Epsilon buffer, and that buffer is in Bufed mode.

Many language modes will call a hook function if you've defined one. For example, C mode tries to call a function named c_mode_hook(). A hook function is a good place to customize a mode by setting buffer-specific variables. It can be a keyboard macro or a function written in EEL, and it will be called whenever Epsilon loads a file that should be in the specified mode.

The fundamental-mode command removes changes to key bindings made by modes such as C mode, Dired mode, or Bufed mode. You can configure Epsilon to highlight matching parentheses and other delimiters in fundamental mode; see the fundamental-auto-show-delim-chars variable.

Standard bindings:

    fundamental-mode
 



Previous   Up    Next
Hex Mode  Commands by Topic   Asm Mode


Lugaru Copyright (C) 1984, 2020 by Lugaru Software Ltd. All rights reserved.