all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Po Lu <luangruo@yahoo.com>
Cc: emacs-devel@gnu.org
Subject: Re: master 6011d39b6a: Fix drag-and-drop of files with multibyte filenames
Date: Sun, 05 Jun 2022 12:21:52 +0300	[thread overview]
Message-ID: <83r143a2j3.fsf@gnu.org> (raw)

> --- a/lisp/select.el
> +++ b/lisp/select.el
> @@ -630,20 +630,20 @@ two markers or an overlay.  Otherwise, it is nil."
>          (xselect--encode-string 'TEXT (buffer-file-name (nth 2 value))))
>      (if (and (stringp value)
>               (file-exists-p value))
> -        (xselect--encode-string 'TEXT (expand-file-name value)
> -                                nil t)
> +        ;; Motif expects this to be STRING, but it treats the data as
> +        ;; a sequence of bytes instead of a Latin-1 string.
> +        (cons 'STRING (encode-coding-string (expand-file-name value)
> +                                            'raw-text-unix))

I don't think I understand this change.  raw-text basically doesn't do
any conversion, except if the text includes raw bytes.  Is that the
problem here, and if so, how come a file name can include raw bytes in
its name?  And what does "Motif expects this to be STRING, but it
treats the data as a sequence of bytes instead of a Latin-1 string"
mean in this context?  The difference between raw bytes and Latin-1
strings is only meaningful to Emacs; how does Motif distinguish
between them?



             reply	other threads:[~2022-06-05  9:21 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-05  9:21 Eli Zaretskii [this message]
2022-06-05 10:00 ` master 6011d39b6a: Fix drag-and-drop of files with multibyte filenames Po Lu
2022-06-05 10:31   ` Eli Zaretskii
2022-06-05 11:42     ` Po Lu
2022-06-05 12:54       ` Eli Zaretskii
2022-06-05 13:07         ` 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=83r143a2j3.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=luangruo@yahoo.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 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.