summaryrefslogtreecommitdiff
path: root/sw/source/filter/html/htmlfldw.cxx
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2011-09-14 00:32:14 +0100
committerCaolán McNamara <caolanm@redhat.com>2011-09-14 09:54:09 +0100
commit79dc19fcbdb1e6aa9a8958a8b3d1fbf0451646cf (patch)
tree79f7d3f5490aa81fd24f14c3232465592ff71b50 /sw/source/filter/html/htmlfldw.cxx
parent98ae11bcd4b24c5616a4aefd4b865fcbe87814ef (diff)
ByteString->rtl::OStringBuffer
Diffstat (limited to 'sw/source/filter/html/htmlfldw.cxx')
-rw-r--r--sw/source/filter/html/htmlfldw.cxx26
1 files changed, 14 insertions, 12 deletions
diff --git a/sw/source/filter/html/htmlfldw.cxx b/sw/source/filter/html/htmlfldw.cxx
index 0a4638d5c1ff..10f4c0b9c7fc 100644
--- a/sw/source/filter/html/htmlfldw.cxx
+++ b/sw/source/filter/html/htmlfldw.cxx
@@ -458,8 +458,9 @@ Writer& OutHTML_SwFmtFld( Writer& rWrt, const SfxPoolItem& rHt )
rWrt.Strm() << '/';
// TODO: HTML-Tags are written without entitities, that for, characters
// not contained in the destination encoding are lost!
- ByteString sTmp( rTxt, ((SwHTMLWriter&)rWrt).eDestEnc );
- rWrt.Strm() << sTmp.GetBuffer() << '>';
+ rtl::OString sTmp(rtl::OUStringToOString(rTxt,
+ ((SwHTMLWriter&)rWrt).eDestEnc));
+ rWrt.Strm() << sTmp.getStr() << '>';
}
else if( RES_POSTITFLD == pFldTyp->Which() )
{
@@ -480,8 +481,9 @@ Writer& OutHTML_SwFmtFld( Writer& rWrt, const SfxPoolItem& rHt )
sComment.ConvertLineEnd( GetSystemLineEnd() );
// TODO: HTML-Tags are written without entitities, that for,
// characters not contained in the destination encoding are lost!
- ByteString sTmp( sComment, ((SwHTMLWriter&)rWrt).eDestEnc );
- rWrt.Strm() << sTmp.GetBuffer();
+ rtl::OString sTmp(rtl::OUStringToOString(sComment,
+ ((SwHTMLWriter&)rWrt).eDestEnc));
+ rWrt.Strm() << sTmp.getStr();
bWritten = sal_True;
}
else if( rComment.Len() >= 7 &&
@@ -496,8 +498,9 @@ Writer& OutHTML_SwFmtFld( Writer& rWrt, const SfxPoolItem& rHt )
// TODO: HTML-Tags are written without entitities, that for,
// characters not contained in the destination encoding are
// lost!
- ByteString sTmp( sComment, ((SwHTMLWriter&)rWrt).eDestEnc );
- rWrt.Strm() << sTmp.GetBuffer();
+ rtl::OString sTmp(rtl::OUStringToOString(sComment,
+ ((SwHTMLWriter&)rWrt).eDestEnc));
+ rWrt.Strm() << sTmp.getStr();
bWritten = sal_True;
}
@@ -505,15 +508,14 @@ Writer& OutHTML_SwFmtFld( Writer& rWrt, const SfxPoolItem& rHt )
if( !bWritten )
{
- ByteString sOut( '<' );
-
String sComment( rComment );
sComment.ConvertLineEnd( GetSystemLineEnd() );
+ rtl::OStringBuffer sOut;
// TODO: ???
- (((sOut += OOO_STRING_SVTOOLS_HTML_comment) += ' ')
- += ByteString( sComment, ((SwHTMLWriter&)rWrt).eDestEnc ))
- += " -->";
- rWrt.Strm() << sOut.GetBuffer();
+ sOut.append('<').append(OOO_STRING_SVTOOLS_HTML_comment)
+ .append(' ').append(rtl::OUStringToOString(sComment,
+ ((SwHTMLWriter&)rWrt).eDestEnc)).append(" -->");
+ rWrt.Strm() << sOut.getStr();
}
}
else if( RES_SCRIPTFLD == pFldTyp->Which() )