unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#963: no support for viewing bmp images?
@ 2008-09-11 22:02 xah lee
  2011-07-19 20:46 ` Glenn Morris
  2019-08-20 16:17 ` Stefan Kangas
  0 siblings, 2 replies; 6+ messages in thread
From: xah lee @ 2008-09-11 22:02 UTC (permalink / raw)
  To: bug-gnu-emacs


I tried to open a bmp image file, but when it opened in a buffer it  
shows ascii.
for example, i can view jpg, gif, png image files.


In GNU Emacs 22.2.1 (powerpc-apple-darwin8.11.0, Carbon Version 1.6.0)
  of 2008-04-05 on g5.tokyo.stp.isas.jaxa.jp
Windowing system distributor `Apple Inc.', version 10.4.11
configured using `configure  '--prefix=/Applications/Emacs.app/ 
Contents/Resources' '--with-carbon' '--without-x' '--libexecdir=/ 
Volumes/Emacs/Emacs.app/Contents/MacOS/libexec' 'CFLAGS=-Os -arch  
i386 -arch ppc -isysroot /Developer/SDKs/MacOSX10.4u.sdk -DUSE_ATSUI - 
DUSE_MAC_TSM''

Recent messages:
./Snapshot_001.bmp
./Snapshot_002.bmp
./Snapshot_003.bmp
./Snapshot_004.bmp

   Xah
∑ http://xahlee.org/

☄


☄









^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#963: no support for viewing bmp images?
  2008-09-11 22:02 bug#963: no support for viewing bmp images? xah lee
@ 2011-07-19 20:46 ` Glenn Morris
  2019-08-20 16:17 ` Stefan Kangas
  1 sibling, 0 replies; 6+ messages in thread
From: Glenn Morris @ 2011-07-19 20:46 UTC (permalink / raw)
  To: 963


Emacs 24.1 will be able to view bmp files through the ImageMagick
library. However, it looks like this is not implemented for the Nextstep
port (from examining configure), nor for MS Windows (?), ref thread

http://lists.gnu.org/archive/html/emacs-devel/2010-09/msg01579.html
http://lists.gnu.org/archive/html/emacs-devel/2010-10/msg00002.html

The documentation doesn't seem to make this explicit, it probably
should.





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#963: no support for viewing bmp images?
  2008-09-11 22:02 bug#963: no support for viewing bmp images? xah lee
  2011-07-19 20:46 ` Glenn Morris
@ 2019-08-20 16:17 ` Stefan Kangas
  2019-09-26 18:11   ` Lars Ingebrigtsen
  1 sibling, 1 reply; 6+ messages in thread
From: Stefan Kangas @ 2019-08-20 16:17 UTC (permalink / raw)
  To: Glenn Morris; +Cc: 963

Glenn Morris <rgm@gnu.org> writes:

> Emacs 24.1 will be able to view bmp files through the ImageMagick
> library. However, it looks like this is not implemented for the Nextstep
> port (from examining configure), nor for MS Windows (?), ref thread
>
> http://lists.gnu.org/archive/html/emacs-devel/2010-09/msg01579.html
> http://lists.gnu.org/archive/html/emacs-devel/2010-10/msg00002.html
>
> The documentation doesn't seem to make this explicit, it probably
> should.

This is from 2011 and should probably have been closed, since we had
bmp support in Emacs 24.1.  But since it wasn't, here's the current
state of affairs AFAICT:

When I compile the current master branch using --with-imagemagick,
viewing bmp images works for me.  But imagemagick is now disabled by
default (and rightly so).  Without imagemagick compiled in I just get
garbled text when opening a bmp file.

Using Emacs 26.1 from Debian I can view BMP images just fine, as
expected, since it comes with imagemagick support.

It seems to me that Emacs is missing BMP support if built without
imagemagick.  It would be nice to not depend on that library for this
use case.

Thanks,
Stefan Kangas





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#963: no support for viewing bmp images?
  2019-08-20 16:17 ` Stefan Kangas
@ 2019-09-26 18:11   ` Lars Ingebrigtsen
  2019-09-27 10:40     ` Stefan Kangas
  0 siblings, 1 reply; 6+ messages in thread
From: Lars Ingebrigtsen @ 2019-09-26 18:11 UTC (permalink / raw)
  To: Stefan Kangas; +Cc: 963

Stefan Kangas <stefan@marxist.se> writes:

> When I compile the current master branch using --with-imagemagick,
> viewing bmp images works for me.  But imagemagick is now disabled by
> default (and rightly so).  Without imagemagick compiled in I just get
> garbled text when opening a bmp file.
>
> Using Emacs 26.1 from Debian I can view BMP images just fine, as
> expected, since it comes with imagemagick support.
>
> It seems to me that Emacs is missing BMP support if built without
> imagemagick.  It would be nice to not depend on that library for this
> use case.

Are BMP images used much, though?  I can't remember the last time I saw
one in the wild.

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





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#963: no support for viewing bmp images?
  2019-09-26 18:11   ` Lars Ingebrigtsen
@ 2019-09-27 10:40     ` Stefan Kangas
  2019-09-27 13:41       ` Lars Ingebrigtsen
  0 siblings, 1 reply; 6+ messages in thread
From: Stefan Kangas @ 2019-09-27 10:40 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: 963

Lars Ingebrigtsen <larsi@gnus.org> writes:

> Are BMP images used much, though?  I can't remember the last time I saw
> one in the wild.

I remember seeing them in stuff like tutorials for how to load an
image in <foo> language and suchlike.  Perhaps I saw was some Scheme
stuff a couple of years ago where the examples used BMP...?  I can't
remember exactly.  It might have been PNG too, to be honest.

I still think it would be a nice little feature to have.  But I won't
protest if this is closed as wontfix either.

Best regards,
Stefan Kangas





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#963: no support for viewing bmp images?
  2019-09-27 10:40     ` Stefan Kangas
@ 2019-09-27 13:41       ` Lars Ingebrigtsen
  0 siblings, 0 replies; 6+ messages in thread
From: Lars Ingebrigtsen @ 2019-09-27 13:41 UTC (permalink / raw)
  To: Stefan Kangas; +Cc: 963

Stefan Kangas <stefan@marxist.se> writes:

> I remember seeing them in stuff like tutorials for how to load an
> image in <foo> language and suchlike.  Perhaps I saw was some Scheme
> stuff a couple of years ago where the examples used BMP...?  I can't
> remember exactly.  It might have been PNG too, to be honest.
>
> I still think it would be a nice little feature to have.  But I won't
> protest if this is closed as wontfix either.

Yeah, I think this is one of those image formats we'll just have to
defer users to ImageMagick if they want to see...

This reminds me: Since we don't really want to point users towards
compiling with ImageMagick due to security concerns -- would it make
sense to write a shim over external utilities to handle exotic formats?
I mean, it would just have to call "convert" in a temp buffer to some
format we do handle (like PNG).

But I guess that doesn't really deal with the security issue, as buffer
overflows in "convert" will do pretty much the same as in Emacs.  But it
would lead to fewer segfaults in Emacs itself, so perhaps it's worth
doing?  It'd be a pretty trivial shim, and we could deprecate compiling
with ImageMagick for sure.

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





^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2019-09-27 13:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-09-11 22:02 bug#963: no support for viewing bmp images? xah lee
2011-07-19 20:46 ` Glenn Morris
2019-08-20 16:17 ` Stefan Kangas
2019-09-26 18:11   ` Lars Ingebrigtsen
2019-09-27 10:40     ` Stefan Kangas
2019-09-27 13:41       ` Lars Ingebrigtsen

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).