Re: Filtering clipboard MIME types (was: Re: clipboard events)

On Mon, May 16, 2011 at 21:23, Hallvord R. M. Steen <hallvord@opera.com>wrote:

> On Mon, 31 Jan 2011 19:39:13 +0900, Daniel Cheng <dcheng@chromium.org>
> wrote:
>
>  I'd go one step further and say that there should be some agreement on
>> what
>> MIME types ought to be supported to try to insure somewhat consistent
>> behavior across different platforms.
>>
>
> To get a table started in the spec, could you give me a small list of
> (MIME) types one should mandate the UA to be aware of and be able to
> "roundtrip" to/from native clipboard types? Just off the top of your head?
> The typical Web MIME types would of course be something along the lines of
>
> text/plain
> text/html
> image/jpg
> image/gif
> image/png
> application/xhtml+xml
> image/svg+xml
>
> What about e.g. RTF?
>
>  The way I'm working on implementing it
>> (for drag and drop, though it applies to copy and paste as well),
>> arbitrary
>> strings would not be accessible from a non-DOM application, e.g. a native
>> app like Word or Photoshop. Only a set of known MIME types would be
>> automatically converted to the corresponding native type.
>>
>
> That's dragging from UA to another app, right? So the way to spec it would
> be "during copy/cut processing, the UA should support placing content of
> these MIME types on the clipboard and translate the type to the OS native
> equivalent where applicable" or something like that?
>
>   When pulling data from the clipboard
>>>
>> <X>
>
>> I'm choosing
>> to restrict the number of native types to a smaller, defined set that are
>> visible to webpages. Any paths in this set can be filtered as necessary
>> when a file drag is detected.
>>
>
> Again the specific list of types for this would be great :-)
>
> --
> Hallvord R. M. Steen, Core Tester, Opera Software
> http://www.opera.com http://my.opera.com/hallvors/
>

http://lists.whatwg.org/htdig.cgi/whatwg-whatwg.org/2010-October/028926.htmlis
a set of types I proposed originally. I omitted GIF/JPG because
platform
support for GIFs/JPGs isn't as strong, nor is it widely used.

Daniel

Received on Tuesday, 17 May 2011 06:36:59 UTC