From: "Eli Zaretskii" <eliz@is.elta.co.il>
Cc: bug-gnu-emacs@gnu.org
Subject: Re: user sees \xxx but is thwarted from searching for them
Date: Tue, 16 Apr 2002 15:32:11 +0300 [thread overview]
Message-ID: <7377-Tue16Apr2002153210+0300-eliz@is.elta.co.il> (raw)
In-Reply-To: <x5hembooxe.fsf@tupik.goethe.zz> (message from David Kastrup on 16 Apr 2002 13:36:45 +0200)
> From: David Kastrup <David.Kastrup@t-online.de>
> Newsgroups: gnu.emacs.bug
> Date: 16 Apr 2002 13:36:45 +0200
>
> eliz@is.elta.co.il (Eli Zaretskii) writes:
>
> > On 16 Apr 2002, Dan Jacobson wrote:
> >
> > > Anyway, the user sees a \. The user wants to hunt for a \. The user
> > > must have a Ph.D. to hunt for a \.
> >
> > Not really. `M-: (skip-chars-forward "\000-\177") RET' will do.
> > Wrapping this into a simple user command is left as an exercise for the
> > interested reader.
>
> That's exactly what Dan means by "must have a Ph.D.". It is easy, but
> non-obvious.
It's easy once you know what to do. To _know_ it might require
specific knowledge, but to _use_ it does not.
> We have regular expressions like [::ascii::] or so, perhaps something
> like [::encodable-in-the-current-default-encoding::]
> [::not-encodable-in-latin2::] (look for better names) would be a
> first shot at making things easier to wrap into user accessible
> functions.
This was discussed in preparation for Emacs 21.1, and turned out to be
a very complex job. The main problem is that, contrary to what users
may expect, Emacs does not actually know what characters prevent it to
encode the buffer in the default coding systems. The code which
implements this test (see the function select-safe-coding-system and
its subroutines) calls primitives that don't return this information.
Instead, they return a list of encodings that can safely encode all of
the characters in the region; Emacs then compares that list with the
list of default and preferred encodings, and if these two lists don't
intersect, it pops up the question.
Several alternatives were suggested to show the offending characters,
but IIRC they were all non-trivial. On top of that, all the effort to
implement that will go down the drain when Emacs switches to
Unicode-based internal representation of characters. And since
Handa-san, who does most of the Mule-related development, is currently
busy working on Unicode support... well, you can guess the rest.
prev parent reply other threads:[~2002-04-16 12:32 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-04-16 2:24 user sees \xxx but is thwarted from searching for them Dan Jacobson
2002-04-16 8:41 ` Eli Zaretskii
2002-04-16 10:55 ` Kai Großjohann
2002-04-16 11:57 ` Heinrich Rommerskirchen
2002-04-16 13:52 ` Kai Großjohann
2002-04-16 14:08 ` Eli Zaretskii
2002-04-16 14:41 ` Heinrich Rommerskirchen
2002-04-16 18:19 ` Eli Zaretskii
2002-04-16 12:21 ` Eli Zaretskii
2002-04-16 13:56 ` Kai Großjohann
2002-04-18 2:15 ` Dan Jacobson
2002-04-18 9:42 ` Kai Großjohann
2002-04-16 11:36 ` David Kastrup
2002-04-16 11:57 ` Kai Großjohann
2002-04-16 14:07 ` Eli Zaretskii
2002-04-16 12:32 ` Eli Zaretskii [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7377-Tue16Apr2002153210+0300-eliz@is.elta.co.il \
--to=eliz@is.elta.co.il \
--cc=bug-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).