From: Martin Sevior (msevior@seviorpc.ph.unimelb.edu.au)
Date: Thu Jul 17 2003 - 01:27:26 EDT
On Thu, 2003-07-17 at 13:31, Dom Lachowicz wrote:
> So the generic cut+paste framework that I started (and
> Tomas mildly criticized for being incomplete) should
> now be working fairly well. The framework has been
> laid so that any importer should be able to paste data
> in with a relative minimum of fuss now. I've done this
> through hiding the difference between the appendXXX
> and insertXXX piecetable methods inside of the IE_Imp
> class. To an importer, it should all look the same
> anyway, IMO.
>
> Anyway, nothing really uses this yet except for the
> GDA plugin to "paste" in tables, but things will
> hopefully work with all of our file formats after 2.0.
> The next bit is making a memory buffer look the same
> as a FILE*, but as many of you know, I've got plans
> for that too. Plans within plans...
>
HI Dom,
This is all very cool. Especially being able to paste arbitary
clipboard data into abi.
However I just want to point out that there is some really special case
code for copy and pasting lists and tables in the RTF export/importer.
The difference here is that that what happens after the paste depends on
the context that the text is being pasted into.
In the case of lists, the RTF importer attempts to merge the pasted list
into the current list structure. This required a lot of specialized
code.
Without this the a pasted list would not merge with the current but
would be a seperate entity surrounded by the previous list.
Getting all this to work right for every importer will require a fair
bit of abstracting and reusing code in the RTF importer.
Cheers
Martin
> Dom
>
> Checking in src/wp/impexp/xp/ie_imp.cpp;
> /cvsroot/abi/src/wp/impexp/xp/ie_imp.cpp,v <--
> ie_imp.cpp
> new revision: 1.77; previous revision: 1.76
> done
> Notifying #AbiWord...done.
>
> __________________________________
> Do you Yahoo!?
> SBC Yahoo! DSL - Now only $29.95 per month!
> http://sbc.yahoo.com
This archive was generated by hypermail 2.1.4 : Thu Jul 17 2003 - 00:36:21 EDT