[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
How to really escape a double quote?
From: |
MarkS. |
Subject: |
How to really escape a double quote? |
Date: |
Thu, 24 Feb 2011 15:54:43 -0800 (PST) |
User-agent: |
G2/1.0 |
This is a two part question, but both parts are looking for how to
escape a double quote AND have it work with Emacs.
I was looking for a way to make Emacs delete inside of delimiters the
way Vim does. I found some code that some nice person had written. The
key search line is like:
(skip-chars-backward "^(<[“") (setq p1 (point))
but there's no double quote, which is what I need most often. I looked
up Emacs/lisp documentation on-line, and it said that I could escape a
double-quote with a slash. So I tried changing the line to:
(skip-chars-backward "\"^(<[“") (setq p1 (point))
But when I run the code, it can't find the escaped double quote. It
seems to ignore it.
So, how do I get code like this to recognize an escaped quote mark?
The other part of the question is, how do I get a key mapping that
uses double quotes?
I tried
(global-set-key "\c-x\"" 'delete-stuff)
but this gave me all sorts of errors. However, if I activate global-
set-key interactively, I can set control-x " and it works to activate
the function. So there must be some way to make emacs recognize double
quotes in a key-mapping.
Thanks!