From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Johan Andersson Newsgroups: gmane.emacs.help Subject: String to Vector Date: Wed, 3 Feb 2010 17:40:27 +0000 Message-ID: <929ccd881002030940k5eff17b2ke380cbd89d3fd058@mail.gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=001485f63198c38034047eb5b665 X-Trace: ger.gmane.org 1265218984 16422 80.91.229.12 (3 Feb 2010 17:43:04 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 3 Feb 2010 17:43:04 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Feb 03 18:43:00 2010 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1NcjFj-0004Kx-Sm for geh-help-gnu-emacs@m.gmane.org; Wed, 03 Feb 2010 18:43:00 +0100 Original-Received: from localhost ([127.0.0.1]:46948 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NcjFj-0002DD-CZ for geh-help-gnu-emacs@m.gmane.org; Wed, 03 Feb 2010 12:42:59 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NcjDL-00013H-3F for help-gnu-emacs@gnu.org; Wed, 03 Feb 2010 12:40:31 -0500 Original-Received: from [199.232.76.173] (port=53107 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NcjDK-00012d-FF for help-gnu-emacs@gnu.org; Wed, 03 Feb 2010 12:40:30 -0500 Original-Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1NcjDJ-0002vI-OO for help-gnu-emacs@gnu.org; Wed, 03 Feb 2010 12:40:30 -0500 Original-Received: from mail-bw0-f219.google.com ([209.85.218.219]:35959) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NcjDJ-0002uu-Aw for help-gnu-emacs@gnu.org; Wed, 03 Feb 2010 12:40:29 -0500 Original-Received: by bwz19 with SMTP id 19so250665bwz.8 for ; Wed, 03 Feb 2010 09:40:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:date:message-id:subject :from:to:content-type; bh=x77uVGuJJ2v4Hai5QgWLvSrHSsF1FUNbC4PU3HPpEsc=; b=oAu/8Nlun0tm7iETvJIFCeVWpe/fPdOkpKK9LVW+hrTKtKVwbtyRPsOZ8Zs6RX48NE PchsNhZ+rkzj0OUDrmSpnGh6Csad23172YxwGpMQu3VM2IuFeNSUX+JfHC/Co5O95gvG vNuEZoTho512fbK55DGmCkZ9hPQgm7/D9j4n8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=V3CVz4Luzffae5gQIJs7RHRW2fSbK/U/CEyrIERM3zzRSRxjhYeqgzOOs7/vC6N0iK HmtDX5IVEF+LhjiiddE2IWEm+QfquHzgNn7hi4depMRbK5aHxF32h3fSR7RaDbnaTUod 88pLKVe6RQzaWDk14ROqGH8S7MPHgBCuYxzGE= Original-Received: by 10.239.184.9 with SMTP id w9mr112899hbg.120.1265218827288; Wed, 03 Feb 2010 09:40:27 -0800 (PST) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:71656 Archived-At: --001485f63198c38034047eb5b665 Content-Type: text/plain; charset=ISO-8859-1 Hi, How can I convert for example the string: "M-x" to the vector: "[?\M-x]"? (string-to-vector "M-x") will not give me the correct vector. I will give me the vector for each part of the string. I want to do something like this: (execute-kbd-macro (vconcat (string-to-vector "M-x ") (string-to-vector "linum-mode ") (vector 'return))) --001485f63198c38034047eb5b665 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Hi,

How can I convert for example the string:= "M-x" to the vector: "[?\M-x]"?

(string-to-vector "M-x") will not give me the correct vector. = I will give me the vector for each part of the string.

I want to do something like this:
(execute-kb= d-macro
=A0(vconcat
=A0=A0(string-to-vector "M-x &= quot;)
=A0=A0(string-to-vector "linum-mode ")
=A0=A0(vector 'return))) --001485f63198c38034047eb5b665--