On Mon, 2002-08-12 at 12:55, Kovriga, Gregory wrote:
> Hi,
> could anyone drop some light on the following issue:
> when drag&dropping file using XDND the files are passed using
> "text/uri-list" encoding. This seems to mean that non-ascii? other then en?
> characters are converted to %XX%XX notations...
> Does anybody know how exactly this is done and how exactly could this name
> then be converted back to original file name?

One or more URIs contained in the "text/uri-list" data have their
non-Latin-1 characters encoded in the standard URL encoding, where every
octet which doesn't fall into the Latin-1 range is substituted by a
percent sign and its (octet's) hex value. Thus, you see multiple %XXs
for non-English letters.

Since for the OS, filenames are merely sequences of octets, the charset
of the URI isn't specified by the standard. As far as you are concerned,
the URI contains a string of octets, not text.

Converting to original filename is easy -- simply scan and convert all
%XXs to octets.



=================================================================
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word "unsubscribe" in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]

Reply via email to