summaryrefslogtreecommitdiffstats
path: root/writerfilter
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@frugalware.org>2012-01-21 00:58:48 +0100
committerMiklos Vajna <vmiklos@frugalware.org>2012-01-21 01:02:10 +0100
commitc39e891d4dc963d2cac9843b426494e4dc490278 (patch)
treec1d3eb1bae36f58fef24bc801941e7ec099e9100 /writerfilter
parentkill some doxygen warnings (diff)
downloadcore-c39e891d4dc963d2cac9843b426494e4dc490278.tar.gz
core-c39e891d4dc963d2cac9843b426494e4dc490278.zip
fdo#44983 Fix RTF import of \paperh and \paperw
These keywords should not only set the *default* paper height/width but also set the current values.
Diffstat (limited to 'writerfilter')
-rw-r--r--writerfilter/source/rtftok/rtfdocumentimpl.cxx10
1 files changed, 4 insertions, 6 deletions
diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
index 0a1fafbd489c..aab8952c7f1a 100644
--- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx
+++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
@@ -2366,18 +2366,16 @@ int RTFDocumentImpl::dispatchValue(RTFKeyword nKeyword, int nParam)
pIntValue));
}
break;
- case RTF_PAPERH:
+ case RTF_PAPERH: // fall through: set the default + current value
lcl_putNestedAttribute(m_aDefaultState.aSectionSprms,
NS_ooxml::LN_EG_SectPrContents_pgSz, NS_ooxml::LN_CT_PageSz_h, pIntValue, true);
- break;
- case RTF_PAPERW:
- lcl_putNestedAttribute(m_aDefaultState.aSectionSprms,
- NS_ooxml::LN_EG_SectPrContents_pgSz, NS_ooxml::LN_CT_PageSz_w, pIntValue, true);
- break;
case RTF_PGHSXN:
lcl_putNestedAttribute(m_aStates.top().aSectionSprms,
NS_ooxml::LN_EG_SectPrContents_pgSz, NS_ooxml::LN_CT_PageSz_h, pIntValue, true);
break;
+ case RTF_PAPERW: // fall through: set the default + current value
+ lcl_putNestedAttribute(m_aDefaultState.aSectionSprms,
+ NS_ooxml::LN_EG_SectPrContents_pgSz, NS_ooxml::LN_CT_PageSz_w, pIntValue, true);
case RTF_PGWSXN:
lcl_putNestedAttribute(m_aStates.top().aSectionSprms,
NS_ooxml::LN_EG_SectPrContents_pgSz, NS_ooxml::LN_CT_PageSz_w, pIntValue, true);