From kristo@bic.mni.mcgill.ca Thu May 2 20:28:49 1996 Received: from grumio.mni.mcgill.ca (grumio [132.206.178.18]) by bottom.bic.mni.mcgill.ca (8.7.5/8.7.3) with ESMTP id UAA07042 for ; Thu, 2 May 1996 20:28:48 -0400 (EDT) Received: (kristo@localhost) by grumio.mni.mcgill.ca (8.6.12/8.6.11) id UAA10430; Thu, 2 May 1996 20:28:42 -0400 Date: Thu, 2 May 1996 20:28:42 -0400 (EDT) From: Krzysztof KOLMAGA X-Sender: kristo@grumio To: Kate HANRATTY Subject: The emacs guru speaks!!! Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Status: RO Hello Kate I asked a friend of mine who is a guru about your problem with replacing newline characters in emacs. Now this is the wisdom he taught me: In emacs the stroke of ENTER key is interpreted as the *NEWLINE* character wich can also be simulated by Ctrl-J. This NEWLINE is not to be confused with the CARRIAGE RETURN (Ctrl-M) which is somehow different from the NEWLINE. Furthermore: To "quote" (i.e. escape ) a Ctrl-somekey combination in emacs you have to do Ctrl-Q. Example: You have the file: first line second line third line You do: Alt-X replace-string (ENTER) Emacs pormpts you: Replace string: You say: Ctrl-Q Ctrl-J (ENTER) Emacs says: Replace string ^J with: You type: , Ctrl-Q Ctrl-J (ENTER) Emacs shouts: Done The file now looks: first line, second line, third line, Anyhow that's it folks Cheers Chris