From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Peter Tury Newsgroups: gmane.emacs.help Subject: Re: removing spaces from a string Date: Wed, 19 Apr 2006 10:43:22 GMT Organization: Nokia Message-ID: <19il38twme189$.1ey704zs7hwp8$.dlg@40tude.net> References: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1145446842 1395 80.91.229.2 (19 Apr 2006 11:40:42 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 19 Apr 2006 11:40:42 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Apr 19 13:40:40 2006 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1FWB2x-0006QR-Ao for geh-help-gnu-emacs@m.gmane.org; Wed, 19 Apr 2006 13:40:35 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FWB2w-00077E-Dl for geh-help-gnu-emacs@m.gmane.org; Wed, 19 Apr 2006 07:40:34 -0400 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!news.tele.dk!news.tele.dk!small.news.tele.dk!newsfeed1.swip.net!swipnet!newsfeed1.funet.fi!newsfeeds.funet.fi!nntp.inet.fi!inet.fi!newsfeed1.nokia.com!news1.nokia.com!not-for-mail Original-Newsgroups: gnu.emacs.help User-Agent: 40tude_Dialog/2.0.15.1 Original-Lines: 31 Original-NNTP-Posting-Host: 172.24.170.105 Original-X-Complaints-To: newsmaster@nokia.com Original-X-Trace: news1.nokia.com 1145443402 172.24.170.105 (Wed, 19 Apr 2006 13:43:22 EET DST) Original-NNTP-Posting-Date: Wed, 19 Apr 2006 13:43:22 EET DST Original-Xref: shelby.stanford.edu gnu.emacs.help:138835 Original-To: help-gnu-emacs@gnu.org 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:34453 Archived-At: On Wed, 19 Apr 2006 12:01:21 +0200, LENNART BORGMAN wrote: > From: Peter Tury > Date: Wednesday, April 19, 2006 11:02 am > Subject: removing spaces from a string > >> Hi, >> >> how can I most simply remove all spaces from a string? I plan to >> have a >> variable what holds the string, so functions what operates on regions, >> rectangles or any parts of a buffer, etc. are not good (I guess). >> >> I would need something like this: (remove-all-space a-sting-var); >> if e.g. >> (setq a-string-var "abcd ef dg ") then this should return >> "abcdefdg" what >> I will pass forward to another function (namely: process-send-string). >> >> Thanks! >> P >> > > Maybe use replace-regexp-in-string? Thanks! I looked exactly for this one. Unfortunately I couldn't find it (using C-h a ..., and browsing the emacs and elisp manuals... -- now I see I should have used C-h d ...?) Thanks, P