unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Cecilio Pardo <cpardo@imayhem.com>
Cc: 71909@debbugs.gnu.org
Subject: bug#71909: 30.0.60;
Date: Sun, 06 Oct 2024 08:59:39 +0300	[thread overview]
Message-ID: <86o73xvkj8.fsf@gnu.org> (raw)
In-Reply-To: <0056b65b-5cdc-4271-b717-0acc75661c17@imayhem.com> (message from Cecilio Pardo on Sat, 5 Oct 2024 23:24:09 +0200)

> Date: Sat, 5 Oct 2024 23:24:09 +0200
> From: Cecilio Pardo <cpardo@imayhem.com>
> Cc: 71909@debbugs.gnu.org
> 
> On 05/10/2024 21:31, Eli Zaretskii wrote:
> 
> > If you invoke "M-: (gui-get-selection 'CLIPBOARD 'TARGETS) RET" after
> > copying something to the clipboard, you will see some very weird
> > format names there.  For the standard formats, we convert them to
> > something similar to what X Window system produces (see
> > w32-selection-targets), but the rest are returned as-is.  For example,
> > after copying an image from Firefox, I get this as the return value of
> > the above evaluation:
> > 
> >    [DataObject text/html HTML\ Format text/_moz_htmlinfo text/_moz_htmlcontext application/x-moz-file-promise-url application/x-moz-file-promise-dest-filename FILE_NAMES Preferred\ DropEffect application/x-moz-nativeimage DIB Ole\ Private\ Data BITMAP nil]
> > 
> > There's no image/* here, only DIB and BITMAP (which correspond to
> > CF_DIB and CF_BITMAP clipboard formats).  There are also a lot of
> > text/* formats, but they are all non-standard, except, perhaps,
> > text/html.  Do you have ideas how to select the proper format and how
> > to yank the data?
> 
> > What do the x/special-* formats correspond to on Windows?
> 
> We would convert the BITMAP format to image/png

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.

As another data point. text/html seems to be Firefox-specific thing;
the standard Windows name for this is "HTML Format" (with the embedded
space).

> and FILE_NAMES to
> x-special/gnome-copied-files, to be compatible with what org-mode does 
> now. The offer to yank-media would then be text/html, image/png, and 
> x-special/gnome-copied-files, ignoring the rest of formats.

I don't like the Gnome-specific name x-special/gnome-copied-files.
I'd rather we produced a more generic name, and then ask the Org
developers to add support for it.

What about other kinds of media, like audio and video data?  Is that
supported, and if so, can we include that in some way?





  reply	other threads:[~2024-10-06  5:59 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <865xtnhyn6.fsf@foxmail.com>
2024-10-05 12:28 ` bug#71909: 30.0.60; Cecilio Pardo
2024-10-05 12:33   ` Eli Zaretskii
2024-10-05 12:42     ` Eli Zaretskii
2024-10-05 17:14       ` Cecilio Pardo
2024-10-05 19:31         ` Eli Zaretskii
2024-10-05 21:24           ` Cecilio Pardo
2024-10-06  5:59             ` Eli Zaretskii [this message]
     [not found]               ` <87ldz1h5s4.fsf@gmail.com>
2024-10-06 11:50                 ` Eli Zaretskii
2024-10-06 12:15                   ` Visuwesh
2024-10-07 10:24               ` Cecilio Pardo
2024-10-07 11:58                 ` Eli Zaretskii
2024-10-09 12:52                   ` Cecilio Pardo
2024-10-09 13:40                     ` Eli Zaretskii
2024-10-10 10:04     ` Cecilio Pardo
2024-10-10 10:49       ` Eli Zaretskii

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=86o73xvkj8.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=71909@debbugs.gnu.org \
    --cc=cpardo@imayhem.com \
    /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).