summaryrefslogtreecommitdiff
path: root/svtools/source/svrtf/rtfout.cxx
diff options
context:
space:
mode:
authorjp <jp@openoffice.org>2000-10-16 08:13:46 +0000
committerjp <jp@openoffice.org>2000-10-16 08:13:46 +0000
commit85a28d00993da7000273d6282b59189c4ddc1d49 (patch)
tree54dce6b6df69f49276672ba413f65b77428d2bf0 /svtools/source/svrtf/rtfout.cxx
parent4bb7fb9d3fe1bb4625ec3015df76fdd1657fecf1 (diff)
Bug #79483#: write unicode characters
Diffstat (limited to 'svtools/source/svrtf/rtfout.cxx')
-rw-r--r--svtools/source/svrtf/rtfout.cxx22
1 files changed, 14 insertions, 8 deletions
diff --git a/svtools/source/svrtf/rtfout.cxx b/svtools/source/svrtf/rtfout.cxx
index 8793547f06b3..a053c4a44009 100644
--- a/svtools/source/svrtf/rtfout.cxx
+++ b/svtools/source/svrtf/rtfout.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: rtfout.cxx,v $
*
- * $Revision: 1.1.1.1 $
+ * $Revision: 1.2 $
*
- * last change: $Author: hr $ $Date: 2000-09-18 16:59:05 $
+ * last change: $Author: jp $ $Date: 2000-10-16 09:13:46 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -67,8 +67,8 @@
#* Beschreibung DOKUNAME.DOC
#*
#* Ersterstellung JP 20.02.96
-#* Letzte Aenderung $Author: hr $ $Date: 2000-09-18 16:59:05 $
-#* $Revision: 1.1.1.1 $
+#* Letzte Aenderung $Author: jp $ $Date: 2000-10-16 09:13:46 $
+#* $Revision: 1.2 $
#*
#* $Logfile: T:/svtools/source/svrtf/rtfout.cxv $
#*
@@ -128,10 +128,16 @@ SvStream& RTFOutFuncs::Out_Char( SvStream& rStream, sal_Unicode c,
if( !c )
{
// then write as unicode - character
- // rWrt.Strm() << "\\u";
- // rWrt.OutULong( eCh ) << " ?";
- rStream << "\\'";
- Out_Hex( rStream, cCh, 2 );
+ if( 0xFF < cCh )
+ {
+ ByteString sNo( ByteString::CreateFromInt32( cCh ));
+ rStream << "\\u" << sNo.GetBuffer() << " ?";
+ }
+ else
+ {
+ rStream << "\\'";
+ Out_Hex( rStream, cCh, 2 );
+ }
break;
}