Re: My absence


Subject: Re: My absence
From: Martin Sevior (msevior@mccubbin.ph.unimelb.edu.au)
Date: Thu Nov 23 2000 - 16:17:13 CST


HI Luke,
        Thanks for emailing me. I'm very sorry to hear about your computer
woes. I'm extremely happy with the List backend code now. The work-around
to the THE bug also enabled Abi to import a huge range of MS Word
documents that it previously segfaulted on. Working out why so many
documents don't have last lines in their paragraphs upon import is not
solved but we definately should do that some time. However as it stands
now Abi can happily import MS Word documents over 100 pages long. This is
a combination of Dom's fantastic work on wv and this work around. The
downside is that abi segfaults trying to import a document with a footer.

After being happy about this for a while I realized that we were doing
something fundamentally wrong in the list code by counting fl_layouts as
list items with vectors of fl_AutoNum's in the pd_Document . A document
can have many views so if you printed (requires cloning a view then
drawing into the printing code) or openned a new view on a document your
lists would get totally screwed. There were two solutions. Either go back
fl_AutoNum's in Layouts or count the underlying shd's in the layouts in
the fl_AutoNum's instead. I took the latter approach because I think it
the Right Way to handle the issue in a genuine multi-view way. This
involved a big rewrite (again) but it all works now. Changing a list in
one view is instantly reflected on all cloned views. Also I put back all
the info about the list we were writing into the block headers. I think it
is the only way to get undo/redo to work correctly. It will also
eventually allow us to cut and paste list structures in a document. This
is something MS Word does not do.

I also fixed the const char problem by removing the const definition of
various functions.

What's left? Well we're debating what to do about the List Dialog GUI
right now. You were right to stay away from it. It is proving to be very
difficult to get it just right for your average Church Secretary.

On the list backend I'd like us to be able to correctly undo a list
nested arbitrarily deeply after being cut. Right now we only get the first
two levels right, the third level thinks it's a child of the first level
not the second. Make a list

1.
2.
3.
  3.1
  3.2
  3.3
  3.4
      3.4.1
      3.4.2

cut from 2. to 3.4.2. Do an undo and you get:

1.
2.
3.
  3.1
  3.2
  3.3
  3.4
     3.1
     3.2

This can be fixed in the ::findAndSetParentItem() method by searching
ALL the lists in the document for the first previous sdh rather than just
parent list. Of course we would also have to replace the parent pointer in
the AutoNum if we found an sdh closer to the current list. Once this is
done it would probabally be worthwhile to invent a data structure to speed
up these searches. Maybe a list of sdh's in document order and a binary
search method to find the closest previous sdh?

Then there's is the whole paste challenge. First off we have to work
out how to export our list structure to rtf. Then we want to work out the
semantics of pasting a list structure. What would the user expect if they
pasted a list item? I have some ideas on this but this email is already
long enough.

Sam, Does Luke have CVS access enabled yet?

Cheers

Martin

On Thu, 23 Nov 2000, Luke Jordan wrote:

> Hi Martin,
> I apologise for my lack of input during the last month - I have been
> through a computing nightmare. My power supply blew, then iI got a new
> power supply but my phone line was down, then the line came back up but
> the motherboard blew. Anyway, it's working again now. Unfortunately I
> have 1158 new messages in my abiword-dev folder, so I'm going to have to
> indescriminately delete. Could you please give me a summary of
> developments in the list code, and any other important/related areas of
> AbiWord? I gather 0.7.12 is out soon, is the list work in the user
> version, and what about THE bug?
> Thanks,
> Luke.
>
>
>



This archive was generated by hypermail 2b25 : Thu Nov 23 2000 - 16:17:30 CST