core.git: Branch 'libreoffice-7-6' - 2 commits - sw/source
sw/source/core/docnode/ndtbl.cxx | 43 --- 1 file changed, 40 insertions(+), 3 deletions(-) New commits: commit 921abac0a5a0caa46875db640e3432379a5bcfa7 Author: Michael Stahl AuthorDate: Fri Mar 22 14:27:01 2024 +0100 Commit: Xisco Fauli CommitDate: Fri Mar 22 18:13:43 2024 +0100 tdf#157241 sw: assert when importing ToX in table in rhbz589883-2.docx ndtbl.cxx:1417: SwNodes::TextToTable(): Assertion `!rNode.IsSectionNode()' failed. (regression from commit 62cb3b8b8d6106c6aeb073b12d84973a107182ef) Change-Id: Iec12282573cb914d1924f4da4a28e26e01b866df Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165164 Tested-by: Michael Stahl Reviewed-by: Michael Stahl (cherry picked from commit df6fdb0041f8bfd251a4b03030b8bc47f0614c36) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165172 Tested-by: Jenkins Reviewed-by: Xisco Fauli diff --git a/sw/source/core/docnode/ndtbl.cxx b/sw/source/core/docnode/ndtbl.cxx index faabbf1d4953..b913f0c48a21 100644 --- a/sw/source/core/docnode/ndtbl.cxx +++ b/sw/source/core/docnode/ndtbl.cxx @@ -1413,16 +1413,19 @@ SwTableNode* SwNodes::TextToTable( const SwNodes::TableRanges_t & rTableNodes, // delete frames of all contained content nodes for( nLines = 0; aNodeIndex <= rTableNodes.rbegin()->rbegin()->aEnd; ++aNodeIndex,++nLines ) { -SwNode& rNode = aNodeIndex.GetNode(); -assert(!rNode.IsSectionNode()); // not possible in writerfilter import -if (rNode.IsTableNode()) +SwNode* pNode(()); +while (pNode->IsSectionNode()) // could be ToX field in table { -lcl_RemoveBreaksTable(static_cast(rNode), +pNode = pNode->GetNodes()[pNode->GetIndex()+1]; +} +if (pNode->IsTableNode()) +{ +lcl_RemoveBreaksTable(static_cast(*pNode), (0 == nLines) ? pTableFormat : nullptr); } -else if (rNode.IsContentNode()) +else if (pNode->IsContentNode()) { -lcl_RemoveBreaks(static_cast(rNode), +lcl_RemoveBreaks(static_cast(*pNode), (0 == nLines) ? pTableFormat : nullptr); } } commit 56676a8cb6899f376d9893392700e096ad589bed Author: Michael Stahl AuthorDate: Wed Mar 13 18:57:21 2024 +0100 Commit: Xisco Fauli CommitDate: Fri Mar 22 18:13:38 2024 +0100 tdf#157241 sw: fix crash on RTF paste or insert of nested tables The problem is that there are tables with only empty cell frames in the layout, which causes a crash in IsAllHiddenCell() added in commit ab7893544dc6be6dc192dffefd57cd5ddd421c35. This happens because first inner tables are created, with layout frames because the layout already exists. Then when SwNodes::TextToTable() is called for the outer table, it deletes the SwTextFrames, but not the SwTabFrames/SwCellFrames, so they remain uselessly in the layout. Delete these too, they will be recreated when the frame for the outer table is created. Also the transfer of any existing break to the outer table was missing. Change-Id: Idc2bc1d4c6572702510ae4355e4015c42770eb3e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164788 Tested-by: Jenkins Reviewed-by: Michael Stahl (cherry picked from commit 62cb3b8b8d6106c6aeb073b12d84973a107182ef) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164814 Reviewed-by: Xisco Fauli diff --git a/sw/source/core/docnode/ndtbl.cxx b/sw/source/core/docnode/ndtbl.cxx index cec3e7df57c4..faabbf1d4953 100644 --- a/sw/source/core/docnode/ndtbl.cxx +++ b/sw/source/core/docnode/ndtbl.cxx @@ -888,6 +888,34 @@ const SwTable* SwDoc::TextToTable( const SwInsertTableOptions& rInsTableOpts, return } +static void lcl_RemoveBreaksTable(SwTableNode & rNode, SwTableFormat *const pTableFormat) +{ +// delete old layout frames, new ones need to be created... +rNode.DelFrames(nullptr); + +// remove PageBreaks/PageDesc/ColBreak +SwFrameFormat & rFormat(*rNode.GetTable().GetFrameFormat()); + +if (const SvxFormatBreakItem* pItem = rFormat.GetItemIfSet(RES_BREAK, false)) +{ +if (pTableFormat) +{ +pTableFormat->SetFormatAttr(*pItem); +} +rFormat.ResetFormatAttr(RES_BREAK); +} + +SwFormatPageDesc const*const pPageDescItem(rFormat.GetItemIfSet(RES_PAGEDESC, false)); +if (pPageDescItem && pPageDescItem->GetPageDesc()) +{ +if (pTableFormat) +{ +pTableFormat->SetFormatAttr(*pPageDescItem); +} +rFormat.ResetFormatAttr(RES_PAGEDESC); +} +} + static void lcl_RemoveBreaks(SwContentNode & rNode, SwTableFormat *const pTableFormat) { // delete old layout frames, new ones need to be created... @@ -1386,7 +1414,13 @@ SwTableNode* SwNodes::TextToTable( const SwNodes::TableRanges_t &
[Libreoffice-commits] core.git: Branch 'libreoffice-7-6' - 2 commits - sw/source writerfilter/source
sw/source/core/inc/objectformatter.hxx |3 sw/source/core/layout/fly.cxx|6 - sw/source/core/layout/objectformatter.cxx|5 - writerfilter/source/dmapper/DomainMapper.cxx | 130 ++- writerfilter/source/dmapper/DomainMapper.hxx |1 5 files changed, 81 insertions(+), 64 deletions(-) New commits: commit 09c03d962566d7d7b968f13feac578bd94109ca8 Author: Michael Stahl AuthorDate: Thu Nov 16 13:31:10 2023 +0100 Commit: Xisco Fauli CommitDate: Wed Nov 29 14:13:36 2023 +0100 writerfilter: DomainMapper: fix undetected merge conflict ... between commit fce18155052821756466ea043c638f4ed72f41d6 and commit 15b886f460919ea3dce425a621dc017c2992a96b - move the code from lcl_text() to lcl_utext(). Change-Id: Iaa515d2ebd9861e24b442b0d7b41f83662ed58df Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159501 Tested-by: Michael Stahl Reviewed-by: Michael Stahl (cherry picked from commit 7b3f68257b7b6781dd22830bc118cb0ef92fb113) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159530 Tested-by: Jenkins Reviewed-by: Xisco Fauli diff --git a/writerfilter/source/dmapper/DomainMapper.cxx b/writerfilter/source/dmapper/DomainMapper.cxx index 7a9379698a59..0aeb3337f6f3 100644 --- a/writerfilter/source/dmapper/DomainMapper.cxx +++ b/writerfilter/source/dmapper/DomainMapper.cxx @@ -3923,65 +3923,7 @@ void DomainMapper::lcl_text(const sal_uInt8 * data_, size_t len) pContext->Insert(PROP_BREAK_TYPE, uno::Any(style::BreakType_COLUMN_BEFORE)); m_pImpl->clearDeferredBreak(COLUMN_BREAK); } -if (IsRTFImport() && pContext) { -//reset paragraph style properties not repeated at the paragraph -std::optional paraStyleName = pContext->getProperty(PROP_PARA_STYLE_NAME); -if (paraStyleName.has_value()) { -OUString uStyleName; -paraStyleName->second >>= uStyleName; -StyleSheetEntryPtr pStyleSheet = m_pImpl->GetStyleSheetTable()->FindStyleSheetByConvertedStyleName(uStyleName); -if (pStyleSheet != nullptr) -{ -std::vector< PropertyIds > stylePropertyIds = pStyleSheet->m_pProperties->GetPropertyIds(); -std::vector< PropertyIds >::iterator stylePropertyIdsIt = stylePropertyIds.begin(); -while (stylePropertyIdsIt != stylePropertyIds.end()) -{ -PropertyIds ePropertyId = *stylePropertyIdsIt; -std::optional< PropertyMap::Property > styleProperty = pStyleSheet->m_pProperties->getProperty(ePropertyId); -std::optional< PropertyMap::Property > paragraphProperty = pContext->getProperty(ePropertyId); -if (paragraphProperty.has_value()) { -if (paragraphProperty->second == styleProperty->second && - !isSPRMDeduplicateDenylist(ePropertyId, pContext)) -{ -pContext->Erase(ePropertyId); -} -} -else -{ -switch (ePropertyId) -{ -case PROP_PARA_LEFT_MARGIN: -if (!pContext->getProperty(PROP_NUMBERING_RULES)) -{ -pContext->Insert(ePropertyId, uno::Any(0l)); -} -break; -case PROP_PARA_RIGHT_MARGIN: -pContext->Insert(ePropertyId, uno::Any(0l)); -break; -case PROP_PARA_LAST_LINE_ADJUST: -case PROP_PARA_ADJUST: -pContext->Insert(ePropertyId, uno::Any(style::ParagraphAdjust_LEFT)); -break; -case PROP_PARA_TAB_STOPS: -pContext->Insert(ePropertyId, uno::Any(uno::Sequence< style::TabStop >())); -break; -case PROP_FILL_STYLE: -
[Libreoffice-commits] core.git: Branch 'libreoffice-7-6' - 2 commits - sw/source
sw/source/core/text/porfld.cxx |2 sw/source/core/text/porfld.hxx |1 sw/source/core/text/txtfld.cxx | 213 +++-- 3 files changed, 58 insertions(+), 158 deletions(-) New commits: commit a805185f569463bfc8d597e37c0c3a83be686d67 Author: Mike Kaganski AuthorDate: Wed Oct 25 12:34:51 2023 +0200 Commit: Michael Stahl CommitDate: Fri Oct 27 11:32:04 2023 +0200 Simplify SwTextFormatter::NewFieldPortion Change-Id: I7e5cbce45bba4550f572606f44300b914ff5a41c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158433 Tested-by: Jenkins Reviewed-by: Mike Kaganski Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158479 Reviewed-by: Michael Stahl diff --git a/sw/source/core/text/txtfld.cxx b/sw/source/core/text/txtfld.cxx index 22b5287fce1f..7ca9b9e34fd6 100644 --- a/sw/source/core/text/txtfld.cxx +++ b/sw/source/core/text/txtfld.cxx @@ -69,17 +69,24 @@ static bool lcl_IsInBody( SwFrame const *pFrame ) return pFrame->IsInDocBody(); } +static OUString ExpandField(const SwField& rField, const SwTextFormatter& rFormatter, +const SwTextFormatInfo& rInf) +{ +if (rInf.GetOpt().IsFieldName()) +return rField.GetFieldName(); + +const SwViewShell* pSh = rInf.GetVsh(); +const SwDoc* pDoc(pSh ? pSh->GetDoc() : nullptr); +const bool bInClipboard(!pDoc || pDoc->IsClipBoard()); +return rField.ExpandField(bInClipboard, rFormatter.GetTextFrame()->getRootFrame()); +} + SwExpandPortion *SwTextFormatter::NewFieldPortion( SwTextFormatInfo , const SwTextAttr *pHint ) const { -SwExpandPortion *pRet = nullptr; -SwFrame *pFrame = m_pFrame; SwField *pField = const_cast(pHint->GetFormatField().GetField()); const bool bName = rInf.GetOpt().IsFieldName(); -SwCharFormat* pChFormat = nullptr; -bool bNewFlyPor = false; - // set language const_cast(this)->SeekAndChg( rInf ); if (pField->GetLanguage() != GetFnt()->GetLanguage()) @@ -91,191 +98,100 @@ SwExpandPortion *SwTextFormatter::NewFieldPortion( SwTextFormatInfo , } SwViewShell *pSh = rInf.GetVsh(); -SwDoc *const pDoc( pSh ? pSh->GetDoc() : nullptr ); -bool const bInClipboard( pDoc == nullptr || pDoc->IsClipBoard() ); -bool bPlaceHolder = false; -switch( pField->GetTyp()->Which() ) +switch (pField->GetTyp()->Which()) { case SwFieldIds::Script: case SwFieldIds::Postit: -pRet = new SwPostItsPortion( SwFieldIds::Script == pField->GetTyp()->Which() ); -break; - +return new SwPostItsPortion(SwFieldIds::Script == pField->GetTyp()->Which()); case SwFieldIds::CombinedChars: -{ -if( bName ) -pRet = new SwFieldPortion( pField->GetFieldName() ); -else -pRet = new SwCombinedPortion( pField->ExpandField(bInClipboard, pFrame->getRootFrame()) ); -} +if (!bName) +return new SwCombinedPortion(ExpandField(*pField, *this, rInf)); break; - case SwFieldIds::HiddenText: -{ -OUString const aStr( bName -? pField->GetFieldName() -: pField->ExpandField(bInClipboard, pFrame->getRootFrame()) ); -pRet = new SwHiddenPortion(aStr); -} -break; - +return new SwHiddenPortion(ExpandField(*pField, *this, rInf)); case SwFieldIds::Chapter: -if( !bName && pSh && !pSh->Imp()->IsUpdateExpFields() ) +if (!bName && pSh && !pSh->Imp()->IsUpdateExpFields()) { -static_cast(pField)->ChangeExpansion(*pFrame, -_txtattr_cast(pHint)->GetTextNode()); -} -{ -OUString const aStr( bName -? pField->GetFieldName() -: pField->ExpandField(bInClipboard, pFrame->getRootFrame()) ); -pRet = new SwFieldPortion( aStr ); +static_cast(pField)->ChangeExpansion( +*m_pFrame, _txtattr_cast(pHint)->GetTextNode()); } break; - case SwFieldIds::DocStat: -if( !bName && pSh && !pSh->Imp()->IsUpdateExpFields() ) +if (!bName && pSh && !pSh->Imp()->IsUpdateExpFields()) { -static_cast(pField)->ChangeExpansion( pFrame ); -} -{ -OUString const aStr( bName -? pField->GetFieldName() -: pField->ExpandField(bInClipboard, pFrame->getRootFrame()) ); -pRet = new SwFieldPortion( aStr ); + static_cast(pField)->ChangeExpansion(m_pFrame); } break; - case SwFieldIds::PageNumber: -{ -if( !bName && pSh &&
[Libreoffice-commits] core.git: Branch 'libreoffice-7-6' - 2 commits - sw/source
sw/source/core/layout/calcmove.cxx |9 - sw/source/core/layout/fly.cxx | 13 + 2 files changed, 21 insertions(+), 1 deletion(-) New commits: commit 4a8041bc4ddadd91aec6038a380ab4ce2279d27a Author: Michael Stahl AuthorDate: Thu Aug 17 13:30:38 2023 +0200 Commit: Xisco Fauli CommitDate: Tue Aug 22 20:59:24 2023 +0200 tdf#156728 sw: layout: invalidate fly on header/footer size On page 30 there are at-page anchored shapes Shape22, Shape23 and Shape25. Shape22 and Shape23 are positioned relative to the bottom of the page text area, and that is working; Shape25 is positioned with an offset to the top of the page text area, and that doesn't work. The problem is that the shapes are positioned when the header on the page hasn't been formatted yet, and once the header is formatted, the position of the Shape25 is not invalidated, so it's a header-height too far up. (regression from commit 425a252c3cc5e5a79a533965026dd4af6b8df739) Change-Id: Ic907d98b1bcd4bb544fd1af9bf93ebc7b75bf362 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155762 Tested-by: Jenkins Reviewed-by: Michael Stahl (cherry picked from commit ee82accbd0d67eaf0f5a164a82b86abd00c3b0c9) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155774 Reviewed-by: Xisco Fauli diff --git a/sw/source/core/layout/fly.cxx b/sw/source/core/layout/fly.cxx index c2d27eaf2f0e..a06c2a9e7f70 100644 --- a/sw/source/core/layout/fly.cxx +++ b/sw/source/core/layout/fly.cxx @@ -2718,10 +2718,23 @@ void SwLayoutFrame::NotifyLowerObjs( const bool _bUnlockPosOfObjs ) { assert( dynamic_cast( pObj) && "GetFrameFormat().GetVertOrient().GetRelationOrient()); +if (nO == text::RelOrientation::PAGE_PRINT_AREA +|| nO == text::RelOrientation::PAGE_PRINT_AREA_BOTTOM +|| nO == text::RelOrientation::PAGE_PRINT_AREA_TOP) +{ +isPositionedByHF = true; +} +} // #i26945# - use to check, if // fly frame is lower of layout frame resp. if fly frame is // at a different page registered as its anchor frame is on. if ( IsAnLower( pAnchorFrame ) || + isPositionedByHF || pAnchorFrame->FindPageFrame() != pPageFrame ) { // #i44016# commit 9b6a4fcc010bdb740a5b3581a47327f45ee05718 Author: Michael Stahl AuthorDate: Wed Aug 16 16:09:12 2023 +0200 Commit: Xisco Fauli CommitDate: Tue Aug 22 20:59:13 2023 +0200 tdf#156727 sw: layout: allow MoveBwd if previous has keep-with-next In the pathological fdo56431-6.odt there are 16 pages of 1-line paragraphs that all have keep-with-next set, and only the first of them has a page break before. The layout temporarily uses 5 pages for the table of content at the start but then everything fits on 4 pages, so page 5 is empty. Now the first text frame on page 6 moves backward despite its keep-with-next, because it hits SwFlowFrame::SetMoveBwdJump(true) in SwFrame::GetPrevLeaf(). The next one however nopes out in SwContentFrame::WouldFit_(). This is because it continues along the sequence of keep-with-next frames until it runs out of space in the new upper; this happens with a frame that's actually on page 7. Ignore keep-with-next in case the previous frame in the new upper also has it set, because it really doesn't mean anything then. (somehow regression from commit 25a252c3cc5e5a79a533965026dd4af6b8df739) Change-Id: I0cfbc8b67bd0b95dfe08054660a2935de923a661 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155741 Tested-by: Jenkins Reviewed-by: Michael Stahl (cherry picked from commit 169b4d72b28b05e1a14d9b00571f7488200e39c2) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155709 Reviewed-by: Xisco Fauli diff --git a/sw/source/core/layout/calcmove.cxx b/sw/source/core/layout/calcmove.cxx index 820d7834027b..5fb30d5c7afa 100644 --- a/sw/source/core/layout/calcmove.cxx +++ b/sw/source/core/layout/calcmove.cxx @@ -2004,6 +2004,12 @@ bool SwContentFrame::WouldFit_( SwTwips nSpace, pTmpPrev = static_cast(pTmpPrev)->Lower(); while ( pTmpPrev && pTmpPrev->GetNext() ) pTmpPrev = pTmpPrev->GetNext(); + +// tdf#156727 if the previous one has keep-with-next, ignore it on this one! +bool const isIgnoreKeep(pTmpPrev && pTmpPrev->IsFlowFrame() +&& SwFlowFrame::CastFlowFrame(pTmpPrev)->IsKeep( +pTmpPrev->GetAttrSet()->GetKeep(), pTmpPrev->GetBreakItem())); + do { // #i46181# @@ -2153,7 +2159,8 @@ bool SwContentFrame::WouldFit_( SwTwips nSpace, } } -if (bRet && !bSplit &&
[Libreoffice-commits] core.git: Branch 'libreoffice-7-6' - 2 commits - sw/source
sw/source/core/docnode/nodes.cxx | 69 --- 1 file changed, 43 insertions(+), 26 deletions(-) New commits: commit c69f4a34c65572fbfe01298d90cb0aa6c7afb4de Author: Michael Stahl AuthorDate: Wed Jul 19 15:54:07 2023 +0200 Commit: Caolán McNamara CommitDate: Tue Jul 25 20:51:30 2023 +0200 tdf#153115 sw: fix yet another FindPrvNxtFrameNode() issue In the SwUndoTextToTable for the middle cell it happens that there is no frame remaining in the cell frame and SwNodes::FindPrvNxtFrameNode() erroneously returns a frame from inside the preceding cell, so it creates the frame in the wrong cell. (regression from commit faf2d9e2cb13c3750ac359338f8f31fc1afce368) Change-Id: I2e4f460541e20dda23c1fafb6d63c023dae9b152 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154654 Tested-by: Jenkins Reviewed-by: Michael Stahl (cherry picked from commit ba99cc9d9cf781d9b3888e1cf5becd95bb9fc6d2) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154622 Reviewed-by: Caolán McNamara diff --git a/sw/source/core/docnode/nodes.cxx b/sw/source/core/docnode/nodes.cxx index 45a02bf5d5a0..c045aa57023d 100644 --- a/sw/source/core/docnode/nodes.cxx +++ b/sw/source/core/docnode/nodes.cxx @@ -2239,7 +2239,8 @@ SwNode* SwNodes::FindPrvNxtFrameNode( const SwNode& rFrameNd, pFrameNd = (); } } -else +else if (pFrameNd->IsSectionNode() +|| (pFrameNd->IsEndNode() && pFrameNd->StartOfSectionNode()->IsSectionNode())) { pFrameNd = GoPrevSection( , true, false ); // did we move *into* a table? @@ -2272,6 +2273,10 @@ SwNode* SwNodes::FindPrvNxtFrameNode( const SwNode& rFrameNd, pFrameNd = nullptr; // no preceding content node, stop search } } +else +{ +pFrameNd = nullptr; // no preceding content node, stop search +} } while (pFrameNd != nullptr); @@ -2312,7 +2317,8 @@ SwNode* SwNodes::FindPrvNxtFrameNode( const SwNode& rFrameNd, pFrameNd = (); } } -else +else if (pFrameNd->IsSectionNode() +|| (pFrameNd->IsEndNode() && pFrameNd->StartOfSectionNode()->IsSectionNode())) { pFrameNd = GoNextSection( , true, false ); // did we move *into* a table? @@ -2344,6 +2350,10 @@ SwNode* SwNodes::FindPrvNxtFrameNode( const SwNode& rFrameNd, pFrameNd = nullptr; // no following content node, stop search } } +else +{ +pFrameNd = nullptr; // no preceding content node, stop search +} } while (pFrameNd != nullptr); commit f8b5a12e7034f74fa5ea099634a1202d94e15e1e Author: Michael Stahl AuthorDate: Mon Jul 17 17:32:07 2023 +0200 Commit: Caolán McNamara CommitDate: Tue Jul 25 20:51:19 2023 +0200 sw: handle sequence of sections containing only table SwNodes::FindPrvNxtFrameNode() still relies on the special-case code at the end to handle this situation, which exists only in the forward direction, and since commit af4e20426ad24c6f2c0164b37472f2b7b54ecd30 there's an assert which is triggered by forum-de3-11230.odt Add the handling to the loop, both backwards and forwards. Change-Id: I79702653ec6fc27854f664c2a41c02f9c97edff0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154553 Tested-by: Jenkins Reviewed-by: Michael Stahl (cherry picked from commit faf2d9e2cb13c3750ac359338f8f31fc1afce368) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154533 Reviewed-by: Caolán McNamara diff --git a/sw/source/core/docnode/nodes.cxx b/sw/source/core/docnode/nodes.cxx index 06a50c4de33b..45a02bf5d5a0 100644 --- a/sw/source/core/docnode/nodes.cxx +++ b/sw/source/core/docnode/nodes.cxx @@ -2242,6 +2242,22 @@ SwNode* SwNodes::FindPrvNxtFrameNode( const SwNode& rFrameNd, else { pFrameNd = GoPrevSection( , true, false ); +// did we move *into* a table? +if (pFrameNd) +{ +for (SwTableNode * pTable = pFrameNd->FindTableNode(); +pTable && pTable->EndOfSectionIndex() < rFrameNd.GetIndex(); +pTable = pTable->StartOfSectionNode()->FindTableNode()) +{ +pFrameNd = pTable->EndOfSectionNode(); +} +if (pFrameNd->IsEndNode()) +{ // GoPrevSection() checks that text node isn't section-hidden, +// so table node between can't be section-hidden either +assert(pFrameNd->StartOfSectionNode()->IsTableNode()); +continue; // check other hidden conditions on next iteration +} +} if ( nullptr != pFrameNd && !(
[Libreoffice-commits] core.git: Branch 'libreoffice-7-6' - 2 commits - sw/source
sw/source/uibase/utlui/content.cxx |3 +++ 1 file changed, 3 insertions(+) New commits: commit 3813aa6c8306fce85bb9b9d090ee48766ae87653 Author: Jim Raykowski AuthorDate: Sat Jul 1 19:52:43 2023 -0800 Commit: Xisco Fauli CommitDate: Tue Jul 4 21:07:27 2023 +0200 tdf#156112 SwNavigator: Disallow footnote and endnote dnd Change-Id: I892f8a34f43629f3e76aa187299dc8c805b72545 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153855 Tested-by: Jenkins Reviewed-by: Jim Raykowski (cherry picked from commit 4f9294ec702a82765c04c8652dddec4dda1e6075) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153891 Reviewed-by: Xisco Fauli diff --git a/sw/source/uibase/utlui/content.cxx b/sw/source/uibase/utlui/content.cxx index 6f02872cda43..c2af6a16304d 100644 --- a/sw/source/uibase/utlui/content.cxx +++ b/sw/source/uibase/utlui/content.cxx @@ -2752,6 +2752,8 @@ bool SwContentTree::FillTransferData( TransferDataContainer& rTransfer, case ContentTypeId::INDEX: case ContentTypeId::REFERENCE : case ContentTypeId::TEXTFIELD: +case ContentTypeId::FOOTNOTE: +case ContentTypeId::ENDNOTE: // cannot be inserted, neither as URL nor as section break; case ContentTypeId::URLFIELD: commit 7d5870ba7a505db8251a34448a11643eae14936e Author: Jim Raykowski AuthorDate: Sun Jul 2 21:02:56 2023 -0800 Commit: Xisco Fauli CommitDate: Tue Jul 4 21:07:19 2023 +0200 tdf#156128 Make drawing object hyperlinks created by dnd from Navigator functional Change-Id: Ic12f3c43c079865e31c3bb89d9f277d3567d8c01 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153887 Tested-by: Jenkins Reviewed-by: Jim Raykowski (cherry picked from commit c4515f6be4a0ec923d85fd6b4c85bfaafb0b26ae) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153924 Reviewed-by: Xisco Fauli diff --git a/sw/source/uibase/utlui/content.cxx b/sw/source/uibase/utlui/content.cxx index 1284dc7a0d0e..6f02872cda43 100644 --- a/sw/source/uibase/utlui/content.cxx +++ b/sw/source/uibase/utlui/content.cxx @@ -394,6 +394,7 @@ SwContentType::SwContentType(SwWrtShell* pShell, ContentTypeId nType, sal_uInt8 m_bEdit = true; break; case ContentTypeId::DRAWOBJECT: +m_sTypeToken = "drawingobject"; m_bEdit = true; break; default: break;