Subject: Re: Patch for HTML export (bug#461?)
From: Paul Rohr (paul@abisource.com)
Date: Fri Dec 03 1999 - 17:00:47 CST
At 12:36 PM 12/3/99 +0000, d.rose@salford.ac.uk wrote:
>3. I think I've stuck to coding standards, you may like to check...
Looks fine.  I went ahead and moved the #defines from the .h to the .cpp, 
because they aren't used outside of it.  (Plus which, this matches what's 
happening in the other importers.)
>Something I'd like to ask is: is it possible _ever_ to nest these style
>types? I know headings don't nest, but how about Block/Plain text? They
>don't _appear_ to nest. The code will fail (i.e. stick in the wrong
>end-tags) if nesting does occur.
Styles are flattened down to two levels -- character ("C") and paragraph 
("P"), so at any point in time you could theoretically have one C style 
nested inside one P style.  No other form of nesting is valid.  For an 
example, see:
  abi/test/wp/Styles.abw
For now, it looks like you should be safe.  See the implementation of 
pt_PieceTable::_loadBuiltinStyles() in the following file:
  abi/src/text/ptbl/xp/pt_PT_Styles.cpp
The original builtin set are all paragraph-level ("P") styles, so they'll 
never nest.  
Paul
PS:  Later on, it might be interesting to play around with exporting other 
style information using the usual HTML/CSS mechanisms.  However, we've never 
messed with CSS selectors, so it might take some extra work to get the 
mapping right. 
This archive was generated by hypermail 2b25 : Fri Dec 03 1999 - 16:55:46 CST