summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorMuthu Subramanian <sumuthu@suse.com>2012-06-15 17:20:20 +0530
committerMuthu Subramanian K <sumuthu@suse.com>2012-10-13 13:30:47 +0530
commit28a2ae34a4bc97a526cf75a2766089ff0f2c54c1 (patch)
tree5511f12b3f0a1b1a093a31e19241894c4a2bdf7b /svx
parentb1653c6b3968921ffee34bab2106c6d4e800179c (diff)
n757419: Hidden/Non-wrapping text.
Negative values for left-margin plays havoc with the text in this case.
Diffstat (limited to 'svx')
-rw-r--r--svx/source/unodraw/unoshape.cxx9
1 files changed, 8 insertions, 1 deletions
diff --git a/svx/source/unodraw/unoshape.cxx b/svx/source/unodraw/unoshape.cxx
index 16af6ec00883..4c21d47429f0 100644
--- a/svx/source/unodraw/unoshape.cxx
+++ b/svx/source/unodraw/unoshape.cxx
@@ -4299,11 +4299,18 @@ uno::Any SvxItemPropertySet_getPropertyValue( const SvxItemPropertySet& rPropSet
void SvxItemPropertySet_setPropertyValue( const SvxItemPropertySet& rPropSet, const SfxItemPropertySimpleEntry* pMap, const uno::Any& rVal, SfxItemSet& rSet )
{
+ uno::Any aVal(rVal);
if(!pMap || !pMap->nWID)
return;
bool bDontConvertNegativeValues = ( pMap->nWID == XATTR_FILLBMP_SIZEX || pMap->nWID == XATTR_FILLBMP_SIZEY );
- rPropSet.setPropertyValue( pMap, rVal, rSet, bDontConvertNegativeValues );
+ if( pMap->nWID == EE_PARA_LRSPACE ) // n#757419 Don't import negative values
+ {
+ sal_Int32 nVal;
+ if( (aVal >>= nVal) && nVal < 0 )
+ aVal <<= ( sal_Int32 ) 0;
+ }
+ rPropSet.setPropertyValue( pMap, aVal, rSet, bDontConvertNegativeValues );
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */