[Libreoffice-commits] core.git: comphelper/source

2023-05-09 Thread Noel Grandin (via logerrit)
 comphelper/source/misc/diagnose_ex.cxx |2 --
 1 file changed, 2 deletions(-)

New commits:
commit 71ea95ba55ba9e52318423041c4804771818e01f
Author: Noel Grandin 
AuthorDate: Tue May 9 15:47:13 2023 +0200
Commit: Noel Grandin 
CommitDate: Wed May 10 08:02:07 2023 +0200

re-enable typeid checking in exceptionToStringImpl

now that we have valid RTTI tables for the UNO proxy objects generated
by the bridge code. (We won't get a useful typeid for them, but for all
other objects, we will, so this is still worth doing)

Change-Id: I32bfa0099a242021f353fc4065e8660eb6c7cd93
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151585
Tested-by: Noel Grandin 
Reviewed-by: Noel Grandin 

diff --git a/comphelper/source/misc/diagnose_ex.cxx 
b/comphelper/source/misc/diagnose_ex.cxx
index 020aa69ca241..e805c5b4c2a5 100644
--- a/comphelper/source/misc/diagnose_ex.cxx
+++ b/comphelper/source/misc/diagnose_ex.cxx
@@ -71,7 +71,6 @@ static void exceptionToStringImpl(OStringBuffer& sMessage, 
const css::uno::Any &
 sMessage.append(toOString(exception.Message));
 sMessage.append("\"");
 }
-/*  TODO FIXME (see https://gerrit.libreoffice.org/#/c/83245/)
 if ( exception.Context.is() )
 {
 const char* pContext = typeid( *exception.Context ).name();
@@ -86,7 +85,6 @@ static void exceptionToStringImpl(OStringBuffer& sMessage, 
const css::uno::Any &
 std::free(const_cast(pContext));
 #endif
 }
-*/
 {
 css::configuration::CorruptedConfigurationException specialized;
 if ( caught >>= specialized )


[Libreoffice-commits] core.git: cppuhelper/source

2023-05-09 Thread Noel Grandin (via logerrit)
 cppuhelper/source/macro_expander.cxx |   18 +++---
 1 file changed, 3 insertions(+), 15 deletions(-)

New commits:
commit 89e0a3e05dc00339b1d7b4e14443bdf26f9d09c1
Author: Noel Grandin 
AuthorDate: Sun May 7 12:46:01 2023 +0200
Commit: Noel Grandin 
CommitDate: Wed May 10 08:01:47 2023 +0200

use WeakComponentImplHelper2 in Bootstrap_MacroExpander

Change-Id: I49f051d9c9da46ec877e4f611836c7a3548f9f10
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151581
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/cppuhelper/source/macro_expander.cxx 
b/cppuhelper/source/macro_expander.cxx
index 93f758becc12..0cf2fe99d268 100644
--- a/cppuhelper/source/macro_expander.cxx
+++ b/cppuhelper/source/macro_expander.cxx
@@ -24,7 +24,7 @@
 #include 
 
 #include 
-#include 
+#include 
 #include 
 
 #include 
@@ -83,22 +83,13 @@ Sequence< OUString > const & s_get_service_names()
 return IMPL_NAMES;
 }
 
-typedef cppu::WeakComponentImplHelper<
+typedef cppuhelper::WeakComponentImplHelper2<
 util::XMacroExpander, lang::XServiceInfo > t_uno_impl;
 
-struct mutex_holder
+class Bootstrap_MacroExpander : public t_uno_impl
 {
-Mutex m_mutex;
-};
-
-class Bootstrap_MacroExpander : public mutex_holder, public t_uno_impl
-{
-protected:
-virtual void SAL_CALL disposing() override;
-
 public:
 Bootstrap_MacroExpander()
-: t_uno_impl( m_mutex )
 {}
 
 // XMacroExpander impl
@@ -110,9 +101,6 @@ public:
 };
 
 
-void Bootstrap_MacroExpander::disposing()
-{}
-
 // XServiceInfo impl
 
 OUString Bootstrap_MacroExpander::getImplementationName()


[Libreoffice-commits] core.git: cppuhelper/source

2023-05-09 Thread Noel Grandin (via logerrit)
 cppuhelper/source/servicemanager.cxx |   41 +--
 cppuhelper/source/servicemanager.hxx |   18 +--
 2 files changed, 28 insertions(+), 31 deletions(-)

New commits:
commit 8809b57da900c0fa8e7aa9d05021fe9a00114ecd
Author: Noel Grandin 
AuthorDate: Sun May 7 12:44:36 2023 +0200
Commit: Noel Grandin 
CommitDate: Wed May 10 08:01:25 2023 +0200

use WeakComponentImplHelper2 in ServiceManager

