[Top][All Lists]

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

Re: user sees \xxx but is thwarted from searching for them

From: Kai Großjohann
Subject: Re: user sees \xxx but is thwarted from searching for them
Date: Tue, 16 Apr 2002 15:56:03 +0200
User-agent: Gnus/5.090006 (Oort Gnus v0.06) Emacs/21.2.50 (i686-pc-linux-gnu)

"Eli Zaretskii" <address@hidden> writes:

>> From: address@hidden (Kai =?iso-8859-1?q?Gro=DFjohann?=)
>> Newsgroups: gnu.emacs.bug
>> Date: Tue, 16 Apr 2002 12:55:12 +0200
>> address@hidden (Eli Zaretskii) writes:
>> > `M-: (skip-chars-forward "\000-\177") RET' will do.  
>> This command finds , too, even if it is displayed without \ on
>> screen.  I presume it will also find a lot of other nonascii
>> characters.
> More accurately, if finds _any_ non-ASCII character.  That's what it
> is supposed to do.

Let me cite again from Dan's original posting:

| "Deep in my file there is some binary character[s] that are messing up
| my life.  I must page thru the whole file looking around for their
| \xxx butts, as emacs won't just let me do C-s \, which would find them
| right away, if what we see is what we search."  Istead, emacs probably
| wants me to do things a complicated way, doing C-s C-q followed by the
| exact character, which I don't know until I've seen it, or emacs
| probably wants me to specify a range in a regular expression, which
| would be "all the characters that still cause a \xxx on the screen
| even when in when in some Chinese mode etc. that encompasses most of
| them..."

In the last sentence, he mentions Chinese.  This means that he
doesn't want to find Chinese characters.

He only wants to find characters which are displayed as \xxx.

>> Suppose you have a file which is mostly in the foo encoding, but
>> contains some bytes that are invalid in that encoding.  I think this
>> is the situation Dan is talking about.  He wants to find the invalid
>> bytes, IIUC.
> Perhaps I don't understand the original request, but if I do, it is
> very hard to do that (AFAIK) without knowing what--i.e. which
> character sets--are you looking for.

Hm, yes.

Maybe Dan should say how did the \xxx things get into the buffer in
the first place.  For example, maybe Dan said C-x RET c foo RET C-x
C-f /tmp/somefile RET.  Further suppose that /tmp/somefile contains
byte sequences not valid in the foo coding.

Then it is clear that Dan wants to search for buffer parts that
aren't in (representable) in the foo coding.  Right?


> Recall that, once the file is visited by a buffer, there are no
> bytes, just characters.  What you want is to find characters that
> don't belong to some set of characters, without actually telling
> Emacs what are those ``good'' sets.

Maybe Dan knows what are the good sets.

Silence is foo!

reply via email to

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