From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Yuri Khan Newsgroups: gmane.emacs.help Subject: Re: Regexp: match any character including newline Date: Wed, 16 Oct 2013 22:56:54 +0700 Message-ID: References: <525EB16D.90804@gmx.net> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1381939032 18582 80.91.229.3 (16 Oct 2013 15:57:12 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 16 Oct 2013 15:57:12 +0000 (UTC) Cc: "help-gnu-emacs@gnu.org" To: =?UTF-8?Q?Kai_Gro=C3=9Fjohann?= Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Oct 16 17:57:16 2013 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VWTTH-0003Lm-20 for geh-help-gnu-emacs@m.gmane.org; Wed, 16 Oct 2013 17:57:15 +0200 Original-Received: from localhost ([::1]:48041 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VWTTG-00064v-KG for geh-help-gnu-emacs@m.gmane.org; Wed, 16 Oct 2013 11:57:14 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:60379) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VWTT2-00064l-2U for help-gnu-emacs@gnu.org; Wed, 16 Oct 2013 11:57:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VWTSx-0002Ce-FY for help-gnu-emacs@gnu.org; Wed, 16 Oct 2013 11:57:00 -0400 Original-Received: from mail-qc0-x22c.google.com ([2607:f8b0:400d:c01::22c]:47919) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VWTSx-0002Ca-BL for help-gnu-emacs@gnu.org; Wed, 16 Oct 2013 11:56:55 -0400 Original-Received: by mail-qc0-f172.google.com with SMTP id c9so655695qcz.3 for ; Wed, 16 Oct 2013 08:56:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=YtZ0G/ZGxFGlxg4VxTzMhPxRYCOhU2G5JQsfkPeTlt4=; b=c3edjCWkQLLTFz80Iri+0thIJkzeTjnJSlIHjc4rKBkh24F5DhbUvFoquQWEllpNXg Cc1ERANGKPZlfpm5Vk06IlpAsdn/ThZaiBlhRO56DBC32H9SxcIzA6XzSTXnKHbhQBQz CIWcxo1PpTdC4mYZfERI3xtAi/rWMNhLq7opUh2y+tUuAB+uI/6MmfiQRVgsFTwK9FwY MDRrVjnAqzV3/in3C7MRjV0ybSP69K2Es9RkoCb+JegnKS7V41x0q+F1H/IN341Kqghi Psb3KcVPSChFUDAxd525vWDGpeUeo60I3YmN2iG0sMXgktUnwpjJ9oZwcexMOWgOAKwk S/Mw== X-Received: by 10.224.161.146 with SMTP id r18mr5626166qax.57.1381939014311; Wed, 16 Oct 2013 08:56:54 -0700 (PDT) Original-Received: by 10.96.2.167 with HTTP; Wed, 16 Oct 2013 08:56:54 -0700 (PDT) In-Reply-To: <525EB16D.90804@gmx.net> X-Google-Sender-Auth: DQ9BMaQBbjx6xUd2ikSr_ihD0DQ X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2607:f8b0:400d:c01::22c X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:94040 Archived-At: On Wed, Oct 16, 2013 at 10:31 PM, Kai Gro=C3=9Fjohann wrote: > You can use keyboard macros, but you will need a mode that understands > XML. Let's say you install nxml (it's part of Emacs I think). Let's > say the content is in a file foo.xml, so that nxml mode is turned on. > Consider that point is before the . Now you can use C-M-f to move > it before the . Now you can use C-M-n to move it after the closing > . Even if the content of ... contains tags! Good alternate approach. If only macros were as fast and responsive as regexp replace in my configuration=E2=80=A6 In my case, nesting is not a concern (as HTML tables almost never nest except for layouting, and even then it=E2=80=99s evil), so regexps are an adequate tool. > See? No regex anywhere. Way cool! Instead, you're exploiting the > navigation that you get from Emacs modes. This is way cool indeed, and I am in fact using nxml-mode and its navigation commands. However, this line of thought makes me wish for a match/replace language as concise as regexps and at least as powerful as XSLT :]