diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2021-03-01 10:37:49 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2021-03-01 20:56:03 +0100 |
commit | ebceee31d92f04b58e795d02a26f62b717c47737 (patch) | |
tree | 137df2f7e371a7183de62f2b62ecc77462e7dc4e /editeng/source/items | |
parent | 7def8c3cd8a1d9b4df2478210055b06382e6d493 (diff) |
tdf#140342 sw layout: remove explicit gutter handling when positioning borders
Word has two modes the specify border positions: the distance can be
measured from the edge of the page or from text. Similar to how
documents that have page borders but no gutter, page page border +
gutter documents should be always measured "from text" by the layout.
"From page" should be a concern for Word filters.
"From page" was already working -- fix "from text" by changing the
layout to do "from text" and then extending DOCX import/export to handle
gutter while handling the "from page" page borders.
This also requires allowing nominally negative top margins, because we
want to have the gutter unchanged, but the border might want to be on
the gutter area, which is only possible with a negative top margin.
Change-Id: I7f2c9943357359e76cb554cb2a65b93a492e694b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111735
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Diffstat (limited to 'editeng/source/items')
-rw-r--r-- | editeng/source/items/frmitems.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/editeng/source/items/frmitems.cxx b/editeng/source/items/frmitems.cxx index 45cd825eab54..d010089b3052 100644 --- a/editeng/source/items/frmitems.cxx +++ b/editeng/source/items/frmitems.cxx @@ -725,7 +725,7 @@ bool SvxULSpaceItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId ) } break; case MID_UP_MARGIN : - if(!(rVal >>= nVal) || nVal < 0) + if(!(rVal >>= nVal)) return false; SetUpper(static_cast<sal_uInt16>(bConvert ? convertMm100ToTwip(nVal) : nVal)); break; |