Re: Tables (How hard can it be) ?


Subject: Re: Tables (How hard can it be) ?
From: Robert Sievers (bob@abisource.com)
Date: Sun Jun 04 2000 - 17:26:52 CDT


At 01:17 PM 5/26/00 -0400, Leonard Rosenthol wrote:
>>I still think if we follow the behavior of other word
>>processors, it would become much simpler if we simply
>>thought of each cell as a nested AbiWord document
>>within the main document, and made the main display
>>widget re-entrant, so we could simply make the child
>>documents inherit from the main document.

Tables are HARD.

Jeff Hostetler wrote a complete tables implementation for Spyglass Mosaic,
and he can tell you how tough it is. As the person who tested it, let me
give you a sample of why each table cell cannot be treated as an
independent quantity. This is just off the top of my head. Each of these
has answers, but they aren't easy. When you figure all these out, let me
know and I will actually spend time recreating work from my previous life
and give you 12 more.

Case 1. I have a table with 3 rows and 3 columns. Row 1 has an image X
pixels wide which spans column 1 and column 2. Row 2 has the same image
spanning columns 2 and 3. The entire table is Y pixels across. Quick,
give me the mathematical formula that calculates column sizes for row 3.
When you are done, give me the answer for the arbitrary case.

Case 2. I reformat text inside a column, which forces other columns or
rows to resize. Doing so forces them to reformat, thus causing other rows
or columns to reformat. What is your strategy for not getting caught in an
infinite loop?

Case 3. I put a table inside a table. The interior table needs to grow to
a size larger than the exterior table can handle. How do you intend to
handle this?

Case 4. I have a table half the width of the page. One of rows has a
minimum width restriction, such as an image. What happens when you now
make the document 3-columns?

Tables are HARD. AbiWord needs them, no doubt, but a table implementation
will be brutal. It will take many iterations, and will have impact
spanning much of the code. This mail isn't intended to dissuade anyone
from attempting them; it is to set their expectations accordingly.
Whatever group of people coordinate to implement tables should earn
tremendous respect from everyone on this list.

Robert Sievers
Open Source Evangelist



This archive was generated by hypermail 2b25 : Sun Jun 04 2000 - 17:29:39 CDT