GNU bug report logs - #73727
dired-view-file vs. emacs -nw

Previous Next

Package: emacs;

Reported by: Dan Jacobson <jidanni <at> jidanni.org>

Date: Thu, 10 Oct 2024 10:43:01 UTC

Severity: wishlist

Tags: notabug, wontfix

Done: Eli Zaretskii <eliz <at> gnu.org>

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 73727 in the body.
You can then email your comments to 73727 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#73727; Package emacs. (Thu, 10 Oct 2024 10:43:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Dan Jacobson <jidanni <at> jidanni.org>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Thu, 10 Oct 2024 10:43:02 GMT) Full text and rfc822 format available.

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

From: Dan Jacobson <jidanni <at> jidanni.org>
To: bug-gnu-emacs <at> gnu.org
Subject: dired-view-file vs. emacs -nw
Date: Thu, 10 Oct 2024 18:41:48 +0800
v runs the command dired-view-file which works great even on images etc.
except when the user is using emacs -nw, in which case it just spews the
a lot of binary stuff on the screen which the user was not expecting.
Therefore it should say "xyz.jpg cannot be shown properly on your
terminal." (If they really want to see the bytes, they can use
find-file.)




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#73727; Package emacs. (Thu, 10 Oct 2024 11:30:02 GMT) Full text and rfc822 format available.

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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Dan Jacobson <jidanni <at> jidanni.org>
Cc: 73727 <at> debbugs.gnu.org
Subject: Re: bug#73727: dired-view-file vs. emacs -nw
Date: Thu, 10 Oct 2024 14:29:00 +0300
tags 73727 notabug wontfix
thanks

> From: Dan Jacobson <jidanni <at> jidanni.org>
> Date: Thu, 10 Oct 2024 18:41:48 +0800
> 
> v runs the command dired-view-file which works great even on images etc.
> except when the user is using emacs -nw, in which case it just spews the
> a lot of binary stuff on the screen which the user was not expecting.
> Therefore it should say "xyz.jpg cannot be shown properly on your
> terminal." (If they really want to see the bytes, they can use
> find-file.)

That's not the Emacs way.  Emacs allows users to visit any kind of
files, including those which display as binary garbage.  Moreover,
even on GUI frames, users can customize Emacs to never show image
files as images when they are visited.  Refusing to visit an image
file just because it cannot be displayed as an image is something
Emacs never did and should not do.

dired-view-file's doc string says:

  In Dired, examine a file in view mode, returning to Dired when done.
  When file is a directory, show it in this buffer if it is inserted.
  Otherwise, display it in another buffer.

There's nothing here about showing image files as images or not at
all.  Perhaps you were confused by the "view" part, but that refers to
view-mode, not to "viewing" an image.

So I don't see any bugs here, and don't think we should "fix" anything
in this matter.




