replacing ^M with emacs
keramida at ceid.upatras.gr
Mon Oct 30 08:12:00 UTC 2006
On 2006-10-27 16:30, Noah <admin2 at enabled.com> wrote:
> Thanks Peter,
> where is the logic here? What is control-q for and what is control-j
> for? I am trying to figure out how I could have figured that out.
> also is there a better page than the one I am using below to figure all
> these keystrokes out?
`C-q' is an Emacs-specific prefix for `quoting' the next
character when you are inserting text. This way, you can enter
special characters, like C-a, C-b, C-c, ... C-z while you are
typing text. Just hitting the respective control-key combination
may be bound to an Emacs command. The relevant text from the
Emacs manual describes this much better than me:
Only printing characters and <SPC> insert themselves in
Emacs. Other characters act as editing commands and do not
insert themselves. These include control characters, and
characters with codes above 200 octal. If you need to insert
one of these characters in the buffer, you must "quote" it by
typing the character `Control-q' (`quoted-insert') first.
(This character's name is normally written `C-q' for short.)
There are two ways to use `C-q':
* `C-q' followed by any non-graphic character (even `C-g')
inserts that character.
* `C-q' followed by a sequence of octal digits inserts the
character with the specified octal character code. You
can use any number of octal digits; any non-digit
terminates the sequence. If the terminating character
is <RET>, it serves only to terminate the sequence. Any
other non-digit terminates the sequence and then acts as
normal input--thus, `C-q 1 0 1 B' inserts `AB'.
The use of octal sequences is disabled in ordinary
non-binary Overwrite mode, to give you a convenient way
to insert a digit instead of overwriting with it.
This is from section 8.1 (Inserting Text), of the Emacs 22 manual.
I hope this helps :-)
More information about the freebsd-questions