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.bugs Subject: bug#71909: 30.0.60; Date: Mon, 07 Oct 2024 14:58:28 +0300 Message-ID: <86o73wt997.fsf@gnu.org> References: <865xtnhyn6.fsf@foxmail.com> <868qv2wwyk.fsf@gnu.org> <865xq6wwkc.fsf@gnu.org> <86wmimuz18.fsf@gnu.org> <0056b65b-5cdc-4271-b717-0acc75661c17@imayhem.com> <86o73xvkj8.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="843"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 71909@debbugs.gnu.org To: Cecilio Pardo Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Oct 07 13:59:18 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1sxmOS-000AWw-G9 for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 07 Oct 2024 13:59:16 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sxmO9-0007EE-8P; Mon, 07 Oct 2024 07:58:57 -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 1sxmO7-0007E2-2D for bug-gnu-emacs@gnu.org; Mon, 07 Oct 2024 07:58:55 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sxmO6-00060n-Md for bug-gnu-emacs@gnu.org; Mon, 07 Oct 2024 07:58:54 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=References:In-Reply-To:From:Date:To:Subject; bh=uNuO9dFDF7MOibrw/0oTXOQL+BbTQtrdBUOu1u+cJE0=; b=WXk3ReDvRaTD1312ig7ImbZW4M9xWZmbWvJX0V8d3sE+lZ/cVuPHYJQMw4Qk6jemROHq8S8cLWLW8xMS3xNzgNGlHF9cSnJw9izXoYcHYi7AGW5xFuYieCZC42zzynxSs7V4NHhtJrqUsIXoTlytDwhfYl6/61tVcjv0PPAvQMA2AtwjWy2Bax0vrXPow0HLqPj95Gh2JUzw9dRPvtRVLFbTs4uWuayjFFRZE2fW+a7HKqIkwidddlkXoRHiDAE7+SirBLD+oeEhE6i4t5vaU5tiziINFfWhRVZw5pOpYp1RKy2xTGUF3wV/zTWOJbT9pqp9TyeuRmmd4r4a/41YRA==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sxmOD-0007mx-Qj for bug-gnu-emacs@gnu.org; Mon, 07 Oct 2024 07:59:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 07 Oct 2024 11:59:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 71909 X-GNU-PR-Package: emacs Original-Received: via spool by 71909-submit@debbugs.gnu.org id=B71909.172830232829917 (code B ref 71909); Mon, 07 Oct 2024 11:59:01 +0000 Original-Received: (at 71909) by debbugs.gnu.org; 7 Oct 2024 11:58:48 +0000 Original-Received: from localhost ([127.0.0.1]:45258 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sxmNz-0007mT-RW for submit@debbugs.gnu.org; Mon, 07 Oct 2024 07:58:48 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:36804) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sxmNx-0007mE-To for 71909@debbugs.gnu.org; Mon, 07 Oct 2024 07:58:46 -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 1sxmNk-0005z1-Le; Mon, 07 Oct 2024 07:58:32 -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=uNuO9dFDF7MOibrw/0oTXOQL+BbTQtrdBUOu1u+cJE0=; b=V59zIZ+iMUeO pMCLXHrT8HBdNxgEQ+CucXFetCm6gGUfHMrSwA6/oqJ9lIUHquJbvrV1ZB4NiIjrLWMQ+ON7AOktM acpjgz3AD+/0wr5jJ9Ne0MBq/Ea5pcRp07R2Q5xI5dWrARDbHpERMvZj50HSW61YHJTiGZ8OKEa/m 9srblY0nYeQu7mxRQxpg1+uX11kigg9n0eQmXf7yVvfSkEueu0pFVD3YR4SxA1xxpyitDkOXluHZm u1tirPO+2H0f2TC3Dm1+tlABUciGKKVdOZ3CB2inAn1oAPKyDdR9zJJNwPBPi67q00jSvN3X0pPbb xV7RNX6VldEaJkJ2SmMCFA==; In-Reply-To: (message from Cecilio Pardo on Mon, 7 Oct 2024 12:24:01 +0200) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:293115 Archived-At: > Date: Mon, 7 Oct 2024 12:24:01 +0200 > Cc: 71909@debbugs.gnu.org > From: Cecilio Pardo > > On 06/10/2024 7:59, Eli Zaretskii wrote: > > > But BITMAP is not PNG, AFAIU. Moreover, with some images, when I copy > > them in a Web browser, I see "PNG" in the targets vector reported by > > gui-get-selection. So I think we need to understand what exactly we > > get with each format before we decide on the mapping. > > The standard bitmap formats for the clipboard (CF_BITMAP, CF_DIB, > CF_DIBV5) are image data specific to windows, not an image format for > saving to file. We need to convert it to an image format, with a > mime/type. PNG or any other, even multiple ones. Isn't CF_BITMAP format indicate the data to which we convert images on Windows in the w32-specific portions of image.c? Or maybe it's a BMP data (which we can already display, see w32image.c)? If so, then yanking images into an Emacs buffer could simply use the data instead of converting to PNG, then back to bitmap. > GIMP on ubuntu for example does this when you copy a section of image: > > [TIMESTAMP TARGETS MULTIPLE SAVE_TARGETS image/png image/bmp image/x-bmp > image/x-MS-bmp image/x-icon image/x-ico image/x-win-bitmap > image/vnd.microsoft.icon ...] > > On windows it does this: > > [PNG DIB BITMAP DIBV5] > > And the Paint program that comes with Windows 11: > > [DataObject Embed\ Source Native OwnerLink Object\ Descriptor METAFILE > DIB PNG image/png Ole\ Private\ Data ENHMETAFILE BITMAP ...] > > I didn't expect the PNG, image/png formats. I suppose they are the same > image as the DIB/BITMAP. I'd rather expect them to be in PNG format. > > What about other kinds of media, like audio and video data? Is that > > supported, and if so, can we include that in some way? > > In standard formats there is CF_RIFF and CF_WAVE. Also programas may > insert a file format (as they do with PNGS), but I haven't found any > example yet. In any case, we can do the same as with images. If CF_WAVE are the same data as in *.wav files, then we should be able to invoke play-sound in some way.