Added tag(s) notabug and wontfix. Request was from Eli Zaretskii <eliz <at> gnu.org> to control <at> debbugs.gnu.org. (Thu, 10 Oct 2024 11:30:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#73727; Package emacs. (Fri, 11 Oct 2024 08:17:01 GMT) Full text and rfc822 format available.

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

From: Dan Jacobson <jidanni <at> jidanni.org>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 73727 <at> debbugs.gnu.org
Subject: Re: bug#73727: dired-view-file vs. emacs -nw
Date: Fri, 11 Oct 2024 16:16:22 +0800
All I know is a couple more erroneous keystroks, and one ends up
accidentally editing one of these files, with its regexp parser choking
long lines... might end up using all the CPU...




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#73727; Package emacs. (Fri, 11 Oct 2024 09:29:02 GMT) Full text and rfc822 format available.

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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Dan Jacobson <jidanni <at> jidanni.org>
Cc: 73727 <at> debbugs.gnu.org
Subject: Re: bug#73727: dired-view-file vs. emacs -nw
Date: Fri, 11 Oct 2024 12:28:14 +0300
> From: Dan Jacobson <jidanni <at> jidanni.org>
> Cc: 73727 <at> debbugs.gnu.org
> Date: Fri, 11 Oct 2024 16:16:22 +0800
> 
> All I know is a couple more erroneous keystroks, and one ends up
> accidentally editing one of these files, with its regexp parser choking
> long lines... might end up using all the CPU...

dired-view-file visits the file in read-only mode, so you are not
supposed to edit it unless you really mean to...

IOW, it sounds like there was some cockpit error in your case, and you
somehow decided that it's Emacs's fault.  It isn't.




Severity set to 'wishlist' from 'normal' Request was from Stefan Kangas <stefankangas <at> gmail.com> to control <at> debbugs.gnu.org. (Sat, 12 Oct 2024 14:11:03 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#73727; Package emacs. (Fri, 25 Oct 2024 22:07:02 GMT) Full text and rfc822 format available.

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

From: Dan Jacobson <jidanni <at> jidanni.org>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 73727 <at> debbugs.gnu.org
Subject: Re: bug#73727: dired-view-file vs. emacs -nw
Date: Sat, 26 Oct 2024 06:05:29 +0800
>>>>> "EZ" == Eli Zaretskii <eliz <at> gnu.org> writes:
EZ> dired-view-file visits the file in read-only mode, so you are not
EZ> supposed to edit it unless you really mean to...

(Actually there are tons of keys that will, if held down a little too
long, end up inserting characters into the top of JPGs:

RET		dired-find-file
e .. f		dired-find-file
o		dired-find-file-other-window

Yes, users should then use "undo".)




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#73727; Package emacs. (Sat, 26 Oct 2024 07:06:02 GMT) Full text and rfc822 format available.

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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Dan Jacobson <jidanni <at> jidanni.org>
Cc: 73727 <at> debbugs.gnu.org
Subject: Re: bug#73727: dired-view-file vs. emacs -nw
Date: Sat, 26 Oct 2024 10:04:47 +0300
> From: Dan Jacobson <jidanni <at> jidanni.org>
> Cc: 73727 <at> debbugs.gnu.org
> Date: Sat, 26 Oct 2024 06:05:29 +0800
> 
> >>>>> "EZ" == Eli Zaretskii <eliz <at> gnu.org> writes:
> EZ> dired-view-file visits the file in read-only mode, so you are not
> EZ> supposed to edit it unless you really mean to...
> 
> (Actually there are tons of keys that will, if held down a little too
> long, end up inserting characters into the top of JPGs:
> 
> RET		dired-find-file
> e .. f		dired-find-file
> o		dired-find-file-other-window
> 
> Yes, users should then use "undo".)

I don't see how this changes what I already told above.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#73727; Package emacs. (Sat, 26 Oct 2024 08:59:02 GMT) Full text and rfc822 format available.

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

From: Dan Jacobson <jidanni <at> jidanni.org>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 73727 <at> debbugs.gnu.org
Subject: Re: bug#73727: dired-view-file vs. emacs -nw
Date: Sat, 26 Oct 2024 16:57:44 +0800
>>>>> "EZ" == Eli Zaretskii <eliz <at> gnu.org> writes:
EZ> I don't see how this changes what I already told above.

If you used emacs -nw exclusively for two months, like I have, you would
notice even more problems.

E.g., every time the user opens an image file by accident,
they will see, along with the binary mess,
"File mode specification error: (error Display does not support images)"
It would be better to warn them
"emacs -nw has no image support.  Use find-file-literally if you really want to edit this image."
and not open the file.

What's worse is view-mode doesn't even have a warning. Sure, it is
tailored for the 1% of users who really are using emacs -nw to view the
guts of JPGs.





Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#73727; Package emacs. (Sat, 26 Oct 2024 13:32:01 GMT) Full text and rfc822 format available.

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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Dan Jacobson <jidanni <at> jidanni.org>
Cc: 73727 <at> debbugs.gnu.org
Subject: Re: bug#73727: dired-view-file vs. emacs -nw
Date: Sat, 26 Oct 2024 16:30:47 +0300
> From: Dan Jacobson <jidanni <at> jidanni.org>
> Cc: 73727 <at> debbugs.gnu.org
> Date: Sat, 26 Oct 2024 16:57:44 +0800
> 
> >>>>> "EZ" == Eli Zaretskii <eliz <at> gnu.org> writes:
> EZ> I don't see how this changes what I already told above.
> 
> If you used emacs -nw exclusively for two months, like I have, you would
> notice even more problems.

I'm using "emacs -nw" all the time.  As are others.




Reply sent to Eli Zaretskii <eliz <at> gnu.org>:
You have taken responsibility. (Sun, 27 Oct 2024 10:18:02 GMT) Full text and rfc822 format available.

Notification sent to Dan Jacobson <jidanni <at> jidanni.org>:
bug acknowledged by developer. (Sun, 27 Oct 2024 10:18:02 GMT) Full text and rfc822 format available.

Message #35 received at 73727-done <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: jidanni <at> jidanni.org
Cc: 73727-done <at> debbugs.gnu.org
Subject: Re: bug#73727: dired-view-file vs. emacs -nw
Date: Sun, 27 Oct 2024 12:16:51 +0200
> Cc: 73727 <at> debbugs.gnu.org
> Date: Fri, 11 Oct 2024 12:28:14 +0300
> From: Eli Zaretskii <eliz <at> gnu.org>
> 
> > From: Dan Jacobson <jidanni <at> jidanni.org>
> > Cc: 73727 <at> debbugs.gnu.org
> > Date: Fri, 11 Oct 2024 16:16:22 +0800
> > 
> > All I know is a couple more erroneous keystroks, and one ends up
> > accidentally editing one of these files, with its regexp parser choking
> > long lines... might end up using all the CPU...
> 
> dired-view-file visits the file in read-only mode, so you are not
> supposed to edit it unless you really mean to...
> 
> IOW, it sounds like there was some cockpit error in your case, and you
> somehow decided that it's Emacs's fault.  It isn't.

No substantial new information or comments about this in more than 2
weeks, so I'm now closing this bug.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sun, 24 Nov 2024 12:24:10 GMT) Full text and rfc822 format available.

This bug report was last modified 206 days ago.

Previous Next


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