unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Antero Mejr via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: 63531@debbugs.gnu.org
Subject: bug#63531: [PATCH] View DICOM and Sixel images using image-convert
Date: Mon, 15 May 2023 23:30:13 +0000	[thread overview]
Message-ID: <87cz31fa0q.fsf@mailbox.org> (raw)

[-- Attachment #1: Type: text/plain, Size: 147 bytes --]

These patches add .dcm and .six to auto-mode-alist, so they can be
viewed with image-convert. The Six patch also adds SIX as an ImageMagick
type.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-Allow-viewing-.six-images-via-image-convert.patch --]
[-- Type: text/x-patch, Size: 1532 bytes --]

From d03709e75696c7d081012eade721d80f5b725b42 Mon Sep 17 00:00:00 2001
From: Antero Mejr <antero@mailbox.org>
Date: Mon, 15 May 2023 21:21:12 +0000
Subject: [PATCH 1/2] Allow viewing .six images via image-convert.

* lisp/files.el (auto-mode-alist): Support the Sixel .six image
format.
* lisp/image.el (imagemagick-enabled-types): Add SIX.
---
 lisp/files.el | 1 +
 lisp/image.el | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/lisp/files.el b/lisp/files.el
index 148f47cbc97..ba338e01c6b 100644
--- a/lisp/files.el
+++ b/lisp/files.el
@@ -3082,6 +3082,7 @@ ARC\\|ZIP\\|LZH\\|LHA\\|ZOO\\|[JEW]AR\\|XPI\\|RAR\\|CBR\\|7Z\\|SQUASHFS\\)\\'" .
      ("\\.pict\\'" . image-mode)
      ("\\.rgb\\'" . image-mode)
      ("\\.rgba\\'" . image-mode)
+     ("\\.six\\'" . image-mode)
      ("\\.tga\\'" . image-mode)
      ("\\.wbmp\\'" . image-mode)
      ("\\.webp\\'" . image-mode)
diff --git a/lisp/image.el b/lisp/image.el
index 08190cf86bc..72811b2b197 100644
--- a/lisp/image.el
+++ b/lisp/image.el
@@ -1127,7 +1127,7 @@ has no effect."
     KDC MIFF MNG MRW MSL MSVG MTV NEF ORF OTB PBM PCD PCDS PCL
     PCT PCX PDB PEF PGM PICT PIX PJPEG PNG PNG24 PNG32 PNG8 PNM
     PPM PSD PTIF PWP RAF RAS RBG RGB RGBA RGBO RLA RLE SCR SCT
-    SFW SGI SR2 SRF SUN SVG SVGZ TGA TIFF TIFF64 TILE TIM TTF
+    SFW SGI SIX SR2 SRF SUN SVG SVGZ TGA TIFF TIFF64 TILE TIM TTF
     UYVY VDA VICAR VID VIFF VST WBMP WPG X3F XBM XC XCF XPM XV
     XWD YCbCr YCbCrA YUV)
   "List of ImageMagick types to treat as images.
-- 
2.39.2


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #3: 0002-Allow-viewing-.dcm-images-via-image-convert.patch --]
[-- Type: text/x-patch, Size: 815 bytes --]

From aaeac0b37bd35792dc55fbccc9d5c53e606ac3f1 Mon Sep 17 00:00:00 2001
From: Antero Mejr <antero@mailbox.org>
Date: Mon, 15 May 2023 23:15:33 +0000
Subject: [PATCH 2/2] Allow viewing .dcm images via image-convert.

* lisp/files.el (auto-mode-alist): Support the DICOM .dcm image
format.
---
 lisp/files.el | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lisp/files.el b/lisp/files.el
index ba338e01c6b..2e42d0e74d1 100644
--- a/lisp/files.el
+++ b/lisp/files.el
@@ -3053,6 +3053,7 @@ ARC\\|ZIP\\|LZH\\|LHA\\|ZOO\\|[JEW]AR\\|XPI\\|RAR\\|CBR\\|7Z\\|SQUASHFS\\)\\'" .
      ("\\.cmyk\\'" . image-mode)
      ("\\.cmyka\\'" . image-mode)
      ("\\.crw\\'" . image-mode)
+     ("\\.dcm\\'" . image-mode)
      ("\\.dcr\\'" . image-mode)
      ("\\.dcx\\'" . image-mode)
      ("\\.dng\\'" . image-mode)
-- 
2.39.2


             reply	other threads:[~2023-05-15 23:30 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-15 23:30 Antero Mejr via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2023-05-16 16:23 ` bug#63531: [PATCH] View DICOM and Sixel images using image-convert Eli Zaretskii
     [not found]   ` <871qjgtc37.fsf@mailbox.org>
2023-05-16 17:38     ` Antero Mejr via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-10-22 18:36       ` Stefan Kangas
2023-11-02 17:06         ` Antero Mejr via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-12-21 13:28           ` Daniel Mendler via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-12-22  3:07           ` Stefan Kangas

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=87cz31fa0q.fsf@mailbox.org \
    --to=bug-gnu-emacs@gnu.org \
    --cc=63531@debbugs.gnu.org \
    --cc=antero@mailbox.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).