Emacs編輯命令速查2【摘自Learning Gnu Emacs】

Table E-7. Regular expression search commands (Chapter 3)

Keystrokes

Command name

Action

C-M-s Enter Edit  Search  Regexp Forward

re-search-forward

Search for a regular expression forward.

C-M-r Enter Edit  Search  Regexp Backwards

re-search-backward

Search for a regular expression backward.

C-M-s Edit  Search  Incremental Search  Forward Regexp

isearch-forward-regexp

Search incrementally forward for a regular expression.

C-M-r Edit  Search  Incremental Search  Backward Regexp

isearch-backward-regexp

Search incrementally backward for a regular expression.

C-M-% Edit  Replace  Replace Regexp

query-replace-regexp

Query-replace a regular expression.


Table E-8. Spell-checking commands (Chapter 3)

Keystrokes

Command name

Action

(noneTools  Spell Checking  Spell-Check Buffer

ispell-buffer

Check spelling of the buffer.

(noneTools  Spell Checking  Spell-Check Comments

ispell-comments-and-strings

Checks spelling of comments and strings in a program.

(noneTools  Spell Checking  Automatic Spell-Checking (Flyspell)

flyspell-mode

Enter the flyspell minor mode, in which incorrectly spelled words are highlighted.

(none)

flyspell-buffer

Spell-check the current buffer, underlining all misspelled words. Use middle mouse button to correct.


Table E-9. Buffer commands (Chapter 4)

Keystrokes

Command name

Action

C-x b Buffers  Select Named Buffer

switch-to-buffer

Move to the buffer specified.

C-x  Buffers  Next Buffer

next-buffer

Move to the next buffer in the buffer list.

C-x Buffers  Previous Buffer

previous-buffer

Move to the previous buffer in the buffer list.

C-x C-b Buffers  List All Buffers

list-buffers

Display the buffer list.

C-x k

kill-buffer

Delete the buffer specified.

(none)

kill-some-buffers

Ask about deleting each buffer.


Table E-10. Windows and frames (Chapter 4)

Keystrokes

Command name

Action

C-x 2 File  Split Window

split-window-vertically

Divide current window into two windows, one above the other.

C-x 3

split-window-horizontally

Divide current window into two side-by-side windows.

C-x o

other-window

Move to the other window; if there are several, move to the next window.

C-x 0

delete-window

Delete the current window.

C-x 1 File  Unsplit Windows

delete-other-windows

Delete all windows but this one.

C-x 4 f

find-file-other-window

Find a file in the other window.

C-x 4 b

switch-to-buffer-other-window

Select a buffer in the other window.

(noneTools  Compare (Ediff)  This Window and Next Window

compare-windows

Compare this window with the next window and show the first difference.

C-x 5 o Buffers  Frames

other-frame

Move to other frame.

C-x 5 0 File  Delete Frame

delete-frame

Delete current frame.

C-x 5 2 File  New Frame

make-frame

Create a new frame on the current buffer.

C-x 5 f

find-file-other-frame

Find file in a new frame.

C-x 5 r

find-file-read-only-other-frame

Finds a file in a new frame, but it is read-only.

C-x 5 b

switch-to-buffer-other-frame

Make frame and display other buffer in it.

Table E-11. Shell mode commands (Chapter 5)

Keystrokes

Command name

Action

(none)

shell

Enter shell mode.

C-c C-c Signals  BREAK

comint-interrupt-subjob

Interrupt current job; equivalent to C-c.

C-c C-z Signals  STOP

comint-stop-subjob

Suspend or stop a job; C-z in Unix shells.

M-p In/Out  Previous Input

comint-previous-input

Retrieve previous commands (can be repeated to find earlier commands).

M-n In/Out  Next Input

comint-next-input

Retrieve subsequent commands (can be repeated to find more recent commands).

Enter

comint-send-input

Send input on current line.

Tab

comint-dynamic-complete

Complete current command, filename, or variable name.


Table E-12. Dired commands (Chapter 5)

Keystrokes

Command name

Action

C-x d File  Open Directory

dired

Start Dired.

C Operate  Copy to

dired-do-copy

Copy file.

d Mark  Flag

dired-flag-file-deletion

Flag for deletion.

D Operate  Delete

dired-do-delete

Query for immediate deletion.

f

dired-advertised-find-file

Find (so you can edit).

g Immediate  Refresh

revert-buffer

Reread the directory from disk.

m or * m Mark  Mark

dired-mark

Mark with *.

Q Operate  Query Replace in Files

dired-do-query-replace

Query replace string in marked files.

R Operate  Rename to

dired-do-rename

Rename file.

s

dired-sort-toggle-or-edit

Sort the Dired display by date or by filename (toggles between these).

t Mark  Toggle Marks

dired-toggle-marks

Toggle marks on files and directories; pressing t once marks all unmarked files and directories; pressing t again restores original marks.

u Mark  Unmark

dired-unmark

Remove mark.

+ Immediate  Create Directory

dired-create-directory

Create a directory.

* ! or M-Del Mark  Unmark All

dired-unmark-all-files

Remove all marks from all files.


發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章