From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: yank-media: allow users to limit image types that can be inserted Date: Tue, 24 Sep 2024 16:23:50 +0300 Message-ID: <867cb1dw2h.fsf@gnu.org> References: <79fc91f3-c2c3-44db-9817-595808917f26@cas.cat> <86ed5ahb08.fsf@gnu.org> <87zfnywki8.fsf@gmail.com> <86setqfnmq.fsf@gnu.org> <87frpqflv4.fsf@gmail.com> <86ikumfjri.fsf@gnu.org> <877cb2fj0c.fsf@gmail.com> <86cykufhw7.fsf@gnu.org> <3a015d0f-549a-401f-be1c-651c9dbd5d9a@cas.cat> <8634lqfcaf.fsf@gnu.org> <87ikulwsd6.fsf@gmail.com> <86o74ddzxp.fsf@gnu.org> <875xqlw702.fsf@gmail.com> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="10256"; mail-complaints-to="usenet@ciao.gmane.io" Cc: pinmacs@cas.cat, rpluim@gmail.com, emacs-devel@gnu.org To: Visuwesh Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Sep 24 15:24:23 2024 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1st5Wg-0002TY-Ob for ged-emacs-devel@m.gmane-mx.org; Tue, 24 Sep 2024 15:24:22 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1st5WG-0001kV-Q4; Tue, 24 Sep 2024 09:23:56 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1st5WE-0001ec-Vo for emacs-devel@gnu.org; Tue, 24 Sep 2024 09:23:55 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1st5WE-0002qS-5k; Tue, 24 Sep 2024 09:23:54 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=+jpLSNTqpvmJdb5tIZ4oVPwN/eVrWx7MyCMUbstdUZA=; b=qyIyBbNnYdVk rqf3/D+GKsSanK01L0gvtCjSev8amSV+NjRjJAsVQCj3EHYr0ukkbVLgyUpjsGLc5CHFgz+ejKklt fnZPaVK+eiaS7zFyzdzmHKZpPNN9dG8RnGFj/fS6aVanlhom+Zxbq86n9M3U+zCAIlYnJT+7tlTYq q0u6LEzVtpRkrNPFtsca3HFZlP9Icgugt5SbUQe8hm9KIcyc/21r8CWxcLJoAWXsmoXXFsYX2ROLN jIt/nWhmlgGFX0Oj5WcvY9Gs2mnBlUQm6IAYWAzURf10I/sVmFKcclFXxoCKwPK6dYrO+h1VCQC0d b1AR3urQP+7+q92WDu2EJA==; In-Reply-To: <875xqlw702.fsf@gmail.com> (message from Visuwesh on Tue, 24 Sep 2024 18:20:21 +0530) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:324032 Archived-At: > From: Visuwesh > Cc: pinmacs@cas.cat, rpluim@gmail.com, emacs-devel@gnu.org > Date: Tue, 24 Sep 2024 18:20:21 +0530 > > I haven't encountered many "multiple types available" scenario outside > of Firefox and LibreOffice. In most cases, yank-media just does the > thing without interrupting me but when the uncommon case of "multiple > types available" crops up, I would like yank-media to choose the type I > want automatically for me. In Org, I personally would make yank-media > choose image/png. If you ask me for technical reasons to prefer > image/png specifically, I cannot give you a concrete answer. It might as > well be image/jpeg for all I care. I simply do not want to be asked a > question when I'm focusing on writing. The point of the user option is > to keep user interaction to a minimum. I think if PNG is supported by the running Emacs, it is always preferable. (And we can come up with the list image formats ordered by their preference, and use that to find the first available one.) I do agree that in many/most cases having Emacs deduce the best format automatically is a very useful feature to have. I also agree that it is useful to be able to see the list of available formats and choose from them. I just think that these two extremities is all we need, provided that we can come up with a good algorithm for deciding the "most appropriate format" in each case.