sw/qa/extras/layout/layout2.cxx | 4 ++++ sw/source/core/text/txtfld.cxx | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-)
New commits: commit 8c55fc357cf0bb0608be23098b9d3d565dae2b48 Author: László Németh <nem...@numbertext.org> AuthorDate: Thu Oct 14 17:11:10 2021 +0200 Commit: László Németh <nem...@numbertext.org> CommitDate: Fri Oct 15 09:01:38 2021 +0200 tdf#145068 sw change tracking: highlight numbering of changed list items Highlight the numbering of the changed list item, not the next one. Tracked movement of the list items is more visible this way. Follow-up to commit commit 173b7fcaae86980809889db30ddb82f8ba883103 "tdf#42748 show changes of list numbers and bullets". Change-Id: I4c029f708eb10808f72d44892b986a8fade47f42 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123592 Tested-by: László Németh <nem...@numbertext.org> Reviewed-by: László Németh <nem...@numbertext.org> diff --git a/sw/qa/extras/layout/layout2.cxx b/sw/qa/extras/layout/layout2.cxx index 8c2624b1a389..fce384cd8f3e 100644 --- a/sw/qa/extras/layout/layout2.cxx +++ b/sw/qa/extras/layout/layout2.cxx @@ -292,6 +292,10 @@ CPPUNIT_TEST_FIXTURE(SwLayoutWriter2, testRedlineNumberInNumbering) // Assert the tracked deletion of the number of joined list item and // the tracked insertion of the number after a split list item as not black elements assertXPath(pXmlDoc, "/metafile/push/push/push/textcolor[not(@color='#000000')]", 6); + + // tdf#145068 numbering shows changes in the associated list item, not the next one + // This was 1 (black numbering of the first list item previously) + assertXPath(pXmlDoc, "/metafile/push/push/push/font[4][@color='#000000']", 0); } CPPUNIT_TEST_FIXTURE(SwLayoutWriter2, testTdf125300) diff --git a/sw/source/core/text/txtfld.cxx b/sw/source/core/text/txtfld.cxx index ee9cd7668d12..ef0de08fda59 100644 --- a/sw/source/core/text/txtfld.cxx +++ b/sw/source/core/text/txtfld.cxx @@ -550,7 +550,7 @@ static const SwRangeRedline* lcl_GetRedlineAtNodeInsertionOrDeletion( const SwTe RedlineType::Insert == pTmp->GetType() ) { const SwPosition *pRStt = pTmp->Start(), *pREnd = pTmp->End(); - if( pRStt->nNode < nNdIdx && pREnd->nNode >= nNdIdx ) + if( pRStt->nNode <= nNdIdx && pREnd->nNode > nNdIdx ) return pTmp; } }