[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Then how to replace all my $$ ... $$ to \[ \] through search and rep
From: |
Thierry Volpiatto |
Subject: |
Re: Then how to replace all my $$ ... $$ to \[ \] through search and replace? |
Date: |
Fri, 15 Aug 2008 11:08:02 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) |
Ralf Angeli <dev.null@caeruleus.net> writes:
> * Tassilo Horn (2008-08-15) writes:
>
>> "xiaopeng hu" <huxiaopengstat@gmail.com> writes:
>>
>>> Then how to replace all my $$ ... $$ to \[ \] through search and
>>> replace? Thanks
>>
>> M-x query-replace-regexp RET \$\$\(.+\)\$\$ RET \\[\1\\] RET
>
> This won't work because `.' does not match a newline. Using `[^$]'
> instead should do it.
Just a note about re-builder and regex-tool:
To build a regex to use in a program or with query-replace-regexp, you
can use one of these tools, however, re-builder will build a regex to
use in a program and this regex will not work in query-replace-regexp.
Regex-tool will build a regex more usable with query-replace-regexp.
[0-9]\\{2\\} ==> work in a program but not in query-replace
[0-9]\{2\} ==> work in query-replace but not in a program
--
A + Thierry Volpiatto
Location: Saint-Cyr-Sur-Mer - France
- Then how to replace all my $$ ... $$ to \[ \] through search and replace?, xiaopeng hu, 2008/08/15
- Re: Then how to replace all my $$ ... $$ to \[ \] through search and replace?, Tassilo Horn, 2008/08/15
- Message not available
- Re: Then how to replace all my $$ ... $$ to \[ \] through search and replace?, Ralf Angeli, 2008/08/15
- Re: Then how to replace all my $$ ... $$ to \[ \] through search and replace?, Tassilo Horn, 2008/08/15
- Re: Then how to replace all my $$ ... $$ to \[ \] through search and replace?,
Thierry Volpiatto <=
- Message not available
- Re: Then how to replace all my $$ ... $$ to \[ \] through search and replace?, Phil Carmody, 2008/08/15
- Re: Then how to replace all my $$ ... $$ to \[ \] through search and replace?, Ralf Angeli, 2008/08/15
- Re: Then how to replace all my $$ ... $$ to \[ \] through search and replace?, Reiner Steib, 2008/08/15
- Re: Then how to replace all my $$ ... $$ to \[ \] through search and replace?, Nikos Apostolakis, 2008/08/15
- Re: Then how to replace all my $$ ... $$ to \[ \] through search and replace?, Reiner Steib, 2008/08/16
- Re: Then how to replace all my $$ ... $$ to \[ \] through search and replace?, harven, 2008/08/16
- Re: Then how to replace all my $$ ... $$ to \[ \] through search and replace?, Reiner Steib, 2008/08/16