GNU bug report logs -
#20522
25.0.50; `C-u C-x =' output, `to input' field
Previous Next
Reported by: Drew Adams <drew.adams <at> oracle.com>
Date: Thu, 7 May 2015 00:04:01 UTC
Severity: wishlist
Tags: patch
Found in version 25.0.50
Fixed in version 25.1
Done: Ivan Shmakov <ivan <at> siamics.net>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 20522 in the body.
You can then email your comments to 20522 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#20522
; Package
emacs
.
(Thu, 07 May 2015 00:04:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Drew Adams <drew.adams <at> oracle.com>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Thu, 07 May 2015 00:04:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
C-u C-x 8 RET GREEK CAPITAL LETTER PSI RET
C-b
C-u C-x =
Buffer *Help* says this, for field `to input':
type "C-x 8 RET HEX-CODEPOINT" or "C-x 8 RET NAME"
It should instead be able to say something like this:
type "C-x 8 RET 0x03A8" or "C-x 8 RET GREEK CAPITAL LETTER PSI"
Both of these pieces of information are shown in the same buffer
*Help*. It seems a bit silly to tell a user to type HEX-CODEPOINT or
NAME, when these are known when *Help* is created.
In GNU Emacs 25.0.50.1 (i686-pc-mingw32)
of 2014-10-20 on LEG570
Bzr revision: 118168 rgm <at> gnu.org-20141020195941-icp42t8ttcnud09g
Windowing system distributor `Microsoft Corp.', version 6.1.7601
Configured using:
`configure --enable-checking=yes,glyphs CPPFLAGS=-DGLYPH_DEBUG=1'
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#20522
; Package
emacs
.
(Thu, 07 May 2015 07:11:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 20522 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
tag 20522 + patch
tag 20519 + patch
thanks
>>>>> Drew Adams <drew.adams <at> oracle.com> writes:
> C-u C-x 8 RET GREEK CAPITAL LETTER PSI RET C-b C-u C-x =
> Buffer *Help* says this, for field `to input':
> type "C-x 8 RET HEX-CODEPOINT" or "C-x 8 RET NAME"
> It should instead be able to say something like this:
> type "C-x 8 RET 0x03A8" or "C-x 8 RET GREEK CAPITAL LETTER PSI"
> Both of these pieces of information are shown in the same buffer
> *Help*. It seems a bit silly to tell a user to type HEX-CODEPOINT or
> NAME, when these are known when *Help* is created.
Please consider the patch MIMEd.
* lisp/descr-text.el (describe-char): Show the exact C-x 8 RET
invocation instead of a template. (Bug#20522)
[…]
--
FSF associate member #7257 np. Danger Zone — Rainbow … 3013 B6A0 230E 334A
[Message part 2 (text/diff, inline)]
--- a/lisp/descr-text.el
+++ b/lisp/descr-text.el
@@ -618,7 +618,9 @@ defun describe-char (pos &optional buffer)
'help-args '(,current-input-method))
"input method")
(list
- "type \"C-x 8 RET HEX-CODEPOINT\" or \"C-x 8 RET NAME\"")))))
+ (format
+ "type \"C-x 8 RET %04x\" or \"C-x 8 RET %s\""
+ char (get-char-code-property char 'name)))))))
("buffer code"
,(if multibyte-p
(encoded-string-description
Added tag(s) patch.
Request was from
Ivan Shmakov <ivan <at> siamics.net>
to
control <at> debbugs.gnu.org
.
(Thu, 07 May 2015 07:11:03 GMT)
Full text and
rfc822 format available.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#20522
; Package
emacs
.
(Thu, 07 May 2015 14:46:02 GMT)
Full text and
rfc822 format available.
Message #13 received at 20522 <at> debbugs.gnu.org (full text, mbox):
> From: Ivan Shmakov <ivan <at> siamics.net>
> Date: Thu, 07 May 2015 07:10:23 +0000
>
> --- a/lisp/descr-text.el
> +++ b/lisp/descr-text.el
> @@ -618,7 +618,9 @@ defun describe-char (pos &optional buffer)
> 'help-args '(,current-input-method))
> "input method")
> (list
> - "type \"C-x 8 RET HEX-CODEPOINT\" or \"C-x 8 RET
> NAME\"")))))
> + (format
> + "type \"C-x 8 RET %04x\" or \"C-x 8 RET %s\""
^^^^
I see no need to tell users to type at least 4 hex digits: "C-x 8 RET"
accepts even one digit. So I think we should use %x here.
> + char (get-char-code-property char 'name)))))))
Not every Unicode codepoint has a name, so get-char-code-property
could return nil. E.g., try with any codepoint between zero and #x1f,
inclusive. When that happens, we should try 'old-name' instead, and
if that returns nil as well (try #x99, for example), I think the "by
name" part should be omitted from the output of describe-char.
Thanks.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#20522
; Package
emacs
.
(Thu, 07 May 2015 15:16:02 GMT)
Full text and
rfc822 format available.
Message #16 received at 20522 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
>>>>> Eli Zaretskii <eliz <at> gnu.org> writes:
>>>>> From: Ivan Shmakov Date: Thu, 07 May 2015 07:10:23 +0000
>> + (format
>> + "type \"C-x 8 RET %04x\" or \"C-x 8 RET %s\""
> ^^^^ I see no need to tell users to type at
> least 4 hex digits: "C-x 8 RET" accepts even one digit. So I think
> we should use %x here.
>> + char (get-char-code-property char 'name)))))))
> Not every Unicode codepoint has a name, so get-char-code-property
> could return nil. E. g., try with any codepoint between zero and
> #x1f, inclusive. When that happens, we should try 'old-name'
> instead, and if that returns nil as well (try #x99, for example), I
> think the "by name" part should be omitted from the output of
> describe-char.
(I’ve suspected something like that, but didn’t check.)
Please consider the revised patch MIMEd.
* lisp/descr-text.el (describe-char): Show the exact C-x 8 RET
invocation instead of a template. (Bug#20522)
It was also requested in bug#20499 that a specific C-x 8
(iso-transl) sequence is shown. Yet I believe that deserves a
separate patch.
--
FSF associate member #7257 http://am-1.org/~ivan/ … 3013 B6A0 230E 334A
[Message part 2 (text/diff, inline)]
--- a/lisp/descr-text.el
+++ b/lisp/descr-text.el
@@ -618,7 +618,14 @@ defun describe-char (pos &optional buffer)
'help-args '(,current-input-method))
"input method")
(list
- "type \"C-x 8 RET HEX-CODEPOINT\" or \"C-x 8 RET NAME\"")))))
+ (let ((name
+ (or (get-char-code-property char 'name)
+ (get-char-code-property char 'old-name))))
+ (if name
+ (format
+ "type \"C-x 8 RET %x\" or \"C-x 8 RET %s\""
+ char name)
+ (format "type \"C-x 8 RET %x\"" char))))))))
("buffer code"
,(if multibyte-p
(encoded-string-description
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#20522
; Package
emacs
.
(Thu, 07 May 2015 15:38:02 GMT)
Full text and
rfc822 format available.
Message #19 received at 20522 <at> debbugs.gnu.org (full text, mbox):
> From: Ivan Shmakov <ivan <at> siamics.net>
> Date: Thu, 07 May 2015 15:15:32 +0000
>
> Please consider the revised patch MIMEd.
>
> * lisp/descr-text.el (describe-char): Show the exact C-x 8 RET
> invocation instead of a template. (Bug#20522)
>
> It was also requested in bug#20499 that a specific C-x 8
> (iso-transl) sequence is shown. Yet I believe that deserves a
> separate patch.
>
> --
> FSF associate member #7257 http://am-1.org/~ivan/ … 3013 B6A0 230E 334A
>
> [2:text/diff Hide]
>
> --- a/lisp/descr-text.el
> +++ b/lisp/descr-text.el
> @@ -618,7 +618,14 @@ defun describe-char (pos &optional buffer)
> 'help-args '(,current-input-method))
> "input method")
> (list
> - "type \"C-x 8 RET HEX-CODEPOINT\" or \"C-x 8 RET NAME\"")))))
> + (let ((name
> + (or (get-char-code-property char 'name)
> + (get-char-code-property char 'old-name))))
> + (if name
> + (format
> + "type \"C-x 8 RET %x\" or \"C-x 8 RET %s\""
> + char name)
> + (format "type \"C-x 8 RET %x\"" char))))))))
> ("buffer code"
> ,(if multibyte-p
> (encoded-string-description
LGTM, thanks.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#20522
; Package
emacs
.
(Thu, 07 May 2015 15:57:02 GMT)
Full text and
rfc822 format available.
Message #22 received at 20522 <at> debbugs.gnu.org (full text, mbox):
> > C-u C-x 8 RET GREEK CAPITAL LETTER PSI RET C-b C-u C-x =
> > Buffer *Help* says this, for field `to input':
> > type "C-x 8 RET HEX-CODEPOINT" or "C-x 8 RET NAME"
> > It should instead be able to say something like this:
> > type "C-x 8 RET 0x03A8" or "C-x 8 RET GREEK CAPITAL LETTER PSI"
>
> > Both of these pieces of information are shown in the same buffer
> > *Help*. It seems a bit silly to tell a user to type HEX-
> > CODEPOINT or NAME, when these are known when *Help* is created.
>
> Please consider the patch MIMEd.
> * lisp/descr-text.el (describe-char): Show the exact C-x 8
> RET invocation instead of a template. (Bug#20522)
Looks good; thanks.
Reply sent
to
Ivan Shmakov <ivan <at> siamics.net>
:
You have taken responsibility.
(Wed, 27 May 2015 22:31:07 GMT)
Full text and
rfc822 format available.
Notification sent
to
Drew Adams <drew.adams <at> oracle.com>
:
bug acknowledged by developer.
(Wed, 27 May 2015 22:31:09 GMT)
Full text and
rfc822 format available.
Message #27 received at 20522-done <at> debbugs.gnu.org (full text, mbox):
Version: 25.1
>>>>> Eli Zaretskii <eliz <at> gnu.org> writes:
>>>>> From: Ivan Shmakov Date: Thu, 07 May 2015 15:15:32 +0000
>> Please consider the revised patch MIMEd.
>> * lisp/descr-text.el (describe-char): Show the exact C-x 8 RET
>> invocation instead of a template. (Bug#20522)
[…]
> LGTM, thanks.
Pushed, closing.
commit 21b81bd8c51cf48e08089087a17f66eb70625748
Date: 2015-05-27 22:14:57 +0000
Show the exact C-x 8 RET invocation in describe-char.
* lisp/descr-text.el (describe-char): Show the exact C-x 8 RET
invocation instead of a template. (Bug#20522)
--
FSF associate member #7257 http://am-1.org/~ivan/ … 3013 B6A0 230E 334A
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Thu, 25 Jun 2015 11:24:05 GMT)
Full text and
rfc822 format available.
This bug report was last modified 9 years and 363 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.