[TextShare] - proposal to make a desktop-wide format for text
Shaun McCance
shaunm at gnome.org
Thu Jun 19 12:38:07 PDT 2008
On Thu, 2008-06-19 at 21:15 +0200, François Revol wrote:
> > On Tuesday 17 June 2008, Liam R E Quin wrote:
> >
> > > For this to work, we need cross-desktop agreement on a format
> > > for the text. Since most clipboard mechanisms let applications
> > > give a list of available formats, this format need not be the
> > > only (or even preferred) format for all applications, but it
> > > should be widely supported.
> >
> > IMHO a suitable candidate would be OpenDocument.
> > The destination program can selectively, depending on its
> > capabilities,
> > extract any level of details, e.g. just the content, basic
> > formatting, etc.
>
> Well, other candidates could be possible, like PDF, but it doesn't
> maintain a real logical sturcture AFAIK.
In my experience, pasting formatted text seems to
work reasonably well. Granted, I don't do a lot
of word processing, so my experience is generally
limited to copying from a web browser into an IM
window.
I very much doubt either application implements
OpenDocument, and I doubt the developers are keen
on doing that. I have to assume it's HTML, which
seems to me like the most obvious cross-application
rich text format.
> > Especially if one considers not only text made of words, but also
> > situations
> > where currently a text based exchange is used for structured data,
> > e.g.
> > tables formatted as CSV, or text data is mixed with non-text data,
> > e.g.
>
> BeOS/Haiku spreadsheets can use text/x-csv or something I think...
> But it should be easy to add others. OOo format would be a little
> harder until it's ported and a translator for it is written though.
Obviously, applications should attempt to support
the richest possible formats that are relevant to
them. Copying and pasting between two spreadsheets
or two word processors will be nicer if both support
ODF.
But, I think, every application that does rich text
should be able to publish and receive HTML on the
clipboard. It's the path of least resistance for
a least-common-denominator format.
(Does everybody on this thread know how X clipboard
content negotiation works? Talking about solutions
without knowing the platform is like spitting in the
wind.)
> > copying a selection in a browser, including images.
>
> Indeed html doesn't embed images...
I think the URL is probably sufficient for most
applications. Otherwise, HTML can embed images
using the data: URI scheme:
http://en.wikipedia.org/wiki/Data:_URI_scheme
--
Shaun
More information about the xdg
mailing list