GNU bug report logs - #51961
image-mode: advertize viewing an image as hex less eagerly

Previous Next

Package: emacs;

Reported by: Stefan Kangas <stefan <at> marxist.se>

Date: Fri, 19 Nov 2021 03:39:01 UTC

Severity: minor

Fixed in version 29.1

Done: Stefan Kangas <stefan <at> marxist.se>

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 51961 in the body.
You can then email your comments to 51961 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#51961; Package emacs. (Fri, 19 Nov 2021 03:39:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Stefan Kangas <stefan <at> marxist.se>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Fri, 19 Nov 2021 03:39:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: bug-gnu-emacs <at> gnu.org
Subject: image-mode: advertize viewing an image as hex less eagerly
Date: Fri, 19 Nov 2021 04:38:10 +0100
Severity: minor

This is a usability bug:

I don't think image mode should advertize it's capability to view an
image as hex in a message every time it is enabled:

    Type C-c C-c or C-c C-x to view the image as text or hex

Editing the hex or "text" of something like a JPEG does not strike me as
something most people will be able to do usefully by hand.  For bitmap
formats maybe, but even then, won't people just use an image editor?

And for those users that do know what bits to flip, can't we expect them
to be able to figure out that Emacs has a command to quickly flip to the
built-in hex editor or to "text mode"?  For example by reading the mode
help?  IOW, I think this message confuses more than it helps (but see
the final paragraph below).

Why not advertize some useful commands instead, like "Press h for help",
or "Use + and - to scale up and down"?

Or, even better perhaps, just say nothing?  It's already all there in
`describe-mode', right?

There is a minority of image types where it is obviously useful,
i.e. XPM and similar formats where the image is actually just a plain
text file.  I think we could consider keeping the message for those.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#51961; Package emacs. (Fri, 19 Nov 2021 07:17:02 GMT) Full text and rfc822 format available.

Message #8 received at 51961 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Stefan Kangas <stefan <at> marxist.se>
Cc: 51961 <at> debbugs.gnu.org
Subject: Re: bug#51961: image-mode: advertize viewing an image as hex less
 eagerly
Date: Fri, 19 Nov 2021 09:16:12 +0200
> From: Stefan Kangas <stefan <at> marxist.se>
> Date: Fri, 19 Nov 2021 04:38:10 +0100
> 
> There is a minority of image types where it is obviously useful,
> i.e. XPM and similar formats where the image is actually just a plain
> text file.  I think we could consider keeping the message for those.

SVG is the prominent example of those where there's a significant
ambiguity in the user's intent.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#51961; Package emacs. (Fri, 19 Nov 2021 07:33:01 GMT) Full text and rfc822 format available.

Message #11 received at 51961 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 51961 <at> debbugs.gnu.org, Stefan Kangas <stefan <at> marxist.se>
Subject: Re: bug#51961: image-mode: advertize viewing an image as hex less
 eagerly
Date: Fri, 19 Nov 2021 08:32:49 +0100
Eli Zaretskii <eliz <at> gnu.org> writes:

>> There is a minority of image types where it is obviously useful,
>> i.e. XPM and similar formats where the image is actually just a plain
>> text file.  I think we could consider keeping the message for those.
>
> SVG is the prominent example of those where there's a significant
> ambiguity in the user's intent.

Yup.  I think we should keep the message for SVG and XPM and ditch if
for everything else.  (If there's more of these formats, we can add them
back.  Perhaps make a defcustom to allow tweaking?)

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#51961; Package emacs. (Fri, 19 Nov 2021 08:00:01 GMT) Full text and rfc822 format available.

Message #14 received at 51961 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 51961 <at> debbugs.gnu.org
Subject: Re: bug#51961: image-mode: advertize viewing an image as hex less
 eagerly
Date: Fri, 19 Nov 2021 08:59:33 +0100
Eli Zaretskii <eliz <at> gnu.org> writes:

> SVG is the prominent example of those where there's a significant
> ambiguity in the user's intent.

Ah, but of course.  I forgot about the most important one!

Given my recent experience in working with SVG files, I'd say we would
do well to keep a message for such files.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#51961; Package emacs. (Fri, 19 Nov 2021 08:40:04 GMT) Full text and rfc822 format available.

Message #17 received at 51961 <at> debbugs.gnu.org (full text, mbox):

From: Juri Linkov <juri <at> linkov.net>
To: Stefan Kangas <stefan <at> marxist.se>
Cc: 51961 <at> debbugs.gnu.org
Subject: Re: bug#51961: image-mode: advertize viewing an image as hex less
 eagerly
Date: Fri, 19 Nov 2021 10:25:15 +0200
> There is a minority of image types where it is obviously useful,
> i.e. XPM and similar formats where the image is actually just a plain
> text file.  I think we could consider keeping the message for those.

I agree that this message should be displayed only for modes
where `(major-mode-restore '(image-mode image-mode-as-text))'
in `image-mode-to-text' doesn't change mode to 'fundamental-mode'
or 'so-long-mode'.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#51961; Package emacs. (Fri, 03 Dec 2021 14:58:02 GMT) Full text and rfc822 format available.

Message #20 received at 51961 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: Eli Zaretskii <eliz <at> gnu.org>, 51961 <at> debbugs.gnu.org
Subject: Re: bug#51961: image-mode: advertize viewing an image as hex less
 eagerly
Date: Fri, 3 Dec 2021 06:56:54 -0800
close 51961 29.1
thanks

> Yup.  I think we should keep the message for SVG and XPM and ditch if
> for everything else.  (If there's more of these formats, we can add them
> back.  Perhaps make a defcustom to allow tweaking?)

Now done on master (commit 8fda6770af).

Thanks to everyone who contributed to the discussion.




bug marked as fixed in version 29.1, send any further explanations to 51961 <at> debbugs.gnu.org and Stefan Kangas <stefan <at> marxist.se> Request was from Stefan Kangas <stefan <at> marxist.se> to control <at> debbugs.gnu.org. (Fri, 03 Dec 2021 14:58:02 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sat, 01 Jan 2022 12:24:08 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 116 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.