sw/source/core/frmedt/fetab.cxx | 4 ++-- sw/source/core/table/swnewtable.cxx | 9 ++++++++- sw/source/core/text/porrst.cxx | 12 ++++++++++++ 3 files changed, 22 insertions(+), 3 deletions(-)
New commits: commit 49f63872d7149778efdd1add6f9eb0b7ca254089 Author: Oliver Specht <[email protected]> AuthorDate: Mon Feb 5 09:41:05 2024 +0100 Commit: Thorsten Behrens <[email protected]> CommitDate: Fri Feb 9 00:02:19 2024 +0100 tdf#159560 paragraph break should be shown as pilcrow sign When non-printing characters are switched on at the end of the paragraph a pilcrow sign is shown. This is displayed using the font at the end of the character. If a symbol font is used that would result in a random symbol instead of the pilcrow sign (0x00b6). This is fixed here. Change-Id: I0d4ae9f439d2e34ca774d4e2cb188e94290808a8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162983 Tested-by: Jenkins Reviewed-by: Gabor Kelemen <[email protected]> Tested-by: Gabor Kelemen <[email protected]> (cherry picked from commit 297b47a7e0c191be22f90ab799b4b8bb8bdbaf59) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163142 Reviewed-by: Thorsten Behrens <[email protected]> diff --git a/sw/source/core/text/porrst.cxx b/sw/source/core/text/porrst.cxx index 029adca75336..a4a0d3c713d3 100644 --- a/sw/source/core/text/porrst.cxx +++ b/sw/source/core/text/porrst.cxx @@ -22,6 +22,7 @@ #include <editeng/escapementitem.hxx> #include <editeng/lrspitem.hxx> #include <editeng/pgrditem.hxx> +#include <editeng/fontitem.hxx> #include <vcl/svapp.hxx> #include <comphelper/scopeguard.hxx> @@ -47,6 +48,7 @@ #include <IDocumentRedlineAccess.hxx> #include <IDocumentSettingAccess.hxx> #include <IDocumentDeviceAccess.hxx> +#include <IDocumentLayoutAccess.hxx> #include <crsrsh.hxx> #include <swtypes.hxx> @@ -74,6 +76,16 @@ void SwTmpEndPortion::Paint( const SwTextPaintInfo &rInf ) const SwFont aFont(*pOldFnt); + const SwDoc& rDoc = rInf.GetTextFrame()->GetDoc(); + if (aFont.IsSymbol(rDoc.getIDocumentLayoutAccess().GetCurrentViewShell())) + { + const SvxFontItem& rFontItem = rDoc.GetDefault(RES_CHRATR_FONT); + aFont.SetName( rFontItem.GetFamilyName(), SwFontScript::Latin ); + aFont.SetStyleName( rFontItem.GetStyleName(), SwFontScript::Latin ); + aFont.SetFamily( rFontItem.GetFamily(), SwFontScript::Latin ); + aFont.SetPitch( rFontItem.GetPitch(), SwFontScript::Latin ); + aFont.SetCharSet( rFontItem.GetCharSet(), SwFontScript::Latin ); + } // Paint strikeout/underline based on redline color and settings // (with an extra pilcrow in the background, because there is // no SetStrikeoutColor(), also SetUnderColor() doesn't work()). commit 0b4032eedf5db37201c9ef9c007f4669fb204d6d Author: Oliver Specht <[email protected]> AuthorDate: Wed Jan 24 14:14:20 2024 +0100 Commit: Thorsten Behrens <[email protected]> CommitDate: Fri Feb 9 00:02:06 2024 +0100 tdf#43848 fix selection in table with split/merged cells extends the selection of table cells to reach a more rectangular selection area Additionally tdf#155670 is taken care of by not showing the row selection cursor if row selection is not supported Change-Id: If31aa1030c91d81bc889d8aaa668e96c5328f03f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162508 Tested-by: Jenkins Reviewed-by: Thorsten Behrens <[email protected]> (cherry picked from commit aacf6f0e6059a3b24451da2782e0a0a420e89679) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163143 diff --git a/sw/source/core/frmedt/fetab.cxx b/sw/source/core/frmedt/fetab.cxx index 79f5eb6b5e58..33b9c9327b6d 100644 --- a/sw/source/core/frmedt/fetab.cxx +++ b/sw/source/core/frmedt/fetab.cxx @@ -2116,8 +2116,8 @@ SwTab SwFEShell::WhichMouseTabCol( const Point &rPt ) const { while( pFrame && pFrame->Lower() && pFrame->Lower()->IsRowFrame() ) pFrame = static_cast<const SwCellFrame*>(static_cast<const SwLayoutFrame*>(pFrame->Lower())->Lower()); - if( pFrame && pFrame->GetTabBox()->GetSttNd() && - pFrame->GetTabBox()->GetSttNd()->IsInProtectSect() ) + if( pFrame && ((pFrame->GetTabBox()->GetSttNd() && + pFrame->GetTabBox()->GetSttNd()->IsInProtectSect()) || (pFrame->GetTabBox()->getRowSpan() < 0))) pFrame = nullptr; } diff --git a/sw/source/core/table/swnewtable.cxx b/sw/source/core/table/swnewtable.cxx index 3cc2e3670711..785ef79d3b4d 100644 --- a/sw/source/core/table/swnewtable.cxx +++ b/sw/source/core/table/swnewtable.cxx @@ -1739,7 +1739,11 @@ void SwTable::CreateSelection( const SwNode* pStartNd, const SwNode* pEndNd, rBoxes.insert( pBox ); if( nFound ) { - nBottom = nRow; + //if box is hiding cells bottom needs to be moved + if (pBox->getRowSpan() > 1) + nBottom = std::max(nBottom, size_t(nRow + pBox->getRowSpan() - 1)); + else + nBottom = std::max(nRow, nBottom); lcl_CheckMinMax( nLowerMin, nLowerMax, *pLine, nCol, true ); ++nFound; break; @@ -1747,6 +1751,9 @@ void SwTable::CreateSelection( const SwNode* pStartNd, const SwNode* pEndNd, else { nTop = nRow; + //if box is hiding cells bottom needs to be moved + if (pBox->getRowSpan() > 1) + nBottom = nRow + pBox->getRowSpan() - 1; lcl_CheckMinMax( nUpperMin, nUpperMax, *pLine, nCol, true ); ++nFound; // If start and end node are identical, we're nearly done...
