From: Po Lu <luangruo@yahoo.com>
To: Justus-dev@Piater.name
Cc: emacs-devel@gnu.org
Subject: Re: dired-mouse-drag-files
Date: Sun, 10 Apr 2022 09:04:29 +0800 [thread overview]
Message-ID: <87tub1iw9u.fsf@yahoo.com> (raw)
In-Reply-To: <87tub2t2gu.fsf@uibk.ac.at> (Justus-dev@piater.name's message of "Sat, 09 Apr 2022 22:40:33 +0200")
[You forgot to copy in the list, I did that for you this time.]
Justus-dev@Piater.name writes:
> What about Wayland?
>
> I don't think this should be too hard to implement (famous last words).
> Perhaps I'll give it a shot myself. Any advice?
>
> Best,
> Justus
It shouldn't be too hard, thanks! First, rewrite pgtkselect.c to use
the low-level GDK selections API (the code translates very neatly from
X), since the GTK clipboard API is not very suitable for Emacs
drag-and-drop. The file that needs work is pgtkselect.c.
Then, implement `x-begin-drag' using the GDK drag-and-drop system. I
suggest running a nested event loop until the drop completes.
Most of the low level functions there are not much higher level than the
functions `x_dnd_get_target_window' and `x_set_dnd_targets' on X.
This documentation should be fairly helpful:
https://developer-old.gnome.org/gdk3/stable/gdk3-Drag-and-Drop.html
https://developer-old.gnome.org/gdk3/stable/gdk3-Selections.html
next parent reply other threads:[~2022-04-10 1:04 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <87tub2t2gu.fsf@uibk.ac.at>
2022-04-10 1:04 ` Po Lu [this message]
2022-03-25 12:56 dired-mouse-drag-files Eli Zaretskii
2022-03-25 14:06 ` dired-mouse-drag-files Po Lu
2022-03-25 14:16 ` dired-mouse-drag-files Eli Zaretskii
2022-03-26 0:35 ` dired-mouse-drag-files Po Lu
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87tub1iw9u.fsf@yahoo.com \
--to=luangruo@yahoo.com \
--cc=Justus-dev@Piater.name \
--cc=emacs-devel@gnu.org \
/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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.