From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Chong Yidong Newsgroups: gmane.emacs.devel Subject: Re: Image mode Date: Mon, 05 Feb 2007 14:28:39 -0500 Message-ID: <87d54otndk.fsf@stupidchicken.com> References: <87k5yxeg19.fsf@jurta.org> <45C70ECD.70208@gmail.com> <45C72724.4000800@gmail.com> <7dbe73ed0702050647y15d4ed7cu381a869cd2e835f3@mail.gmail.com> <87lkjcttv5.fsf@stupidchicken.com> <45C77904.8080308@gnu.org> <87hcu0l909.fsf@stupidchicken.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1170703771 11363 80.91.229.12 (5 Feb 2007 19:29:31 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 5 Feb 2007 19:29:31 +0000 (UTC) Cc: Mathias Dahl , emacs-devel@gnu.org, Jason Rumney To: "Juanma Barranquero" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Feb 05 20:29:19 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1HE9Wg-0005sR-Rm for ged-emacs-devel@m.gmane.org; Mon, 05 Feb 2007 20:29:19 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HE9Wg-0007Qm-BU for ged-emacs-devel@m.gmane.org; Mon, 05 Feb 2007 14:29:18 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HE9WH-0007Km-GQ for emacs-devel@gnu.org; Mon, 05 Feb 2007 14:28:53 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HE9WH-0007KZ-3n for emacs-devel@gnu.org; Mon, 05 Feb 2007 14:28:53 -0500 Original-Received: from south-station-annex.mit.edu ([18.72.1.2]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA:32) (Exim 4.52) id 1HE9WG-0000t0-QF; Mon, 05 Feb 2007 14:28:52 -0500 Original-Received: from central-city-carrier-station.mit.edu (CENTRAL-CITY-CARRIER-STATION.MIT.EDU [18.7.7.72]) by south-station-annex.mit.edu (8.13.6/8.9.2) with ESMTP id l15JSo59001598; Mon, 5 Feb 2007 14:28:50 -0500 (EST) Original-Received: from outgoing-legacy.mit.edu (OUTGOING-LEGACY.MIT.EDU [18.7.22.104]) by central-city-carrier-station.mit.edu (8.13.6/8.9.2) with ESMTP id l15JSgrp020753; Mon, 5 Feb 2007 14:28:43 -0500 (EST) Original-Received: from localhost ([18.19.7.58]) ) by outgoing-legacy.mit.edu (8.13.6/8.12.4) with ESMTP id l15JSgCS007997; Mon, 5 Feb 2007 14:28:42 -0500 (EST) Original-Received: from cyd by localhost with local (Exim 3.36 #1 (Debian)) id 1HE9W3-0002Fc-00; Mon, 05 Feb 2007 14:28:39 -0500 In-Reply-To: (Juanma Barranquero's message of "Mon\, 5 Feb 2007 20\:14\:43 +0100") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.93 (gnu/linux) X-Scanned-By: MIMEDefang 2.42 X-Spam-Score: 1 X-detected-kernel: Solaris 9.1 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:65945 Archived-At: "Juanma Barranquero" writes: > As it is Postscript. That's part of the reason > `image-type-auto-detected-p' and `image-type-auto-detectable' were > introduced. As I argued, making this behavior applicable to all images is a mistake. Clearly, we should treat postscript, xpm, and xbm separately from jpegs and pngs. > ...I really, knees-on-the-ground, wholeheartedly BEG we don't do more > accretion-patching without taking half a dozen steps back to gain some > perspective. No drama, please. If you have a specific suggestion, feel free to propose it. My proposal is quite simple, if you actually consider it instead of complaining about accretion: - One function in magic-mode-alist autodetects image types that do not make sense to edit (jpgs, pngs, etc). If the result is ambiguous (as determined by checking auto-mode-alist), prompt the user about whether to use image-mode or the non-image mode specified by auto-mode-alist. - A second function autodetects image types that do make sense to edit (ps, xpm, xbm). If autodetected, set up the editing mode and turn on image-minor-mode. - Otherwise, use auto-mode-alist.