diff options
-rw-r--r-- | sw/source/filter/html/htmlfldw.cxx | 16 | ||||
-rw-r--r-- | sw/source/filter/html/swhtml.cxx | 25 |
2 files changed, 31 insertions, 10 deletions
diff --git a/sw/source/filter/html/htmlfldw.cxx b/sw/source/filter/html/htmlfldw.cxx index f1eb6b2deecf..3b4cd3d77c03 100644 --- a/sw/source/filter/html/htmlfldw.cxx +++ b/sw/source/filter/html/htmlfldw.cxx @@ -2,9 +2,9 @@ * * $RCSfile: htmlfldw.cxx,v $ * - * $Revision: 1.1.1.1 $ + * $Revision: 1.2 $ * - * last change: $Author: hr $ $Date: 2000-09-18 17:14:55 $ + * last change: $Author: mib $ $Date: 2000-12-08 15:14:18 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -467,9 +467,12 @@ Writer& OutHTML_SwFmtFld( Writer& rWrt, const SfxPoolItem& rHt ) const String& rComment = pFld->GetPar2(); BOOL bWritten = FALSE; - if( rComment.Len() >= 6 && '<' == rComment.GetChar(0) && + if( (rComment.Len() >= 6 && '<' == rComment.GetChar(0) && '>' == rComment.GetChar(rComment.Len()-1) && - rComment.Copy( 1, 4 ).EqualsIgnoreCaseAscii(sHTML_meta) ) + rComment.Copy( 1, 4 ).EqualsIgnoreCaseAscii(sHTML_meta)) || + (rComment.Len() >= 7 && + rComment.Copy( 0, 4 ).EqualsAscii( "<!--" ) && + rComment.Copy( rComment.Len()-3, 3 ).EqualsAscii( "-->" )) ) { // META-Tags direkt ausgeben String sComment( rComment ); @@ -546,11 +549,14 @@ Writer& OutHTML_SwFmtFld( Writer& rWrt, const SfxPoolItem& rHt ) Source Code Control System - Header - $Header: /zpool/svn/migration/cvs_rep_09_09_08/code/sw/source/filter/html/htmlfldw.cxx,v 1.1.1.1 2000-09-18 17:14:55 hr Exp $ + $Header: /zpool/svn/migration/cvs_rep_09_09_08/code/sw/source/filter/html/htmlfldw.cxx,v 1.2 2000-12-08 15:14:18 mib Exp $ Source Code Control System - Update $Log: not supported by cvs2svn $ + Revision 1.1.1.1 2000/09/18 17:14:55 hr + initial import + Revision 1.36 2000/09/18 16:04:44 willem.vandorp OpenOffice header added. diff --git a/sw/source/filter/html/swhtml.cxx b/sw/source/filter/html/swhtml.cxx index ee83612c5c00..5ce73794e661 100644 --- a/sw/source/filter/html/swhtml.cxx +++ b/sw/source/filter/html/swhtml.cxx @@ -2,9 +2,9 @@ * * $RCSfile: swhtml.cxx,v $ * - * $Revision: 1.5 $ + * $Revision: 1.6 $ * - * last change: $Author: jp $ $Date: 2000-11-20 14:45:26 $ + * last change: $Author: mib $ $Date: 2000-12-08 15:14:18 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -1989,9 +1989,21 @@ void __EXPORT SwHTMLParser::NextToken( int nToken ) if( aToken.Len() > 5 ) { // als Post-It einfuegen - String aComment( aToken.Copy( 3, aToken.Len()-5 ) ); - aComment.EraseLeadingChars().EraseTrailingChars(); - InsertComment( aComment ); + // MIB 8.12.2000: If there are no space characters right behind + // the <!-- and on front of the -->, leave the comment untouched. + if( ' ' == aToken.GetChar( 3 ) && + ' ' == aToken.GetChar( aToken.Len()-3 ) ) + { + String aComment( aToken.Copy( 3, aToken.Len()-5 ) ); + aComment.EraseLeadingChars().EraseTrailingChars(); + InsertComment( aComment ); + } + else + { + String aComment( '<' ); + (aComment += aToken) += '>'; + InsertComment( aComment ); + } } break; @@ -5237,6 +5249,9 @@ void _HTMLAttr::InsertPrev( _HTMLAttr *pPrv ) /************************************************************************* $Log: not supported by cvs2svn $ + Revision 1.5 2000/11/20 14:45:26 jp + UpdateDocState without second parameter + Revision 1.4 2000/11/15 16:26:50 hr #65293# includes |