[Libreoffice-commits] core.git: sw/source
Oliver-Rainer Wittmann
orw at apache.org
Wed May 15 04:06:04 PDT 2013
sw/source/filter/ww8/rtfattributeoutput.cxx | 17 +++++++++++++++--
1 file changed, 15 insertions(+), 2 deletions(-)
New commits:
commit a0aef8dc44a9ff5899dc920c31a39caeb92043c4
Author: Oliver-Rainer Wittmann <orw at apache.org>
Date: Wed Jun 27 10:07:50 2012 +0000
Resolves: #i119803# RTF export for User Fields
implementation for method <RtfAttributeOutput::WriteExpand(..)>
Found by: ej197us at gmail dot com
Patch by: yuanlin <yuanlin.ibm at gmail dot com>
Review by: Oliver <orw at apache dot org>
(cherry picked from commit 4536f0b98bc01850bf016dc1f60f0156cb7eb99e)
Conflicts:
sw/source/filter/ww8/rtfattributeoutput.cxx
Change-Id: I1cde654dadd26e214a1c097fe2e0aeaa376195c2
diff --git a/sw/source/filter/ww8/rtfattributeoutput.cxx b/sw/source/filter/ww8/rtfattributeoutput.cxx
index c4bcba1..d726cb5 100644
--- a/sw/source/filter/ww8/rtfattributeoutput.cxx
+++ b/sw/source/filter/ww8/rtfattributeoutput.cxx
@@ -3119,8 +3119,21 @@ void RtfAttributeOutput::FormatFrameDirection( const SvxFrameDirectionItem& rDir
void RtfAttributeOutput::WriteExpand( const SwField* pFld )
{
SAL_INFO("sw.rtf", OSL_THIS_FUNC);
- String sCmd;
- m_rExport.OutputField(pFld, ww::eUNKNOWN, sCmd);
+ String sCmd; // for optional Parameters
+ switch (pFld->GetTyp()->Which())
+ {
+ //#i119803# Export user field and DB field for RTF filter
+ case RES_DBFLD:
+ sCmd = FieldString(ww::eMERGEFIELD);
+ // no break !!
+ case RES_USERFLD:
+ sCmd += pFld->GetTyp()->GetName();
+ m_rExport.OutputField(pFld, ww::eNONE, sCmd);
+ break;
+ default:
+ m_rExport.OutputField(pFld, ww::eUNKNOWN, sCmd);
+ break;
+ }
}
void RtfAttributeOutput::RefField( const SwField& /*rFld*/, const String& /*rRef*/ )
More information about the Libreoffice-commits
mailing list