diff options
author | Miklos Vajna <vmiklos@suse.cz> | 2012-02-13 12:52:21 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@frugalware.org> | 2012-02-13 12:54:18 +0100 |
commit | e0328096dc21ce12d15db2045074e7860872570f (patch) | |
tree | cb9a666ff4474391dcf2be104e0582324d8a3fc8 /writerfilter | |
parent | Integrate Josh Heidenreich's nice README parser as start page. (diff) | |
download | core-e0328096dc21ce12d15db2045074e7860872570f.tar.gz core-e0328096dc21ce12d15db2045074e7860872570f.zip |
n#695479 fix RTF import of text frames with exact height
Diffstat (limited to 'writerfilter')
-rw-r--r-- | writerfilter/source/rtftok/rtfdocumentimpl.cxx | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx b/writerfilter/source/rtftok/rtfdocumentimpl.cxx index 8f3f31121a1b..bd02037edcff 100644 --- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx +++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx @@ -3385,6 +3385,7 @@ RTFSprms RTFFrame::getSprms() { NS_ooxml::LN_CT_FramePr_x, NS_ooxml::LN_CT_FramePr_y, + NS_ooxml::LN_CT_FramePr_hRule, // Make sure nHRule is processed before nH NS_sprm::LN_PWHeightAbs, NS_sprm::LN_PDxaWidth, NS_sprm::LN_PDxaFromText, @@ -3395,8 +3396,7 @@ RTFSprms RTFFrame::getSprms() NS_ooxml::LN_CT_FramePr_yAlign, NS_sprm::LN_PWr, NS_ooxml::LN_CT_FramePr_dropCap, - NS_ooxml::LN_CT_FramePr_lines, - NS_ooxml::LN_CT_FramePr_hRule + NS_ooxml::LN_CT_FramePr_lines }; for ( int i = 0, len = sizeof( pNames ) / sizeof( Id ); i < len; ++i ) @@ -3448,7 +3448,10 @@ RTFSprms RTFFrame::getSprms() { sal_Int32 nHRule = NS_ooxml::LN_Value_wordprocessingml_ST_HeightRule_auto; if ( nH < 0 ) + { nHRule = NS_ooxml::LN_Value_wordprocessingml_ST_HeightRule_exact; + nH = -nH; // The negative value just sets nHRule + } else if ( nH > 0 ) nHRule = NS_ooxml::LN_Value_wordprocessingml_ST_HeightRule_atLeast; pValue.reset(new RTFValue(nHRule)); |