help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Is buffer size fixed in batch mode?


From: David Kastrup
Subject: Re: Is buffer size fixed in batch mode?
Date: Wed, 07 Dec 2005 10:39:55 +0100
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux)

Brian Elmegaard <brian@rkspeed-rugby.dk> writes:

> bojohan+news@dd.chalmers.se (Johan Bockgård) writes:
>
>> It depends on the function. Maybe you could tell us in more details
>> what you are trying to do?
>
> I have auto-generated xml and I want to convert it to latex, so I do
> (goto-char 1) 
> and a lot of 
> (save-excursion
>   (while (search-forward "<foo>" nil t)
>     (replace-match "\\foo[bar]{baz}" nil t))
>   )
>
> (save-excursion
>   (while (re-search-forward "<foobar>\\(.*\\)</foobar>" nil t)
>     (replace-match "\\\\foobar{\\1}" nil nil))
>   )
>
> At the end I did several replaces of multiple spaces, end of line
> spaces, and so on.
>
> If I open the xml in a running emacs it works fine, but if I did it
> with a batch it part of the tex disappeared in the output. 
>
> The I decided to move the cleanup of multiple spaces and so on to the
> beginning of the code and it runs fine.
>
> Is this to be expected?

You likely did something wrong.

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum


reply via email to

[Prev in Thread] Current Thread [Next in Thread]