Change-Id: I0f141398effbd2673c02f9d1f4378fd4e67af655
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151580
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/cppuhelper/source/servicemanager.cxx 
b/cppuhelper/source/servicemanager.cxx
index 86d89e445dd4..7eccd274e7f4 100644
--- a/cppuhelper/source/servicemanager.cxx
+++ b/cppuhelper/source/servicemanager.cxx
@@ -795,7 +795,7 @@ void cppuhelper::ServiceManager::loadImplementation(
 {
 assert(implementation);
 {
-osl::MutexGuard g(rBHelper.rMutex);
+std::unique_lock g(m_aMutex);
 if (implementation->status == Data::Implementation::STATUS_LOADED) {
 return;
 }
@@ -871,8 +871,8 @@ void cppuhelper::ServiceManager::loadImplementation(
 //TODO: There is a race here, as the relevant service factory can be 
removed
 // while the mutex is unlocked and loading can thus fail, as the entity 
from
 // which to load can disappear once the service factory is removed.
-osl::MutexGuard g(rBHelper.rMutex);
-if (!(isDisposed()
+std::unique_lock g(m_aMutex);
+if (!(m_bDisposed
   || implementation->status == Data::Implementation::STATUS_LOADED))
 {
 implementation->status = Data::Implementation::STATUS_LOADED;
@@ -882,12 +882,11 @@ void cppuhelper::ServiceManager::loadImplementation(
 }
 }
 
-void cppuhelper::ServiceManager::disposing() {
+void cppuhelper::ServiceManager::disposing(std::unique_lock& 
rGuard) {
 std::vector< css::uno::Reference > sngls;
 std::vector< css::uno::Reference< css::lang::XComponent > > comps;
 Data clear;
 {
-osl::MutexGuard g(rBHelper.rMutex);
 for (const auto& rEntry : data_.namedImplementations)
 {
 assert(rEntry.second);
@@ -916,6 +915,7 @@ void cppuhelper::ServiceManager::disposing() {
 data_.services.swap(clear.services);
 data_.singletons.swap(clear.singletons);
 }
+rGuard.unlock();
 for (const auto& rxSngl : sngls)
 {
 try {
@@ -928,6 +928,7 @@ void cppuhelper::ServiceManager::disposing() {
 {
 removeEventListenerFromComponent(rxComp);
 }
+rGuard.lock();
 }
 
 void cppuhelper::ServiceManager::initialize(
@@ -983,8 +984,8 @@ cppuhelper::ServiceManager::createInstanceWithArguments(
 css::uno::Sequence< OUString >
 cppuhelper::ServiceManager::getAvailableServiceNames()
 {
-osl::MutexGuard g(rBHelper.rMutex);
-if (isDisposed()) {
+std::unique_lock g(m_aMutex);
+if (m_bDisposed) {
 return css::uno::Sequence< OUString >();
 }
 if (data_.services.size() > o3tl::make_unsigned(SAL_MAX_INT32)) {
@@ -1025,7 +1026,7 @@ css::uno::Type 
cppuhelper::ServiceManager::getElementType()
 
 sal_Bool cppuhelper::ServiceManager::hasElements()
 {
-osl::MutexGuard g(rBHelper.rMutex);
+std::unique_lock g(m_aMutex);
 return
 !(data_.namedImplementations.empty()
   && data_.dynamicImplementations.empty());
@@ -1138,7 +1139,7 @@ cppuhelper::ServiceManager::createContentEnumeration(
 {
 std::vector< std::shared_ptr< Data::Implementation > > impls;
 {
-osl::MutexGuard g(rBHelper.rMutex);
+std::unique_lock g(m_aMutex);
 Data::ImplementationMap::const_iterator i(
 data_.services.find(aServiceName));
 if (i != data_.services.end()) {
@@ -1151,8 +1152,8 @@ cppuhelper::ServiceManager::createContentEnumeration(
 Data::Implementation * impl = rxImpl.get();
 assert(impl != nullptr);
 {
-osl::MutexGuard g(rBHelper.rMutex);
-if (isDisposed()) {
+std::unique_lock g(m_aMutex);
+if (m_bDisposed) {
 factories.clear();
 break;
 }
@@ -1572,8 +1573,8 @@ void cppuhelper::ServiceManager::insertLegacyFactory(
 
 bool cppuhelper::ServiceManager::insertExtraData(Data const & extra) {
 {
-osl::MutexGuard g(rBHelper.rMutex);
-if (isDisposed()) {
+std::unique_lock g(m_aMutex);
+if (m_bDisposed) {
 return false;
 }
 auto i = std::find_if(extra.namedImplementations.begin(), 
extra.namedImplementations.end(),
@@ -1651,7 +1652,7 @@ void cppuhelper::ServiceManager::removeRdbFiles(
 // it is called with a uris vector of size one):
 std::vector< std::shared_ptr< Data::Implementation > > clear;
 {
-osl::MutexGuard g(rBHelper.rMutex);
+std::unique_lock g(m_aMutex);
 for (const auto& rUri : uris)
 

[Libreoffice-commits] core.git: 2 commits - sc/qa svx/qa

2023-05-09 Thread Andrea Gelmini (via logerrit)
 sc/qa/uitest/function_wizard/tdf104487.py |2 +-
 svx/qa/unit/gallery/test_gallery.cxx  |1 -
 2 files changed, 1 insertion(+), 2 deletions(-)

New commits:
commit c84b37c0bbab3b386b22b87be52f965839b44a49
Author: Andrea Gelmini 
AuthorDate: Tue May 9 16:23:06 2023 +0200
Commit: Julien Nabet 
CommitDate: Wed May 10 06:49:14 2023 +0200

Remove duplicated include

Change-Id: I324844e4ff628c6a72621a2b1511cc5b7f390901
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151588
Reviewed-by: Julien Nabet 
Tested-by: Jenkins

diff --git a/svx/qa/unit/gallery/test_gallery.cxx 
b/svx/qa/unit/gallery/test_gallery.cxx
index ac6a1b6ee875..47b73c87fbd2 100644
--- a/svx/qa/unit/gallery/test_gallery.cxx
+++ b/svx/qa/unit/gallery/test_gallery.cxx
@@ -17,7 +17,6 @@
 #include 
 #include 
 #include 
-#include 
 
 #include 
 #include 
commit 6e7aaa954082acd432e8e02aee03e2c7d497c34b
Author: Andrea Gelmini 
AuthorDate: Tue May 9 22:16:14 2023 +0200
Commit: Julien Nabet 
CommitDate: Wed May 10 06:49:01 2023 +0200

Fix double word

Change-Id: I72a951275fc0e3ff16be6c2f4cefae7949dea9be
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151594
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/sc/qa/uitest/function_wizard/tdf104487.py 
b/sc/qa/uitest/function_wizard/tdf104487.py
index 8b563bc5b372..13a219ea442f 100755
--- a/sc/qa/uitest/function_wizard/tdf104487.py
+++ b/sc/qa/uitest/function_wizard/tdf104487.py
@@ -12,7 +12,7 @@ from uitest.uihelper.common import get_state_as_dict, 
select_pos
 class tdf104487(UITestCase):
 def test_tdf104487_remember_function_category(self):
 with self.ui_test.create_doc_in_start_center("calc"):
-# Open function dialog and select select a function category
+# Open function dialog and select a function category
 with 
self.ui_test.execute_modeless_dialog_through_command(".uno:FunctionDialog") as 
xDialog:
 xCategory = xDialog.getChild("category")
 select_pos(xCategory, "3")


[Libreoffice-commits] core.git: Changes to 'refs/tags/cib-6.4-17'

2023-05-09 Thread Caolán McNamara (via logerrit)
Tag 'cib-6.4-17' created by Thorsten Behrens  
at 2023-05-10 00:07 +

Release CIB Office cib-6.4-17
-BEGIN PGP SIGNATURE-

iNUEABYKAH0WIQRV78SO268/dhkw1IIeB5amgXyR5gUCZFrgRF8UgAAuAChp
c3N1ZXItZnByQG5vdGF0aW9ucy5vcGVucGdwLmZpZnRoaG9yc2VtYW4ubmV0NTVF
RkM0OEVEQkFGM0Y3NjE5MzBENDgyMUUwNzk2QTY4MTdDOTFFNgAKCRAeB5amgXyR
5hJxAQCfNocinp3rzVwo8YE5PEd3DZY0Da5tgbNhXR8VNs+kjwD+L1Swzr/52y3J
KOFkEl5HHJkfFgP6QMj7GZ8k1L3FzgM=
=rcVr
-END PGP SIGNATURE-

Changes since cib-6.4-16-29:
---
 0 files changed
---


[Libreoffice-commits] core.git: Branch 'distro/collabora/co-23.05' - writerfilter/source

2023-05-09 Thread Miklos Vajna (via logerrit)
 writerfilter/source/dmapper/DomainMapper_Impl.cxx |5 -
 1 file changed, 4 insertions(+), 1 deletion(-)

New commits:
commit 13e4e251a7b19a2c8a638c205633a146806a9560
Author: Miklos Vajna 
AuthorDate: Mon May 8 12:08:01 2023 +0200
Commit: Miklos Vajna 
CommitDate: Tue May 9 23:51:09 2023 +0200

writerfilter: fix crash in DomainMapper_Impl::handleIndex()

Crashreport signature:

program/libwriterfilterlo.so
  
writerfilter::dmapper::DomainMapper_Impl::handleIndex(tools::SvRef
 const&, rtl::OUString const&)
  writerfilter/source/dmapper/DomainMapper_Impl.cxx:6116
program/libwriterfilterlo.so
  writerfilter::dmapper::DomainMapper_Impl::CloseFieldCommand()
  include/rtl/ustring.hxx:527
program/libwriterfilterlo.so
  writerfilter::dmapper::DomainMapper::lcl_text(unsigned char const*, 
unsigned long)
  writerfilter/source/dmapper/DomainMapper.cxx:3735
program/libwriterfilterlo.so
  writerfilter::rtftok::RTFDocumentImpl::singleChar(unsigned char, bool)
  writerfilter/source/rtftok/rtfdocumentimpl.hxx:718

Change-Id: I4e0f93ce50c8c9a1f9a1a0f9204bd4fee70cdde4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151502
Reviewed-by: Miklos Vajna 
Tested-by: Jenkins
(cherry picked from commit 1e75a434e349110990bcccd80b5c63c11080853e)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151512
Reviewed-by: Xisco Fauli 
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151556
Tested-by: Jenkins CollaboraOffice 

diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.cxx 
b/writerfilter/source/dmapper/DomainMapper_Impl.cxx
index 7086a4329cc9..7f23452f92df 100644
--- a/writerfilter/source/dmapper/DomainMapper_Impl.cxx
+++ b/writerfilter/source/dmapper/DomainMapper_Impl.cxx
@@ -6628,7 +6628,10 @@ void DomainMapper_Impl::handleIndex
 {
 sValue = sValue.replaceAll("\"", "");
 uno::Reference xTextColumns;
-xTOC->getPropertyValue(getPropertyName( PROP_TEXT_COLUMNS )) >>= 
xTextColumns;
+if (xTOC.is())
+{
+xTOC->getPropertyValue(getPropertyName( PROP_TEXT_COLUMNS )) >>= 
xTextColumns;
+}
 if (xTextColumns.is())
 {
 xTextColumns->setColumnCount( sValue.toInt32() );


[Libreoffice-commits] core.git: sc/qa

2023-05-09 Thread Xisco Fauli (via logerrit)
 sc/qa/unit/opencl-test-2.cxx |  454 ++-
 1 file changed, 112 insertions(+), 342 deletions(-)

New commits:
commit daf30c29be67b8b8fa361b0efd1a6cdbe087b6f8
Author: Xisco Fauli 
AuthorDate: Tue May 9 16:39:59 2023 +0200
Commit: Xisco Fauli 
CommitDate: Tue May 9 21:44:52 2023 +0200

CppunitTest_sc_opencl-2: use CPPUNIT_TEST_FIXTURE()

Avoiding the declaration/registration/definition of each
test manually saves a lot of space.

Change-Id: I3a6253d259bac58f8d8ca78cd5d4f9e357a2c315
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151589
Tested-by: Jenkins
Reviewed-by: Xisco Fauli 

diff --git a/sc/qa/unit/opencl-test-2.cxx b/sc/qa/unit/opencl-test-2.cxx
index a53613560e71..4c7fbdbcb96d 100644
--- a/sc/qa/unit/opencl-test-2.cxx
+++ b/sc/qa/unit/opencl-test-2.cxx
@@ -20,237 +20,9 @@ class ScOpenCLTest2
 {
 public:
 ScOpenCLTest2();
-
-void testStatisticalFormulaFDist();
-void testStatisticalFormulaVar();
-void testStatisticalFormulaChiDist();
-void testMathFormulaPower();
-void testMathFormulaOdd();
-void testStatisticalFormulaChiSqDist();
-void testStatisticalFormulaChiSqInv();
-void testStatisticalFormulaGammaInv();
-void testMathFormulaFloor();
-void testStatisticalFormulaFInv();
-void testStatisticalFormulaFTest();
-void testStatisticalFormulaB();
-void testStatisticalFormulaBetaDist();
-void testMathFormulaCscH();
-void testMathFormulaExp();
-void testMathFormulaLog10();
-void testStatisticalFormulaExpondist();
-void testMathAverageIfsFormula();
-void testMathCountIfsFormula();
-void testMathFormulaCombina();
-void testMathFormulaEven();
-void testMathFormulaLog();
-void testMathFormulaMod();
-void testMathFormulaTrunc();
-void testStatisticalFormulaSkew();
-void testMathFormulaArcTan2();
-void testMathFormulaBitOr();
-void testMathFormulaBitLshift();
-void testMathFormulaBitRshift();
-void testMathFormulaBitXor();
-void testStatisticalFormulaChiInv();
-void testStatisticalFormulaPoisson();
-void testMathFormulaSumSQ();
-void testStatisticalFormulaSkewp();
-void testMathFormulaSqrtPi();
-void testStatisticalFormulaBinomDist();
-void testStatisticalFormulaVarP();
-void testMathFormulaCeil();
-void testMathFormulaKombin();
-void testStatisticalFormulaDevSq();
-void testStatisticalFormulaStDev();
-void testStatisticalFormulaSlope();
-void testStatisticalFormulaSTEYX();
-void testStatisticalFormulaZTest();
-void testMathFormulaPi();
-void testMathFormulaRandom();
-void testMathFormulaConvert();
-void testMathFormulaProduct();
-void testStatisticalFormulaHypGeomDist();
-void testArrayFormulaSumX2MY2();
-void testArrayFormulaSumX2PY2();
-void testStatisticalFormulaBetainv();
-void testStatisticalFormulaTTest();
-void testStatisticalFormulaTDist();
-void testStatisticalFormulaTInv();
-void testArrayFormulaSumXMY2();
-void testStatisticalFormulaStDevP();
-void testStatisticalFormulaCovar();
-void testLogicalFormulaAnd();
-void testLogicalFormulaOr();
-void testMathFormulaSumProduct();
-void testMathFormulaSumProduct2();
-void testStatisticalParallelCountBug();
-void testSpreadSheetFormulaVLookup();
-void testLogicalFormulaNot();
-void testLogicalFormulaXor();
-void testDatabaseFormulaDmax();
-void testDatabaseFormulaDmin();
-void testDatabaseFormulaDproduct();
-void testDatabaseFormulaDaverage();
-void testDatabaseFormulaDstdev();
-void testDatabaseFormulaDstdevp();
-void testDatabaseFormulaDsum();
-void testDatabaseFormulaDvar();
-void testDatabaseFormulaDvarp();
-void testMathFormulaAverageIf();
-void testDatabaseFormulaDcount();
-void testDatabaseFormulaDcountA();
-void testMathFormulaDegrees();
-void testMathFormulaRoundUp();
-void testMathFormulaRoundDown();
-void testMathFormulaInt();
-void testMathFormulaRadians();
-void testMathFormulaCountIf();
-void testMathFormulaIsEven();
-void testMathFormulaIsOdd();
-void testMathFormulaFact();
-void testStatisticalFormulaMina();
-void testStatisticalFormulaCountA();
-void testStatisticalFormulaMaxa();
-void testStatisticalFormulaAverageA();
-void testStatisticalFormulaVarA();
-void testStatisticalFormulaVarPA();
-void testStatisticalFormulaStDevA();
-void testStatisticalFormulaStDevPA();
-void testMathFormulaSEC();
-void testMathFormulaSECH();
-void testMathFormulaMROUND();
-void testMathFormulaSeriesSum();
-void testMathFormulaQuotient();
-void testMathFormulaSumIf();
-void testAddInFormulaBesseLJ();
-void testNegSub();
-void testStatisticalFormulaAvedev();
-void testMathFormulaAverageIf_Mix();
-void testStatisticalFormulaKurt1();
-void testStatisticalForm

[Libreoffice-commits] core.git: comphelper/IwyuFilter_comphelper.yaml comphelper/Library_comphelper.mk comphelper/source include/comphelper include/IwyuFilter_include.yaml solenv/clang-format

2023-05-09 Thread Noel Grandin (via logerrit)
 comphelper/IwyuFilter_comphelper.yaml  |3 
 comphelper/Library_comphelper.mk   |1 
 comphelper/source/misc/servicedecl.cxx |  161 -
 include/IwyuFilter_include.yaml|4 
 include/comphelper/servicedecl.hxx |  155 ---
 solenv/clang-format/excludelist|2 
 6 files changed, 326 deletions(-)

New commits:
commit 6a936ebc2909f22143da3c7e03582afc5c673c22
Author: Noel Grandin 
AuthorDate: Tue May 9 12:42:12 2023 +0200
Commit: Noel Grandin 
CommitDate: Tue May 9 21:33:39 2023 +0200

comphelper/servicedecl.hxx is unused

Change-Id: I3ddb06a31c746bfd7da72368a51266d688b1230b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151570
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/comphelper/IwyuFilter_comphelper.yaml 
b/comphelper/IwyuFilter_comphelper.yaml
index 3e22a187b7e5..9e60203c6750 100644
--- a/comphelper/IwyuFilter_comphelper.yaml
+++ b/comphelper/IwyuFilter_comphelper.yaml
@@ -68,9 +68,6 @@ excludelist:
 # Stop warnings about include/
 - com/sun/star/beans/PropertyValue.hpp
 - com/sun/star/beans/NamedValue.hpp
-include/comphelper/servicedecl.hxx:
-# Stop warnings about include/
-- com/sun/star/uno/XComponentContext.hpp
 comphelper/source/misc/simplefileaccessinteraction.cxx:
 # Needed for UnoType template
 - com/sun/star/task/XInteractionAbort.hpp
diff --git a/comphelper/Library_comphelper.mk b/comphelper/Library_comphelper.mk
index f75dc446cdd2..d03dc06dd67f 100644
--- a/comphelper/Library_comphelper.mk
+++ b/comphelper/Library_comphelper.mk
@@ -124,7 +124,6 @@ $(eval $(call gb_Library_add_exception_objects,comphelper,\
 comphelper/source/misc/random \
 comphelper/source/misc/SelectionMultiplex \
 comphelper/source/misc/sequenceashashmap \
-comphelper/source/misc/servicedecl \
 comphelper/source/misc/sharedmutex \
 comphelper/source/misc/simplefileaccessinteraction \
 comphelper/source/misc/solarmutex \
diff --git a/comphelper/source/misc/servicedecl.cxx 
b/comphelper/source/misc/servicedecl.cxx
deleted file mode 100644
index 2b16539d1a55..
--- a/comphelper/source/misc/servicedecl.cxx
+++ /dev/null
@@ -1,161 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-
-#include 
-#include 
-#include 
-#include 
-#include 
-#include 
-#include 
-#include 
-
-using namespace com::sun::star;
-
-namespace comphelper::service_decl {
-
-const char cDelim = ';';
-
-class ServiceDecl::Factory :
-public cppu::WeakImplHelper
-{
-public:
-explicit Factory( ServiceDecl const& rServiceDecl )
-: m_rServiceDecl(rServiceDecl) {}
-// noncopyable
-Factory(const Factory&) = delete;
-const Factory& operator=(const Factory&) = delete;
-
-// XServiceInfo:
-virtual OUString SAL_CALL getImplementationName() override;
-virtual sal_Bool SAL_CALL supportsService( OUString const& name ) override;
-virtual uno::Sequence SAL_CALL getSupportedServiceNames() 
override;
-// XSingleComponentFactory:
-virtual uno::Reference SAL_CALL createInstanceWithContext(
-uno::Reference const& xContext ) override;
-virtual uno::Reference SAL_CALL
-createInstanceWithArgumentsAndContext(
-uno::Sequence const& args,
-uno::Reference const& xContext ) override;
-
-private:
-virtual ~Factory() override;
-
-ServiceDecl const& m_rServiceDecl;
-};
-
-ServiceDecl::Factory::~Factory()
-{
-}
-
-// XServiceInfo:
-OUString ServiceDecl::Factory::getImplementationName()
-{
-return m_rServiceDecl.getImplementationName();
-}
-
-sal_Bool ServiceDecl::Factory::supportsService( OUString const& name )
-{
-return m_rServiceDecl.supportsService(name);
-}
-
-uno::Sequence ServiceDecl::Factory::getSupportedServiceNames()
-{
-return m_rServiceDecl.getSupportedServiceNames();
-}
-
-// XSingleComponentFactory:
-uno::Reference 
ServiceDecl::Factory::createInstanceWithContext(
-uno::Reference const& xContext )
-{
-return m_rServiceDecl.m_createFunc(
-m_rServiceDecl, uno::Sequence(), xContext );
-}
-
-uno:

[Libreoffice-commits] core.git: chart2/source

2023-05-09 Thread Noel Grandin (via logerrit)
 chart2/source/controller/chartapiwrapper/ChartDataWrapper.cxx |3 ---
 1 file changed, 3 deletions(-)

New commits:
commit 40f5a5be9fd228a5d33a3b1218864a38cb70dc1f
Author: Noel Grandin 
AuthorDate: Tue May 9 15:28:58 2023 +0200
Commit: Noel Grandin 
CommitDate: Tue May 9 21:33:24 2023 +0200

tdf#155210 FILESAVE ODT Default chart row labels disappear from Writer chart

revert
commit 6500106dff0f0cd86f509ffd01542aab77c21596
Author: Noel Grandin 
Date:   Tue Apr 19 13:48:55 2022 +0200
tdf#148635 no need to init ChartDataWrapper more than once

Change-Id: I28f078731bd8bfedbde63d0bb2e5fe40f0a4ff46
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151583
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/chart2/source/controller/chartapiwrapper/ChartDataWrapper.cxx 
b/chart2/source/controller/chartapiwrapper/ChartDataWrapper.cxx
index b54e029d54db..84b98f0d8018 100644
--- a/chart2/source/controller/chartapiwrapper/ChartDataWrapper.cxx
+++ b/chart2/source/controller/chartapiwrapper/ChartDataWrapper.cxx
@@ -587,14 +587,11 @@ void ChartDataWrapper::switchToInternalDataProvider()
 rtl::Reference< ChartModel > xChartDoc( 
m_spChart2ModelContact->getDocumentModel() );
 if( xChartDoc.is() )
 xChartDoc->createInternalDataProvider( true /*bCloneExistingData*/ );
-m_xDataAccess.clear();
 initDataAccess();
 }
 
 void ChartDataWrapper::initDataAccess()
 {
-if (m_xDataAccess)
-return;
 rtl::Reference< ChartModel > xChartDoc( 
m_spChart2ModelContact->getDocumentModel() );
 if( !xChartDoc.is() )
 return;


[Libreoffice-commits] core.git: sd/uiconfig

2023-05-09 Thread Julien Nabet (via logerrit)
 sd/uiconfig/simpress/ui/optimpressgeneralpage.ui |6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 333f91b389a62bf4c21a963389a3a0bae27f110f
Author: Julien Nabet 
AuthorDate: Sun May 7 22:39:05 2023 +0200
Commit: Julien Nabet 
CommitDate: Tue May 9 21:10:25 2023 +0200

Typo: tapstoplabel->tabstoplabel in sd/optimpressgeneralpage.ui

Change-Id: Ie271244eb971fc8180984b7a2723e2c780a9fb0e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151486
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/sd/uiconfig/simpress/ui/optimpressgeneralpage.ui 
b/sd/uiconfig/simpress/ui/optimpressgeneralpage.ui
index 051534ffdeba..d97502be275f 100644
--- a/sd/uiconfig/simpress/ui/optimpressgeneralpage.ui
+++ b/sd/uiconfig/simpress/ui/optimpressgeneralpage.ui
@@ -321,10 +321,10 @@
 False
 12
 
-  
+  
 True
 False
-Ta_b stops:
+Ta_b stops:
 True
 fill
 metricFields
@@ -709,7 +709,7 @@
   
 
   
-  
+  
 
   
   


[Libreoffice-commits] core.git: include/sal solenv/clang-format vcl/inc vcl/Library_vcl.mk vcl/unx

2023-05-09 Thread Caolán McNamara (via logerrit)
 include/sal/log-areas.dox   |2 
 solenv/clang-format/excludelist |2 
 vcl/Library_vcl.mk  |2 
 vcl/inc/qt5/QtFrame.hxx |2 
 vcl/inc/strings.hrc |3 
 vcl/inc/unx/gtk/gtkframe.hxx|9 +
 vcl/inc/unx/salframe.h  |2 
 vcl/inc/unx/sessioninhibitor.hxx|3 
 vcl/unx/generic/window/sessioninhibitor.cxx |   19 +--
 vcl/unx/gtk3/gtkframe.cxx   |  174 +++-
 10 files changed, 197 insertions(+), 21 deletions(-)

New commits:
commit c04d0570b6c8c78e35c2c9b58bf37bb1218021f5
Author: Caolán McNamara 
AuthorDate: Tue May 9 08:46:09 2023 +0100
Commit: Caolán McNamara 
CommitDate: Tue May 9 20:42:49 2023 +0200

Resolves: tdf#142176 under GNOME inhibit logout if there are modified docs

and if we are forced to quit anyway, unset modifications on documents and
terminate.

Change-Id: If4a3aed48a4621950e2d630fdfef34b28ba1b089
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151575
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 

diff --git a/include/sal/log-areas.dox b/include/sal/log-areas.dox
index 15bcf5a03573..51b005e1bb51 100644
--- a/include/sal/log-areas.dox
+++ b/include/sal/log-areas.dox
@@ -506,7 +506,7 @@ certain functionality.
 @li @c vcl.quartz
 @li @c vcl.schedule - scheduler / main-loop information
 @li @c vcl.schedule.deinit
-@li @c vcl.screensaverinhibitor
+@li @c vcl.sessioninhibitor
 @li @c vcl.scrollbar - Scroll Bars
 @li @c vcl.se - VCL Session Manager
 @li @c vcl.se.debug
diff --git a/solenv/clang-format/excludelist b/solenv/clang-format/excludelist
index 3453747854d3..a4f04ad0c9e7 100644
--- a/solenv/clang-format/excludelist
+++ b/solenv/clang-format/excludelist
@@ -14978,7 +14978,7 @@ vcl/unx/generic/printer/ppdparser.cxx
 vcl/unx/generic/printer/printerinfomanager.cxx
 vcl/unx/generic/window/salframe.cxx
 vcl/unx/generic/window/salobj.cxx
-vcl/unx/generic/window/screensaverinhibitor.cxx
+vcl/unx/generic/window/sessioninhibitor.cxx
 vcl/unx/gtk3/a11y/atklistener.hxx
 vcl/unx/gtk3/a11y/atkwrapper.hxx
 vcl/unx/gtk3/a11y/atkaction.cxx
diff --git a/vcl/Library_vcl.mk b/vcl/Library_vcl.mk
index 9eca7534218e..a7c1fbc22b2f 100644
--- a/vcl/Library_vcl.mk
+++ b/vcl/Library_vcl.mk
@@ -579,7 +579,7 @@ endif
 
 ifeq ($(USING_X11),TRUE)
 $(eval $(call gb_Library_add_exception_objects,vcl,\
-vcl/unx/generic/window/screensaverinhibitor \
+vcl/unx/generic/window/sessioninhibitor \
 vcl/unx/generic/printer/cpdmgr \
 ))
 
diff --git a/vcl/inc/qt5/QtFrame.hxx b/vcl/inc/qt5/QtFrame.hxx
index b927d366765d..09abe5301538 100644
--- a/vcl/inc/qt5/QtFrame.hxx
+++ b/vcl/inc/qt5/QtFrame.hxx
@@ -34,7 +34,7 @@
 #include 
 
 #if CHECK_ANY_QT_USING_X11
-#include 
+#include 
 // any better way to get rid of the X11 / Qt type clashes?
 #undef Bool
 #undef CursorShape
diff --git a/vcl/inc/strings.hrc b/vcl/inc/strings.hrc
index 83beea008e9e..c2e95f20ceac 100644
--- a/vcl/inc/strings.hrc
+++ b/vcl/inc/strings.hrc
@@ -122,6 +122,9 @@
 #define STR_QUIRKY  NC_("STR_QUIRKY", "Quirky 
Tests: %1")
 #define STR_FAILED  NC_("STR_FAILED", "Failed 
Tests: %1")
 #define STR_SKIPPED NC_("STR_SKIPPED", 
"Skipped Tests: %1")
+
+#define STR_UNSAVED_DOCUMENTS   
NC_("STR_UNSAVED_DOCUMENTS", "There are unsaved documents")
+
 #endif // INCLUDED_VCL_INC_STRINGS_HRC
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/inc/unx/gtk/gtkframe.hxx b/vcl/inc/unx/gtk/gtkframe.hxx
index 1a83a7fc39d3..890bcdb8a6ea 100644
--- a/vcl/inc/unx/gtk/gtkframe.hxx
+++ b/vcl/inc/unx/gtk/gtkframe.hxx
@@ -32,7 +32,7 @@
 #include 
 #include 
 #include 
-#include 
+#include 
 
 #include 
 
@@ -187,6 +187,9 @@ class GtkSalFrame final : public SalFrame
 #endif
 gulong  m_nPortalSettingChangedSignalId;
 GDBusProxy* m_pSettingsPortal;
+gulong  m_nSessionClientSignalId;
+GDBusProxy* m_pSessionManager;
+GDBusProxy* m_pSessionClient;
 #if !GTK_CHECK_VERSION(4, 0, 0)
 GdkWindow*  m_pForeignParent;
 GdkNativeWindow m_aForeignParentWindow;
@@ -425,6 +428,8 @@ class GtkSalFrame final : public SalFrame
 
 void ListenPortalSettings();
 
+void ListenSessionManager();
+
 void UpdateGeometryFromEvent(int x_root, int y_root, int nEventX, int 
nEventY);
 
 public:
@@ -654,6 +659,8 @@ public:
 
 void SetColorScheme(GVariant* variant);
 
+void SessionManagerInhibit(bool bStart, ApplicationInhibitFlags eType, 
std::u16string_view sReason, const char* application_id);
+
 void DisallowCycleFocusOut();
 bool IsCycleFocusOutDisallowed() const;
 void AllowCycleFocusOut();
diff --git a/vcl/inc/unx/salframe

[Libreoffice-commits] core.git: 2 commits - sw/source vcl/inc vcl/source

2023-05-09 Thread Caolán McNamara (via logerrit)
 sw/source/core/access/acccontext.cxx |7 ++-
 sw/source/core/access/acccontext.hxx |2 ++
 sw/source/core/access/accmap.cxx |4 +++-
 vcl/inc/svdata.hxx   |1 -
 vcl/source/app/svapp.cxx |6 --
 5 files changed, 11 insertions(+), 9 deletions(-)

New commits:
commit 5c73c3aa6875b1e69b2d58a47ba823faf78b8aa2
Author: Caolán McNamara 
AuthorDate: Tue May 9 11:59:40 2023 +0100
Commit: Caolán McNamara 
CommitDate: Tue May 9 20:42:35 2023 +0200

drop unused ImplPrepareExitMsg

Change-Id: I9254328829ac051524fbfdf6a3b5b2f72b12c427
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151574
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 

diff --git a/vcl/inc/svdata.hxx b/vcl/inc/svdata.hxx
index 6d1d8adac015..448262492054 100644
--- a/vcl/inc/svdata.hxx
+++ b/vcl/inc/svdata.hxx
@@ -168,7 +168,6 @@ struct ImplSVAppData
 bool m_bUseSystemLoop = false;
 
 DECL_STATIC_LINK(ImplSVAppData, ImplQuitMsg, void*, void);
-DECL_STATIC_LINK(ImplSVAppData, ImplPrepareExitMsg, void*, void);
 DECL_STATIC_LINK(ImplSVAppData, ImplEndAllDialogsMsg, void*, void);
 DECL_STATIC_LINK(ImplSVAppData, ImplEndAllPopupsMsg, void*, void);
 };
diff --git a/vcl/source/app/svapp.cxx b/vcl/source/app/svapp.cxx
index 4690c534df70..c61d9ea0f2aa 100644
--- a/vcl/source/app/svapp.cxx
+++ b/vcl/source/app/svapp.cxx
@@ -339,12 +339,6 @@ void Application::notifyInvalidation(tools::Rectangle 
const* /*pRect*/) const
 {
 }
 
-IMPL_STATIC_LINK_NOARG( ImplSVAppData, ImplPrepareExitMsg, void*, void )
-{
-//now close top level frames
-(void)GetpApp()->QueryExit();
-}
-
 void Application::Execute()
 {
 ImplSVData* pSVData = ImplGetSVData();
commit 5e99e5d734f19fe7299a3e390b23a93db971e013
Author: Caolán McNamara 
AuthorDate: Tue May 9 14:16:20 2023 +0100
Commit: Caolán McNamara 
CommitDate: Tue May 9 20:42:22 2023 +0200

Resolves: tdf#138512 don't crash on removing already Disposed a11y context

Change-Id: I2a8f3d10a1349de233e11d841f7f244e4e513b2c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151582
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 

diff --git a/sw/source/core/access/acccontext.cxx 
b/sw/source/core/access/acccontext.cxx
index 37cb87fb3114..3445114b2d78 100644
--- a/sw/source/core/access/acccontext.cxx
+++ b/sw/source/core/access/acccontext.cxx
@@ -518,9 +518,14 @@ bool SwAccessibleContext::IsEditableState()
 return bRet;
 }
 
+bool SwAccessibleContext::IsDisposed() const
+{
+return !(GetFrame() && GetMap());
+}
+
 void SwAccessibleContext::ThrowIfDisposed()
 {
-if (!(GetFrame() && GetMap()))
+if (IsDisposed())
 {
 throw lang::DisposedException("object is nonfunctional",
 static_cast(this));
diff --git a/sw/source/core/access/acccontext.hxx 
b/sw/source/core/access/acccontext.hxx
index 32d13efbf513..d64939089622 100644
--- a/sw/source/core/access/acccontext.hxx
+++ b/sw/source/core/access/acccontext.hxx
@@ -349,6 +349,8 @@ public:
 virtual bool SetSelectedState(bool bSelected);
 bool  IsSelectedInDoc() const { return m_isSelectedInDoc; }
 
+bool IsDisposed() const;
+
 static OUString GetResource(TranslateId pResId,
 const OUString *pArg1 = nullptr,
 const OUString *pArg2 = nullptr);
diff --git a/sw/source/core/access/accmap.cxx b/sw/source/core/access/accmap.cxx
index fe0384ca0ea2..5cc2fd73801b 100644
--- a/sw/source/core/access/accmap.cxx
+++ b/sw/source/core/access/accmap.cxx
@@ -2673,7 +2673,9 @@ void SwAccessibleMap::InvalidateCursorPosition( const 
SwFrame *pFrame )
 
 for (SwAccessibleParagraph* pAccPara : m_setParaRemove)
 {
-if(pAccPara && pAccPara->getSelectedAccessibleChildCount() == 0 && 
pAccPara->getSelectedText().getLength() == 0)
+if (pAccPara && !pAccPara->IsDisposed() &&
+pAccPara->getSelectedAccessibleChildCount() == 0 &&
+pAccPara->getSelectedText().getLength() == 0)
 {
 if(pAccPara->SetSelectedState(false))
 {


[Libreoffice-commits] cppunit.git: include/cppunit

2023-05-09 Thread Libreoffice Gerrit user
 include/cppunit/TestAssert.h |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit e2b0721c33d0df57c6a596b18ae98644575c51f9
Author: Stephan Bergmann 
AuthorDate: Tue Feb 21 11:10:00 2023 +0100
Commit: Markus Mohrhard 
CommitDate: Tue May 9 20:00:18 2023 +0200

Don't mis-apply GCC < 4.6 workaround for Clang

...which happens to define __GNUC__=4, __GNUC_MINOR__=2.  (See also


"external/cppunit: Don't mis-apply GCC < 4.6 workaround for Clang".  This 
change
requires  "Use snprintf
instead of sprintf" to avoid deprecation warnings on macOS, which had 
originally
been hidden by the mis-applied #pragma.)

Change-Id: I4fcb38a79766238862795ba4019638862e65b041
Reviewed-on: https://gerrit.libreoffice.org/c/cppunit/+/147384
Reviewed-by: Markus Mohrhard 
Tested-by: Markus Mohrhard 

diff --git a/include/cppunit/TestAssert.h b/include/cppunit/TestAssert.h
index 19a8ae5..de97f21 100644
--- a/include/cppunit/TestAssert.h
+++ b/include/cppunit/TestAssert.h
@@ -11,7 +11,8 @@
 
 // Work around "passing 'T' chooses 'int' over 'unsigned int'" warnings when T
 // is an enum type:
-#if defined __GNUC__ && (__GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 6))
+#if defined __GNUC__ && (__GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 
6)) \
+&& !defined __clang__
 #pragma GCC system_header
 #endif
 


[Libreoffice-commits] cppunit.git: include/cppunit

2023-05-09 Thread Libreoffice Gerrit user
 include/cppunit/TestAssert.h |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 5f9aab1993016720db1d7008ed190b0a96293190
Author: Stephan Bergmann 
AuthorDate: Tue Feb 21 10:59:04 2023 +0100
Commit: Markus Mohrhard 
CommitDate: Tue May 9 19:59:41 2023 +0200

Use snprintf instead of sprintf

See


"external/cppunit: Use snprintf instead of sprintf" for how sprintf would 
have
caused deprecation warnings on macOS.

(For MSVC, keep using sprintf_s.  According to

:
"Beginning with the UCRT in Visual Studio 2015 and Windows 10, snprintf is 
no
longer identical to _snprintf.  The snprintf function behavior is now C99
standard conformant."  So for older versions, snprintf would potentially not
store a terminating NUL, like _snprintf but unlike sprintf_s.)

Change-Id: Ibf8b228cd1dd57428ecf85ed10e0793b78ae90c9
Reviewed-on: https://gerrit.libreoffice.org/c/cppunit/+/147383
Reviewed-by: Markus Mohrhard 
Tested-by: Markus Mohrhard 

diff --git a/include/cppunit/TestAssert.h b/include/cppunit/TestAssert.h
index 521a4e4..19a8ae5 100644
--- a/include/cppunit/TestAssert.h
+++ b/include/cppunit/TestAssert.h
@@ -112,7 +112,7 @@ struct assertion_traits
 #ifdef __STDC_SECURE_LIB__ // Use secure version with visual studio 2005 to 
avoid warning.
sprintf_s(buffer, sizeof(buffer), "%.*g", precision, x); 
 #else  
-   sprintf(buffer, "%.*g", precision, x); 
+   snprintf(buffer, sizeof(buffer), "%.*g", precision, x); 
 #endif
return buffer;
 }


[Libreoffice-commits] core.git: include/xmloff xmloff/source

2023-05-09 Thread Mike Kaganski (via logerrit)
 include/xmloff/maptype.hxx  |4 ++--
 xmloff/source/text/txtprmap.cxx |   20 ++--
 2 files changed, 12 insertions(+), 12 deletions(-)

New commits:
commit b7affedf9c281d6329ac87c5f3cd0fd0f617acbb
Author: Mike Kaganski 
AuthorDate: Tue May 9 19:14:41 2023 +0300
Commit: Mike Kaganski 
CommitDate: Tue May 9 19:51:27 2023 +0200

const -> constexpr

Change-Id: Ibeeba1862d84e43fa659cb2a97ef3498674f0d40
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151590
Tested-by: Jenkins
Reviewed-by: Mike Kaganski 

diff --git a/include/xmloff/maptype.hxx b/include/xmloff/maptype.hxx
index 942f7c46279a..5102b899b11e 100644
--- a/include/xmloff/maptype.hxx
+++ b/include/xmloff/maptype.hxx
@@ -102,7 +102,7 @@ struct XMLPropertyMapEntry
 static constexpr OUStringLiteral EMPTY{u""};
 
 template
-XMLPropertyMapEntry(
+constexpr XMLPropertyMapEntry(
 const OUStringLiteral& sApiName,
 sal_uInt16  nNameSpace,
 enum ::xmloff::token::XMLTokenEnum eXMLName,
@@ -118,7 +118,7 @@ struct XMLPropertyMapEntry
 {}
 
 /// used to mark the end of the array
-XMLPropertyMapEntry(std::nullptr_t)
+constexpr XMLPropertyMapEntry(std::nullptr_t)
 :
 msApiName(EMPTY),
 meXMLName(xmloff::token::XML_TOKEN_INVALID), mnNameSpace(0), mnType(0),
diff --git a/xmloff/source/text/txtprmap.cxx b/xmloff/source/text/txtprmap.cxx
index c3b7403de1d7..0c2a04a1eec4 100644
--- a/xmloff/source/text/txtprmap.cxx
+++ b/xmloff/source/text/txtprmap.cxx
@@ -87,7 +87,7 @@ using namespace ::xmloff::token;
 #define MAP_(name,prefix,token,type,context)  { name, prefix, token, type, 
context, SvtSaveOptions::ODFSVER_010, false }
 #define GMAP(name,prefix,token,type,context) 
MAP_(name,prefix,token,static_cast(type|XML_TYPE_PROP_GRAPHIC),context)
 
-XMLPropertyMapEntry const aXMLParaPropMap[] =
+XMLPropertyMapEntry constexpr aXMLParaPropMap[] =
 {
 // RES_UNKNOWNATR_CONTAINER
 MP_E( PROP_ParaUserDefinedAttributes, TEXT, XMLNS, 
XML_TYPE_ATTRIBUTE_CONTAINER | MID_FLAG_SPECIAL_ITEM, 0 ),
@@ -467,7 +467,7 @@ XMLPropertyMapEntry const aXMLParaPropMap[] =
 };
 
 
-XMLPropertyMapEntry const aXMLAdditionalTextDefaultsMap[] =
+XMLPropertyMapEntry constexpr aXMLAdditionalTextDefaultsMap[] =
 {
 // RES_FOLLOW_TEXT_FLOW - DVO #i18732#
 MG_ED( PROP_IsFollowingTextFlow, STYLE, FLOW_WITH_TEXT,  
XML_TYPE_BOOL, 0 ),
@@ -478,7 +478,7 @@ XMLPropertyMapEntry const aXMLAdditionalTextDefaultsMap[] =
 M_END()
 };
 
-XMLPropertyMapEntry const aXMLTextPropMap[] =
+XMLPropertyMapEntry constexpr aXMLTextPropMap[] =
 {
 // RES_CHRATR_CASEMAP
 MT_E( PROP_CharCaseMap,FO, FONT_VARIANT,   
XML_TYPE_TEXT_CASEMAP_VAR,  0 ),
@@ -682,7 +682,7 @@ XMLPropertyMapEntry const aXMLTextPropMap[] =
 M_END()
 };
 
-XMLPropertyMapEntry const aXMLFramePropMap[] =
+XMLPropertyMapEntry constexpr aXMLFramePropMap[] =
 {
 // RES_FILL_ORDER
 // TODO: not required???
@@ -894,7 +894,7 @@ XMLPropertyMapEntry const aXMLFramePropMap[] =
 M_END()
 };
 
-XMLPropertyMapEntry const aXMLShapePropMap[] =
+XMLPropertyMapEntry constexpr aXMLShapePropMap[] =
 {
 // RES_LR_SPACE
 MG_E( PROP_LeftMargin, FO, MARGIN_LEFT,
XML_TYPE_MEASURE,  0),
@@ -943,7 +943,7 @@ XMLPropertyMapEntry const aXMLShapePropMap[] =
 M_END()
 };
 
-XMLPropertyMapEntry const aXMLSectionPropMap[] =
+XMLPropertyMapEntry constexpr aXMLSectionPropMap[] =
 {
 // RES_COL
 MS_E( PROP_TextColumns,STYLE,  COLUMNS,
MID_FLAG_ELEMENT_ITEM|XML_TYPE_TEXT_COLUMNS, CTF_TEXTCOLUMNS ),
@@ -989,7 +989,7 @@ XMLPropertyMapEntry const aXMLSectionPropMap[] =
 M_END()
 };
 
-XMLPropertyMapEntry const aXMLRubyPropMap[] =
+XMLPropertyMapEntry constexpr aXMLRubyPropMap[] =
 {
 MR_E( PROP_RubyAdjust, STYLE, RUBY_ALIGN, XML_TYPE_TEXT_RUBY_ADJUST, 0 ),
 MR_E( PROP_RubyIsAbove,STYLE, RUBY_POSITION, 
XML_TYPE_TEXT_RUBY_IS_ABOVE, 0 ),
@@ -998,7 +998,7 @@ XMLPropertyMapEntry const aXMLRubyPropMap[] =
 };
 
 
-XMLPropertyMapEntry const aXMLTableDefaultsMap[] =
+XMLPropertyMapEntry constexpr aXMLTableDefaultsMap[] =
 {
 // RES_COLLAPSING_BORDERS: only occurs in tables, but we need to
 // read/write the default for this item
@@ -1007,7 +1007,7 @@ XMLPropertyMapEntry const aXMLTableDefaultsMap[] =
 M_END()
 };
 
-XMLPropertyMapEntry const aXMLTableRowDefaultsMap[] =
+XMLPropertyMapEntry constexpr aXMLTableRowDefaultsMap[] =
 {
 // RES_ROW_SPLIT: only occurs in table rows, but we need to
 // read/write the default for this item
@@ -1016,7 +1016,7 @@ XMLPropertyMapEntry const aXMLTableRowDefaultsMap[] =
 M_END()
 };
 
-XMLPropertyMapEntry const aXMLCellPropMap[] =
+XMLPropertyMapEntry constexpr aXMLCellPropMap[] =
 {
 MC_E( PROP_BackColor,FO,BACKGROUND_COLOR, 
XML_TYPE_COLORTRANSPARENT|MID_FLAG_MULTI_PROPERTY, 0 ),
 MC_E( PROP_LeftBorder,   FO,BORDER_LEFT,  XM

[Libreoffice-commits] core.git: sc/Library_scqahelper.mk sc/qa

2023-05-09 Thread Xisco Fauli (via logerrit)
 sc/Library_scqahelper.mk   |1 
 sc/qa/unit/helper/qahelper.cxx |   58 
 sc/qa/unit/helper/qahelper.hxx |5 +++
 sc/qa/unit/opencl-test-1.cxx   |   66 -
 sc/qa/unit/opencl-test-2.cxx   |   66 -
 5 files changed, 64 insertions(+), 132 deletions(-)

New commits:
commit 14c12d7a0672148522f0773146f41bb0648f6caa
Author: Xisco Fauli 
AuthorDate: Tue May 9 16:18:33 2023 +0200
Commit: Xisco Fauli 
CommitDate: Tue May 9 19:28:13 2023 +0200

CppunitTest_sc_opencl: factor out common code

Change-Id: I5da3d3a0e0f9f18033d8695081501a52aea5bd60
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151586
Tested-by: Jenkins
Reviewed-by: Xisco Fauli 

diff --git a/sc/Library_scqahelper.mk b/sc/Library_scqahelper.mk
index 07d769b77b4d..a4a6814203bd 100644
--- a/sc/Library_scqahelper.mk
+++ b/sc/Library_scqahelper.mk
@@ -20,6 +20,7 @@ $(eval $(call gb_Library_use_externals,scqahelper, \
mdds_headers \
cppunit \
libxml2 \
+   $(call gb_Helper_optional,OPENCL,clew) \
 ))
 
 ifneq ($(SYSTEM_LIBORCUS),)
diff --git a/sc/qa/unit/helper/qahelper.cxx b/sc/qa/unit/helper/qahelper.cxx
index af8e5ad8dca1..b5236da1f89e 100644
--- a/sc/qa/unit/helper/qahelper.cxx
+++ b/sc/qa/unit/helper/qahelper.cxx
@@ -19,6 +19,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -45,6 +46,7 @@
 
 #include 
 #include 
+#include 
 
 using namespace com::sun::star;
 using namespace ::com::sun::star::uno;
@@ -546,6 +548,13 @@ ScDocument* ScModelTestBase::getScDoc()
 return pModelObj->GetDocument();
 }
 
+ScDocument* ScModelTestBase::getScDoc2()
+{
+ScModelObj* pModelObj = 
comphelper::getFromUnoTunnel(mxComponent2);
+CPPUNIT_ASSERT(pModelObj);
+return pModelObj->GetDocument();
+}
+
 ScDocShell* ScModelTestBase::getScDocShell()
 {
 SfxObjectShell* pFoundShell = 
SfxObjectShell::GetShellFromComponent(mxComponent);
@@ -600,6 +609,55 @@ void ScModelTestBase::miscRowHeightsTest( TestParam const 
* aTestValues, unsigne
 }
 }
 
+void ScModelTestBase::enableOpenCL()
+{
+/**
+ * Turn on OpenCL group interpreter. Call this after the document is
+ * loaded and before performing formula calculation.
+ */
+sc::FormulaGroupInterpreter::enableOpenCL_UnitTestsOnly();
+}
+
+void ScModelTestBase::disableOpenCL()
+{
+sc::FormulaGroupInterpreter::disableOpenCL_UnitTestsOnly();
+}
+
+void ScModelTestBase::initTestEnv(std::u16string_view fileName)
+{
+// Some documents contain macros, disable them, otherwise
+// the "Error, BASIC runtime error." dialog is prompted
+// and it crashes in tearDown
+std::vector args;
+beans::PropertyValue aMacroValue;
+aMacroValue.Name = "MacroExecutionMode";
+aMacroValue.Handle = -1;
+aMacroValue.Value <<= document::MacroExecMode::NEVER_EXECUTE;
+aMacroValue.State = beans::PropertyState_DIRECT_VALUE;
+args.push_back(aMacroValue);
+
+disableOpenCL();
+CPPUNIT_ASSERT(!ScCalcConfig::isOpenCLEnabled());
+
+// Open the document with OpenCL disabled
+mxComponent = mxDesktop->loadComponentFromURL(
+createFileURL(fileName), "_default", 0, 
comphelper::containerToSequence(args));
+
+enableOpenCL();
+CPPUNIT_ASSERT(ScCalcConfig::isOpenCLEnabled());
+
+// it's not possible to open the same document twice, thus, create a temp 
file
+createTempCopy(fileName);
+
+// Open the document with OpenCL enabled
+mxComponent2 = mxDesktop->loadComponentFromURL(
+maTempFile.GetURL(), "_default", 0, 
comphelper::containerToSequence(args));
+
+// Check there are 2 documents
+uno::Reference xFrames = mxDesktop->getFrames();
+CPPUNIT_ASSERT_EQUAL(static_cast(2), xFrames->getCount());
+}
+
 ScRange ScUcalcTestBase::insertRangeData(
 ScDocument* pDoc, const ScAddress& rPos, const 
std::vector>& rData )
 {
diff --git a/sc/qa/unit/helper/qahelper.hxx b/sc/qa/unit/helper/qahelper.hxx
index fecf88a6ad0e..4b95451c96d1 100644
--- a/sc/qa/unit/helper/qahelper.hxx
+++ b/sc/qa/unit/helper/qahelper.hxx
@@ -156,10 +156,15 @@ public:
 
 void createScDoc(const char* pName = nullptr, const char* pPassword = 
nullptr, bool bCheckErrorCode = true);
 ScDocument* getScDoc();
+ScDocument* getScDoc2();
 ScDocShell* getScDocShell();
 ScTabViewShell* getViewShell();
 void miscRowHeightsTest( TestParam const * aTestValues, unsigned int 
numElems);
 
+void enableOpenCL();
+void disableOpenCL();
+void initTestEnv(std::u16string_view fileName);
+
 void testFile(const OUString& aFileName, ScDocument& rDoc, SCTAB nTab, 
StringType aStringFormat = StringType::StringValue);
 
 //need own handler because conditional formatting strings must be generated
diff --git a/sc/qa/unit/opencl-test-1.cxx b/sc/qa/unit/opencl-test-1.cxx
index 773c576b40db..3352ab3e4ad6 100644
--- a/sc/qa/unit/opencl-test-1.

[Libreoffice-commits] core.git: sc/qa

2023-05-09 Thread Xisco Fauli (via logerrit)
 sc/qa/uitest/autofilter2/tdf95520.py |   49 +++
 1 file changed, 49 insertions(+)

New commits:
commit efdbe4179d151899c8a9a9de8f5bc1660700b27d
Author: Xisco Fauli 
AuthorDate: Tue May 9 14:37:31 2023 +0200
Commit: Xisco Fauli 
CommitDate: Tue May 9 19:26:36 2023 +0200

tdf#95520: sc: Add UItest

Change-Id: Ia4e30a1e4dea3dbd9eb40c29c96e5ab3d700e54e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151578
Tested-by: Jenkins
Reviewed-by: Xisco Fauli 

diff --git a/sc/qa/uitest/autofilter2/tdf95520.py 
b/sc/qa/uitest/autofilter2/tdf95520.py
new file mode 100644
index ..ec245912c5a2
--- /dev/null
+++ b/sc/qa/uitest/autofilter2/tdf95520.py
@@ -0,0 +1,49 @@
+# -*- tab-width: 4; indent-tabs-mode: nil; py-indent-offset: 4 -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+from uitest.framework import UITestCase
+from uitest.uihelper.common import get_url_for_data_file
+from libreoffice.uno.propertyvalue import mkPropertyValues
+from libreoffice.calc.document import get_cell_by_position
+
+class tdf95520(UITestCase):
+def test_tdf95520(self):
+# Reuse existing document
+with self.ui_test.load_file(get_url_for_data_file("tdf144549.ods")) as 
doc:
+calcDoc = self.xUITest.getTopFocusWindow()
+xGridWin = calcDoc.getChild("grid_window")
+
+xGridWin.executeAction("LAUNCH", mkPropertyValues({"AUTOFILTER": 
"", "COL": "1", "ROW": "0"}))
+xFloatWindow = self.xUITest.getFloatWindow()
+xMenu = xFloatWindow.getChild("menu")
+
+# Sort by Color
+xMenu.executeAction("TYPE", mkPropertyValues({"KEYCODE":"DOWN"}))
+xMenu.executeAction("TYPE", mkPropertyValues({"KEYCODE":"DOWN"}))
+xMenu.executeAction("TYPE", mkPropertyValues({"KEYCODE":"RETURN"}))
+
+# Choose Red
+xSubFloatWindow = self.xUITest.getFloatWindow()
+xSubMenu = xSubFloatWindow.getChild("textcolor")
+xSubMenu.executeAction("TYPE", 
mkPropertyValues({"KEYCODE":"DOWN"}))
+xSubMenu.executeAction("TYPE", 
mkPropertyValues({"KEYCODE":"RETURN"}))
+
+self.assertEqual("Jan", get_cell_by_position(doc, 0, 0, 
1).getString())
+self.assertEqual("Dez", get_cell_by_position(doc, 0, 0, 
2).getString())
+self.assertEqual("Aug", get_cell_by_position(doc, 0, 0, 
3).getString())
+self.assertEqual("Nov", get_cell_by_position(doc, 0, 0, 
4).getString())
+self.assertEqual("Jun", get_cell_by_position(doc, 0, 0, 
5).getString())
+self.assertEqual("Apr", get_cell_by_position(doc, 0, 0, 
6).getString())
+self.assertEqual("Mai", get_cell_by_position(doc, 0, 0, 
7).getString())
+self.assertEqual("Okt", get_cell_by_position(doc, 0, 0, 
8).getString())
+self.assertEqual("Feb", get_cell_by_position(doc, 0, 0, 
9).getString())
+self.assertEqual("Mär", get_cell_by_position(doc, 0, 0, 
10).getString())
+self.assertEqual("Jul", get_cell_by_position(doc, 0, 0, 
11).getString())
+self.assertEqual("Sep", get_cell_by_position(doc, 0, 0, 
12).getString())
+
+# vim: set shiftwidth=4 softtabstop=4 expandtab:


[Libreoffice-commits] core.git: oox/source

2023-05-09 Thread Andrea Gelmini (via logerrit)
 oox/source/export/drawingml.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 91bdd2fa1a8d602a2af26dfbc38cdd09f2e8394e
Author: Andrea Gelmini 
AuthorDate: Wed May 3 19:55:51 2023 +0200
Commit: Julien Nabet 
CommitDate: Tue May 9 19:25:18 2023 +0200

Fix typo

Change-Id: I38877f928fd6943afa1a6c17d8225caef8411d1b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151338
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/oox/source/export/drawingml.cxx b/oox/source/export/drawingml.cxx
index ad07308ada62..9f705a20cf9e 100644
--- a/oox/source/export/drawingml.cxx
+++ b/oox/source/export/drawingml.cxx
@@ -860,7 +860,7 @@ void DrawingML::WriteGradientFill(
 // Caution: do not add 1st entry again, that would be double 
since it was
 // already added as last element of the inverse run above. But 
only if
 // the gradient has a start entry for 0.0 aka StartColor, else 
it is correct.
-// Since aColorStops and aAlphaStops are already syched (see
+// Since aColorStops and aAlphaStops are already synched (see
 // synchronizeColorStops above), testing one of them is 
sufficient here.
 aCurrColor++;
 aCurrAlpha++;


[Libreoffice-commits] core.git: Branch 'libreoffice-7-5' - 2 commits - filter/source

2023-05-09 Thread Michael Stahl (via logerrit)
 filter/source/xslt/odf2xhtml/export/common/table/table.xsl |2 +-
 filter/source/xslt/odf2xhtml/export/xhtml/header.xsl   |3 ---
 2 files changed, 1 insertion(+), 4 deletions(-)

New commits:
commit 35fe68188e984d32d3f21db81e633743ca06f67c
Author: Michael Stahl 
AuthorDate: Wed May 3 16:00:17 2023 +0200
Commit: Adolfo Jayme Barrientos 
CommitDate: Tue May 9 18:28:26 2023 +0200

tdf#153839 XHTML export: do not add newlines to attribute values

(regression from commit d2e8705c9cc503afdaed366b1f71ed012b0c568f)

Change-Id: I5e841b1db195b0646c5a2244061f93b97344c3dd
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151465
Tested-by: Michael Stahl 
Reviewed-by: Michael Stahl 
(cherry picked from commit 84d798a9cfd8da090c68340838102fc8704febb3)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151388
Tested-by: Jenkins
Reviewed-by: Adolfo Jayme Barrientos 

diff --git a/filter/source/xslt/odf2xhtml/export/xhtml/header.xsl 
b/filter/source/xslt/odf2xhtml/export/xhtml/header.xsl
index 581b8b8d3421..8ee38796ebdf 100644
--- a/filter/source/xslt/odf2xhtml/export/xhtml/header.xsl
+++ b/filter/source/xslt/odf2xhtml/export/xhtml/header.xsl
@@ -267,7 +267,6 @@
  
  en-US
  
- 

 
 
 
@@ -277,7 +276,6 @@
  
  
  
- 

 
 
 
@@ -287,7 +285,6 @@
 , 
 
 
-

 
 
 

commit fc4b4d007e41192c21d2979e45ac73541935c00e
Author: Michael Stahl 
AuthorDate: Wed May 3 15:02:30 2023 +0200
Commit: Adolfo Jayme Barrientos 
CommitDate: Tue May 9 18:28:15 2023 +0200

tdf#153839 XHTML export: fix syntax error in table.xsl

Static error at xsl:param on line 67 column 40 of table.xsl:
  XTSE0010: xsl:param must not be preceded by other instructions

(regression from commit ce4272c25426f0084e53735e80870b9339239078)

Change-Id: I5bed9a8ad81edc5ec016618cb9fd5d75209a2809
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151464
Tested-by: Michael Stahl 
Reviewed-by: Michael Stahl 
(cherry picked from commit 63ac36893ad7f3b1c73cb46667fbfd5384a747dc)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151389
Tested-by: Jenkins
Reviewed-by: Adolfo Jayme Barrientos 

diff --git a/filter/source/xslt/odf2xhtml/export/common/table/table.xsl 
b/filter/source/xslt/odf2xhtml/export/common/table/table.xsl
index d55948cab5b9..1e9baa5703f2 100644
--- a/filter/source/xslt/odf2xhtml/export/common/table/table.xsl
+++ b/filter/source/xslt/odf2xhtml/export/common/table/table.xsl
@@ -63,9 +63,9 @@
 
 
 
-

 
 
+

 
 
 


[Libreoffice-commits] core.git: Branch 'libreoffice-7-5' - filter/source

2023-05-09 Thread Franklin Weng (via logerrit)
 filter/source/xslt/odf2xhtml/export/common/table/table.xsl |4 ++
 filter/source/xslt/odf2xhtml/export/xhtml/body.xsl |   19 ++---
 2 files changed, 20 insertions(+), 3 deletions(-)

New commits:
commit c910a1320c7247c111d4f7e2a61540fc646938ff
Author: Franklin Weng 
AuthorDate: Wed Mar 22 12:33:38 2023 +0800
Commit: Adolfo Jayme Barrientos 
CommitDate: Tue May 9 18:26:48 2023 +0200

tdf#153839 : Further handling for adding newlines

before and after some tags as described in comment 7

Change-Id: I6e2a6559a888d259c6d1cc848fad7d39a1ab653b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/149280
Reviewed-by: Stéphane Guillou 
Tested-by: Ilmari Lauhakangas 
Reviewed-by: Ilmari Lauhakangas 
(cherry picked from commit ce4272c25426f0084e53735e80870b9339239078)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150729
Tested-by: Jenkins
Reviewed-by: Adolfo Jayme Barrientos 

diff --git a/filter/source/xslt/odf2xhtml/export/common/table/table.xsl 
b/filter/source/xslt/odf2xhtml/export/common/table/table.xsl
index cfc1ebbc525b..d55948cab5b9 100644
--- a/filter/source/xslt/odf2xhtml/export/common/table/table.xsl
+++ b/filter/source/xslt/odf2xhtml/export/common/table/table.xsl
@@ -63,6 +63,7 @@
 
 
 
+

 
 
 
@@ -71,6 +72,7 @@
 
 
 
+

 
 
 
@@ -110,10 +112,12 @@
 
 
 
+

 
 
 
 
+

 
 
 
diff --git a/filter/source/xslt/odf2xhtml/export/xhtml/body.xsl 
b/filter/source/xslt/odf2xhtml/export/xhtml/body.xsl
index 6f64b5a83d82..6ad03e260d8c 100644
--- a/filter/source/xslt/odf2xhtml/export/xhtml/body.xsl
+++ b/filter/source/xslt/odf2xhtml/export/xhtml/body.xsl
@@ -254,7 +254,9 @@
 
 
 
+

 Next 'div' was a 'draw:text-box'.
+

 
 
 
@@ -379,10 +381,14 @@
 
 
 
+

 Next 'div' was a 'text:p'.
+

 
 
+

 Next 'div' was a 
'draw:page'.
+

 
 
 
@@ -840,7 +846,9 @@
 
+

 Next 'div' added for 
floating.
+

 
 
 display:inline; position:relative; 
left:
@@ -1031,7 +1039,9 @@
 
 
 
+

 Next 'div' is emulating the top height of a 
draw:frame.
+

 

[Libreoffice-commits] core.git: cppuhelper/source

2023-05-09 Thread Noel Grandin (via logerrit)
 cppuhelper/source/typemanager.cxx |3 ---
 cppuhelper/source/typemanager.hxx |9 +++--
 2 files changed, 3 insertions(+), 9 deletions(-)

New commits:
commit 94aba9289af06b3a18f143d1253467f32c4af2cd
Author: Noel Grandin 
AuthorDate: Sun May 7 12:20:57 2023 +0200
Commit: Noel Grandin 
CommitDate: Tue May 9 18:15:20 2023 +0200

use WeakComponentImplHelper2 in TypeManager

Change-Id: I2358006a069ea4e8cdeeeafb8384ad8d47fba50a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151579
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/cppuhelper/source/typemanager.cxx 
b/cppuhelper/source/typemanager.cxx
index bede11f7c405..0408234c4b39 100644
--- a/cppuhelper/source/typemanager.cxx
+++ b/cppuhelper/source/typemanager.cxx
@@ -1825,7 +1825,6 @@ void Enumeration::findNextMatch() {
 }
 
 cppuhelper::TypeManager::TypeManager():
-TypeManager_Base(m_aMutex),
 manager_(new unoidl::Manager)
 {}
 
@@ -1906,8 +1905,6 @@ cppuhelper::TypeManager::resolve(OUString const & name) {
 
 cppuhelper::TypeManager::~TypeManager() noexcept {}
 
-void cppuhelper::TypeManager::disposing() {} //TODO
-
 OUString cppuhelper::TypeManager::getImplementationName()
 {
 return
diff --git a/cppuhelper/source/typemanager.hxx 
b/cppuhelper/source/typemanager.hxx
index 24fe0ef12166..ab1dc4fdbe71 100644
--- a/cppuhelper/source/typemanager.hxx
+++ b/cppuhelper/source/typemanager.hxx
@@ -20,8 +20,7 @@
 #include 
 #include 
 #include 
-#include 
-#include 
+#include 
 #include 
 #include 
 
@@ -37,12 +36,12 @@ namespace unoidl {
 
 namespace cppuhelper {
 
-typedef cppu::WeakComponentImplHelper<
+typedef WeakComponentImplHelper2<
 css::lang::XServiceInfo, css::container::XHierarchicalNameAccess,
 css::container::XSet, css::reflection::XTypeDescriptionEnumerationAccess >
 TypeManager_Base;
 
-class TypeManager: private cppu::BaseMutex, public TypeManager_Base {
+class TypeManager: public TypeManager_Base {
 public:
 TypeManager();
 
@@ -59,8 +58,6 @@ public:
 private:
 virtual ~TypeManager() noexcept override;
 
-virtual void SAL_CALL disposing() override;
-
 virtual OUString SAL_CALL getImplementationName() override;
 
 virtual sal_Bool SAL_CALL supportsService(OUString const & ServiceName) 
override;


[Libreoffice-commits] core.git: include/toolkit solenv/clang-format toolkit/inc toolkit/source

2023-05-09 Thread Noel Grandin (via logerrit)
 solenv/clang-format/excludelist   |3 +--
 toolkit/inc/helper/property.hxx   |4 +---
 toolkit/source/awt/animatedimagespeer.cxx |2 +-
 toolkit/source/awt/vclxcontainer.cxx  |2 +-
 toolkit/source/awt/vclxspinbutton.cxx |2 +-
 toolkit/source/awt/vclxtabpagecontainer.cxx   |2 +-
 toolkit/source/awt/vclxtoolkit.cxx|2 +-
 toolkit/source/awt/vclxwindow.cxx |2 +-
 toolkit/source/awt/vclxwindows.cxx|2 +-
 toolkit/source/controls/animatedimages.cxx|2 +-
 toolkit/source/controls/controlmodelcontainerbase.cxx |2 +-
 toolkit/source/controls/dialogcontrol.cxx |2 +-
 toolkit/source/controls/formattedcontrol.cxx  |2 +-
 toolkit/source/controls/geometrycontrolmodel.cxx  |2 +-
 toolkit/source/controls/grid/gridcontrol.cxx  |2 +-
 toolkit/source/controls/roadmapcontrol.cxx|2 +-
 toolkit/source/controls/svtxgridcontrol.cxx   |2 +-
 toolkit/source/controls/tabpagecontainer.cxx  |2 +-
 toolkit/source/controls/tabpagemodel.cxx  |2 +-
 toolkit/source/controls/tkscrollbar.cxx   |2 +-
 toolkit/source/controls/tkspinbutton.cxx  |2 +-
 toolkit/source/controls/tree/treecontrol.cxx  |2 +-
 toolkit/source/controls/tree/treecontrolpeer.cxx  |2 +-
 toolkit/source/controls/unocontrol.cxx|2 +-
 toolkit/source/controls/unocontrolbase.cxx|2 +-
 toolkit/source/controls/unocontrolcontainermodel.cxx  |2 +-
 toolkit/source/controls/unocontrolmodel.cxx   |2 +-
 toolkit/source/controls/unocontrols.cxx   |2 +-
 toolkit/source/helper/property.cxx|2 +-
 toolkit/source/helper/unopropertyarrayhelper.cxx  |2 +-
 30 files changed, 30 insertions(+), 33 deletions(-)

New commits:
commit cd52832249267a83f7207e6702a50af6e94c6654
Author: Noel Grandin 
AuthorDate: Tue May 9 09:03:35 2023 +0200
Commit: Noel Grandin 
CommitDate: Tue May 9 18:12:21 2023 +0200

move a toolkit header inside the module

It is only used inside the module, no need to be public

Change-Id: Ibd8445ecbb67624569ee7225f0bdf6d9c041dab4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151569
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/solenv/clang-format/excludelist b/solenv/clang-format/excludelist
index b0437ef47617..3453747854d3 100644
--- a/solenv/clang-format/excludelist
+++ b/solenv/clang-format/excludelist
@@ -5270,7 +5270,6 @@ include/framework/desktop.hxx
 include/framework/documentundoguard.hxx
 include/framework/framecontainer.hxx
 include/framework/framelistanalyzer.hxx
-include/framework/gate.hxx
 include/framework/generictoolbarcontroller.hxx
 include/framework/imutex.hxx
 include/framework/sfxhelperfunctions.hxx
@@ -6107,7 +6106,6 @@ include/toolkit/helper/accessiblefactory.hxx
 include/toolkit/helper/convert.hxx
 include/toolkit/helper/listenermultiplexer.hxx
 include/toolkit/helper/macros.hxx
-include/toolkit/helper/property.hxx
 include/toolkit/helper/vclunohelper.hxx
 include/tools/b3dtrans.hxx
 include/tools/bigint.hxx
@@ -13563,6 +13561,7 @@ toolkit/inc/controls/unocontrolcontainermodel.hxx
 toolkit/inc/helper/accessibilityclient.hxx
 toolkit/inc/helper/btndlg.hxx
 toolkit/inc/helper/imagealign.hxx
+toolkit/inc/helper/property.hxx
 toolkit/inc/helper/scrollabledialog.hxx
 toolkit/inc/helper/unopropertyarrayhelper.hxx
 toolkit/inc/helper/unowrapper.hxx
diff --git a/include/toolkit/helper/property.hxx 
b/toolkit/inc/helper/property.hxx
similarity index 99%
rename from include/toolkit/helper/property.hxx
rename to toolkit/inc/helper/property.hxx
index e082433dd364..013f73496482 100644
--- a/include/toolkit/helper/property.hxx
+++ b/toolkit/inc/helper/property.hxx
@@ -20,8 +20,6 @@
 #ifndef INCLUDED_TOOLKIT_HELPER_PROPERTY_HXX
 #define INCLUDED_TOOLKIT_HELPER_PROPERTY_HXX
 
-#include 
-
 #include 
 #include 
 
@@ -234,7 +232,7 @@ namespace com::sun::star::uno {
 #define PROPERTY_ALIGN_RIGHT2
 
 
-TOOLKIT_DLLPUBLIC sal_uInt16GetPropertyId( const OUString& 
rPropertyName );
+sal_uInt16GetPropertyId( const OUString& rPropertyName );
 const css::uno::Type*  GetPropertyType( sal_uInt16 nPropertyId );
 const OUString&GetPropertyName( sal_uInt16 nPropertyId );
 sal_Int16   GetPropertyAttribs( sal_uInt16 nPropertyId 
);
diff --git a/toolkit/source/awt/animatedimagespeer.cxx 
b/toolkit/source/awt/animatedimagespeer.cxx
index adb89c2c962b..ac2dca5603be 100644
--- a/toolkit/source/awt/animatedimagespeer.cxx
+++ b/toolkit/source/awt/animatedimagespeer.cxx
@@ -19,7 +19,7 @@
 
 
 #include 
-#include 
+#include 
 
 #include 
 #include 
diff --git a/toolkit/source/awt/vclxcontainer.cxx 
b/toolkit/source/awt/vc

[Libreoffice-commits] core.git: svx/inc svx/source

2023-05-09 Thread Noel Grandin (via logerrit)
 svx/inc/galleryfilestorageentry.hxx |   15 ---
 svx/source/gallery2/gallery1.cxx|2 +-
 svx/source/gallery2/galleryfilestorageentry.cxx |9 +++--
 3 files changed, 12 insertions(+), 14 deletions(-)

New commits:
commit 4f520dc7e3badc0165ee3b13ddd514bb94b00265
Author: Noel Grandin 
AuthorDate: Mon May 8 13:00:26 2023 +0200
Commit: Noel Grandin 
CommitDate: Tue May 9 18:12:02 2023 +0200

inline GalleryStorageLocations allocation into GalleryFileStorageEntry

no need to allocate this separately

Change-Id: I01795ac459c5b65b5c143dc081e5b7cf74c2e6f4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151554
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/svx/inc/galleryfilestorageentry.hxx 
b/svx/inc/galleryfilestorageentry.hxx
index 66762fa82241..10a020297e72 100644
--- a/svx/inc/galleryfilestorageentry.hxx
+++ b/svx/inc/galleryfilestorageentry.hxx
@@ -30,7 +30,7 @@ class GalleryObjectCollection;
 class GalleryFileStorageEntry final
 {
 private:
-std::unique_ptr mpGalleryStorageLocations;
+GalleryStorageLocations maGalleryStorageLocations;
 
 public:
 GalleryFileStorageEntry();
@@ -38,15 +38,16 @@ public:
 
 OUString ReadStrFromIni(std::u16string_view aKeyName) const;
 
-const INetURLObject& GetThmURL() const { return 
mpGalleryStorageLocations->GetThmURL(); }
-const INetURLObject& GetSdgURL() const { return 
mpGalleryStorageLocations->GetSdgURL(); }
-const INetURLObject& GetSdvURL() const { return 
mpGalleryStorageLocations->GetSdvURL(); }
-const INetURLObject& GetStrURL() const { return 
mpGalleryStorageLocations->GetStrURL(); }
+const INetURLObject& GetThmURL() const { return 
maGalleryStorageLocations.GetThmURL(); }
+const INetURLObject& GetSdgURL() const { return 
maGalleryStorageLocations.GetSdgURL(); }
+const INetURLObject& GetSdvURL() const { return 
maGalleryStorageLocations.GetSdvURL(); }
+const INetURLObject& GetStrURL() const { return 
maGalleryStorageLocations.GetStrURL(); }
 
-const std::unique_ptr& 
getGalleryStorageLocations() const
+const GalleryStorageLocations& getGalleryStorageLocations() const
 {
-return mpGalleryStorageLocations;
+return maGalleryStorageLocations;
 }
+GalleryStorageLocations& getGalleryStorageLocations() { return 
maGalleryStorageLocations; }
 
 static GalleryThemeEntry* CreateThemeEntry(const INetURLObject& rURL, bool 
bReadOnly);
 
diff --git a/svx/source/gallery2/gallery1.cxx b/svx/source/gallery2/gallery1.cxx
index 8dad889b6a8c..17bc19a8990a 100644
--- a/svx/source/gallery2/gallery1.cxx
+++ b/svx/source/gallery2/gallery1.cxx
@@ -726,7 +726,7 @@ bool GalleryThemeEntry::IsDefault() const
 
 GalleryStorageLocations& GalleryThemeEntry::getGalleryStorageLocations() const
 {
-return *mpGalleryStorageEngineEntry->getGalleryStorageLocations();
+return mpGalleryStorageEngineEntry->getGalleryStorageLocations();
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/gallery2/galleryfilestorageentry.cxx 
b/svx/source/gallery2/galleryfilestorageentry.cxx
index b7de500f66e3..593396aaed37 100644
--- a/svx/source/gallery2/galleryfilestorageentry.cxx
+++ b/svx/source/gallery2/galleryfilestorageentry.cxx
@@ -35,20 +35,17 @@ static bool FileExists(const INetURLObject& rURL, 
std::u16string_view rExt)
 return FileExists(aURL);
 }
 
-GalleryFileStorageEntry::GalleryFileStorageEntry()
-{
-mpGalleryStorageLocations = std::make_unique();
-}
+GalleryFileStorageEntry::GalleryFileStorageEntry() {}
 
 void GalleryFileStorageEntry::setStorageLocations(INetURLObject& rURL)
 {
-mpGalleryStorageLocations->SetStorageLocations(rURL);
+maGalleryStorageLocations.SetStorageLocations(rURL);
 }
 
 std::unique_ptr 
GalleryFileStorageEntry::createGalleryStorageEngine(
 GalleryObjectCollection& mrGalleryObjectCollection, bool& bReadOnly)
 {
-return std::make_unique(*mpGalleryStorageLocations,
+return std::make_unique(maGalleryStorageLocations,
 mrGalleryObjectCollection, 
bReadOnly);
 }
 


[Libreoffice-commits] core.git: sw/qa

2023-05-09 Thread Xisco Fauli (via logerrit)
 sw/qa/extras/uiwriter/uiwriter3.cxx |   15 +++
 1 file changed, 15 insertions(+)

New commits:
commit 9af57871fc153ca0145dd40e48f577564395ab73
Author: Xisco Fauli 
AuthorDate: Tue May 9 11:18:49 2023 +0200
Commit: Xisco Fauli 
CommitDate: Tue May 9 17:48:18 2023 +0200

tdf#154282: sw_uiwriter3: Add unittest

Change-Id: I48b0dd636f50bf0b4d08ee0d43593f6142babd3b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151566
Tested-by: Jenkins
Reviewed-by: Xisco Fauli 

diff --git a/sw/qa/extras/uiwriter/uiwriter3.cxx 
b/sw/qa/extras/uiwriter/uiwriter3.cxx
index c1a8faef373a..ef6de9c8e660 100644
--- a/sw/qa/extras/uiwriter/uiwriter3.cxx
+++ b/sw/qa/extras/uiwriter/uiwriter3.cxx
@@ -1780,6 +1780,21 @@ CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testTdf134253)
 CPPUNIT_ASSERT_EQUAL(6, getPages());
 }
 
+CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testNotebookBar)
+{
+createSwDoc();
+
+//tdf#154282: Without the fix in place, this test would have crashed
+dispatchCommand(mxComponent, 
".uno:ToolbarMode?Mode:string=notebookbar.ui", {});
+dispatchCommand(mxComponent, ".uno:ToolbarMode?Mode:string=Single", {});
+dispatchCommand(mxComponent, ".uno:ToolbarMode?Mode:string=Sidebar", {});
+dispatchCommand(mxComponent, 
".uno:ToolbarMode?Mode:string=notebookbar_compact.ui", {});
+dispatchCommand(mxComponent, 
".uno:ToolbarMode?Mode:string=notebookbar_groupedbar_compact.ui",
+{});
+dispatchCommand(mxComponent, 
".uno:ToolbarMode?Mode:string=notebookbar_single.ui", {});
+dispatchCommand(mxComponent, ".uno:ToolbarMode?Mode:string=Default", {});
+}
+
 CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, TestAsCharTextBox)
 {
 // Related tickets:


[Libreoffice-commits] core.git: sc/source

2023-05-09 Thread Dennis Francis (via logerrit)
 sc/source/core/data/validat.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 4adf6852cc3fd0eddf53c2ab4f66efed0668b699
Author: Dennis Francis 
AuthorDate: Wed May 3 13:00:09 2023 +0530
Commit: Dennis Francis 
CommitDate: Tue May 9 17:41:47 2023 +0200

sc: use the current cell's numfmt to format...

to format the values in the validation list when the items are numbers.
This is better than applying no formatting since we lost track of the
source formatting when values are passed through a matrix.

Change-Id: I06432bd93ef8d01181dd16d2f5ee99eb0477c094
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151313
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Henry Castro 
(cherry picked from commit 2f6d1cefc184fda3ba292f1718b034202989d7b3)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151386
Tested-by: Jenkins
Reviewed-by: Dennis Francis 

diff --git a/sc/source/core/data/validat.cxx b/sc/source/core/data/validat.cxx
index 8fb0f9f7924a..009bc0eaebe7 100644
--- a/sc/source/core/data/validat.cxx
+++ b/sc/source/core/data/validat.cxx
@@ -856,6 +856,7 @@ bool ScValidationData::GetSelectionFromFormula(
 rMatch = -1;
 
 SvNumberFormatter* pFormatter = GetDocument()->GetFormatTable();
+sal_uInt32 nDestFormat = pDocument->GetNumberFormat(rPos.Col(), 
rPos.Row(), rPos.Tab());
 
 SCSIZE  nCol, nRow, nCols, nRows, n = 0;
 pValues->GetDimensions( nCols, nRows );
@@ -957,7 +958,7 @@ bool ScValidationData::GetSelectionFromFormula(
 }
 else
 {
-pFormatter->GetInputLineString( nMatVal.fVal, 0, 
aValStr );
+pFormatter->GetInputLineString( nMatVal.fVal, 
nDestFormat, aValStr );
 }
 }
 


[Libreoffice-commits] core.git: formula/source sc/qa

2023-05-09 Thread Andreas Heinisch (via logerrit)
 formula/source/ui/dlg/formula.cxx |3 ++-
 formula/source/ui/dlg/funcpage.cxx|   10 +-
 formula/source/ui/dlg/funcpage.hxx|6 ++
 sc/qa/uitest/function_wizard/tdf104487.py |   28 
 4 files changed, 45 insertions(+), 2 deletions(-)

New commits:
commit 421d4fc533498d058a91f9686c47b35114e6a6c9
Author: Andreas Heinisch 
AuthorDate: Tue May 9 11:04:37 2023 +0200
Commit: Andreas Heinisch 
CommitDate: Tue May 9 17:39:05 2023 +0200

tdf#104487 - Function wizard: remember last used function category

Change-Id: I978dd63553e3528e7b9b853dbb438304f1f680cc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151565
Tested-by: Jenkins
Reviewed-by: Andreas Heinisch 

diff --git a/formula/source/ui/dlg/formula.cxx 
b/formula/source/ui/dlg/formula.cxx
index c12534268131..123642c46c1e 100644
--- a/formula/source/ui/dlg/formula.cxx
+++ b/formula/source/ui/dlg/formula.cxx
@@ -828,7 +828,8 @@ void FormulaDlg_Impl::FillListboxes()
 }
 else if ( pData )
 {
-m_xFuncPage->SetCategory( 1 );
+// tdf#104487 - remember last used function category
+m_xFuncPage->SetCategory(FuncPage::GetRememeberdFunctionCategory());
 m_xFuncPage->SetFunction( -1 );
 }
 FuncSelHdl(*m_xFuncPage);
diff --git a/formula/source/ui/dlg/funcpage.cxx 
b/formula/source/ui/dlg/funcpage.cxx
index 3013b84c06b6..dbdb49464ae7 100644
--- a/formula/source/ui/dlg/funcpage.cxx
+++ b/formula/source/ui/dlg/funcpage.cxx
@@ -37,6 +37,9 @@ IMPL_LINK(FuncPage, KeyInputHdl, const KeyEvent&, rKEvt, bool)
 return false;
 }
 
+// tdf#104487 - remember last used function category - set default to All 
category
+sal_Int32 FuncPage::m_nRememberedFunctionCategory = 1;
+
 FuncPage::FuncPage(weld::Container* pParent, const IFunctionManager* 
_pFunctionManager)
 : m_xBuilder(Application::CreateBuilder(pParent, 
"formula/ui/functionpage.ui"))
 , m_xContainer(m_xBuilder->weld_container("FunctionPage"))
@@ -58,7 +61,8 @@ FuncPage::FuncPage(weld::Container* pParent, const 
IFunctionManager* _pFunctionM
 m_xLbCategory->append(sId, pCategory->getName());
 }
 
-m_xLbCategory->set_active(1);
+// tdf#104487 - remember last used function category
+m_xLbCategory->set_active(m_nRememberedFunctionCategory);
 OUString searchStr = m_xLbFunctionSearchString->get_text();
 UpdateFunctionList(searchStr);
 // lock to its initial size
@@ -96,6 +100,8 @@ void FuncPage::UpdateFunctionList(const OUString& aStr)
 m_xLbFunction->freeze();
 
 const sal_Int32 nSelPos = m_xLbCategory->get_active();
+// tdf#104487 - remember last used function category
+m_nRememberedFunctionCategory = nSelPos;
 
 if (aStr.isEmpty() || nSelPos == 0)
 {
@@ -217,6 +223,8 @@ IMPL_LINK_NOARG(FuncPage, ModifyHdl, weld::Entry&, void)
 
 void FuncPage::SetCategory(sal_Int32 nCat)
 {
+// tdf#104487 - remember last used function category
+m_nRememberedFunctionCategory = nCat;
 m_xLbCategory->set_active(nCat);
 UpdateFunctionList(OUString());
 }
diff --git a/formula/source/ui/dlg/funcpage.hxx 
b/formula/source/ui/dlg/funcpage.hxx
index 1e91b610ec0d..e7ca248d861b 100644
--- a/formula/source/ui/dlg/funcpage.hxx
+++ b/formula/source/ui/dlg/funcpage.hxx
@@ -48,6 +48,9 @@ private:
 ::std::vector< TFunctionDesc >  aLRUList;
 OUStringm_aHelpId;
 
+// tdf#104487 - remember last used function category
+static sal_Int32 m_nRememberedFunctionCategory;
+
 void impl_addFunctions(const IFunctionCategory* _pCategory);
 
 DECL_LINK(SelComboBoxHdl, weld::ComboBox&, void);
@@ -71,6 +74,9 @@ public:
 sal_Int32   GetFunction() const;
 sal_Int32   GetFunctionEntryCount() const;
 
+// tdf#104487 - remember last used function category
+static sal_Int32 GetRememeberdFunctionCategory() { return 
m_nRememberedFunctionCategory; };
+
 sal_Int32   GetFuncPos(const IFunctionDescription* _pDesc);
 const IFunctionDescription* GetFuncDesc( sal_Int32  nPos ) const;
 OUStringGetSelFunctionName() const;
diff --git a/sc/qa/uitest/function_wizard/tdf104487.py 
b/sc/qa/uitest/function_wizard/tdf104487.py
new file mode 100755
index ..8b563bc5b372
--- /dev/null
+++ b/sc/qa/uitest/function_wizard/tdf104487.py
@@ -0,0 +1,28 @@
+# -*- tab-width: 4; indent-tabs-mode: nil; py-indent-offset: 4 -*-
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+from uitest.framework import UITestCase
+from uitest.uihelper.common import get_state_as_dict, select_pos
+
+class tdf104487(UITestCase):
+def test_tdf104487_remember_function_category(self):
+with self.ui_test.create_doc_in_start_center("calc"):
+# Open function dialog and select select a fu

[Libreoffice-commits] core.git: sc/Library_sc.mk sc/Library_scui.mk sc/source sc/ucalc_setup.mk

2023-05-09 Thread Tomaž Vajngerl (via logerrit)
 sc/Library_sc.mk|1 +
 sc/Library_scui.mk  |1 +
 sc/source/ui/docshell/docsh.cxx |   23 +++
 sc/source/ui/inc/docsh.hxx  |1 +
 sc/ucalc_setup.mk   |1 +
 5 files changed, 27 insertions(+)

New commits:
commit 600ad0a53e25beed8b418d477635d0c8513d5d07
Author: Tomaž Vajngerl 
AuthorDate: Fri May 5 23:09:32 2023 +0900
Commit: Tomaž Vajngerl 
CommitDate: Tue May 9 16:27:17 2023 +0200

sc: add theme colors to the color picker

Change-Id: Iae8f502a24187f4d41f60fbb727066f214d1cf70
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151449
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 

diff --git a/sc/Library_sc.mk b/sc/Library_sc.mk
index 82bab43389c1..141c01fc73b8 100644
--- a/sc/Library_sc.mk
+++ b/sc/Library_sc.mk
@@ -72,6 +72,7 @@ $(eval $(call gb_Library_use_libraries,sc,\
 dbtools \
 drawinglayercore \
 drawinglayer \
+docmodel \
 editeng \
 for \
 forui \
diff --git a/sc/Library_scui.mk b/sc/Library_scui.mk
index 02c2bc8244d1..a4c7572734ae 100644
--- a/sc/Library_scui.mk
+++ b/sc/Library_scui.mk
@@ -50,6 +50,7 @@ $(eval $(call gb_Library_use_libraries,scui,\
comphelper \
cppu \
cppuhelper \
+   docmodel \
editeng \
for \
forui \
diff --git a/sc/source/ui/docshell/docsh.cxx b/sc/source/ui/docshell/docsh.cxx
index f5d10cfe67ab..3d8647dc8ea8 100644
--- a/sc/source/ui/docshell/docsh.cxx
+++ b/sc/source/ui/docshell/docsh.cxx
@@ -79,6 +79,9 @@
 #include 
 #include 
 #include 
+#include 
+#include 
+#include 
 
 #include 
 #include 
@@ -215,6 +218,26 @@ std::set ScDocShell::GetDocColors()
 return m_pDocument->GetDocColors();
 }
 
+std::vector ScDocShell::GetThemeColors()
+{
+ScTabViewShell* pSh = GetBestViewShell();
+if (!pSh)
+return {};
+ScTabView* pTabView = pSh->GetViewData().GetView();
+if (!pTabView)
+return {};
+ScDrawView* pView = pTabView->GetScDrawView();
+if (!pView)
+return {};
+SdrPage* pPage = pView->GetSdrPageView()->GetPage();
+if (!pPage)
+return {};
+auto const& pTheme = pPage->getSdrPageProperties().GetTheme();
+if (!pTheme)
+return {};
+return pTheme->GetColors();
+}
+
 void ScDocShell::DoEnterHandler()
 {
 ScTabViewShell* pViewSh = ScTabViewShell::GetActiveViewShell();
diff --git a/sc/source/ui/inc/docsh.hxx b/sc/source/ui/inc/docsh.hxx
index d92c93e73ff3..5c8484a2fd32 100644
--- a/sc/source/ui/inc/docsh.hxx
+++ b/sc/source/ui/inc/docsh.hxx
@@ -181,6 +181,7 @@ public:
bool bTemplate = false ) const override;
 
 virtual std::set GetDocColors() override;
+virtual std::vector GetThemeColors() override;
 
 virtual boolInitNew( const css::uno::Reference< css::embed::XStorage 
>& ) override;
 virtual boolLoad( SfxMedium& rMedium ) override;
diff --git a/sc/ucalc_setup.mk b/sc/ucalc_setup.mk
index 9a2323572611..63351a87aa28 100644
--- a/sc/ucalc_setup.mk
+++ b/sc/ucalc_setup.mk
@@ -47,6 +47,7 @@ $(eval $(call gb_CppunitTest_use_libraries,sc_ucalc$(1), \
 dbtools \
 drawinglayer \
 drawinglayercore \
+docmodel \
 editeng \
 for \
 forui \


[Libreoffice-commits] core.git: vcl/workben

2023-05-09 Thread Caolán McNamara (via logerrit)
 vcl/workben/fodt2pdffuzzer.options |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 4232b46b4a0f7b4ae0c6967778af437f59b90e14
Author: Caolán McNamara 
AuthorDate: Tue May 9 15:19:50 2023 +0100
Commit: Caolán McNamara 
CommitDate: Tue May 9 16:20:53 2023 +0200

increase max_len for fodt2pdffuzzer

Change-Id: Ib8c3c0e35c6a7cc8b3b40fce4f89c038e819f088
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151587
Tested-by: Caolán McNamara 
Reviewed-by: Caolán McNamara 

diff --git a/vcl/workben/fodt2pdffuzzer.options 
b/vcl/workben/fodt2pdffuzzer.options
index 01b2eedfcd5e..caa2af4fbf45 100644
--- a/vcl/workben/fodt2pdffuzzer.options
+++ b/vcl/workben/fodt2pdffuzzer.options
@@ -1,3 +1,3 @@
 [libfuzzer]
-max_len = 3072
+max_len = 4096
 dict = odf.dict


[Libreoffice-commits] core.git: Branch 'libreoffice-7-5' - basic/qa basic/source

2023-05-09 Thread Andreas Heinisch (via logerrit)
 basic/qa/vba_tests/constants.vb |9 +
 basic/source/comp/parser.cxx|9 +
 2 files changed, 18 insertions(+)

New commits:
commit b15035870c0be5fc855904ba3750b38d68abb1ae
Author: Andreas Heinisch 
AuthorDate: Tue May 9 11:43:45 2023 +0200
Commit: Xisco Fauli 
CommitDate: Tue May 9 16:15:07 2023 +0200

tdf#153543 - Add vba shell constants

Change-Id: Ifa73050f6892ce8ce95d16dedc166e68d1809491
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151567
Tested-by: Jenkins
Reviewed-by: Andreas Heinisch 
(cherry picked from commit fa0a1f6462c050bdd14a4f75589eb324c6575a91)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151522
Reviewed-by: Xisco Fauli 

diff --git a/basic/qa/vba_tests/constants.vb b/basic/qa/vba_tests/constants.vb
index be7add515e83..c31444889fae 100644
--- a/basic/qa/vba_tests/constants.vb
+++ b/basic/qa/vba_tests/constants.vb
@@ -25,6 +25,15 @@ Sub verify_testConstants()
 TestUtil.AssertEqual(vbNewLine, vbLf, "vbNewline")
 End If
 
+' tdf#153543 - check for vba shell constants
+' See 
https://learn.microsoft.com/en-us/office/vba/language/reference/user-interface-help/shell-constants
+TestUtil.AssertEqual(vbHide, 0, "vbHide")
+TestUtil.AssertEqual(vbNormalFocus,  1, "vbNormalFocus")
+TestUtil.AssertEqual(vbMinimizedFocus,   2, "vbMinimizedFocus")
+TestUtil.AssertEqual(vbMaximizedFocus,   3, "vbMaximizedFocus")
+TestUtil.AssertEqual(vbNormalNoFocus,4, "vbNormalNoFocus")
+TestUtil.AssertEqual(vbMinimizedNoFocus, 6, "vbMinimizedNoFocus")
+
 ' tdf#131563 - check for vba color constants
 ' See 
https://docs.microsoft.com/en-us/office/vba/language/reference/user-interface-help/color-constants
 TestUtil.AssertEqual(vbBlack,   RGB(0, 0, 0),   "vbBlack")
diff --git a/basic/source/comp/parser.cxx b/basic/source/comp/parser.cxx
index 70bc27dcd16b..97bd27675fa8 100644
--- a/basic/source/comp/parser.cxx
+++ b/basic/source/comp/parser.cxx
@@ -849,6 +849,15 @@ static void addNumericConst(SbiSymPool& rPool, const 
OUString& pSym, double nVal
 
 void SbiParser::AddConstants()
 {
+// tdf#153543 - shell constants
+// See 
https://learn.microsoft.com/en-us/office/vba/language/reference/user-interface-help/shell-constants
+addNumericConst(aPublics, "vbHide", 0);
+addNumericConst(aPublics, "vbNormalFocus", 1);
+addNumericConst(aPublics, "vbMinimizedFocus", 2);
+addNumericConst(aPublics, "vbMaximizedFocus", 3);
+addNumericConst(aPublics, "vbNormalNoFocus", 4);
+addNumericConst(aPublics, "vbMinimizedNoFocus", 6);
+
 // tdf#131563 - add vba color constants
 // See 
https://docs.microsoft.com/en-us/office/vba/language/reference/user-interface-help/color-constants
 addNumericConst(aPublics, "vbBlack", 0x0);


[Libreoffice-commits] core.git: sc/UITest_autofilter2.mk sc/UITest_autofilter.mk

2023-05-09 Thread Xisco Fauli (via logerrit)
 sc/UITest_autofilter.mk  |2 ++
 sc/UITest_autofilter2.mk |2 ++
 2 files changed, 4 insertions(+)

New commits:
commit b189172dd639f79bdf6564c2b9fab532fdcfe8cd
Author: Xisco Fauli 
AuthorDate: Tue May 9 13:42:51 2023 +0200
Commit: Xisco Fauli 
CommitDate: Tue May 9 15:57:59 2023 +0200

tdf#154451 uitest: use more oneprocess mode

Execution time changes:

- UITest_autofilter: 4m39,519s -> 3m10,079s
- UITest_autofilter2: 2m11,254s -> 1m32,543s

Change-Id: Ibeb22b46a4ccaa1d560a4d82288ba9f2351b8f54
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151576
Tested-by: Jenkins
Reviewed-by: Xisco Fauli 

diff --git a/sc/UITest_autofilter.mk b/sc/UITest_autofilter.mk
index 539ca4556d5f..361216e19ab1 100644
--- a/sc/UITest_autofilter.mk
+++ b/sc/UITest_autofilter.mk
@@ -17,4 +17,6 @@ $(eval $(call gb_UITest_set_defs,autofilter, \
 TDOC="$(SRCDIR)/sc/qa/uitest/data/autofilter" \
 ))
 
+$(eval $(call gb_UITest_use_oneprocess,autofilter))
+
 # vim: set noet sw=4 ts=4:
diff --git a/sc/UITest_autofilter2.mk b/sc/UITest_autofilter2.mk
index 387033912e1e..11e962aa6d8b 100644
--- a/sc/UITest_autofilter2.mk
+++ b/sc/UITest_autofilter2.mk
@@ -17,4 +17,6 @@ $(eval $(call gb_UITest_set_defs,autofilter2, \
 TDOC="$(SRCDIR)/sc/qa/uitest/data/autofilter" \
 ))
 
+$(eval $(call gb_UITest_use_oneprocess,autofilter2))
+
 # vim: set noet sw=4 ts=4:


[Libreoffice-commits] core.git: sc/qa

2023-05-09 Thread Xisco Fauli (via logerrit)
 sc/qa/unit/opencl-test-2.cxx |7 ++-
 1 file changed, 2 insertions(+), 5 deletions(-)

New commits:
commit 7b6dbbcb5a42bb51b3e84b54f9950f3f43e97c97
Author: Xisco Fauli 
AuthorDate: Tue May 9 12:59:29 2023 +0200
Commit: Xisco Fauli 
CommitDate: Tue May 9 15:32:53 2023 +0200

CppunitTest_sc_opencl-2: re-enable test

Disable in 836abd393d126cfbba6b0bd1fdda5b03095516c9
"GPU Calc: temporarily disable Kombin unit test"

Change-Id: I311caae5450874c61a6bf5e40940513f614da965
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151572
Tested-by: Xisco Fauli 
Reviewed-by: Xisco Fauli 

diff --git a/sc/qa/unit/opencl-test-2.cxx b/sc/qa/unit/opencl-test-2.cxx
index e3f79293e1eb..a99808da19c4 100644
--- a/sc/qa/unit/opencl-test-2.cxx
+++ b/sc/qa/unit/opencl-test-2.cxx
@@ -68,7 +68,7 @@ public:
 void testStatisticalFormulaBinomDist();
 void testStatisticalFormulaVarP();
 void testMathFormulaCeil();
-// void testMathFormulaKombin();
+void testMathFormulaKombin();
 void testStatisticalFormulaDevSq();
 void testStatisticalFormulaStDev();
 void testStatisticalFormulaSlope();
@@ -182,8 +182,7 @@ public:
 CPPUNIT_TEST(testStatisticalFormulaBinomDist);
 CPPUNIT_TEST(testStatisticalFormulaVarP);
 CPPUNIT_TEST(testMathFormulaCeil);
-// This test fails MacOS 10.8. Disabled temporarily
-// CPPUNIT_TEST(testMathFormulaKombin);
+CPPUNIT_TEST(testMathFormulaKombin);
 CPPUNIT_TEST(testStatisticalFormulaDevSq);
 CPPUNIT_TEST(testStatisticalFormulaStDev);
 CPPUNIT_TEST(testStatisticalFormulaSlope);
@@ -1177,7 +1176,6 @@ void ScOpenCLTest2::testMathFormulaProduct()
 }
 }
 
-#if 0 //Disabled temporarily
 void ScOpenCLTest2::testMathFormulaKombin()
 {
 initTestEnv(u"ods/opencl/math/Kombin.ods");
@@ -1193,7 +1191,6 @@ void ScOpenCLTest2::testMathFormulaKombin()
 CPPUNIT_ASSERT_DOUBLES_EQUAL(fExcel, fLibre, fabs(0.0001*fExcel));
 }
 }
-#endif
 
 void ScOpenCLTest2:: testArrayFormulaSumX2MY2()
 {


[Libreoffice-commits] core.git: sw/source

2023-05-09 Thread Justin Luth (via logerrit)
 sw/source/core/edit/edtab.cxx |   20 +---
 1 file changed, 9 insertions(+), 11 deletions(-)

New commits:
commit 10c2e1f4a2158f629892356f569de01e7fea20f7
Author: Justin Luth 
AuthorDate: Mon May 8 11:38:30 2023 -0400
Commit: Justin Luth 
CommitDate: Tue May 9 15:24:07 2023 +0200

NFC sw edtab.cxx: remove do ... while (false) without break

Since original import in 2000, the clause was while(false)
(although at that point it still had a commented out condition).
The next change to this function remove the commented out stuff,
leaving only a pointless do while bracket
that has no early exit uses.

Change-Id: I4e0c083a52677c3116e6d008a860b1473418d1f5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151549
Tested-by: Jenkins
Reviewed-by: Justin Luth 

diff --git a/sw/source/core/edit/edtab.cxx b/sw/source/core/edit/edtab.cxx
index 303149770208..b011a182b3ca 100644
--- a/sw/source/core/edit/edtab.cxx
+++ b/sw/source/core/edit/edtab.cxx
@@ -304,17 +304,15 @@ bool SwEditShell::GetTableBoxFormulaAttrs( SfxItemSet& 
rSet ) const
 ::GetTableSelCrs( *this, aBoxes );
 else
 {
-do {
-SwFrame *pFrame = GetCurrFrame();
-do {
-pFrame = pFrame->GetUpper();
-} while ( pFrame && !pFrame->IsCellFrame() );
-if ( pFrame )
-{
-SwTableBox *pBox = 
const_cast(static_cast(pFrame)->GetTabBox());
-aBoxes.insert( pBox );
-}
-} while( false );
+SwFrame* pFrame = GetCurrFrame()->GetUpper();
+while (pFrame && !pFrame->IsCellFrame())
+pFrame = pFrame->GetUpper();
+
+if (pFrame)
+{
+auto pBox = 
const_cast(static_cast(pFrame)->GetTabBox());
+aBoxes.insert(pBox);
+}
 }
 
 for (size_t n = 0; n < aBoxes.size(); ++n)


[Libreoffice-commits] core.git: drawinglayer/source

2023-05-09 Thread Armin Le Grand (allotropia) (via logerrit)
 drawinglayer/source/texture/texture.cxx |   20 ++--
 1 file changed, 6 insertions(+), 14 deletions(-)

New commits:
commit 81e77bcc7c454d79b302df7ad545e7da16b64ae0
Author: Armin Le Grand (allotropia) 
AuthorDate: Tue May 9 12:29:30 2023 +0200
Commit: Armin Le Grand 
CommitDate: Tue May 9 15:03:11 2023 +0200

MCGR: Correct interpolate TextureMap due to possible zero value

Change-Id: I5b2fe354077bea659f522e5b5c839be1f4cae1c4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151568
Tested-by: Jenkins
Reviewed-by: Armin Le Grand 

diff --git a/drawinglayer/source/texture/texture.cxx 
b/drawinglayer/source/texture/texture.cxx
index aeeb5b61bb05..eb9df6469225 100644
--- a/drawinglayer/source/texture/texture.cxx
+++ b/drawinglayer/source/texture/texture.cxx
@@ -244,11 +244,7 @@ namespace drawinglayer::texture
 // set and add at target
 aCallback(
 maGradientInfo.getTextureTransform() * aNew,
-interpolate(
-aCStart, aCEnd,
-nSteps == 1
-? std::numeric_limits::infinity()
-: double(innerLoop) / double(nSteps - 1)));
+1 == nSteps ? aCStart : 
basegfx::BColor(interpolate(aCStart, aCEnd, double(innerLoop) / double(nSteps - 
1;
 }
 }
 
@@ -372,7 +368,7 @@ namespace drawinglayer::texture
 // set and add at target
 aCallback(
 maGradientInfo.getTextureTransform() * aNew,
-interpolate(aCStart, aCEnd, double(innerLoop) / 
double(nSteps - 1)));
+1 == nSteps ? aCStart : 
basegfx::BColor(interpolate(aCStart, aCEnd, double(innerLoop) / double(nSteps - 
1;
 }
 }
 
@@ -467,11 +463,7 @@ namespace drawinglayer::texture
 // set and add at target
 aCallback(
 maGradientInfo.getTextureTransform() * 
basegfx::utils::createScaleB2DHomMatrix(fSize, fSize),
-interpolate(
-aCStart, aCEnd,
-nSteps == 1
-? std::numeric_limits::infinity()
-: double(innerLoop) / double(nSteps - 1)));
+1 == nSteps ? aCStart : 
basegfx::BColor(interpolate(aCStart, aCEnd, double(innerLoop) / double(nSteps - 
1;
 }
 }
 
@@ -572,7 +564,7 @@ namespace drawinglayer::texture
 * basegfx::utils::createScaleB2DHomMatrix(
 1.0 - (bMTO ? fSize / fAR : fSize),
 1.0 - (bMTO ? fSize : fSize * fAR)),
-interpolate(aCStart, aCEnd, double(innerLoop) / 
double(nSteps - 1)));
+1 == nSteps ? aCStart : 
basegfx::BColor(interpolate(aCStart, aCEnd, double(innerLoop) / double(nSteps - 
1;
 }
 }
 
@@ -666,7 +658,7 @@ namespace drawinglayer::texture
 // set and add at target
 aCallback(
 maGradientInfo.getTextureTransform() * 
basegfx::utils::createScaleB2DHomMatrix(fSize, fSize),
-interpolate(aCStart, aCEnd, double(innerLoop) / 
double(nSteps - 1)));
+1 == nSteps ? aCStart : 
basegfx::BColor(interpolate(aCStart, aCEnd, double(innerLoop) / double(nSteps - 
1;
 }
 }
 
@@ -767,7 +759,7 @@ namespace drawinglayer::texture
 * basegfx::utils::createScaleB2DHomMatrix(
 1.0 - (bMTO ? fSize / fAR : fSize),
 1.0 - (bMTO ? fSize : fSize * fAR)),
-interpolate(aCStart, aCEnd, double(innerLoop) / 
double(nSteps - 1)));
+1 == nSteps ? aCStart : 
basegfx::BColor(interpolate(aCStart, aCEnd, double(innerLoop) / double(nSteps - 
1;
 }
 }
 


[Libreoffice-commits] core.git: include/svx solenv/clang-format svx/inc svx/source

2023-05-09 Thread Noel Grandin (via logerrit)
 solenv/clang-format/excludelist   |2 +-
 svx/source/items/autoformathelper.cxx |2 +-
 svx/source/items/legacyitem.cxx   |2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 9585ce0e6a1075597943268ef72ccd859b6c8065
Author: Noel Grandin 
AuthorDate: Tue May 9 12:46:33 2023 +0200
Commit: Noel Grandin 
CommitDate: Tue May 9 15:01:54 2023 +0200

move include/svx/legacyitem.hxx inside svx

it is only used from there

Change-Id: I12065d4e2db142d50c403310ea4a7bb23412884e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151571
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/solenv/clang-format/excludelist b/solenv/clang-format/excludelist
index 35d750b22cc9..b0437ef47617 100644
--- a/solenv/clang-format/excludelist
+++ b/solenv/clang-format/excludelist
@@ -5842,7 +5842,6 @@ include/svx/imapdlg.hxx
 include/svx/itextprovider.hxx
 include/svx/langbox.hxx
 include/svx/lathe3d.hxx
-include/svx/legacyitem.hxx
 include/svx/linectrl.hxx
 include/svx/msdffdef.hxx
 include/svx/nbdtmg.hxx
@@ -11232,6 +11231,7 @@ svx/inc/extrud3d.hxx
 svx/inc/galbrws2.hxx
 svx/inc/galobj.hxx
 svx/inc/helpids.h
+svx/inc/legacyitem.hxx
 svx/inc/palettes.hxx
 svx/inc/sdgcoitm.hxx
 svx/inc/sdginitm.hxx
diff --git a/include/svx/legacyitem.hxx b/svx/inc/legacyitem.hxx
similarity index 100%
rename from include/svx/legacyitem.hxx
rename to svx/inc/legacyitem.hxx
diff --git a/svx/source/items/autoformathelper.cxx 
b/svx/source/items/autoformathelper.cxx
index 0ae522fbd7ac..cb09ea735e81 100644
--- a/svx/source/items/autoformathelper.cxx
+++ b/svx/source/items/autoformathelper.cxx
@@ -21,7 +21,7 @@
 #include 
 #include 
 #include 
-#include 
+#include 
 #include 
 #include 
 #include 
diff --git a/svx/source/items/legacyitem.cxx b/svx/source/items/legacyitem.cxx
index 005f97d2d95b..6e7e99d8cb5c 100644
--- a/svx/source/items/legacyitem.cxx
+++ b/svx/source/items/legacyitem.cxx
@@ -17,7 +17,7 @@
  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
  */
 
-#include 
+#include 
 #include 
 #include 
 #include 


[Libreoffice-commits] core.git: Branch 'feature/cib_contract138e' - 29 commits - configure.ac connectivity/source download.lst editeng/source embeddedobj/source extensions/source external/curl externa

2023-05-09 Thread Caolán McNamara (via logerrit)
 configure.ac|6 
 connectivity/source/drivers/hsqldb/HDriver.cxx  |   31 
 connectivity/source/manager/mdrivermanager.cxx  |7 
 download.lst|  870 
 editeng/source/accessibility/AccessibleEditableTextPara.cxx |3 
 embeddedobj/source/commonembedding/embedobj.cxx |   60 
 embeddedobj/source/commonembedding/specialobject.cxx|9 
 embeddedobj/source/inc/commonembobj.hxx |3 
 embeddedobj/source/inc/specialobject.hxx|6 
 extensions/source/logging/csvformatter.cxx  |   18 
 external/curl/curl-msvc-disable-protocols.patch.1   |2 
 external/curl/curl-nss.patch.1  |6 
 external/curl/zlib.patch.0  |   12 
 external/expat/expat-winapi.patch   |   13 
 external/hsqldb/UnpackedTarball_hsqldb.mk   |1 
 external/hsqldb/patches/disable-dump-script.patch   |   14 
 external/nss/UnpackedTarball_nss.mk |2 
 external/nss/asan.patch.1   |2 
 external/nss/clang-cl.patch.0   |   12 
 external/nss/macos-dlopen.patch.0   |2 
 external/nss/nss-android.patch.1|6 
 external/nss/nss-ios.patch  |   36 
 external/nss/nss-restore-manual-pre-dependencies.patch.1|2 
 external/nss/nss-win32-make.patch.1 |4 
 external/nss/nss.aix.patch  |   10 
 external/nss/nss.bzmozilla1238154.patch |2 
 external/nss/nss.cygwin64.in32bit.patch |2 
 external/nss/nss.nowerror.patch |2 
 external/nss/nss.utf8bom.patch.1|4 
 external/nss/nss.vs2015.patch   |2 
 external/nss/nss.vs2015.pdb.patch   |2 
 external/nss/nss.windows.patch  |6 
 external/nss/nss_macosx.patch   |   12 
 external/nss/ubsan.patch.0  |2 
 external/postgresql/arm64.patch.1   |2 
 external/postgresql/postgresql.exit.patch.0 |4 
 external/skia/UnpackedTarball_skia.mk   |1 
 external/skia/missing-include.patch.0   |   10 
 formula/source/core/api/token.cxx   |   13 
 include/svx/svdoole2.hxx|   17 
 include/svx/unoshape.hxx|2 
 sc/source/core/inc/interpre.hxx |   12 
 sc/source/core/tool/interpr1.cxx|4 
 sc/source/core/tool/interpr3.cxx|4 
 sc/source/core/tool/interpr4.cxx|   10 
 sc/source/ui/docshell/documentlinkmgr.cxx   |9 
 sc/source/ui/drawfunc/drtxtob.cxx   |3 
 sc/source/ui/view/editsh.cxx|3 
 sd/qa/unit/tiledrendering/tiledrendering.cxx|8 
 sfx2/source/doc/iframe.cxx  |   69 
 slideshow/source/engine/eventqueue.cxx  |4 
 solenv/gbuild/partial_build.mk  |2 
 starmath/source/unomodel.cxx|   27 
 svx/source/svdraw/svdoole2.cxx  |  104 +
 svx/source/unodraw/shapeimpl.hxx|5 
 svx/source/unodraw/unoshap4.cxx |   23 
 sw/inc/ndole.hxx|4 
 sw/qa/extras/htmlexport/htmlexport.cxx  |   16 
 sw/source/core/ole/ndole.cxx|   89 +
 vcl/source/window/layout.cxx|   28 
 xmloff/source/draw/ximpshap.cxx |   29 
 xmloff/source/draw/ximpshap.hxx |2 
 62 files changed, 1181 insertions(+), 494 deletions(-)

New commits:
commit 22e1bf2c53be4272eeef88efceb5e57b09d564bf
Author: Caolán McNamara 
AuthorDate: Thu Apr 20 20:58:21 2023 +0100
Commit: Michael Stahl 
CommitDate: Tue May 9 14:12:02 2023 +0200

assume IFrame script/macro support isn't needed

seems undocumented at least

Change-Id: I316e4f4f25ddb7cf6b7bac4d856a721b987207a3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151020
Tested-by: Jenkins
Reviewed-by: Xisco Fauli 
(cherry picked from commit a10a5994bddf7646196ff45f6af598420d8663ad)

diff --git a/sfx2/source/doc/iframe.cxx b/sfx2/source/doc/iframe.cxx
index 16750d8da0b3..52962c4be75d 100

[Libreoffice-commits] core.git: Branch 'distro/collabora/co-23.05' - sw/source

2023-05-09 Thread Jim Raykowski (via logerrit)
 sw/source/filter/html/htmlfldw.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 2dbf19425b2494676daf0dc8674b72a3b2defe8d
Author: Jim Raykowski 
AuthorDate: Tue May 2 11:05:47 2023 -0800
Commit: Paris Oplopoios 
CommitDate: Tue May 9 14:51:17 2023 +0200

tdf#154551 check pointer before use

Change-Id: Ied215ea393760f246128610c5b7b4d50ab211f97
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151300
Tested-by: Jenkins
Reviewed-by: Paris Oplopoios 
Reviewed-by: Jim Raykowski 
(cherry picked from commit 20bf9f2b31343e17c14a3091d59b40a71eeb3e26)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151520
Tested-by: Jenkins CollaboraOffice 

diff --git a/sw/source/filter/html/htmlfldw.cxx 
b/sw/source/filter/html/htmlfldw.cxx
index 64dd86a347dc..d6d3e4ba1137 100644
--- a/sw/source/filter/html/htmlfldw.cxx
+++ b/sw/source/filter/html/htmlfldw.cxx
@@ -544,7 +544,7 @@ Writer& OutHTML_SwFormatField( Writer& rWrt, const 
SfxPoolItem& rHt )
 {
 const SwTextField *pTextField = rField.GetTextField();
 OSL_ENSURE( pTextField, "Where is the txt fld?" );
-if( pTextField && rWrt.m_pDoc->GetDocShell() )
+if (pTextField && rWrt.m_pDoc->GetDocShell() && 
rWrt.m_pDoc->GetDocShell()->GetView())
 {
 // ReqIF-XHTML doesn't allow specifying a background color.
 const SwViewOption* pViewOptions = 
rWrt.m_pDoc->GetDocShell()->GetView()->GetWrtShell().GetViewOptions();


[Libreoffice-commits] core.git: cppuhelper/inc cppuhelper/Library_cppuhelper.mk cppuhelper/source

2023-05-09 Thread Noel Grandin (via logerrit)
 cppuhelper/Library_cppuhelper.mk|7 
 cppuhelper/inc/compbase2.hxx|  128 +
 cppuhelper/inc/interfacecontainer4.hxx  |  426 
 cppuhelper/inc/unoimplbase.hxx  |   37 ++
 cppuhelper/source/compbase.cxx  |  231 +
 cppuhelper/source/component_context.cxx |   49 +--
 cppuhelper/source/unoimplbase.cxx   |   27 ++
 7 files changed, 882 insertions(+), 23 deletions(-)

New commits:
commit 00f8f75f36dfb4394d43b10510ea08049752a1a7
Author: Noel Grandin 
AuthorDate: Sat May 6 12:45:43 2023 +0200
Commit: Noel Grandin 
CommitDate: Tue May 9 14:50:31 2023 +0200

copy some comphelper code down into cppuhelper

Since I want to use them in the cppuhelper too, but comphelper is
"above" cppuhelper in the dependency tree.

And sharing the code between cppuhelper and the rest of LO
across the URE boundary appears to be nigh impossible.

Change-Id: I2ebf37746928dc820df43347dc1a2c158f00ec50
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151445
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/cppuhelper/Library_cppuhelper.mk b/cppuhelper/Library_cppuhelper.mk
index dbbfa55d542e..3a1b4b776f66 100644
--- a/cppuhelper/Library_cppuhelper.mk
+++ b/cppuhelper/Library_cppuhelper.mk
@@ -45,10 +45,16 @@ $(eval $(call gb_Library_add_cxxflags,cppuhelper,\
 ))
 endif
 
+$(eval $(call gb_Library_set_include,cppuhelper,\
+-I$(SRCDIR)/cppuhelper/inc \
+$$(INCLUDE) \
+))
+
 $(eval $(call gb_Library_add_exception_objects,cppuhelper,\
cppuhelper/source/access_control \
cppuhelper/source/bootstrap \
cppuhelper/source/compat \
+   cppuhelper/source/compbase \
cppuhelper/source/component_context \
cppuhelper/source/component \
cppuhelper/source/defaultbootstrap \
@@ -68,6 +74,7 @@ $(eval $(call gb_Library_add_exception_objects,cppuhelper,\
cppuhelper/source/tdmgr \
cppuhelper/source/typemanager \
cppuhelper/source/typeprovider \
+   cppuhelper/source/unoimplbase \
cppuhelper/source/unourl \
cppuhelper/source/weak \
 ))
diff --git a/cppuhelper/inc/compbase2.hxx b/cppuhelper/inc/compbase2.hxx
new file mode 100644
index ..6e1486d9fabe
--- /dev/null
+++ b/cppuhelper/inc/compbase2.hxx
@@ -0,0 +1,128 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; 
fill-column: 100 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#pragma once
+
+#include 
+
+#include 
+#include "interfacecontainer4.hxx"
+#include "unoimplbase.hxx"
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+/**
+This is a straight copy of the include/comphelper/compbase.hxx file, copied 
here
+because it is nigh impossible to move shared code down into the URE layer.
+*/
+
+namespace cppuhelper
+{
+/**
+Serves two purposes
+(1) extracts code that doesn't need to be templated
+(2) helps to handle the custom where we have conflicting interfaces
+e.g. multiple UNO interfaces that extend css::lang::XComponent
+*/
+class CPPUHELPER_DLLPUBLIC WeakComponentImplHelperBase2 : public virtual 
UnoImplBase,
+  public 
cppu::OWeakObject,
+  public 
css::lang::XComponent
+{
+public:
+virtual ~WeakComponentImplHelperBase2() override;
+
+// css::lang::XComponent
+virtual void SAL_CALL dispose() override;
+virtual void SAL_CALL
+addEventListener(css::uno::Reference const& 
rxListener) override;
+virtual void SAL_CALL
+removeEventListener(css::uno::Reference const& 
rxListener) override;
+
+virtual css::uno::Any SAL_CALL queryInterface(css::uno::Type const& rType) 
override;
+
+/**
+Called by dispose for subclasses to do dispose() work.
+The mutex is held when called, and subclasses can unlock() the guard 
if necessary.
+ */
+virtual void disposing(std::unique_lock&);
+
+protected:
+void throwIfDisposed(std::unique_lock&)
+{
+if (m_bDisposed)
+throw css::lang::DisposedException(OUString(), 
static_cast(this));
+}
+OInterfaceContainerHelper4 maEventListeners;
+};
+
+/** WeakComponentImplHelper
+*/
+CPPUHELPER_DLLPUBLIC css::uno::Any
+WeakComponentImplHelper_query(css::uno::Type const& rType, cppu::class_data* 
cd,
+  WeakComponentImplHelperBase2* pBase);
+
+template 
+class SAL_DLLPUBLIC_TEMPLATE WeakComponentImplHelper2 : public 
WeakComponentImplHelperBase2,
+public 
css::lang::XTypeProvider,
+public If

[Libreoffice-commits] core.git: basic/qa basic/source

2023-05-09 Thread Andreas Heinisch (via logerrit)
 basic/qa/vba_tests/constants.vb |9 +
 basic/source/comp/parser.cxx|9 +
 2 files changed, 18 insertions(+)

New commits:
commit fa0a1f6462c050bdd14a4f75589eb324c6575a91
Author: Andreas Heinisch 
AuthorDate: Tue May 9 11:43:45 2023 +0200
Commit: Andreas Heinisch 
CommitDate: Tue May 9 14:12:54 2023 +0200

tdf#153543 - Add vba shell constants

Change-Id: Ifa73050f6892ce8ce95d16dedc166e68d1809491
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151567
Tested-by: Jenkins
Reviewed-by: Andreas Heinisch 

diff --git a/basic/qa/vba_tests/constants.vb b/basic/qa/vba_tests/constants.vb
index be7add515e83..c31444889fae 100644
--- a/basic/qa/vba_tests/constants.vb
+++ b/basic/qa/vba_tests/constants.vb
@@ -25,6 +25,15 @@ Sub verify_testConstants()
 TestUtil.AssertEqual(vbNewLine, vbLf, "vbNewline")
 End If
 
+' tdf#153543 - check for vba shell constants
+' See 
https://learn.microsoft.com/en-us/office/vba/language/reference/user-interface-help/shell-constants
+TestUtil.AssertEqual(vbHide, 0, "vbHide")
+TestUtil.AssertEqual(vbNormalFocus,  1, "vbNormalFocus")
+TestUtil.AssertEqual(vbMinimizedFocus,   2, "vbMinimizedFocus")
+TestUtil.AssertEqual(vbMaximizedFocus,   3, "vbMaximizedFocus")
+TestUtil.AssertEqual(vbNormalNoFocus,4, "vbNormalNoFocus")
+TestUtil.AssertEqual(vbMinimizedNoFocus, 6, "vbMinimizedNoFocus")
+
 ' tdf#131563 - check for vba color constants
 ' See 
https://docs.microsoft.com/en-us/office/vba/language/reference/user-interface-help/color-constants
 TestUtil.AssertEqual(vbBlack,   RGB(0, 0, 0),   "vbBlack")
diff --git a/basic/source/comp/parser.cxx b/basic/source/comp/parser.cxx
index 70bc27dcd16b..97bd27675fa8 100644
--- a/basic/source/comp/parser.cxx
+++ b/basic/source/comp/parser.cxx
@@ -849,6 +849,15 @@ static void addNumericConst(SbiSymPool& rPool, const 
OUString& pSym, double nVal
 
 void SbiParser::AddConstants()
 {
+// tdf#153543 - shell constants
+// See 
https://learn.microsoft.com/en-us/office/vba/language/reference/user-interface-help/shell-constants
+addNumericConst(aPublics, "vbHide", 0);
+addNumericConst(aPublics, "vbNormalFocus", 1);
+addNumericConst(aPublics, "vbMinimizedFocus", 2);
+addNumericConst(aPublics, "vbMaximizedFocus", 3);
+addNumericConst(aPublics, "vbNormalNoFocus", 4);
+addNumericConst(aPublics, "vbMinimizedNoFocus", 6);
+
 // tdf#131563 - add vba color constants
 // See 
https://docs.microsoft.com/en-us/office/vba/language/reference/user-interface-help/color-constants
 addNumericConst(aPublics, "vbBlack", 0x0);


[Libreoffice-commits] core.git: helpcontent2

2023-05-09 Thread Eike Rathke (via logerrit)
 helpcontent2 |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit f75b4eca9f9f81abbace8fdf192293feed90565c
Author: Eike Rathke 
AuthorDate: Tue May 9 13:59:06 2023 +0200
Commit: Gerrit Code Review 
CommitDate: Tue May 9 13:59:06 2023 +0200

Update git submodules

* Update helpcontent2 from branch 'master'
  to 59861677cc4ca59020718033f675b54f49fc0b74
  - Size in characters, not bytes; tdf#153574 follow-up

Change-Id: I67a23a18801d152579f521692550d22493e0cb24
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/151577
Reviewed-by: Eike Rathke 
Tested-by: Jenkins

diff --git a/helpcontent2 b/helpcontent2
index d0d854aabafc..59861677cc4c 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit d0d854aabafc612def2622647c8e85b599fcc097
+Subproject commit 59861677cc4ca59020718033f675b54f49fc0b74


[Libreoffice-commits] help.git: source/text

2023-05-09 Thread Eike Rathke (via logerrit)
 source/text/scalc/05/0214.xhp |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 59861677cc4ca59020718033f675b54f49fc0b74
Author: Eike Rathke 
AuthorDate: Tue May 9 13:41:14 2023 +0200
Commit: Eike Rathke 
CommitDate: Tue May 9 13:59:05 2023 +0200

Size in characters, not bytes; tdf#153574 follow-up

Change-Id: I67a23a18801d152579f521692550d22493e0cb24
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/151577
Reviewed-by: Eike Rathke 
Tested-by: Jenkins

diff --git a/source/text/scalc/05/0214.xhp 
b/source/text/scalc/05/0214.xhp
index 914d9635b1..26be7ce4d1 100644
--- a/source/text/scalc/05/0214.xhp
+++ b/source/text/scalc/05/0214.xhp
@@ -193,7 +193,7 @@
 
 

-  Compiler: an identifier in the formula exceeds 
1024 bytes in size. Interpreter: a result of a string operation 
exceeds 256 MB in size.
+  Compiler: an identifier in the formula exceeds 
1024 characters (UTF-16 code points) in size. Interpreter: a 
result of a string operation would exceed 256M characters (UTF-16 code points, 
so 512MiB) in size.
 
  
  


[Libreoffice-commits] core.git: Branch 'distro/collabora/co-22.05' - editeng/source include/editeng sd/CppunitTest_sd_textfitting_tests.mk sd/Module_sd.mk sd/qa svx/source

2023-05-09 Thread Tomaž Vajngerl (via logerrit)
 editeng/source/editeng/editeng.cxx |   16 +++
 include/editeng/editeng.hxx|5 -
 sd/CppunitTest_sd_textfitting_tests.mk |   79 ++
 sd/Module_sd.mk|1 
 sd/qa/unit/TextFittingTest.cxx |  139 +
 sd/qa/unit/data/TextFitting.odp|binary
 svx/source/svdraw/svdotext.cxx |   20 
 7 files changed, 257 insertions(+), 3 deletions(-)

New commits:
commit d8e4c649f511b4af179dc379bb871df4b0314e8e
Author: Tomaž Vajngerl 
AuthorDate: Fri May 5 15:34:38 2023 +0900
Commit: Tomaž Vajngerl 
CommitDate: Tue May 9 13:57:57 2023 +0200

Change text auto-fit alg. to also increase the scaling

When in edit mode, the text can be deleted, so the text box size
can become smaller, but the auto-fit algorithm didn't take into
account.
In this case we already have the font and spacing scaling already
set to a specific value and we need to find a scaling value where
the margin is the smallest.

This change also adds a test for the issue.

Change-Id: I6c52f06dfbf5a1e582f7b31aceabf4736498ee90
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151412
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 
(cherry picked from commit 6c042848b688f64b3c56d65dd9dc5fe85412660a)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151446
Tested-by: Jenkins CollaboraOffice 

diff --git a/editeng/source/editeng/editeng.cxx 
b/editeng/source/editeng/editeng.cxx
index d364cc47a179..579766796b93 100644
--- a/editeng/source/editeng/editeng.cxx
+++ b/editeng/source/editeng/editeng.cxx
@@ -2285,11 +2285,27 @@ void EditEngine::getGlobalSpacingScale(double& rX, 
double& rY) const
 pImpEditEngine->getSpacingScale(rX, rY);
 }
 
+basegfx::B2DTuple EditEngine::getGlobalSpacingScale() const
+{
+double x = 0.0;
+double y = 0.0;
+pImpEditEngine->getSpacingScale(x, y);
+return {x, y};
+}
+
 void EditEngine::getGlobalFontScale(double& rX, double& rY) const
 {
 pImpEditEngine->getFontScale(rX, rY);
 }
 
+basegfx::B2DTuple EditEngine::getGlobalFontScale() const
+{
+double x = 0.0;
+double y = 0.0;
+pImpEditEngine->getFontScale(x, y);
+return {x, y};
+}
+
 void EditEngine::setRoundFontSizeToPt(bool bRound) const
 {
 pImpEditEngine->setRoundToNearestPt(bRound);
diff --git a/include/editeng/editeng.hxx b/include/editeng/editeng.hxx
index 57e57125da8c..55e08f694c1b 100644
--- a/include/editeng/editeng.hxx
+++ b/include/editeng/editeng.hxx
@@ -16,7 +16,7 @@
  *   except in compliance with the License. You may obtain a copy of
  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
  */
-// MyEDITENG, due to exported EditEng
+
 #ifndef INCLUDED_EDITENG_EDITENG_HXX
 #define INCLUDED_EDITENG_EDITENG_HXX
 
@@ -40,6 +40,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -419,7 +420,9 @@ public:
 void setGlobalScale(double fFontScaleX, double fFontScaleY, double 
fSpacingScaleX, double fSpacingScaleY);
 
 void getGlobalSpacingScale(double& rX, double& rY) const;
+basegfx::B2DTuple getGlobalSpacingScale() const;
 void getGlobalFontScale(double& rX, double& rY) const;
+basegfx::B2DTuple getGlobalFontScale() const;
 
 void setRoundFontSizeToPt(bool bRound) const;
 
diff --git a/sd/CppunitTest_sd_textfitting_tests.mk 
b/sd/CppunitTest_sd_textfitting_tests.mk
new file mode 100644
index ..20e302d86793
--- /dev/null
+++ b/sd/CppunitTest_sd_textfitting_tests.mk
@@ -0,0 +1,79 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#*
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+#*
+
+$(eval $(call gb_CppunitTest_CppunitTest,sd_textfitting_tests))
+
+$(eval $(call gb_CppunitTest_use_externals,sd_textfitting_tests,\
+boost_headers \
+libxml2 \
+))
+
+$(eval $(call 
gb_CppunitTest_use_common_precompiled_header,sd_textfitting_tests))
+
+$(eval $(call gb_CppunitTest_add_exception_objects,sd_textfitting_tests, \
+sd/qa/unit/TextFittingTest \
+))
+
+$(eval $(call gb_CppunitTest_use_libraries,sd_textfitting_tests, \
+basegfx \
+comphelper \
+cppu \
+cppuhelper \
+drawinglayer \
+editeng \
+for \
+forui \
+i18nlangtag \
+msfilter \
+oox \
+sal \
+salhelper \
+sax \
+sd \
+sfx \
+sot \
+subsequenttest \
+svl \
+svt \
+svx \
+svxcore \
+test \
+tl \
+tk \
+ucbhelper \
+unotest \
+utl \
+vcl \
+xo \
+))
+
+$(eval $(call gb_CppunitTest_set_include,sd_textfitting_tests,\
+-I$(SRCDIR)/sd/source/u

[Libreoffice-commits] core.git: compilerplugins/clang include/svx svx/inc svx/Library_svxcore.mk svx/source

2023-05-09 Thread Noel Grandin (via logerrit)
 compilerplugins/clang/mergeclasses.results  |1 
 include/svx/gallery1.hxx|4 
 include/svx/galtheme.hxx|6 
 svx/Library_svxcore.mk  |1 
 svx/inc/gallerybinaryengine.hxx |  109 ---
 svx/inc/galleryfilestorage.hxx  |   85 ++
 svx/inc/galleryfilestorageentry.hxx |5 
 svx/inc/galobj.hxx  |2 
 svx/source/gallery2/gallery1.cxx|2 
 svx/source/gallery2/gallerybinaryengine.cxx |  811 
 svx/source/gallery2/galleryfilestorage.cxx  |  789 +++
 svx/source/gallery2/galleryfilestorageentry.cxx |6 
 svx/source/gallery2/galtheme.cxx|4 
 svx/source/unogallery/unogalitem.cxx|2 
 14 files changed, 886 insertions(+), 941 deletions(-)

New commits:
commit c9b0a6010e96d22844cdab6c1e8e67fbf14ab142
Author: Noel Grandin 
AuthorDate: Mon May 8 12:56:36 2023 +0200
Commit: Noel Grandin 
CommitDate: Tue May 9 13:53:47 2023 +0200

merge GalleryFileStorage with GalleryBinaryEngine

Change-Id: Id948627873db9c646d1a81784dd16f6aa1c2063b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151553
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/compilerplugins/clang/mergeclasses.results 
b/compilerplugins/clang/mergeclasses.results
index a1e8c6be6e3d..9d4e9d583926 100644
--- a/compilerplugins/clang/mergeclasses.results
+++ b/compilerplugins/clang/mergeclasses.results
@@ -54,7 +54,6 @@ merge FmRecordCountListener_Base with FmRecordCountListener
 merge FmXDisposeListener with DisposeListenerGridBridge
 merge FmXFormShell_Base_Disambiguation with FmXFormShell
 merge GLWindow with GLX11Window
-merge GalleryFileStorage with GalleryBinaryEngine
 merge GroupTable with PPTWriterBase
 merge HostDetailsContainer with DavDetailsContainer
 merge IDocumentChartDataProviderAccess with 
sw::DocumentChartDataProviderManager
diff --git a/include/svx/gallery1.hxx b/include/svx/gallery1.hxx
index 49427be4d723..6f159e3b5139 100644
--- a/include/svx/gallery1.hxx
+++ b/include/svx/gallery1.hxx
@@ -30,7 +30,7 @@
 #include 
 
 class Gallery;
-class GalleryBinaryEngine;
+class GalleryFileStorage;
 class GalleryFileStorageEntry;
 class GalleryObjectCollection;
 class GalleryStorageLocations;
@@ -61,7 +61,7 @@ public:
 
 GalleryTheme* createGalleryTheme(Gallery* pGallery);
 
-std::unique_ptr 
createGalleryStorageEngine(GalleryObjectCollection& mrGalleryObjectCollection);
+std::unique_ptr 
createGalleryStorageEngine(GalleryObjectCollection& mrGalleryObjectCollection);
 
 const OUString& GetThemeName() const { return aName; }
 
diff --git a/include/svx/galtheme.hxx b/include/svx/galtheme.hxx
index e3ef7f7d991f..e14372066f51 100644
--- a/include/svx/galtheme.hxx
+++ b/include/svx/galtheme.hxx
@@ -31,7 +31,7 @@
 #include 
 #include 
 
-class GalleryBinaryEngine;
+class GalleryFileStorage;
 class GalleryThemeEntry;
 class SgaObject;
 class SotStorageStream;
@@ -57,7 +57,7 @@ class SVXCORE_DLLPUBLIC GalleryTheme final : public 
SfxBroadcaster
 
 private:
 
-std::unique_ptr mpGalleryStorageEngine;
+std::unique_ptr mpGalleryStorageEngine;
 GalleryObjectCollection maGalleryObjectCollection;
 Gallery*pParent;
 GalleryThemeEntry*  pThm;
@@ -67,7 +67,7 @@ private:
 boolbDragging;
 boolbAbortActualize;
 
-const std::unique_ptr& getGalleryStorageEngine() 
const { return mpGalleryStorageEngine; }
+const std::unique_ptr& getGalleryStorageEngine() const 
{ return mpGalleryStorageEngine; }
 
 SAL_DLLPRIVATE void ImplSetModified( bool bModified );
 SAL_DLLPRIVATE void ImplBroadcast(sal_uInt32 nUpdatePos);
diff --git a/svx/Library_svxcore.mk b/svx/Library_svxcore.mk
index 8dd99ef5484b..b0ce4a15165f 100644
--- a/svx/Library_svxcore.mk
+++ b/svx/Library_svxcore.mk
@@ -204,7 +204,6 @@ $(eval $(call gb_Library_add_exception_objects,svxcore,\
 svx/source/gallery2/galobj \
 svx/source/gallery2/galtheme \
 svx/source/gallery2/GalleryControl \
-svx/source/gallery2/gallerybinaryengine \
 svx/source/gallery2/galleryobjectcollection \
 svx/source/gallery2/galleryfilestorage \
 svx/source/gallery2/galleryfilestorageentry \
diff --git a/svx/inc/gallerybinaryengine.hxx b/svx/inc/gallerybinaryengine.hxx
deleted file mode 100644
index f1f221e34447..
--- a/svx/inc/gallerybinaryengine.hxx
+++ /dev/null
@@ -1,109 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file i

[Libreoffice-commits] core.git: helpcontent2

2023-05-09 Thread Olivier Hallot (via logerrit)
 helpcontent2 |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 38a658f3f064e1f0dc28cd7f69d800f78115c8df
Author: Olivier Hallot 
AuthorDate: Tue May 9 08:33:50 2023 -0300
Commit: Gerrit Code Review 
CommitDate: Tue May 9 13:33:50 2023 +0200

Update git submodules

* Update helpcontent2 from branch 'master'
  to d0d854aabafc612def2622647c8e85b599fcc097
  - tdf#149223 (part) Missing Help page for database connection properties 
page

Change-Id: If9a306f53abf031dfca58e5ce9a3f9bb0862dd70
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/151546
Tested-by: Jenkins
Reviewed-by: Olivier Hallot 

diff --git a/helpcontent2 b/helpcontent2
index a8a10f51d667..d0d854aabafc 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit a8a10f51d66795e9fd8f49839d01e26c9cc4e2a2
+Subproject commit d0d854aabafc612def2622647c8e85b599fcc097


[Libreoffice-commits] help.git: source/text

2023-05-09 Thread Olivier Hallot (via logerrit)
 source/text/sdatabase/dabapropgen.xhp |   60 +-
 1 file changed, 31 insertions(+), 29 deletions(-)

New commits:
commit d0d854aabafc612def2622647c8e85b599fcc097
Author: Olivier Hallot 
AuthorDate: Mon May 8 17:31:27 2023 -0300
Commit: Olivier Hallot 
CommitDate: Tue May 9 13:33:50 2023 +0200

tdf#149223 (part) Missing Help page for database connection properties page

Change-Id: If9a306f53abf031dfca58e5ce9a3f9bb0862dd70
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/151546
Tested-by: Jenkins
Reviewed-by: Olivier Hallot 

diff --git a/source/text/sdatabase/dabapropgen.xhp 
b/source/text/sdatabase/dabapropgen.xhp
index c1f1f398d8..12f479450d 100644
--- a/source/text/sdatabase/dabapropgen.xhp
+++ b/source/text/sdatabase/dabapropgen.xhp
@@ -19,55 +19,57 @@
 
 
 
-Advanced Properties
+Advanced Properties
 /text/sdatabase/dabapropgen.xhp
 
 
 
+
+
 
 Advanced 
Properties
-Specifies some 
options for a database.
+Specifies some options for a 
database.
 
 
-In a database 
window, choose Edit - Database - Properties, click Advanced 
Properties tab
+In a database window, choose 
Edit - Database - Properties, click Advanced 
Properties tab
 
-The 
availability of the following controls depends on the type of 
database:
-Path to dBASE 
filesUFI: found for dBase
-Enter the path to the directory that contains the dBASE 
files.
+The availability of the 
following controls depends on the type of database:
+Path to dBASE filesUFI: found 
for dBase
+Enter the path to 
the directory that contains the dBASE files.
 Ensure that the *.dbf file name extension of the 
dBASE files is lowercase.moved from 
shared\explorer\database\1103.xhp
 BrowseUFI: found for dBase
-Opens a dialog where you can select a file or a 
directory.which one? or depends?
-Test ConnectionUFI: found for 
dBaseand for Calc doc
-Tests the database connection with the current 
settings.
-Path to the text 
filesUFI: found for text file folder
-Enter the path to the folder of the text files.
-Path to the 
spreadsheet documentUFI: found for a Calc doc
-Enter the path to the spreadsheet document that you want to use as a 
database.
+Opens a dialog 
where you can select a file or a directory.which one? or 
depends?
+Test 
ConnectionUFI: found for dBaseand for Calc 
doc
+Tests the 
database connection with the current settings.
+Path to the text filesUFI: 
found for text file folder
+Enter the path to 
the folder of the text files.
+Path to the spreadsheet 
documentUFI: found for a Calc doc
+Enter the path to 
the spreadsheet document that you want to use as a database.
 Name of the ODBC data source on your system
-Enter the name of the ODBC data source.
+Enter the name of 
the ODBC data source.
 User name
-Enter the user name that is required to access the 
database.
-Password requiredUFI: found 
for Calc doc
-If checked, the user will be asked to enter the password that is 
required to access the database.
-Name of the databaseUFI: found 
for JDBC
-Enter the name of the database.
+Enter the user 
name that is required to access the database.
+Password 
requiredUFI: found for Calc doc
+If checked, the 
user will be asked to enter the password that is required to access the 
database.
+Name of the 
databaseUFI: found for JDBC
+Enter the name 
of the database.
 Name of the MySQL database
-Enter the name of the MySQL database that you want to use as a data 
source.
+Enter the name of 
the MySQL database that you want to use as a data source.
 Name of the Oracle database
-Enter the name of the Oracle database that you want to use as a data 
source.
+Enter the name of 
the Oracle database that you want to use as a data source.
 Microsoft Access database file
-Enter the name of the Microsoft Access database file that you want to 
use as a data source.
+Enter the name of 
the Microsoft Access database file that you want to use as a data 
source.
 Host name
-Enter the host name for the LDAP data source.
+Enter the host 
name for the LDAP data source.
 Data source URL
-Enter the location of the JDBC data source as a URL.
-
+Enter the 
location of the JDBC data source as a URL.
+
 JDBC driver class
-Enter the name of the JDBC driver class that connects to the data 
source.
-
+Enter the name of 
the JDBC driver class that connects to the data source.
+
 Test ClassUFI: found 
for JDBC
-Tests the database connection through the JDBC driver 
class.
+Tests the 
database connection through the JDBC driver class.
 Choose a database
-Select a database from the list or click Create to create 
a new database.
+Select a database 
from the list or click Create to create a new 
database.
 
 


[Libreoffice-commits] help.git: source/text

2023-05-09 Thread Olivier Hallot (via logerrit)
 source/text/shared/02/14020100.xhp |   31 ---
 1 file changed, 16 insertions(+), 15 deletions(-)

New commits:
commit a8a10f51d66795e9fd8f49839d01e26c9cc4e2a2
Author: Olivier Hallot 
AuthorDate: Mon May 8 16:37:13 2023 -0300
Commit: Olivier Hallot 
CommitDate: Tue May 9 13:32:52 2023 +0200

tdf#149222 Missing Help page for database Relationship dialog

Change-Id: Ieab2dd8906b2d368b054655e22c714076e0d96b2
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/151545
Tested-by: Jenkins
Reviewed-by: Olivier Hallot 

diff --git a/source/text/shared/02/14020100.xhp 
b/source/text/shared/02/14020100.xhp
index 3554730381..ce82eb45e1 100644
--- a/source/text/shared/02/14020100.xhp
+++ b/source/text/shared/02/14020100.xhp
@@ -20,34 +20,35 @@
 
 
   
-Add Tables
+Add Tables
 /text/shared/02/14020100.xhp
   
 
 
-tables in databases; adding to 
queries
+tables in 
databases; adding to queries
 
-
-
+
+
+
 Add Tables
-Specifies the 
tables to be inserted into the design window. In the Add 
Tables dialog, select the tables you need for your current task.
+Specifies the 
tables to be inserted into the design window. In the Add 
Tables dialog, select the tables you need for your current task.
  When creating a query or a new table presentation, select the 
corresponding table to which the query or table presentation should refer. When 
working with relational databases, select the tables between which you want to 
build relationships.
-The inserted 
tables appear in a separate window in the query design or relational windows, 
along with a list of the fields contained in the table. You can determine the 
size and order of this window.
+The inserted tables appear in a 
separate window in the query design or relational windows, along with a list of 
the fields contained in the table. You can determine the size and order of this 
window.
 
   
 
 Table
-
-Shows only tables.
-
-Shows only 
queries.
+
+Shows only tables.
+
+Shows only queries.
 Table name
-Lists the available 
tables. To insert a table, select one from the list and click 
Add. You can also double-click the table name, and a window will 
be displayed containing the table fields at the top of the query design or the 
relational window.
-
+Lists the available 
tables. To insert a table, select one from the list and click 
Add. You can also double-click the table name, and a window will 
be displayed containing the table fields at the top of the query design or the 
relational window.
+
 Add
-Inserts the currently selected 
table.
-
+Inserts the currently selected 
table.
+
 Close
-Closes the Add Tables 
dialog.
+Closes the Add Tables 
dialog.
 
 


[Libreoffice-commits] core.git: helpcontent2

2023-05-09 Thread Olivier Hallot (via logerrit)
 helpcontent2 |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 3b3aaf3f228a628e7c1dbc4903ee6160400c1cfb
Author: Olivier Hallot 
AuthorDate: Tue May 9 08:32:53 2023 -0300
Commit: Gerrit Code Review 
CommitDate: Tue May 9 13:32:53 2023 +0200

Update git submodules

* Update helpcontent2 from branch 'master'
  to a8a10f51d66795e9fd8f49839d01e26c9cc4e2a2
  - tdf#149222 Missing Help page for database Relationship dialog

Change-Id: Ieab2dd8906b2d368b054655e22c714076e0d96b2
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/151545
Tested-by: Jenkins
Reviewed-by: Olivier Hallot 

diff --git a/helpcontent2 b/helpcontent2
index 429400018469..a8a10f51d667 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit 429400018469d9925c4645fe7b2266bb275f407d
+Subproject commit a8a10f51d66795e9fd8f49839d01e26c9cc4e2a2


[Libreoffice-commits] core.git: helpcontent2

2023-05-09 Thread Olivier Hallot (via logerrit)
 helpcontent2 |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 0d94705113db12f3c9b31669a66693e171c6ca03
Author: Olivier Hallot 
AuthorDate: Tue May 9 08:31:44 2023 -0300
Commit: Gerrit Code Review 
CommitDate: Tue May 9 13:31:44 2023 +0200

Update git submodules

* Update helpcontent2 from branch 'master'
  to 429400018469d9925c4645fe7b2266bb275f407d
  - tdf#154687 Line & Filling toolbar hidden feature

Change-Id: If751ae42947cfc3320ec4bbf273074ec25e59e5e
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/151543
Tested-by: Jenkins
Reviewed-by: Olivier Hallot 

diff --git a/helpcontent2 b/helpcontent2
index baa3ad9698df..429400018469 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit baa3ad9698dfc80375109478ff88d7929dfb62ea
+Subproject commit 429400018469d9925c4645fe7b2266bb275f407d


[Libreoffice-commits] help.git: source/text

2023-05-09 Thread Olivier Hallot (via logerrit)
 source/text/simpress/main0202.xhp |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 429400018469d9925c4645fe7b2266bb275f407d
Author: Olivier Hallot 
AuthorDate: Mon May 8 12:52:26 2023 -0300
Commit: Olivier Hallot 
CommitDate: Tue May 9 13:31:44 2023 +0200

tdf#154687 Line & Filling toolbar hidden feature

Change-Id: If751ae42947cfc3320ec4bbf273074ec25e59e5e
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/151543
Tested-by: Jenkins
Reviewed-by: Olivier Hallot 

diff --git a/source/text/simpress/main0202.xhp 
b/source/text/simpress/main0202.xhp
index 2e59f4e215..ab7c874f79 100644
--- a/source/text/simpress/main0202.xhp
+++ b/source/text/simpress/main0202.xhp
@@ -31,7 +31,7 @@
 Line and Filling 
Bar
 The Line and 
Filling Bar contains commands and options that you can apply in the current 
view.
 
-
+With no object selected in the workspace, if 
you set the shape attributes like line width, line color, line style, area fill 
type and area fill style with the Line and Filling bar, then the line and 
filling settings are applied to new shapes, as direct formatting, overriding 
the shape Default Drawing Style attributes. To reset the attributes of the Line 
and Filling bar to those of the Default Drawing Style, unselect any object in 
the workspace and double-click on the Default Drawing Style entry in the Styles 
pane of the Sidebar. The next object you draw shows the Default Drawing 
Style.
 
 
 


[Libreoffice-commits] core.git: Branch 'distro/collabora/co-23.05' - sfx2/source

2023-05-09 Thread Szymon Kłos (via logerrit)
 sfx2/source/view/viewfrm.cxx |3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit 5b29a2b363196b9811fa73be552d8ba22566226a
Author: Szymon Kłos 
AuthorDate: Tue May 9 13:05:06 2023 +0200
Commit: Szymon Kłos 
CommitDate: Tue May 9 13:09:31 2023 +0200

navigator: use toggle available for all apps

Change-Id: I3136071ee943b120ebb2ad6491c91d8ebbcd6244
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151573
Tested-by: Szymon Kłos 
Reviewed-by: Szymon Kłos 

diff --git a/sfx2/source/view/viewfrm.cxx b/sfx2/source/view/viewfrm.cxx
index e082d651073e..7472cd37c905 100644
--- a/sfx2/source/view/viewfrm.cxx
+++ b/sfx2/source/view/viewfrm.cxx
@@ -3340,8 +3340,7 @@ void SfxViewFrame::ChildWindowExecute( SfxRequest &rReq )
 if (comphelper::LibreOfficeKit::isActive())
 {
 ShowChildWindow(SID_SIDEBAR);
-OUString panelId = "SdNavigatorPanel";
-::sfx2::sidebar::Sidebar::TogglePanel(panelId, 
GetFrame().GetFrameInterface());
+::sfx2::sidebar::Sidebar::ToggleDeck(u"NavigatorDeck", this);
 rReq.Done();
 return;
 }


[Libreoffice-commits] core.git: sc/CppunitTest_sc_ucalc_document_themes.mk sc/Module_sc.mk sc/qa svx/source

2023-05-09 Thread Tomaž Vajngerl (via logerrit)
 sc/CppunitTest_sc_ucalc_document_themes.mk |   67 +
 sc/Module_sc.mk|1 
 sc/qa/unit/ucalc_DocumentThemes.cxx|   38 
 svx/source/svdraw/svdpage.cxx  |2 
 4 files changed, 107 insertions(+), 1 deletion(-)

New commits:
commit 60cc7b1fbe8e44f323016ce79a14c5c74c8b4cd0
Author: Tomaž Vajngerl 
AuthorDate: Wed Apr 12 16:04:42 2023 +0900
Commit: Tomaž Vajngerl 
CommitDate: Tue May 9 12:41:58 2023 +0200

sc: enable document themes in Calc

Create and check that the SdrPage, that is associated with the
current sheet, has a model::Theme available on creation.

Change-Id: I1814d4a86452b1a15ef01e0b2349d435405f4b7d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150263
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 

diff --git a/sc/CppunitTest_sc_ucalc_document_themes.mk 
b/sc/CppunitTest_sc_ucalc_document_themes.mk
new file mode 100644
index ..b779a643ba19
--- /dev/null
+++ b/sc/CppunitTest_sc_ucalc_document_themes.mk
@@ -0,0 +1,67 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#*
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+#*
+
+$(eval $(call gb_CppunitTest_CppunitTest,sc_ucalc_document_themes))
+
+$(eval $(call 
gb_CppunitTest_use_common_precompiled_header,sc_ucalc_document_themes))
+
+$(eval $(call gb_CppunitTest_add_exception_objects,sc_ucalc_document_themes, \
+sc/qa/unit/ucalc_DocumentThemes \
+))
+
+$(eval $(call gb_CppunitTest_use_externals,sc_ucalc_document_themes, \
+boost_headers \
+mdds_headers \
+libxml2 \
+))
+
+$(eval $(call gb_CppunitTest_use_libraries,sc_ucalc_document_themes, \
+basegfx \
+comphelper \
+cppu \
+cppuhelper \
+sal \
+salhelper \
+sax \
+sc \
+scqahelper \
+sfx \
+svxcore \
+subsequenttest \
+test \
+tl \
+unotest \
+utl \
+vcl \
+))
+
+$(eval $(call gb_CppunitTest_set_include,sc_ucalc_document_themes,\
+-I$(SRCDIR)/sc/source/ui/inc \
+-I$(SRCDIR)/sc/inc \
+$$(INCLUDE) \
+))
+
+$(eval $(call gb_CppunitTest_use_api,sc_ucalc_document_themes,\
+offapi \
+udkapi \
+))
+
+$(eval $(call gb_CppunitTest_use_sdk_api,sc_ucalc_document_themes))
+$(eval $(call gb_CppunitTest_use_ure,sc_ucalc_document_themes))
+$(eval $(call gb_CppunitTest_use_vcl,sc_ucalc_document_themes))
+$(eval $(call gb_CppunitTest_use_rdb,sc_ucalc_document_themes,services))
+$(eval $(call gb_CppunitTest_use_components,sc_ucalc_document_themes))
+$(eval $(call gb_CppunitTest_use_configuration,sc_ucalc_document_themes))
+$(eval $(call gb_CppunitTest_add_arguments,sc_ucalc_document_themes, \
+
-env:arg-env=$(gb_Helper_LIBRARY_PATH_VAR)"{$(gb_Helper_LIBRARY_PATH_VAR)+=$(gb_Helper_LIBRARY_PATH_VAR)}"
 \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/sc/Module_sc.mk b/sc/Module_sc.mk
index 7531130809e8..ce76695b4e4b 100644
--- a/sc/Module_sc.mk
+++ b/sc/Module_sc.mk
@@ -46,6 +46,7 @@ $(eval $(call gb_Module_add_check_targets,sc,\
CppunitTest_sc_ucalc_condformat \
CppunitTest_sc_ucalc_copypaste \
CppunitTest_sc_ucalc_datatransformation \
+   CppunitTest_sc_ucalc_document_themes \
CppunitTest_sc_ucalc_formula \
CppunitTest_sc_ucalc_formula2 \
CppunitTest_sc_ucalc_parallelism \
diff --git a/sc/qa/unit/ucalc_DocumentThemes.cxx 
b/sc/qa/unit/ucalc_DocumentThemes.cxx
new file mode 100644
index ..5c568b9f5ca0
--- /dev/null
+++ b/sc/qa/unit/ucalc_DocumentThemes.cxx
@@ -0,0 +1,38 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#include "helper/qahelper.hxx"
+#include 
+#include 
+
+using namespace css;
+
+class DocumentThemesTest : public ScUcalcTestBase
+{
+};
+
+namespace
+{
+CPPUNIT_TEST_FIXTURE(DocumentThemesTest, testThemes)
+{
+m_pDoc->InitDrawLayer();
+m_pDoc->InsertTab(0, "Test");
+ScDrawLayer* pDrawLayer = m_pDoc->GetDrawLayer();
+CPPUNIT_ASSERT(pDrawLayer);
+const SdrPage* pPage(pDrawLayer->GetPage(0));
+CPPUNIT_ASSERT(pPage);
+auto const& pTheme = pPage->getSdrPageProperties().GetTheme();
+CPPUNIT_ASSERT(pTheme);
+}
+
+} // end anonymous namespace
+
+CPPUNIT_PLUGIN_IMPLEMENT();
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/svdraw/svdpage.cxx b/svx/sourc

[Libreoffice-commits] core.git: sw/inc sw/Library_sw.mk sw/qa sw/source

2023-05-09 Thread Tomaž Vajngerl (via logerrit)
 sw/Library_sw.mk   |1 
 sw/inc/strings.hrc |2 
 sw/inc/swundo.hxx  |1 
 sw/qa/core/theme/ThemeTest.cxx |   78 +
 sw/source/core/inc/ThemeColorChanger.hxx   |3 -
 sw/source/core/inc/UndoThemeChange.hxx |   35 +
 sw/source/core/model/ThemeColorChanger.cxx |   17 --
 sw/source/core/undo/UndoThemeChange.cxx|   48 +
 sw/source/core/undo/undobj.cxx |3 +
 9 files changed, 181 insertions(+), 7 deletions(-)

New commits:
commit 33d35a2181c9cebf77bc1aa9322a2d11892de5fd
Author: Tomaž Vajngerl 
AuthorDate: Thu May 4 00:21:55 2023 +0900
Commit: Tomaž Vajngerl 
CommitDate: Tue May 9 12:41:37 2023 +0200

sw: support Undo/Redo for theme colors

Change-Id: Ic4166ec4836545467866a70b4160f1adba0bad96
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151448
Tested-by: Tomaž Vajngerl 
Reviewed-by: Tomaž Vajngerl 

diff --git a/sw/Library_sw.mk b/sw/Library_sw.mk
index bc0067dcb8a8..f49117e58f86 100644
--- a/sw/Library_sw.mk
+++ b/sw/Library_sw.mk
@@ -483,6 +483,7 @@ $(eval $(call gb_Library_add_exception_objects,sw,\
 sw/source/core/undo/unspnd \
 sw/source/core/undo/untbl \
 sw/source/core/undo/untblk \
+sw/source/core/undo/UndoThemeChange \
 sw/source/core/unocore/SwXTextDefaults \
 sw/source/core/unocore/TextCursorHelper  \
 sw/source/core/unocore/XMLRangeHelper \
diff --git a/sw/inc/strings.hrc b/sw/inc/strings.hrc
index 2c7eb4069688..733193103d1e 100644
--- a/sw/inc/strings.hrc
+++ b/sw/inc/strings.hrc
@@ -599,6 +599,8 @@
 #define STR_UNDO_UPDATE_FORM_FIELDS 
NC_("STR_UNDO_UPDATE_FORM_FIELDS", "Update form fields")
 #define STR_UNDO_DELETE_FORM_FIELDS 
NC_("STR_UNDO_DELETE_FORM_FIELDS", "Delete form fields")
 #define STR_UNDO_INSERT_PAGE_NUMBER 
NC_("STR_UNDO_INSERT_PAGE_NUMBER", "Insert page number")
+#define STR_UNDO_CHANGE_THEME_COLORS
NC_("STR_UNDO_CHANGE_THEME_COLORS", "Change document theme color")
+
 #define STR_DROP_DOWN_FIELD_ITEM_LIMIT  
NC_("STR_DROP_DOWN_FIELD_ITEM_LIMIT", "You can specify maximum of 25 items for 
a drop-down form field.")
 
 #define STR_ACCESS_DOC_NAME NC_("STR_ACCESS_DOC_NAME", 
"Document view")
diff --git a/sw/inc/swundo.hxx b/sw/inc/swundo.hxx
index 5f0e006114f8..b8bf714aa580 100644
--- a/sw/inc/swundo.hxx
+++ b/sw/inc/swundo.hxx
@@ -177,6 +177,7 @@ enum class SwUndoId
 UPDATE_FIELDS, // 145
 DELETE_FIELDS, // 146
 UPDATE_SECTIONS,   // 147
+CHANGE_THEME = 148,
 };
 
 OUString GetUndoComment(SwUndoId eId);
diff --git a/sw/qa/core/theme/ThemeTest.cxx b/sw/qa/core/theme/ThemeTest.cxx
index 0802994aead6..f76460eb6b98 100644
--- a/sw/qa/core/theme/ThemeTest.cxx
+++ b/sw/qa/core/theme/ThemeTest.cxx
@@ -18,6 +18,8 @@
 #include 
 #include 
 #include 
+#include 
+#include 
 
 using namespace css;
 
@@ -392,6 +394,82 @@ CPPUNIT_TEST_FIXTURE(SwCoreThemeTest, 
testDrawPageThemeExistsODT)
 CPPUNIT_ASSERT_EQUAL(Color(0xCCDDEA), 
pTheme->GetColor(model::ThemeColorType::Light2));
 }
 
+CPPUNIT_TEST_FIXTURE(SwCoreThemeTest, testThemeChanging)
+{
+createSwDoc("ThemeColorInHeading.docx");
+SwDoc* pDoc = getSwDoc();
+CPPUNIT_ASSERT(pDoc);
+SwWrtShell* pWrtShell = pDoc->GetDocShell()->GetWrtShell();
+CPPUNIT_ASSERT(pWrtShell);
+SdrPage* pPage = 
pDoc->getIDocumentDrawModelAccess().GetDrawModel()->GetPage(0);
+CPPUNIT_ASSERT(pPage);
+
+// Check current theme colors
+{
+auto const& pTheme = pPage->getSdrPageProperties().GetTheme();
+CPPUNIT_ASSERT(pTheme);
+CPPUNIT_ASSERT_EQUAL(OUString(u"Office Theme"), pTheme->GetName());
+
+auto pColorSet = pTheme->getColorSet();
+CPPUNIT_ASSERT(pColorSet);
+CPPUNIT_ASSERT_EQUAL(OUString(u"Orange"), pColorSet->getName());
+CPPUNIT_ASSERT_EQUAL(Color(0xE48312), 
pTheme->GetColor(model::ThemeColorType::Accent1));
+}
+
+// Change theme colors
+{
+auto const& rColorSets = svx::ColorSets::get();
+model::ColorSet const& rNewColorSet = rColorSets.getColorSet(0);
+// check that the theme colors are as expected
+CPPUNIT_ASSERT_EQUAL(OUString(u"LibreOffice"), rNewColorSet.getName());
+
+sw::ThemeColorChanger aChanger(pDoc->GetDocShell());
+aChanger.apply(rNewColorSet);
+}
+
+// Check new theme colors
+{
+auto const& pTheme = pPage->getSdrPageProperties().GetTheme();
+CPPUNIT_ASSERT(pTheme);
+CPPUNIT_ASSERT_EQUAL(OUString(u"Office Theme"), pTheme->GetName());
+
+auto pColorSet = pTheme->getColorSet();
+CPPUNIT_ASSERT(pColorSet);
+CPPUNIT_ASSERT_EQUAL(OUString(u"LibreOffice"), pColorSet->getName());
+CPPUNIT_ASSERT_EQUAL(Color(0x18A303), 
pTheme->GetColor(model::ThemeColorType::A

[Libreoffice-commits] core.git: compilerplugins/clang include/svx svx/inc svx/Library_svxcore.mk svx/source

2023-05-09 Thread Noel Grandin (via logerrit)
 compilerplugins/clang/mergeclasses.results   |1 
 include/svx/gallery1.hxx |6 
 svx/Library_svxcore.mk   |1 
 svx/inc/gallerybinaryengineentry.hxx |   66 
 svx/inc/galleryfilestorageentry.hxx  |   42 +
 svx/source/gallery2/galini.cxx   |4 
 svx/source/gallery2/gallery1.cxx |8 -
 svx/source/gallery2/gallerybinaryengineentry.cxx |  181 ---
 svx/source/gallery2/galleryfilestorageentry.cxx  |  159 
 9 files changed, 207 insertions(+), 261 deletions(-)

New commits:
commit afccbe23cecc04a08281a91e02bb25dd7b0ffdcf
Author: Noel Grandin 
AuthorDate: Mon May 8 12:30:36 2023 +0200
Commit: Noel Grandin 
CommitDate: Tue May 9 12:31:56 2023 +0200

merge GalleryFileStorageEntry with GalleryBinaryEngineEntry

Change-Id: I21b3f49cdf04b021931ab9e1171bfffa5cd76e1f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151552
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/compilerplugins/clang/mergeclasses.results 
b/compilerplugins/clang/mergeclasses.results
index e92d1bfc19b7..a1e8c6be6e3d 100644
--- a/compilerplugins/clang/mergeclasses.results
+++ b/compilerplugins/clang/mergeclasses.results
@@ -55,7 +55,6 @@ merge FmXDisposeListener with DisposeListenerGridBridge
 merge FmXFormShell_Base_Disambiguation with FmXFormShell
 merge GLWindow with GLX11Window
 merge GalleryFileStorage with GalleryBinaryEngine
-merge GalleryFileStorageEntry with GalleryBinaryEngineEntry
 merge GroupTable with PPTWriterBase
 merge HostDetailsContainer with DavDetailsContainer
 merge IDocumentChartDataProviderAccess with 
sw::DocumentChartDataProviderManager
diff --git a/include/svx/gallery1.hxx b/include/svx/gallery1.hxx
index 7b6fe2b23dc5..49427be4d723 100644
--- a/include/svx/gallery1.hxx
+++ b/include/svx/gallery1.hxx
@@ -31,7 +31,7 @@
 
 class Gallery;
 class GalleryBinaryEngine;
-class GalleryBinaryEngineEntry;
+class GalleryFileStorageEntry;
 class GalleryObjectCollection;
 class GalleryStorageLocations;
 class GalleryTheme;
@@ -40,7 +40,7 @@ class SVXCORE_DLLPUBLIC GalleryThemeEntry
 {
 private:
 
-std::unique_ptr mpGalleryStorageEngineEntry;
+std::unique_ptr mpGalleryStorageEngineEntry;
 OUStringaName;
 sal_uInt32  nId;
 boolbReadOnly;
@@ -55,7 +55,7 @@ public:
sal_uInt32 nId, bool 
bThemeNameFromResource );
 ~GalleryThemeEntry();
 
-const std::unique_ptr& 
getGalleryStorageEngineEntry() const { return mpGalleryStorageEngineEntry; }
+const std::unique_ptr& 
getGalleryStorageEngineEntry() const { return mpGalleryStorageEngineEntry; }
 
 GalleryStorageLocations& getGalleryStorageLocations() const;
 
diff --git a/svx/Library_svxcore.mk b/svx/Library_svxcore.mk
index 757244f5f6d0..8dd99ef5484b 100644
--- a/svx/Library_svxcore.mk
+++ b/svx/Library_svxcore.mk
@@ -205,7 +205,6 @@ $(eval $(call gb_Library_add_exception_objects,svxcore,\
 svx/source/gallery2/galtheme \
 svx/source/gallery2/GalleryControl \
 svx/source/gallery2/gallerybinaryengine \
-svx/source/gallery2/gallerybinaryengineentry \
 svx/source/gallery2/galleryobjectcollection \
 svx/source/gallery2/galleryfilestorage \
 svx/source/gallery2/galleryfilestorageentry \
diff --git a/svx/inc/gallerybinaryengineentry.hxx 
b/svx/inc/gallerybinaryengineentry.hxx
deleted file mode 100644
index e21d6a64fea7..
--- a/svx/inc/gallerybinaryengineentry.hxx
+++ /dev/null
@@ -1,66 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#pragma once
-
-#include 
-#include 
-#include "gallerybinaryengine.hxx"
-#include "gallerystoragelocations.hxx"
-#include "galleryfilestorageentry.hxx"
-
-class GalleryObjectCollection;
-class GalleryBinaryEngine;
-
-class GalleryBinaryEngineEntry final : public GalleryFileStorageEntry
-{
-private:
-std::unique_ptr mpGalleryStorageLocations;
-
-public:
-GalleryBinaryEngineEntry();
-static void CreateUniqueUR

[Libreoffice-commits] core.git: sc/qa

2023-05-09 Thread Xisco Fauli (via logerrit)
 sc/qa/extras/vba-macro-test.cxx |  101 +---
 1 file changed, 24 insertions(+), 77 deletions(-)

New commits:
commit 3efb1714d7095898389f86258e805a62e7468a19
Author: Xisco Fauli 
AuthorDate: Tue May 9 10:40:02 2023 +0200
Commit: Xisco Fauli 
CommitDate: Tue May 9 12:28:57 2023 +0200

CppunitTest_sc_vba_macro_test: use CPPUNIT_TEST_FIXTURE()

Avoid the declaration/registration/definition of each
test manually saves a lot of space.

Change-Id: Ifbefb1950f7fe547489f279c8b229c43dac57f3d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151564
Tested-by: Jenkins
Reviewed-by: Xisco Fauli 

diff --git a/sc/qa/extras/vba-macro-test.cxx b/sc/qa/extras/vba-macro-test.cxx
index 73dab6bba921..ffe77d21fe7d 100644
--- a/sc/qa/extras/vba-macro-test.cxx
+++ b/sc/qa/extras/vba-macro-test.cxx
@@ -47,61 +47,9 @@ public:
 : UnoApiTest("/sc/qa/extras/testdocuments")
 {
 }
-
-void testSimpleCopyAndPaste();
-void testMultiDocumentCopyAndPaste();
-void testSheetAndColumnSelectAndHide();
-void testPrintArea();
-void testSelectAllChaged();
-void testRangeSelect();
-void testWindowState();
-void testScroll();
-void testMacroKeyBinding();
-
-void testVba();
-void testTdf149579();
-void testVbaRangeSort();
-void testTdf107885();
-void testTdf131562();
-void testTdf52602();
-void testTdf107902();
-void testTdf90278();
-void testTdf149531();
-void testTdf118247();
-void testTdf126457();
-void testVbaPDFExport();
-void testForEachInSelection();
-void testNonAsciiMacroIRI();
-
-CPPUNIT_TEST_SUITE(VBAMacroTest);
-CPPUNIT_TEST(testSimpleCopyAndPaste);
-CPPUNIT_TEST(testMultiDocumentCopyAndPaste);
-CPPUNIT_TEST(testSheetAndColumnSelectAndHide);
-CPPUNIT_TEST(testPrintArea);
-CPPUNIT_TEST(testSelectAllChaged);
-CPPUNIT_TEST(testRangeSelect);
-CPPUNIT_TEST(testWindowState);
-CPPUNIT_TEST(testScroll);
-CPPUNIT_TEST(testMacroKeyBinding);
-
-CPPUNIT_TEST(testVba);
-CPPUNIT_TEST(testTdf149579);
-CPPUNIT_TEST(testVbaRangeSort);
-CPPUNIT_TEST(testTdf107885);
-CPPUNIT_TEST(testTdf131562);
-CPPUNIT_TEST(testTdf52602);
-CPPUNIT_TEST(testTdf107902);
-CPPUNIT_TEST(testTdf90278);
-CPPUNIT_TEST(testTdf149531);
-CPPUNIT_TEST(testTdf118247);
-CPPUNIT_TEST(testTdf126457);
-CPPUNIT_TEST(testVbaPDFExport);
-CPPUNIT_TEST(testForEachInSelection);
-CPPUNIT_TEST(testNonAsciiMacroIRI);
-CPPUNIT_TEST_SUITE_END();
 };
 
-void VBAMacroTest::testSimpleCopyAndPaste()
+CPPUNIT_TEST_FIXTURE(VBAMacroTest, testSimpleCopyAndPaste)
 {
 // Copy-paste values in the same sheet
 
@@ -138,7 +86,7 @@ void VBAMacroTest::testSimpleCopyAndPaste()
 CPPUNIT_ASSERT_EQUAL(30.0, rDoc.GetValue(ScAddress(1, 5, 0)));
 }
 
-void VBAMacroTest::testMultiDocumentCopyAndPaste()
+CPPUNIT_TEST_FIXTURE(VBAMacroTest, testMultiDocumentCopyAndPaste)
 {
 // Creates a new workbook (document) and copy-pastes values
 // between the documents.
@@ -172,7 +120,7 @@ void VBAMacroTest::testMultiDocumentCopyAndPaste()
 CPPUNIT_ASSERT_EQUAL(0.0, rDoc.GetValue(ScAddress(1, 3, 0)));
 }
 
-void VBAMacroTest::testSheetAndColumnSelectAndHide()
+CPPUNIT_TEST_FIXTURE(VBAMacroTest, testSheetAndColumnSelectAndHide)
 {
 loadFromURL(u"SheetAndColumnSelectAndHide.xlsm");
 
@@ -233,7 +181,7 @@ void VBAMacroTest::testSheetAndColumnSelectAndHide()
 CPPUNIT_ASSERT_EQUAL(SCTAB(0), rViewData.GetTabNo());
 }
 
-void VBAMacroTest::testPrintArea()
+CPPUNIT_TEST_FIXTURE(VBAMacroTest, testPrintArea)
 {
 // Sets the print area to A1:B5
 // ActiveSheet.PageSetup.PrintArea = "$A$1:$B$5"
@@ -258,7 +206,7 @@ void VBAMacroTest::testPrintArea()
 }
 }
 
-void VBAMacroTest::testSelectAllChaged()
+CPPUNIT_TEST_FIXTURE(VBAMacroTest, testSelectAllChaged)
 {
 // Columns("A:A").Select
 // Range(Selection, Selection.End(xlToRight)).Select
@@ -280,7 +228,7 @@ void VBAMacroTest::testSelectAllChaged()
 CPPUNIT_ASSERT_EQUAL(ScRange(0, 0, 0, 4, MAXROW, 0), 
pViewData.GetMarkData().GetMarkArea());
 }
 
-void VBAMacroTest::testRangeSelect()
+CPPUNIT_TEST_FIXTURE(VBAMacroTest, testRangeSelect)
 {
 // Range("B2").Select
 // Range(Selection, Selection.End(xlToRight)).Select
@@ -302,7 +250,7 @@ void VBAMacroTest::testRangeSelect()
 CPPUNIT_ASSERT_EQUAL(ScRange(1, 1, 0, 4, 1, 0), 
pViewData.GetMarkData().GetMarkArea());
 }
 
-void VBAMacroTest::testWindowState()
+CPPUNIT_TEST_FIXTURE(VBAMacroTest, testWindowState)
 {
 // Application.WindowState = xlMinimized
 // Application.WindowState = xlMaximized
@@ -313,7 +261,7 @@ void VBAMacroTest::testWindowState()
  "location=document");
 }
 
-void VBAMacroTest::testScroll()
+CPPUNIT_TEST_FIXTURE(VBAMacroTest, testScroll)
 {
 // ActiveWindow.ScrollColumn = 30
 // ActiveWindow.ScrollRow = 100
@@ -340,7 +288,7 @@ void VBAMacroTest::testScroll()

[Libreoffice-commits] core.git: Branch 'libreoffice-7-5' - 2 commits - oox/source sc/qa sc/source

2023-05-09 Thread Czeber László Ádám (via logerrit)
 oox/source/helper/attributelist.cxx|3 
 sc/qa/unit/data/csv/tdf152980.csv  |9 ++
 sc/qa/unit/subsequent_export_test2.cxx |   29 
 sc/source/filter/oox/richstring.cxx|  112 -
 4 files changed, 42 insertions(+), 111 deletions(-)

New commits:
commit 47b30728db3ad47f1b4d0d8b027ba0a55607ac1e
Author: Czeber László Ádám 
AuthorDate: Mon May 8 09:33:07 2023 +0200
Commit: Xisco Fauli 
CommitDate: Tue May 9 12:28:34 2023 +0200

tdf#152980 CSV import: Fix control character length in XLSX save

Converting from CSV to XLSX corrupts text that looks like a control
character. Only 4 numeric length escape character allowed, in _x000D_
format, not _x0D_ for exampled.

Change lcl_unEscapeUnicodeChars function to decodeXString. Delete not used 
functions and add multiple occurence for unit test.

Change-Id: Id1d4bfcf7d27cf5005e7bea8e289303c5d9aca73
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151494
Reviewed-by: Eike Rathke 
Tested-by: Eike Rathke 
Signed-off-by: Xisco Fauli 
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151562
Reviewed-by: Michael Stahl 
Tested-by: Jenkins

diff --git a/sc/qa/unit/data/csv/tdf152980.csv 
b/sc/qa/unit/data/csv/tdf152980.csv
new file mode 100644
index ..c5050b86d968
--- /dev/null
+++ b/sc/qa/unit/data/csv/tdf152980.csv
@@ -0,0 +1,9 @@
+"a_x1_b"
+"a_x01_b"
+"a_x001_b"
+"a_x0001_b"
+"a_xfoo
b"
+"a b"
+"a
+b"
+"a

b"
diff --git a/sc/qa/unit/subsequent_export_test2.cxx 
b/sc/qa/unit/subsequent_export_test2.cxx
index 56d7ac158151..d1920de3c3cb 100644
--- a/sc/qa/unit/subsequent_export_test2.cxx
+++ b/sc/qa/unit/subsequent_export_test2.cxx
@@ -193,6 +193,7 @@ public:
 void testTotalsRowFunction();
 void testAutofilterHiddenButton();
 void testTdf119565();
+void testTdf152980();
 
 CPPUNIT_TEST_SUITE(ScExportTest2);
 
@@ -325,6 +326,7 @@ public:
 CPPUNIT_TEST(testTotalsRowFunction);
 CPPUNIT_TEST(testAutofilterHiddenButton);
 CPPUNIT_TEST(testTdf119565);
+CPPUNIT_TEST(testTdf152980);
 
 CPPUNIT_TEST_SUITE_END();
 };
@@ -2969,6 +2971,33 @@ void ScExportTest2::testTdf119565()
  
xShapeProps->getPropertyValue("LineJoint").get());
 }
 
+void ScExportTest2::testTdf152980()
+{
+createScDoc("csv/tdf152980.csv");
+ScDocShell* pDocSh = getScDocShell();
+pDocSh->DoHardRecalc();
+saveAndReload("Calc Office Open XML");
+pDocSh = getScDocShell();
+pDocSh->DoHardRecalc();
+
+ScDocument* pDoc = getScDoc();
+
+// - Expected: The part between a and b does not change
+// - Actual  : Only the characters a and b remain
+CPPUNIT_ASSERT_EQUAL(OUString("a_x1_b"), pDoc->GetString(0, 0, 0));
+CPPUNIT_ASSERT_EQUAL(OUString("a_x01_b"), pDoc->GetString(0, 1, 0));
+CPPUNIT_ASSERT_EQUAL(OUString("a_x001_b"), pDoc->GetString(0, 2, 0));
+
+// The character code does not change in both cases
+CPPUNIT_ASSERT_EQUAL(OUString("a_x0001_b"), pDoc->GetString(0, 3, 0));
+
+// The escape characters are handled correctly in both cases
+CPPUNIT_ASSERT_EQUAL(OUString("a_xfoo\nb"), pDoc->GetString(0, 4, 0));
+CPPUNIT_ASSERT_EQUAL(OUString("a\tb"), pDoc->GetString(0, 5, 0));
+CPPUNIT_ASSERT_EQUAL(OUString("a\nb"), pDoc->GetString(0, 6, 0));
+CPPUNIT_ASSERT_EQUAL(OUString("a\n\nb"), pDoc->GetString(0, 7, 0));
+}
+
 CPPUNIT_TEST_SUITE_REGISTRATION(ScExportTest2);
 
 CPPUNIT_PLUGIN_IMPLEMENT();
diff --git a/sc/source/filter/oox/richstring.cxx 
b/sc/source/filter/oox/richstring.cxx
index a9b272d62a9a..8d2f964362d0 100644
--- a/sc/source/filter/oox/richstring.cxx
+++ b/sc/source/filter/oox/richstring.cxx
@@ -48,116 +48,6 @@ bool lclNeedsRichTextFormat( const oox::xls::Font* pFont )
 return pFont && pFont->needsRichTextFormat();
 }
 
-sal_Int32 lcl_getHexLetterValue(sal_Unicode nCode)
-{
-if (nCode >= '0' && nCode <= '9')
-return nCode - '0';
-
-if (nCode >= 'A' && nCode <= 'F')
-return nCode - 'A' + 10;
-
-if (nCode >= 'a' && nCode <= 'f')
-return nCode - 'a' + 10;
-
-return -1;
-}
-
-bool lcl_validEscape(sal_Unicode nCode)
-{
-// Valid XML chars that can be escaped (ignoring the restrictions) as in 
the OOX open spec
-// 2.1.1742 Part 1 Section 22.9.2.19, ST_Xstring (Escaped String)
-if (nCode == 0x000D || nCode == 0x000A || nCode == 0x0009 || nCode == 
0x005F)
-return true;
-
-// Other valid XML chars in basic multilingual plane that cannot be 
escaped.
-if ((nCode >= 0x0020 && nCode <= 0xD7FF) || (nCode >= 0xE000 && nCode <= 
0xFFFD))
-return false;
-
-return true;
-}
-
-OUString lcl_unEscapeUnicodeChars(const OUString& rSrc)
-{
-// Example: Escaped representation of unicode char 0x000D is _x000D_
-
-sal_Int32 nLen = rSrc.getLength();
-if (!nLen)
-return rSrc;
-
-sal_Int32 nStart = 0;
-bool bFound = false;
-const OUString aPrefix = "_x

[Libreoffice-commits] core.git: Branch 'distro/collabora/co-23.05' - vcl/jsdialog

2023-05-09 Thread Szymon Kłos (via logerrit)
 vcl/jsdialog/enabled.cxx |9 +
 1 file changed, 9 insertions(+)

New commits:
commit 880828b028c68ae4654322c98cc60d0c0cec3855
Author: Szymon Kłos 
AuthorDate: Tue May 9 09:13:13 2023 +0200
Commit: Szymon Kłos 
CommitDate: Tue May 9 12:08:13 2023 +0200

jsdialog: enable image properties dialogs

Change-Id: Id3bf64e38093e7c068871029599a13f64891b6fa
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151557
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Szymon Kłos 

diff --git a/vcl/jsdialog/enabled.cxx b/vcl/jsdialog/enabled.cxx
index 807f1d14a580..3a6ec1d1e943 100644
--- a/vcl/jsdialog/enabled.cxx
+++ b/vcl/jsdialog/enabled.cxx
@@ -38,6 +38,7 @@ bool isBuilderEnabled(std::u16string_view rUIFile, bool 
bMobile)
 || rUIFile == u"cui/ui/charnamepage.ui"
 || rUIFile == u"cui/ui/colorpage.ui"
 || rUIFile == u"cui/ui/colorpickerdialog.ui"
+|| rUIFile == u"cui/ui/croppage.ui"
 || rUIFile == u"cui/ui/effectspage.ui"
 || rUIFile == u"cui/ui/eventassigndialog.ui"
 || rUIFile == u"cui/ui/fontfeaturesdialog.ui"
@@ -71,6 +72,7 @@ bool isBuilderEnabled(std::u16string_view rUIFile, bool 
bMobile)
 || rUIFile == u"cui/ui/rotationtabpage.ui"
 || rUIFile == u"cui/ui/shadowtabpage.ui"
 || rUIFile == u"cui/ui/slantcornertabpage.ui"
+|| rUIFile == u"cui/ui/spinbox.ui"
 || rUIFile == u"cui/ui/queryduplicatedialog.ui"
 || rUIFile == u"cui/ui/similaritysearchdialog.ui"
 || rUIFile == u"cui/ui/specialcharacters.ui"
@@ -172,6 +174,9 @@ bool isBuilderEnabled(std::u16string_view rUIFile, bool 
bMobile)
 || rUIFile == u"modules/swriter/ui/footnotepage.ui"
 || rUIFile == u"modules/swriter/ui/footnotesendnotestabpage.ui"
 || rUIFile == u"modules/swriter/ui/formattablepage.ui"
+|| rUIFile == u"modules/swriter/ui/frmaddpage.ui"
+|| rUIFile == u"modules/swriter/ui/frmurlpage.ui"
+|| rUIFile == u"modules/swriter/ui/frmtypepage.ui"
 || rUIFile == u"modules/swriter/ui/indentpage.ui"
 || rUIFile == u"modules/swriter/ui/indexentry.ui"
 || rUIFile == u"modules/swriter/ui/inforeadonlydialog.ui"
@@ -183,6 +188,8 @@ bool isBuilderEnabled(std::u16string_view rUIFile, bool 
bMobile)
 || rUIFile == u"modules/swriter/ui/numparapage.ui"
 || rUIFile == u"modules/swriter/ui/pagenumberdlg.ui"
 || rUIFile == u"modules/swriter/ui/paradialog.ui"
+|| rUIFile == u"modules/swriter/ui/picturedialog.ui"
+|| rUIFile == u"modules/swriter/ui/picturepage.ui"
 || rUIFile == u"modules/swriter/ui/sectionpage.ui"
 || rUIFile == u"modules/swriter/ui/sortdialog.ui"
 || rUIFile == u"modules/swriter/ui/splittable.ui"
@@ -200,6 +207,7 @@ bool isBuilderEnabled(std::u16string_view rUIFile, bool 
bMobile)
 || rUIFile == u"modules/swriter/ui/translationdialog.ui"
 || rUIFile == u"modules/swriter/ui/watermarkdialog.ui"
 || rUIFile == u"modules/swriter/ui/wordcount.ui"
+|| rUIFile == u"modules/swriter/ui/wrappage.ui"
 // sfx
 || rUIFile == u"sfx/ui/cmisinfopage.ui"
 || rUIFile == u"sfx/ui/custominfopage.ui"
@@ -214,6 +222,7 @@ bool isBuilderEnabled(std::u16string_view rUIFile, bool 
bMobile)
 // svx
 || rUIFile == u"svx/ui/accessibilitycheckdialog.ui"
 || rUIFile == u"svx/ui/accessibilitycheckentry.ui"
+|| rUIFile == u"svx/ui/compressgraphicdialog.ui"
 || rUIFile == u"svx/ui/findreplacedialog.ui"
 || rUIFile == u"svx/ui/fontworkgallerydialog.ui"
 || rUIFile == u"svx/ui/headfootformatpage.ui"


[Libreoffice-commits] core.git: Branch 'libreoffice-7-5' - external/libwpg

2023-05-09 Thread Stephan Bergmann (via logerrit)
 external/libwpg/UnpackedTarball_libwpg.mk |4 
 external/libwpg/rpath.patch   |   10 ++
 2 files changed, 14 insertions(+)

New commits:
commit ca27971934595a074f98afadfa49aa799e8491a4
Author: Stephan Bergmann 
AuthorDate: Tue May 9 08:34:43 2023 +0200
Commit: Xisco Fauli 
CommitDate: Tue May 9 12:01:02 2023 +0200

Reinstate external/libwpg/rpath.patch

...which 0c0c9a0dd8a7b102315ab1075f78a0f1f3397b67 "tdf#155057: Wrong colors 
in
some WPG2 (well rendered in WPG1)" had dropped for no apparent reason, 
causing

> [CHK] CustomTarget/postprocess/check_dynamic_objects/check.done
> ~/lo/core/instdir/program/libwpg-0.3-lo.so.3 has unexpected RPATH  
0x001d (RUNPATH)Library runpath: 
[~/lo/core/workdir/UnpackedTarball/libwpd/src/lib/.libs:~/lo/core/workdir/UnpackedTarball/librevenge/src/lib/.libs:/usr/local/lib:$ORIGIN]

to fail (in Linux builds that execute that test)

Change-Id: Id9f87b14f571b328b98496625351bc1f87bf8c61
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151555
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann 
(cherry picked from commit edf471ba8b5a69ce26e68eff26283b304c4c9a9e)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151518
Reviewed-by: Michael Stahl 

diff --git a/external/libwpg/UnpackedTarball_libwpg.mk 
b/external/libwpg/UnpackedTarball_libwpg.mk
index e3790c831296..9ca55c669d72 100644
--- a/external/libwpg/UnpackedTarball_libwpg.mk
+++ b/external/libwpg/UnpackedTarball_libwpg.mk
@@ -15,6 +15,10 @@ $(eval $(call gb_UnpackedTarball_set_patchlevel,libwpg,0))
 
 $(eval $(call gb_UnpackedTarball_update_autoconf_configs,libwpg))
 
+$(eval $(call gb_UnpackedTarball_add_patches,libwpg, \
+external/libwpg/rpath.patch \
+))
+
 ifneq ($(OS),MACOSX)
 ifneq ($(OS),WNT)
 ifneq ($(OS),iOS)
diff --git a/external/libwpg/rpath.patch b/external/libwpg/rpath.patch
new file mode 100644
index ..5a8f56105509
--- /dev/null
+++ b/external/libwpg/rpath.patch
@@ -0,0 +1,10 @@
+--- configure
 configure
+@@ -13858,6 +13858,7 @@
+   esac
+   ;;
+   esac
++hardcode_libdir_flag_spec_CXX=
+   ;;
+ 
+   lynxos*)


[Libreoffice-commits] core.git: sc/qa

2023-05-09 Thread Xisco Fauli (via logerrit)
 sc/qa/unit/data/xls/tdf120177.xls  |binary
 sc/qa/unit/subsequent_export_test4.cxx |   32 
 2 files changed, 32 insertions(+)

New commits:
commit 332ac45c73952af7e2c2a868fc03e17d96a7de2c
Author: Xisco Fauli 
AuthorDate: Tue May 9 10:31:28 2023 +0200
Commit: Xisco Fauli 
CommitDate: Tue May 9 11:55:17 2023 +0200

tdf#120177: sc_subsequent_export_test4: Add unittest

Change-Id: I71846e6e80674dc61126069d13ddd431560b071b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151563
Tested-by: Jenkins
Reviewed-by: Xisco Fauli 

diff --git a/sc/qa/unit/data/xls/tdf120177.xls 
b/sc/qa/unit/data/xls/tdf120177.xls
new file mode 100644
index ..b843060f6f71
Binary files /dev/null and b/sc/qa/unit/data/xls/tdf120177.xls differ
diff --git a/sc/qa/unit/subsequent_export_test4.cxx 
b/sc/qa/unit/subsequent_export_test4.cxx
index 233195b2ebde..46ea2547eadc 100644
--- a/sc/qa/unit/subsequent_export_test4.cxx
+++ b/sc/qa/unit/subsequent_export_test4.cxx
@@ -132,6 +132,38 @@ CPPUNIT_TEST_FIXTURE(ScExportTest4, testRotatedImageODS)
 CPPUNIT_ASSERT(sY.endsWith("mm"));
 }
 
+CPPUNIT_TEST_FIXTURE(ScExportTest4, testTdf120177)
+{
+createScDoc("xls/tdf120177.xls");
+
+// Error: unexpected attribute "form:input-required"
+skipValidation();
+
+save("calc8");
+xmlDocUniquePtr pXmlDoc = parseExport("content.xml");
+CPPUNIT_ASSERT(pXmlDoc);
+
+// Without the fix in place, this test would have failed with
+// no attribute 'value' exist
+assertXPath(pXmlDoc,
+
"/office:document-content/office:body/office:spreadsheet/table:table/office:forms/"
+"form:form/form:radio[1]",
+"value", "1");
+assertXPath(pXmlDoc,
+
"/office:document-content/office:body/office:spreadsheet/table:table/office:forms/"
+"form:form/form:radio[2]",
+"value", "2");
+const OUString sGroupName1 = getXPath(pXmlDoc,
+  
"/office:document-content/office:body/office:spreadsheet/"
+  
"table:table/office:forms/form:form/form:radio[1]",
+  "group-name");
+const OUString sGroupName2 = getXPath(pXmlDoc,
+  
"/office:document-content/office:body/office:spreadsheet/"
+  
"table:table/office:forms/form:form/form:radio[2]",
+  "group-name");
+CPPUNIT_ASSERT_EQUAL(sGroupName1, sGroupName2);
+}
+
 CPPUNIT_TEST_FIXTURE(ScExportTest4, testTdf85553)
 {
 createScDoc("ods/tdf85553.ods");


[Libreoffice-commits] core.git: vcl/inc vcl/qt5 vcl/unx

2023-05-09 Thread Caolán McNamara (via logerrit)
 vcl/inc/qt5/QtFrame.hxx |2 
 vcl/inc/unx/gtk/gtkframe.hxx|2 
 vcl/inc/unx/salframe.h  |2 
 vcl/inc/unx/screensaverinhibitor.hxx|   28 ++--
 vcl/qt5/QtFrame.cxx |8 +-
 vcl/unx/generic/window/salframe.cxx |4 -
 vcl/unx/generic/window/screensaverinhibitor.cxx |   75 ++--
 vcl/unx/gtk3/gtkframe.cxx   |   15 +---
 8 files changed, 66 insertions(+), 70 deletions(-)

New commits:
commit 796fb57d7b2e2ea05795dc49c4438c25adc26fd4
Author: Caolán McNamara 
AuthorDate: Mon May 8 11:17:00 2023 +0100
Commit: Caolán McNamara 
CommitDate: Tue May 9 11:20:29 2023 +0200

Related: tdf#142176 rearrange screensaver inhibiter to be more generic

and for not-x11 I see gtk just uses 0 for xid (which is called
window_system_id there now)

Change-Id: I9248bcceaa2d21d34133dea80697776df0aa8c6c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151560
Tested-by: Caolán McNamara 
Reviewed-by: Caolán McNamara 

diff --git a/vcl/inc/qt5/QtFrame.hxx b/vcl/inc/qt5/QtFrame.hxx
index 963572ca819b..b927d366765d 100644
--- a/vcl/inc/qt5/QtFrame.hxx
+++ b/vcl/inc/qt5/QtFrame.hxx
@@ -102,7 +102,7 @@ class VCLPLUG_QT_PUBLIC QtFrame : public QObject, public 
SalFrame
 QRect m_aRestoreGeometry;
 
 #if CHECK_ANY_QT_USING_X11
-ScreenSaverInhibitor m_ScreenSaverInhibitor;
+SessionManagerInhibitor m_SessionManagerInhibitor;
 ModKeyFlags m_nKeyModifiers;
 #endif
 
diff --git a/vcl/inc/unx/gtk/gtkframe.hxx b/vcl/inc/unx/gtk/gtkframe.hxx
index 00bbd26379ae..1a83a7fc39d3 100644
--- a/vcl/inc/unx/gtk/gtkframe.hxx
+++ b/vcl/inc/unx/gtk/gtkframe.hxx
@@ -202,7 +202,7 @@ class GtkSalFrame final : public SalFrame
 boolm_bGraphics;
 ModKeyFlags m_nKeyModifiers;
 PointerStylem_ePointerStyle;
-ScreenSaverInhibitorm_ScreenSaverInhibitor;
+SessionManagerInhibitor m_SessionManagerInhibitor;
 gulong  m_nSetFocusSignalId;
 boolm_bFullscreen;
 boolm_bDefaultPos;
diff --git a/vcl/inc/unx/salframe.h b/vcl/inc/unx/salframe.h
index 3bbf9729c971..d8a177d9a867 100644
--- a/vcl/inc/unx/salframe.h
+++ b/vcl/inc/unx/salframe.h
@@ -105,7 +105,7 @@ class X11SalFrame final : public SalFrame
 int m_nWorkArea;
 boolm_bSetFocusOnMap;
 
-ScreenSaverInhibitor maScreenSaverInhibitor;
+SessionManagerInhibitor maSessionManagerInhibitor;
 tools::Rectangle   maPaintRegion;
 
 Timer   maAlwaysOnTopRaiseTimer;
diff --git a/vcl/inc/unx/screensaverinhibitor.hxx 
b/vcl/inc/unx/screensaverinhibitor.hxx
index 4ddbb53f9c12..6cfa3e2fd700 100644
--- a/vcl/inc/unx/screensaverinhibitor.hxx
+++ b/vcl/inc/unx/screensaverinhibitor.hxx
@@ -19,17 +19,25 @@
 #include 
 #include 
 
-class VCL_PLUGIN_PUBLIC ScreenSaverInhibitor
+enum ApplicationInhibitFlags
+{
+APPLICATION_INHIBIT_LOGOUT = (1 << 0),
+APPLICATION_INHIBIT_SWITCH = (1 << 1),
+APPLICATION_INHIBIT_SUSPEND = (1 << 2),
+APPLICATION_INHIBIT_IDLE = (1 << 3) // Inhibit the session being marked as 
idle
+};
+
+class VCL_PLUGIN_PUBLIC SessionManagerInhibitor
 {
 public:
-void inhibit(bool bInhibit, std::u16string_view sReason, bool bIsX11,
- const std::optional& xid, 
std::optional pDisplay);
+void inhibit(bool bInhibit, std::u16string_view sReason, 
ApplicationInhibitFlags eType,
+ unsigned int window_system_id, std::optional 
pDisplay);
 
 private:
 // These are all used as guint, however this header may be included
 // in kde/tde/etc backends, where we would ideally avoid having
 // any glib dependencies, hence the direct use of unsigned int.
-std::optional mnFDOCookie; // FDO ScreenSaver Inhibit
+std::optional mnFDOSSCookie; // FDO ScreenSaver Inhibit
 std::optional mnFDOPMCookie; // FDO PowerManagement Inhibit
 std::optional mnGSMCookie;
 std::optional mnMSMCookie;
@@ -49,18 +57,20 @@ private:
 // all encompassing standard, hence we should just try all of them.
 //
 // The current APIs we have: (note: the list of supported environments is 
incomplete)
-// FDO: org.freedesktop.ScreenSaver::Inhibit - appears to be supported 
only by KDE?
+// FDSSO: org.freedesktop.ScreenSaver::Inhibit - appears to be supported 
only by KDE?
 // FDOPM: org.freedesktop.PowerManagement.Inhibit::Inhibit - XFCE, (KDE) ?
 //(KDE: doesn't inhibit screensaver, but does inhibit 
PowerManagement)
 // GSM: org.gnome.SessionManager::Inhibit - gnome 3
 // MSM: org.mate.Sessionmanager::Inhibit - Mate <= 1.10, is identical to 
GSM
 //   (This is replaced by the GSM interface from Mate 1.12 onwards)
 //
-// Note: the Uninhibit call has different

[Libreoffice-commits] core.git: 2 commits - vcl/source vcl/unx

2023-05-09 Thread Caolán McNamara (via logerrit)
 vcl/source/gdi/metaact.cxx  |3 +++
 vcl/unx/generic/window/screensaverinhibitor.cxx |   12 +++-
 2 files changed, 14 insertions(+), 1 deletion(-)

New commits:
commit 4a8a24be5a378308680a0b6e2e246d5d9df414c4
Author: Caolán McNamara 
AuthorDate: Mon May 8 10:43:07 2023 +0100
Commit: Caolán McNamara 
CommitDate: Tue May 9 11:20:08 2023 +0200

Related: tdf#142176 document what the other inhibit options are

via an enum like the gtk one so it can be seen how to inhibit logging
out due to unsaved changes

Change-Id: I07609cfb7a97b5b6c1b94a09b7b79bcca308d5d1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151559
Tested-by: Caolán McNamara 
Reviewed-by: Caolán McNamara 

diff --git a/vcl/unx/generic/window/screensaverinhibitor.cxx 
b/vcl/unx/generic/window/screensaverinhibitor.cxx
index ec19fad09e5d..a2274028b526 100644
--- a/vcl/unx/generic/window/screensaverinhibitor.cxx
+++ b/vcl/unx/generic/window/screensaverinhibitor.cxx
@@ -207,6 +207,16 @@ void ScreenSaverInhibitor::inhibitFDOPM( bool bInhibit, 
const char* appname, con
 #endif // ENABLE_GIO
 }
 
+#if ENABLE_GIO
+enum ApplicationInhibitFlags
+{
+APPLICATION_INHIBIT_LOGOUT  = (1 << 0),
+APPLICATION_INHIBIT_SWITCH  = (1 << 1),
+APPLICATION_INHIBIT_SUSPEND = (1 << 2),
+APPLICATION_INHIBIT_IDLE= (1 << 3) // Inhibit the session being marked 
as idle
+};
+#endif
+
 void ScreenSaverInhibitor::inhibitGSM( bool bInhibit, const char* appname, 
const char* reason, const unsigned int xid )
 {
 #if ENABLE_GIO
@@ -218,7 +228,7 @@ void ScreenSaverInhibitor::inhibitGSM( bool bInhibit, const 
char* appname, const
   appname,
   xid,
   reason,
-  8 //Inhibit 
the session being marked as idle
+  
APPLICATION_INHIBIT_IDLE
  ),
 G_DBUS_CALL_FLAGS_NONE, 
-1, nullptr, &error );
  },
commit b7ec54b7c6e85d507066442de3b7398f34bbb653
Author: Caolán McNamara 
AuthorDate: Tue May 9 08:45:34 2023 +0100
Commit: Caolán McNamara 
CommitDate: Tue May 9 11:19:57 2023 +0200

ofz#58756 Integer-overflow

Change-Id: Ie2782c1d68f73e5e88cf868eb1ce106ec0c181b0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151558
Tested-by: Caolán McNamara 
Reviewed-by: Caolán McNamara 

diff --git a/vcl/source/gdi/metaact.cxx b/vcl/source/gdi/metaact.cxx
index 107972fe8765..22093a95735e 100644
--- a/vcl/source/gdi/metaact.cxx
+++ b/vcl/source/gdi/metaact.cxx
@@ -973,6 +973,9 @@ MetaBmpScalePartAction::MetaBmpScalePartAction( const 
Point& rDstPt, const Size&
 
 void MetaBmpScalePartAction::Execute( OutputDevice* pOut )
 {
+if (!AllowRect(pOut->LogicToPixel(tools::Rectangle(maDstPt, maDstSz
+return;
+
 pOut->DrawBitmap( maDstPt, maDstSz, maSrcPt, maSrcSz, maBmp );
 }
 


Re: Bub report in libreoffice writer

2023-05-09 Thread Stéphane Guillou

On 9/5/23 07:32, JM M wrote:


It's the first time I report a bug in libreoffice writer, debug 
information are in the attach file.



It's happen when I scroll the pages of a text.


Thank You


Jean-Michel


Hi Jean-Michel

You can report the bug here: 
https://bugs.documentfoundation.org/enter_bug.cgi?product=LibreOffice&format=guided


You can attach the backtrace after the report is created (there will be 
a link for attachments).


Please make sure to include the version information copied from Help > 
About LibreOffice.


Thank you!

--
Stéphane Guillou
Quality Assurance Analyst | The Document Foundation

Email: stephane.guil...@libreoffice.org
Mobile (France): +33 7 79 67 18 72
Matrix: @stragu:matrix.org
Fediverse: @str...@mastodon.indie.host
Web: https://stragu.gitlab.io/



[Libreoffice-commits] core.git: sw/inc sw/qa sw/source

2023-05-09 Thread Michael Stahl (via logerrit)
 sw/inc/crsrsh.hxx|   14 -
 sw/qa/extras/odfimport/odfimport.cxx |4 
 sw/qa/extras/uiwriter/uiwriter3.cxx  |8 
 sw/source/core/crsr/crsrsh.cxx   |  281 ---
 sw/source/core/edit/eddel.cxx|   20 --
 sw/source/core/edit/edglss.cxx   |   20 --
 sw/source/uibase/wrtsh/move.cxx  |   46 +
 sw/source/uibase/wrtsh/select.cxx|   36 ++--
 8 files changed, 348 insertions(+), 81 deletions(-)

New commits:
commit d81379db730a163c5ff75d4f3a3cddbd7b5eddda
Author: Michael Stahl 
AuthorDate: Mon May 8 16:38:03 2023 +0200
Commit: Michael Stahl 
CommitDate: Tue May 9 10:34:40 2023 +0200

tdf#154877 sw: generalise ExtendedSelectAll()

This used to work only in the body text; make it work in any text, so
also text frame, header/footer, footnote, table cell.

(fixes regression from commit 0590cd2857f68f48b8847071a9c1a7dbef135721)

This is made much more difficult by table cells, which may contain
nested tables; there is already some code to switch between text
selection (via m_pCurrentCursor) and table cell selection (via
m_pTableCursor).

There were also a few things that looked kinda wrong, but i forgot
where.

One tricky case that can't be handled well is if there are multiple
tables in a text but no paragraph (this is impossible in the body but
possible in other texts by removing the paragraph via Ctrl+Shift+Delete)
... here the most we get is one table fully selected, because the
SwTableCursor can't select cells from multiple tables.

Change-Id: I0964baacecb8f10636792a27efa9ea6b18da4709
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151544
Tested-by: Jenkins
Reviewed-by: Michael Stahl 

diff --git a/sw/inc/crsrsh.hxx b/sw/inc/crsrsh.hxx
index 5f99deff126b..57bb90a11a5d 100644
--- a/sw/inc/crsrsh.hxx
+++ b/sw/inc/crsrsh.hxx
@@ -331,7 +331,7 @@ public:
 // only for usage in special cases allowed!
 void ExtendedSelectAll(bool bFootnotes = true);
 /// If ExtendedSelectAll() was called and selection didn't change since 
then.
-bool ExtendedSelectedAll();
+SwNode const* ExtendedSelectedAll() const;
 enum class StartsWith { None, Table, HiddenPara };
 /// If document body starts with a table or starts/ends with hidden 
paragraph.
 StartsWith StartsWith_();
@@ -593,8 +593,11 @@ public:
 // fields etc.
 OUString GetSelText() const;
 
-// Check of SPoint or Mark of current cursor are placed within a table.
-inline const SwTableNode* IsCursorInTable() const;
+/// Check if Point of current cursor is placed within a table.
+const SwTableNode* IsCursorInTable() const;
+bool MoveOutOfTable();
+bool TrySelectOuterTable();
+bool MoveStartText();
 
 bool IsCursorInFootnote() const;
 
@@ -912,11 +915,6 @@ inline bool SwCursorShell::IsMultiSelection() const
 return m_pCurrentCursor->GetNext() != m_pCurrentCursor;
 }
 
-inline const SwTableNode* SwCursorShell::IsCursorInTable() const
-{
-return m_pCurrentCursor->GetPointNode().FindTableNode();
-}
-
 inline bool SwCursorShell::IsCursorPtAtEnd() const
 {
 return m_pCurrentCursor->End() == m_pCurrentCursor->GetPoint();
diff --git a/sw/qa/extras/odfimport/odfimport.cxx 
b/sw/qa/extras/odfimport/odfimport.cxx
index add0d98789b6..7225be2d4b8e 100644
--- a/sw/qa/extras/odfimport/odfimport.cxx
+++ b/sw/qa/extras/odfimport/odfimport.cxx
@@ -732,6 +732,8 @@ CPPUNIT_TEST_FIXTURE(Test, testFdo37606)
 
 pWrtShell->SelAll(); // Selects the whole table.
 pWrtShell->SelAll(); // Selects the whole document.
+pShellCursor = pWrtShell->getShellCursor(false);
+
 SwTextNode& rStart = 
dynamic_cast(pShellCursor->Start()->GetNode());
 CPPUNIT_ASSERT_EQUAL(OUString("A1"), rStart.GetText());
 
@@ -798,11 +800,11 @@ CPPUNIT_TEST_FIXTURE(Test, testFdo69862)
 SwXTextDocument* pTextDoc = dynamic_cast(mxComponent.get());
 CPPUNIT_ASSERT(pTextDoc);
 SwWrtShell* pWrtShell = pTextDoc->GetDocShell()->GetWrtShell();
-SwShellCursor* pShellCursor = pWrtShell->getShellCursor(false);
 
 pWrtShell->SelAll(); // Selects A1.
 pWrtShell->SelAll(); // Selects the whole table.
 pWrtShell->SelAll(); // Selects the whole document.
+SwShellCursor* pShellCursor = pWrtShell->getShellCursor(false);
 SwTextNode& rStart = 
dynamic_cast(pShellCursor->Start()->GetNode());
 // This was "Footnote.", as Ctrl-A also selected footnotes, but it should 
not.
 CPPUNIT_ASSERT_EQUAL(OUString("A1"), rStart.GetText());
diff --git a/sw/qa/extras/uiwriter/uiwriter3.cxx 
b/sw/qa/extras/uiwriter/uiwriter3.cxx
index 9580cd93c67f..c1a8faef373a 100644
--- a/sw/qa/extras/uiwriter/uiwriter3.cxx
+++ b/sw/qa/extras/uiwriter/uiwriter3.cxx
@@ -246,10 +246,12 @@ CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testTdf114973)
 {
 createSwDoc("tdf114973.fodt");
 
-dispatchCommand(mxComponent, ".uno:SelectAll", {});

[Libreoffice-commits] core.git: external/libwpg

2023-05-09 Thread Stephan Bergmann (via logerrit)
 external/libwpg/UnpackedTarball_libwpg.mk |4 
 external/libwpg/rpath.patch   |   10 ++
 2 files changed, 14 insertions(+)

New commits:
commit edf471ba8b5a69ce26e68eff26283b304c4c9a9e
Author: Stephan Bergmann 
AuthorDate: Tue May 9 08:34:43 2023 +0200
Commit: Stephan Bergmann 
CommitDate: Tue May 9 10:30:56 2023 +0200

Reinstate external/libwpg/rpath.patch

...which 0c0c9a0dd8a7b102315ab1075f78a0f1f3397b67 "tdf#155057: Wrong colors 
in
some WPG2 (well rendered in WPG1)" had dropped for no apparent reason, 
causing

> [CHK] CustomTarget/postprocess/check_dynamic_objects/check.done
> ~/lo/core/instdir/program/libwpg-0.3-lo.so.3 has unexpected RPATH  
0x001d (RUNPATH)Library runpath: 
[~/lo/core/workdir/UnpackedTarball/libwpd/src/lib/.libs:~/lo/core/workdir/UnpackedTarball/librevenge/src/lib/.libs:/usr/local/lib:$ORIGIN]

to fail (in Linux builds that execute that test)

Change-Id: Id9f87b14f571b328b98496625351bc1f87bf8c61
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151555
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann 

diff --git a/external/libwpg/UnpackedTarball_libwpg.mk 
b/external/libwpg/UnpackedTarball_libwpg.mk
index e3790c831296..9ca55c669d72 100644
--- a/external/libwpg/UnpackedTarball_libwpg.mk
+++ b/external/libwpg/UnpackedTarball_libwpg.mk
@@ -15,6 +15,10 @@ $(eval $(call gb_UnpackedTarball_set_patchlevel,libwpg,0))
 
 $(eval $(call gb_UnpackedTarball_update_autoconf_configs,libwpg))
 
+$(eval $(call gb_UnpackedTarball_add_patches,libwpg, \
+external/libwpg/rpath.patch \
+))
+
 ifneq ($(OS),MACOSX)
 ifneq ($(OS),WNT)
 ifneq ($(OS),iOS)
diff --git a/external/libwpg/rpath.patch b/external/libwpg/rpath.patch
new file mode 100644
index ..5a8f56105509
--- /dev/null
+++ b/external/libwpg/rpath.patch
@@ -0,0 +1,10 @@
+--- configure
 configure
+@@ -13858,6 +13858,7 @@
+   esac
+   ;;
+   esac
++hardcode_libdir_flag_spec_CXX=
+   ;;
+ 
+   lynxos*)


[Libreoffice-commits] core.git: Branch 'libreoffice-7-5' - dbaccess/source

2023-05-09 Thread Julien Nabet (via logerrit)
 dbaccess/source/ui/uno/copytablewizard.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 656fe420f0cb7d1c4f69f6aa5777c47eac90189f
Author: Julien Nabet 
AuthorDate: Sun Jan 15 10:46:46 2023 +0100
Commit: Xisco Fauli 
CommitDate: Tue May 9 10:00:27 2023 +0200

tdf#153004: error when copying content to a table without autovalue primary 
key

In fact, hsql is well managed without extra code.

Change-Id: I93e2b02f3ec78e263cd0f9fab6e33b708dbd3f11
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145525
Reviewed-by: Julien Nabet 
Tested-by: Jenkins
(cherry picked from commit 9d2355b674d103fe8a73d2db716389980bb69e55)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151514
Reviewed-by: Xisco Fauli 

diff --git a/dbaccess/source/ui/uno/copytablewizard.cxx 
b/dbaccess/source/ui/uno/copytablewizard.cxx
index c886995398a7..85000f2dc9f8 100644
--- a/dbaccess/source/ui/uno/copytablewizard.cxx
+++ b/dbaccess/source/ui/uno/copytablewizard.cxx
@@ -1361,7 +1361,7 @@ void CopyTableWizard::impl_doCopy_nothrow()
 OUString sDatabaseDest = 
xDestMetaData->getDatabaseProductName().toAsciiLowerCase();
 // If we created a new primary key, then it won't necessarily 
be an IDENTITY column
 const bool bShouldCreatePrimaryKey = 
rWizard.shouldCreatePrimaryKey();
-if ( !bShouldCreatePrimaryKey && 
((sDatabaseDest.indexOf("hsql") != -1) || (sDatabaseDest.indexOf("firebird") != 
-1)) )
+if ( !bShouldCreatePrimaryKey && 
(sDatabaseDest.indexOf("firebird") != -1) )
 {
 const OUString sComposedTableName = 
::dbtools::composeTableName( xDestMetaData, xTable, 
::dbtools::EComposeRule::InDataManipulation, true );
 


[Libreoffice-commits] core.git: compilerplugins/clang svx/inc svx/Library_svxcore.mk svx/qa svx/source

2023-05-09 Thread Noel Grandin (via logerrit)
 compilerplugins/clang/mergeclasses.results|1 
 svx/Library_svxcore.mk|3 
 svx/inc/gallerybinaryengine.hxx   |8 -
 svx/inc/gallerybinaryengineentry.hxx  |7 -
 svx/inc/gallerybinarystoragelocations.hxx |   52 
 svx/inc/gallerystoragelocations.hxx   |   26 +-
 svx/qa/unit/gallery/test_gallery.cxx  |   13 +--
 svx/source/gallery2/gallerybinaryengine.cxx   |2 
 svx/source/gallery2/gallerybinaryengineentry.cxx  |5 -
 svx/source/gallery2/gallerybinarystoragelocations.cxx |   75 --
 svx/source/gallery2/gallerystoragelocations.cxx   |   53 
 11 files changed, 91 insertions(+), 154 deletions(-)

New commits:
commit 440c23ee678442fc64aa9fcca13b137738e10a04
Author: Noel Grandin 
AuthorDate: Mon May 8 12:18:42 2023 +0200
Commit: Noel Grandin 
CommitDate: Tue May 9 09:11:48 2023 +0200

merge GalleryStorageLocations with GalleryBinaryStorageLocations

Change-Id: Icf9a942047f212132d7b543cd1b1a857f8f95223
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151551
Tested-by: Jenkins
Reviewed-by: Noel Grandin 

diff --git a/compilerplugins/clang/mergeclasses.results 
b/compilerplugins/clang/mergeclasses.results
index 7b002c436974..e92d1bfc19b7 100644
--- a/compilerplugins/clang/mergeclasses.results
+++ b/compilerplugins/clang/mergeclasses.results
@@ -56,7 +56,6 @@ merge FmXFormShell_Base_Disambiguation with FmXFormShell
 merge GLWindow with GLX11Window
 merge GalleryFileStorage with GalleryBinaryEngine
 merge GalleryFileStorageEntry with GalleryBinaryEngineEntry
-merge GalleryStorageLocations with GalleryBinaryStorageLocations
 merge GroupTable with PPTWriterBase
 merge HostDetailsContainer with DavDetailsContainer
 merge IDocumentChartDataProviderAccess with 
sw::DocumentChartDataProviderManager
diff --git a/svx/Library_svxcore.mk b/svx/Library_svxcore.mk
index 270a2056ef60..757244f5f6d0 100644
--- a/svx/Library_svxcore.mk
+++ b/svx/Library_svxcore.mk
@@ -206,11 +206,10 @@ $(eval $(call gb_Library_add_exception_objects,svxcore,\
 svx/source/gallery2/GalleryControl \
 svx/source/gallery2/gallerybinaryengine \
 svx/source/gallery2/gallerybinaryengineentry \
-svx/source/gallery2/gallerystoragelocations \
-svx/source/gallery2/gallerybinarystoragelocations \
 svx/source/gallery2/galleryobjectcollection \
 svx/source/gallery2/galleryfilestorage \
 svx/source/gallery2/galleryfilestorageentry \
+svx/source/gallery2/gallerystoragelocations \
 svx/source/items/chrtitem \
 svx/source/items/clipfmtitem \
 svx/source/items/customshapeitem \
diff --git a/svx/inc/gallerybinaryengine.hxx b/svx/inc/gallerybinaryengine.hxx
index 2863e8dc9d69..f1f221e34447 100644
--- a/svx/inc/gallerybinaryengine.hxx
+++ b/svx/inc/gallerybinaryengine.hxx
@@ -22,7 +22,7 @@
 #include 
 #include 
 #include 
-#include "gallerybinarystoragelocations.hxx"
+#include "gallerystoragelocations.hxx"
 #include "galleryfilestorage.hxx"
 #include 
 #include 
@@ -32,8 +32,6 @@
 
 #include 
 
-class GalleryStorageLocations;
-class GalleryBinaryStorageLocations;
 class GalleryObjectCollection;
 class SgaObjectSvDraw;
 class SgaObjectBmp;
@@ -48,7 +46,7 @@ class SVXCORE_DLLPUBLIC GalleryBinaryEngine final : public 
GalleryFileStorage
 {
 private:
 tools::SvRef m_aSvDrawStorageRef;
-const GalleryBinaryStorageLocations& maGalleryStorageLocations;
+const GalleryStorageLocations& maGalleryStorageLocations;
 GalleryObjectCollection& mrGalleryObjectCollection;
 bool mbReadOnly;
 OUString m_aDestDir;
@@ -60,7 +58,7 @@ private:
 const INetURLObject& GetThmURL() const { return 
maGalleryStorageLocations.GetThmURL(); }
 
 public:
-GalleryBinaryEngine(const GalleryBinaryStorageLocations& 
rGalleryStorageLocations,
+GalleryBinaryEngine(const GalleryStorageLocations& 
rGalleryStorageLocations,
 GalleryObjectCollection& rGalleryObjectCollection, 
bool bReadOnly);
 SAL_DLLPRIVATE ~GalleryBinaryEngine();
 
diff --git a/svx/inc/gallerybinaryengineentry.hxx 
b/svx/inc/gallerybinaryengineentry.hxx
index 8b5b3d3f607b..e21d6a64fea7 100644
--- a/svx/inc/gallerybinaryengineentry.hxx
+++ b/svx/inc/gallerybinaryengineentry.hxx
@@ -22,17 +22,16 @@
 #include 
 #include 
 #include "gallerybinaryengine.hxx"
-#include "gallerybinarystoragelocations.hxx"
+#include "gallerystoragelocations.hxx"
 #include "galleryfilestorageentry.hxx"
 
-class GalleryBinaryStorageLocations;
 class GalleryObjectCollection;
 class GalleryBinaryEngine;
 
 class GalleryBinaryEngineEntry final : public GalleryFileStorageEntry
 {
 private:
-std::unique_ptr mpGalleryStorageLocations;
+std::unique_ptr mpGalleryStorageLocations;
 
 public:
 GalleryBinaryEngineEntry();
@@ -45,7 +44,7 @@ public:
 const INetURLObject& GetSdvURL() const { return 
mpGalleryStorageLocations->Ge