Re: Moniker-based d&d and c&p



On Thu, 17 May 2001, ERDI Gergo wrote:

> Hi,
> 
> so how will moniker-based c&p and d&d work? Let's say I select some rich
> text in AbiWord, and either cut & paste or drag it to gedit. How will
> gedit get a plain text stream? Will it resolve the moniker on the
> clipboard/in the d&d context for PersistStream and save it to a text/plain
> stream? 
> What about non-saved files, how do you textualize a moniker that points to
> a section in an unsaved file? I.e. if I start up AbiWord (previous
> scenario again), type in some text, then select it and copy & paste it to
> GEdit -- what will the clipboard contain? Something like "pid:4523!Unsaved
> Document 1!Paragraph 1"?
> 

Right now selecting text in AbiWord will generate both an RTF
representation of the selected text as well as plain text and place them
in the RTF and strings buffer of the X-clipboard.  Since gedit can only
read plain text it just gets the ascii values plus CR/LF/tabs. Basically
all the richness is removed leaving the raw ascii ala export to plain text
in Abi.

If an application can read RTF text they can recover the rich text
attributes from an Abi document. Similarly Abi can import RTF text loaded
into the RTF buffer of the X-clipboard.

RTF is actually quite a powerful representation of formatted text. It was
orginally developed by DEC and the X-clipboard has an explicit RTF buffer
defined.

Cheers

Martin







[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]