Opening XEmacs
You can launch XEmacs in several ways:- Click the XEmacs icon in the CDE panel
- Double-click a text file in the File Manager
- From Terminal Lab: Open a file with
man emacsfor help
Splash Screen
When you first open XEmacs, you’ll see the GNU-style splash screen with the scratch buffer:- Link to open an existing file
- Welcome message in the minibuffer
- Scratch buffer for temporary notes
Essential Keybindings
File Operations
| Keybinding | Action | Description |
|---|---|---|
C-x C-f | Find File | Open or create a file |
C-x C-s | Save | Save the current file |
C-x C-w | Save As | Save with a new name |
C-x C-c | Quit | Close XEmacs |
Navigation
| Keybinding | Action | Description |
|---|---|---|
C-a | Beginning of Line | Move to start of line |
C-e | End of Line | Move to end of line |
C-n | Next Line | Move down one line |
C-p | Previous Line | Move up one line |
C-f | Forward Char | Move right one character |
C-b | Backward Char | Move left one character |
C-l | Recenter | Recenter cursor in window |
Editing
| Keybinding | Action | Description |
|---|---|---|
C-k | Kill Line | Delete from cursor to end of line |
C-d | Delete Char | Delete character at cursor |
C-_ | Undo | Undo last change |
C-x h | Select All | Select entire buffer |
C-s | Search | Open find dialog |
C-g | Abort | Cancel current operation |
Clipboard Operations
While XEmacs traditionally uses “kill” and “yank” terminology, Time Capsule’s implementation provides standard clipboard operations:- Copy: Use the Edit menu or
document.execCommand - Cut: Use the Edit menu
- Paste:
C-yor Edit menu (reads from clipboard)
The Minibuffer
The minibuffer is XEmacs’s command-line interface at the bottom of the window. It displays:- Status messages (“Wrote /home/victxrlarixs/file.txt”)
- Prompts for input (“Visit file: ”)
- Command sequences (“C-x-” when waiting for the next key)
- Error messages
Using the Minibuffer
When prompted for input:- Type your response (e.g., filename)
- Press
Enterto confirm - Press
EscapeorC-gto cancel
M-x: Execute Command
PressM-x (Alt+X) to execute commands by name:
| Command | Action |
|---|---|
save-buffer | Save current file |
find-file | Open a file |
kill-emacs | Quit XEmacs |
help | Show keybinding help |
eval-buffer | (Not implemented - shows message) |
The Mode Line
The mode line at the bottom shows:- File status:
%%(unmodified) or**(modified) - File name: Currently open file
- Line number: Current cursor line
- Column number: Current cursor column
Menubar Features
File Menu
- New File: Create a new buffer
- Open: Find and open a file (
C-x C-f) - Save: Save current file (
C-x C-s) - Save As: Save with new name (
C-x C-w) - Close: Quit XEmacs (
C-x C-c)
Edit Menu
- Undo: Undo last change
- Cut: Cut selected text
- Copy: Copy selected text
- Paste: Paste from clipboard
- Select All: Select entire buffer
Options Menu
- Word Wrap: Toggle visual line mode
- Font Size: Small (12px), Medium (14px), Large (16px)
- Clear Buffer: Erase all content
Help Menu
- Shows all available keybindings
- Message: “Bindings: C-x C-s Save C-x C-c Quit C-s Search C-k Kill C-_ Undo C-g Abort”
Find and Replace
PressC-s to open the find bar:
- Type your search term
- Press
Enteror click “Next” to find next occurrence - Click “Previous” to find previous occurrence
- Press
Escapeto close the find bar
Working with Files
Opening Files
- Press
C-x C-f - Enter the file path in the minibuffer:
- Absolute path:
/home/victxrlarixs/Desktop/readme.txt - Relative path:
readme.txt(opens from ~/Desktop/)
- Absolute path:
- Press
Enter
Saving Files
When you modify a file, the mode line shows** to indicate unsaved changes.
Press C-x C-s to save. The minibuffer confirms:
Save As
- Press
C-x C-w - Enter the new path
- Press
Enter
Integration with File Manager
XEmacs integrates seamlessly with the CDE File Manager:- Double-clicking a text file opens it in XEmacs
- The file path is automatically resolved
- Saving updates the file in the virtual filesystem
- The File Manager refreshes to show changes
Keyboard Shortcuts Summary
Most Used:C-x C-s: Save fileC-x C-f: Open fileC-x C-c: QuitC-k: Kill lineC-s: SearchC-g: Cancel/AbortC-_: Undo
C-a,C-e: Start/end of lineC-n,C-p: Next/previous lineC-f,C-b: Forward/backward character
M-x help: Show keybindings- From Help menu: Display all shortcuts
Tips and Tricks
Two-key Commands
Two-key Commands
Some commands require two key sequences. Press
C-x, then the second key:C-x C-s: SaveC-x C-f: Find fileC-x C-c: QuitC-x C-w: Save asC-x h: Select all
Aborting Commands
Aborting Commands
Made a mistake? Press
C-g to cancel:- Exits partial command sequences
- Cancels minibuffer prompts
- Closes dialogs
Visual Line Mode
Visual Line Mode
Toggle word wrap for easier reading:
- Open Options menu
- Click “Word Wrap”
- Or use
Options→Word Wrap
Scratch Buffer vs. Files
Scratch Buffer vs. Files
The scratch buffer is temporary:
- Not saved automatically
- Perfect for quick notes
- To save it, use
C-x C-w(Save As)
C-x C-f for persistent storage.Source Code
XEmacs is implemented in:/src/scripts/features/emacs.ts: Core editor logic (822 lines)- Minibuffer prompt system with Enter/Escape handlers
- Mode line showing file status, cursor position
- Full Emacs keybinding emulation
- Integration with VFS for file operations

