unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#47032: 26.3; doc of `interprogram-paste-function'
@ 2021-03-09 23:46 Drew Adams
  2021-03-10 12:55 ` Eli Zaretskii
  0 siblings, 1 reply; 4+ messages in thread
From: Drew Adams @ 2021-03-09 23:46 UTC (permalink / raw)
  To: 47032

The doc string and (elisp) `Low-Level Kill Ring' say that the function
value of this var can return a "list of strings", to support window
systems that support multiple selections.

Is this a Lisp list of file-name strings?  What kind of multiselection
in MS Windows would result in such a list being obtained and returned
by the function value of the var?

I tried this in Windows Explorer, thinking that it might give me such a
list:

 1. Select all files in a folder (`C-a').  Or use Control + click to
    select several files.
 2. Shift + right-click and choose `Copy as Path'.

But (funcall interprogram-paste-function) then returns a string that's
the contatenation of the (absolute) file names, with each name enclosed
in " chars and with those double-quoted names separated by newline chars.

Is that what was meant by a "list of strings"?  I'm guessing no, and
that some method of obtaining a Lisp list of strings from multiselection
of file names is intended.  But what method, for example?

And if that really was what was meant by a "list of strings" then maybe
that doc could be clarified, because the way it is now I expected a Lisp
list of strings that are (absolute) file names.


In GNU Emacs 26.3 (build 1, x86_64-w64-mingw32)
 of 2019-08-29
Repository revision: 96dd0196c28bc36779584e47fffcca433c9309cd
Windowing system distributor `Microsoft Corp.', version 10.0.19041
Configured using:
 `configure --without-dbus --host=x86_64-w64-mingw32
 --without-compress-install 'CFLAGS=-O2 -static -g3''






^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#47032: 26.3; doc of `interprogram-paste-function'
  2021-03-09 23:46 bug#47032: 26.3; doc of `interprogram-paste-function' Drew Adams
@ 2021-03-10 12:55 ` Eli Zaretskii
  2022-06-20  8:32   ` Lars Ingebrigtsen
  2022-06-20 10:03   ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
  0 siblings, 2 replies; 4+ messages in thread
From: Eli Zaretskii @ 2021-03-10 12:55 UTC (permalink / raw)
  To: Drew Adams; +Cc: 47032

> From: Drew Adams <drew.adams@oracle.com>
> Date: Tue, 9 Mar 2021 23:46:37 +0000
> 
> The doc string and (elisp) `Low-Level Kill Ring' say that the function
> value of this var can return a "list of strings", to support window
> systems that support multiple selections.

Not "can", "may".

> Is this a Lisp list of file-name strings?

Of course.  What other kind of list could be alluded to in the ELisp
manual?

> What kind of multiselection in MS Windows would result in such a
> list being obtained and returned by the function value of the var?

MS Windows doesn't support selections at all, it only supports the
clipboard.

> And if that really was what was meant by a "list of strings" then maybe
> that doc could be clarified, because the way it is now I expected a Lisp
> list of strings that are (absolute) file names.

It's hard to clarify what the manual says because this is not
implemented yet in Emacs, see xselect.c (search for QMULTIPLE).

In a nutshell, this is something we hope will be implemented some day,
and if so, probably only for X selections.





^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#47032: 26.3; doc of `interprogram-paste-function'
  2021-03-10 12:55 ` Eli Zaretskii
@ 2022-06-20  8:32   ` Lars Ingebrigtsen
  2022-06-20 10:03   ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
  1 sibling, 0 replies; 4+ messages in thread
From: Lars Ingebrigtsen @ 2022-06-20  8:32 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 47032, Drew Adams

Eli Zaretskii <eliz@gnu.org> writes:

> It's hard to clarify what the manual says because this is not
> implemented yet in Emacs, see xselect.c (search for QMULTIPLE).
>
> In a nutshell, this is something we hope will be implemented some day,
> and if so, probably only for X selections.

So I guess there's nothing to be done here in this bug report, and I'm
therefore closing it.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#47032: 26.3; doc of `interprogram-paste-function'
  2021-03-10 12:55 ` Eli Zaretskii
  2022-06-20  8:32   ` Lars Ingebrigtsen
@ 2022-06-20 10:03   ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
  1 sibling, 0 replies; 4+ messages in thread
From: Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2022-06-20 10:03 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 47032, Drew Adams

Eli Zaretskii <eliz@gnu.org> writes:

> It's hard to clarify what the manual says because this is not
> implemented yet in Emacs, see xselect.c (search for QMULTIPLE).
>
> In a nutshell, this is something we hope will be implemented some day,
> and if so, probably only for X selections.

The MULTIPLE target is unrelated to the question at hand, as it only
provides a more efficient way for clients to request multiple targets of
the same selection at once.  Emacs also implements the MULTIPLE target,
but only for requests from other clients.

The ICCCM doesn't define a specific "list" format, but it does define
separators for several data types.  If you want to respond to a
selection request with a list of file names, then add a selection
converter to `selection-converter-alist' that returns a cons of
`C_STRING' and the encoded file names in a single unibyte string,
separated by NULL bytes.





^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-06-20 10:03 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-03-09 23:46 bug#47032: 26.3; doc of `interprogram-paste-function' Drew Adams
2021-03-10 12:55 ` Eli Zaretskii
2022-06-20  8:32   ` Lars Ingebrigtsen
2022-06-20 10:03   ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors

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).