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: Re: String to Vector Date: Wed, 3 Feb 2010 18:07:14 +0000 Message-ID: <929ccd881002031007p7ef662b2i19f5cd0ecb6de561@mail.gmail.com> References: <929ccd881002030940k5eff17b2ke380cbd89d3fd058@mail.gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=001485f80e4495f4a3047eb6169f X-Trace: ger.gmane.org 1265220477 22230 80.91.229.12 (3 Feb 2010 18:07:57 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 3 Feb 2010 18:07:57 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: Lennart Borgman Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Feb 03 19:07:53 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 1Ncjdp-0008Uz-5z for geh-help-gnu-emacs@m.gmane.org; Wed, 03 Feb 2010 19:07:53 +0100 Original-Received: from localhost ([127.0.0.1]:37940 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ncjdo-0002W6-FA for geh-help-gnu-emacs@m.gmane.org; Wed, 03 Feb 2010 13:07:52 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NcjdL-0002V5-2Z for help-gnu-emacs@gnu.org; Wed, 03 Feb 2010 13:07:23 -0500 Original-Received: from [199.232.76.173] (port=46273 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NcjdJ-0002Ur-UY for help-gnu-emacs@gnu.org; Wed, 03 Feb 2010 13:07:21 -0500 Original-Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1NcjdJ-0006Hh-6R for help-gnu-emacs@gnu.org; Wed, 03 Feb 2010 13:07:21 -0500 Original-Received: from gv-out-0910.google.com ([216.239.58.189]:62369) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NcjdI-0006HZ-Bl for help-gnu-emacs@gnu.org; Wed, 03 Feb 2010 13:07:21 -0500 Original-Received: by gv-out-0910.google.com with SMTP id c17so76377gvd.17 for ; Wed, 03 Feb 2010 10:07:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type; bh=fYNtWmuQme0IDgvfG7htNb99rmX6cKILa/RBXzkXp3c=; b=LSqi8CDYWstMebvsPPi93hqbFUIjKn76Ec7K0xLMEGA1dVgew5w8OuxgliPyD7Gikp RkDD5E1ZceMiHVmtAUjKeiQkPGFK7r+BXmij497OhKyO7wIuji9GbEGTHntFSfgjOs+c TYFKEmoB6WVRZxNxo3vtANf6d0OBkS6vuxEV4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=Wgqj9VxcGsWBXdnJcC2TaNst4Ayy6fh9DnWz2fj71cCEu8ihiHJ6DlIhOARMEofND1 l1ocDGysjimoRhglWU8pocHSKHJaa9dInba/Piu+BiDVPk7oA7Bxy7rK6OxCgw626qsD oNfMgI+m77PzLKs3w/UAu+8lXNpuBIAUUxYXo= Original-Received: by 10.239.153.133 with SMTP id z5mr955991hbb.88.1265220434914; Wed, 03 Feb 2010 10:07:14 -0800 (PST) In-Reply-To: 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:71660 Archived-At: --001485f80e4495f4a3047eb6169f Content-Type: text/plain; charset=ISO-8859-1 In Emacs, it's all about finding the functions. Yes, Lennart that's the function I'm looking for. But can you execute the chain without concatenating the vectors? I would rather be able to do something like this: (progn (execute-kbd-macro (edmacro-parse-keys "M-x")) (execute-kbd-macro (edmacro-parse-keys "linum-mode")) (execute-kbd-macro (vector 'return))) I want the above to give me the same result as this: (execute-kbd-macro (vconcat (edmacro-parse-keys "M-x") (edmacro-parse-keys "linum-mode") (vector 'return))) On Wed, Feb 3, 2010 at 5:55 PM, Lennart Borgman wrote: > On Wed, Feb 3, 2010 at 6:40 PM, Johan Andersson > wrote: > > Hi, > > How can I convert for example the string: "M-x" to the vector: "[?\M-x]"? > > Is it something like this you are looking for: > > (edmacro-parse-keys "M-x") > --001485f80e4495f4a3047eb6169f Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
In Emacs, it's all about finding the functions. Yes, Lennart that&= #39;s the function I'm looking for.

But can yo= u execute the chain without concatenating the vectors? I would rather be ab= le to do something like this:
(progn
=A0=A0(execute-kbd-macro (edmacro-parse-keys "M-= x"))
=A0=A0(execute-kbd-macro (edmacro-parse-keys "linu= m-mode"))
=A0=A0(execute-kbd-macro (vector 'return)))

I want the above to give me the same result as this:
(execute-kbd-macro
=A0(vconcat
=A0=A0(edmacro-p= arse-keys "M-x")
=A0=A0(edmacro-parse-keys "linum-= mode")
=A0=A0(vector 'return)))

On Wed, Feb 3, 2010 at 5:55 PM, Lennart Borgman <lennart.borgman@gmail.com><= /span> wrote:
On Wed, Feb 3, 2010 at 6:= 40 PM, Johan Andersson <johan.= rejeep@gmail.com> wrote:
> Hi,
> How can I convert for example the string: "M-x" to the vecto= r: "[?\M-x]"?

Is it something like this you are looking for:

=A0 =A0(edmacro-parse-keys "M-x")

--001485f80e4495f4a3047eb6169f--