Kaydet (Commit) 2a4e77a6 authored tarafından Cédric Bosdonnat's avatar Cédric Bosdonnat

Revert "make text wrapping work in headers/footers too (fdo#39155)"

This reverts commit e2a8fb04. This is a
feature, not a bug and would cause loads of documents to be badly
rendered.

Link to the spec that brough that feature:
    http://www.openoffice.org/specs/writer/compatibility/adjust-text-wrapping.sxw

Conflicts:

	sw/source/core/text/txtfly.cxx
üst 1e18fdb2
...@@ -886,7 +886,14 @@ SwAnchoredObjList* SwTxtFly::InitAnchoredObjList() ...@@ -886,7 +886,14 @@ SwAnchoredObjList* SwTxtFly::InitAnchoredObjList()
const SwSortedObjs *pSorted = pPage->GetSortedObjs(); const SwSortedObjs *pSorted = pPage->GetSortedObjs();
const sal_uInt32 nCount = pSorted ? pSorted->Count() : 0; const sal_uInt32 nCount = pSorted ? pSorted->Count() : 0;
const sal_Bool bWrapAllowed = !SwLayouter::FrmNotToWrap( *pCurrFrm->GetTxtNode()->getIDocumentLayoutAccess(), *pCurrFrm ); // --> #108724# Page header/footer content doesn't have to wrap around
// floating screen objects
const bool bFooterHeader = 0 != pCurrFrm->FindFooterOrHeader();
const IDocumentSettingAccess* pIDSA = pCurrFrm->GetTxtNode()->getIDocumentSettingAccess();
// #i40155# - check, if frame is marked not to wrap
const sal_Bool bWrapAllowed = ( pIDSA->get(IDocumentSettingAccess::USE_FORMER_TEXT_WRAPPING) ||
( !pCurrFrm->IsInFtn() && !bFooterHeader ) ) &&
!SwLayouter::FrmNotToWrap( *pCurrFrm->GetTxtNode()->getIDocumentLayoutAccess(), *pCurrFrm );
bOn = sal_False; bOn = sal_False;
...@@ -898,7 +905,6 @@ SwAnchoredObjList* SwTxtFly::InitAnchoredObjList() ...@@ -898,7 +905,6 @@ SwAnchoredObjList* SwTxtFly::InitAnchoredObjList()
// #i28701# - consider complete frame area for new // #i28701# - consider complete frame area for new
// text wrapping // text wrapping
SwRect aRect; SwRect aRect;
const IDocumentSettingAccess* pIDSA = pCurrFrm->GetTxtNode()->getIDocumentSettingAccess();
if ( pIDSA->get(IDocumentSettingAccess::USE_FORMER_TEXT_WRAPPING) ) if ( pIDSA->get(IDocumentSettingAccess::USE_FORMER_TEXT_WRAPPING) )
{ {
aRect = pCurrFrm->Prt(); aRect = pCurrFrm->Prt();
...@@ -914,7 +920,6 @@ SwAnchoredObjList* SwTxtFly::InitAnchoredObjList() ...@@ -914,7 +920,6 @@ SwAnchoredObjList* SwTxtFly::InitAnchoredObjList()
const long nRight = (aRect.*fnRect->fnGetRight)() - 1; const long nRight = (aRect.*fnRect->fnGetRight)() - 1;
const long nLeft = (aRect.*fnRect->fnGetLeft)() + 1; const long nLeft = (aRect.*fnRect->fnGetLeft)() + 1;
const sal_Bool bR2L = pCurrFrm->IsRightToLeft(); const sal_Bool bR2L = pCurrFrm->IsRightToLeft();
const bool bFooterHeader = ( pCurrFrm->FindFooterOrHeader() != NULL );
const IDocumentDrawModelAccess* pIDDMA = pCurrFrm->GetTxtNode()->getIDocumentDrawModelAccess(); const IDocumentDrawModelAccess* pIDDMA = pCurrFrm->GetTxtNode()->getIDocumentDrawModelAccess();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment