chunks design -- ABW-format selections on the clipboard


Subject: chunks design -- ABW-format selections on the clipboard
From: Paul Rohr (paul@abisource.com)
Date: Fri Sep 22 2000 - 19:44:15 CDT


I should mention that one hidden benefit of factoring out the CHUNK
mechanism is that this is exactly what we'll need if we ever want to have
abiword-format content on the clipboard.

Currently, we just cut and paste RTF, which works pretty well, so long as we
continue to keep the RTF import/export code in sync with our file format.
However, if we ever add features which shouldn't be added to RTF, it might
be handy to have ABW format content on the clipboard instead. (It's sure a
lot faster to parse.)

Essentially, all clipboard content would look something like:

  <abiword>
  <styles> <!-- referenced style definitions, if any --></styles>
  <section>
  <p>
  
  ... whetever the selection is goes inside here, wrapped in CHUNK tags ...

  </p>
  </section>
  <data><!-- again, only referenced data items --></data>
  </abiword>

This means that the selection is a complete and valid document, but on a
paste, the importer knows to ignore the outermost SECTION and P tags when
inserting the selected chunk.

Paul



This archive was generated by hypermail 2b25 : Fri Sep 22 2000 - 19:37:39 CDT