sw/source/ui/table/instable.cxx | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-)
New commits: commit 8620b204b51a9e0552a0002f7f06292bdfad37a7 Author: Mert Tumer <[email protected]> AuthorDate: Fri Mar 25 17:56:30 2022 +0300 Commit: Szymon Kłos <[email protected]> CommitDate: Thu Feb 9 19:11:09 2023 +0000 make default selected table style to Default Table Style for only online unfortunately when the table has a style sw/qa/uitest/writer_tests4/tdf115573.py fails because tables that have pre-applied style resets the style of the elements in their cells when a new row is inserted and the ui test above relies on that. For now this is LOK only Signed-off-by: Mert Tumer <[email protected]> Change-Id: I2f60376fc2d929498aef45259a5ef291922ccdcd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132124 Tested-by: Jenkins CollaboraOffice <[email protected]> Reviewed-by: Gökay ŞATIR <[email protected]> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146723 Tested-by: Jenkins Reviewed-by: Szymon Kłos <[email protected]> diff --git a/sw/source/ui/table/instable.cxx b/sw/source/ui/table/instable.cxx index 7383da93bdef..a5aa4cd83853 100644 --- a/sw/source/ui/table/instable.cxx +++ b/sw/source/ui/table/instable.cxx @@ -148,8 +148,13 @@ void SwInsTableDlg::InitAutoTableFormat() // Change this min variable if you add autotable manually. minTableIndexInLb = 1; maxTableIndexInLb = minTableIndexInLb + static_cast<sal_uInt8>(m_xTableTable->size()); - m_xLbFormat->select( minTableIndexInLb ); - m_tbIndex = lbIndexToTableIndex( minTableIndexInLb ); + // 1 means default table style + // unfortunately when the table has a style sw/qa/uitest/writer_tests4/tdf115573.py fails + // because tables that have pre-applied style resets the style of the elements in their cells + // when a new row is inserted and the ui test above relies on that. For now this is LOK only + m_lbIndex = comphelper::LibreOfficeKit::isActive() ? 1 : 0; + m_xLbFormat->select(m_lbIndex); + m_tbIndex = lbIndexToTableIndex(m_lbIndex); SelFormatHdl( *m_xLbFormat ); } commit ef46afe71751929b8b17d278d83c8e3ceefc862f Author: Mert Tumer <[email protected]> AuthorDate: Wed Mar 23 14:23:23 2022 +0300 Commit: Szymon Kłos <[email protected]> CommitDate: Thu Feb 9 19:10:58 2023 +0000 sw: change inserttable style option default to 1 Right now it is default to NONE in the list if the user explicitly choses otherwise but that does not align with inserttable option on the toolbar there it is defaulted to "Default Table Style" 1 means "Default Table Style" Signed-off-by: Mert Tumer <[email protected]> Change-Id: I1db19f0292ac6775653b0db3f2860fea9e3b0adf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131971 Tested-by: Andras Timar <[email protected]> Reviewed-by: Andras Timar <[email protected]> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146722 Tested-by: Szymon Kłos <[email protected]> Reviewed-by: Szymon Kłos <[email protected]> diff --git a/sw/source/ui/table/instable.cxx b/sw/source/ui/table/instable.cxx index e10279add315..7383da93bdef 100644 --- a/sw/source/ui/table/instable.cxx +++ b/sw/source/ui/table/instable.cxx @@ -148,9 +148,8 @@ void SwInsTableDlg::InitAutoTableFormat() // Change this min variable if you add autotable manually. minTableIndexInLb = 1; maxTableIndexInLb = minTableIndexInLb + static_cast<sal_uInt8>(m_xTableTable->size()); - m_lbIndex = 0; - m_xLbFormat->select( m_lbIndex ); - m_tbIndex = lbIndexToTableIndex(m_lbIndex); + m_xLbFormat->select( minTableIndexInLb ); + m_tbIndex = lbIndexToTableIndex( minTableIndexInLb ); SelFormatHdl( *m_xLbFormat ); }
