Hi,

See
http://cgit.freedesktop.org/libreoffice/core/commit/?id=6f7defd

Regression from 3.4; backported patch attached.

Thanks,

Miklos
>From 1bd34686c06e97821b8ad224b831b5a2d0c7c0ea Mon Sep 17 00:00:00 2001
From: Miklos Vajna <[email protected]>
Date: Wed, 25 Apr 2012 17:51:45 +0200
Subject: [PATCH] fdo#48037 fix RTF import of localized fields

---
 writerfilter/source/rtftok/rtfdocumentimpl.cxx |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
index ff81727..7c2b92d 100644
--- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx
+++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
@@ -2198,6 +2198,9 @@ int RTFDocumentImpl::dispatchValue(RTFKeyword nKeyword, int nParam)
     if (nSprm > 0)
     {
         m_aStates.top().aCharacterSprms->push_back(make_pair(nSprm, pIntValue));
+        // Language is a character property, but we should store it at a paragraph level as well for fields.
+        if (nKeyword == RTF_LANG && m_bNeedPap)
+            m_aStates.top().aParagraphSprms->push_back(make_pair(nSprm, pIntValue));
         return 0;
     }
     // Trivial paragraph sprms.
-- 
1.7.7

_______________________________________________
LibreOffice mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice

Reply via email to