The following message is a courtesy copy of an article
that has been posted to comp.emacs.xemacs as well.
>>>> "Keith" == Keith Lancaster
<klancast(a)swbell.net> writes:
Keith> Adrian,
Keith> That works, but seems awfully awkword. Is it the case that
Hi Keith, that wasn't a workaround, it was just a demonstration.
Keith> you cannot do an interactive regex search
Keith> (query-replace-regexp) with a \t in it, i.e., something
Keith> like "foo\tbar"? Are you saying that "\t" is not
expanded
Keith> to a tab char when a regex is used interactively?
Yes.
xemacs-beta, is there a way to use character escape sequences ála \n,
\r, \t, in interactive regexp searches? I fear not. Why not?
Best regards,
Adrian
Keith> Keith
Keith> "Adrian Aichner" <adrian(a)xemacs.org> wrote in message
Keith> news:hetfh991.fsf@ecf.teradyne.com...
>>
>>>> "Keith" == Keith
Lancaster <klancast(a)swbell.net> writes:
>>
Keith> Interactively. I'm using 21.4 under Windows, byt the way.
Keith> Keith
>
> Hi Keith!
>
> Try
> M-: (re-search-forward "\t")
> at the begin of a buffer containing TABs.
>
> You'll find this to work.
>
> The lisp engine expands the \t in the string above to
> Char: ^I (011, 9, 0x9)
>
> When you search interactively, the expression you enter is not subject
> to this expansion.
>
> Hope this helps,
>
> Adrian
>
Keith> "Christian Nybø" <chr(a)nybo.no> wrote in message
Keith> news:873d4z7tta.fsf@siteloft.com...
> >> "Keith"
<Keith.Lancaster(a)scalablesoftware.com> writes:
> >>
> >> > According to the regex docs, I should be able to search for a tab
Keith> character
> >> > using '\t' in the regex, as I can in other
tools. The only way
Keith> I've
Keith> managed
> >> > to get it to work, however, is to use C-q followed
by hitting the
Keith> tab
Keith> key.
> >> > Why is this necessary, or am I missing something?
> >>
> >> Are you searching interactively, or are you evaluating lisp code?
> >> --
> >> chr
>
>
>
> --
> Adrian Aichner
> mailto:adrian@xemacs.org
>
http://www.xemacs.org/
--
Adrian Aichner
mailto:adrian@xemacs.org
http://www.xemacs.org/