This patch should fix the bug where headers were formatted improperly on
import. The importer ignored some paragraph formatting since the flag that
tells the importer that a new paragraph has begun was not always set.
I also fixed a different section of code that contained vestiges of a
previous method of tracking styles. I added some TODO comments, since the
code has unreachable segments that are leftovers of the old way. Could
whoever added the new way check this and delete the bloat?
Matti
Index: ie_imp_RTF.cpp
===================================================================
RCS file: /cvsroot/abi/src/wp/impexp/xp/ie_imp_RTF.cpp,v
retrieving revision 1.102
diff -c -r1.102 ie_imp_RTF.cpp
*** ie_imp_RTF.cpp 2001/09/19 20:07:29 1.102
--- ie_imp_RTF.cpp 2001/09/19 21:19:53
***************
*** 5720,5725 ****
--- 5720,5726 ----
// tell that we are parsing headers and footers
m_parsingHdrFtr = true;
+ m_newParaFlagged = true;
_parseFile (NULL);
m_parsingHdrFtr = false;
}
***************
*** 5862,5869 ****
attribs[attribsCount++] = NULL;
attribs[attribsCount] = NULL;
}
! else
{
char * val = (char
*)m_styleTable.getNthItem(parameter);
if (val != NULL)
{
--- 5863,5871 ----
attribs[attribsCount++] = NULL;
attribs[attribsCount] = NULL;
}
! else if(0)
{
+ // TODO: Why is this code here? It left over
+from before the BasedOn array
char * val = (char
*)m_styleTable.getNthItem(parameter);
if (val != NULL)
{
***************
*** 5890,5895 ****
--- 5892,5898 ----
}
else if(parameter < styleNumber)
{
+ // TODO: Why is this code here? It left over
+from before the FollowedBy array
char * val = (char
*)m_styleTable.getNthItem(parameter);
if (val != NULL)
{