[Libreoffice-commits] core.git: Branch 'distro/cib/libreoffice-6-4' - icon-themes/breeze icon-themes/colibre icon-themes/elementary icon-themes/karasa_jaga icon-themes/sifr icon-themes/tango instsetoo

2022-08-24 Thread Gabor Kelemen (via logerrit)
 icon-themes/breeze/sfx2/res/logo.png|binary
 icon-themes/colibre/sfx2/res/logo.png   |binary
 icon-themes/elementary/sfx2/res/logo.png|binary
 icon-themes/karasa_jaga/sfx2/res/logo.png   |binary
 icon-themes/sifr/sfx2/res/logo.png  |binary
 icon-themes/tango/sfx2/res/logo.png |binary
 instsetoo_native/inc_common/windows/msi_templates/Binary/Banner.bmp |binary
 instsetoo_native/inc_common/windows/msi_templates/Binary/Image.bmp  |binary
 8 files changed

New commits:
commit b6ecd935b74aa398aed331c580efef65f61f3f6f
Author: Gabor Kelemen 
AuthorDate: Thu Aug 25 08:42:02 2022 +0200
Commit: Gabor Kelemen 
CommitDate: Thu Aug 25 08:53:40 2022 +0200

[CIBO] Branding images for msi installer and startcenter bg

inspiration from 6da13ca3dc073a8dd38da6779cb63d7de024207e

Change-Id: I247ef5e1ae200355b625e3d1f284ca37fea29f73

diff --git a/icon-themes/breeze/sfx2/res/logo.png 
b/icon-themes/breeze/sfx2/res/logo.png
index ace737a89fd9..e2cd4aaa3aea 100755
Binary files a/icon-themes/breeze/sfx2/res/logo.png and 
b/icon-themes/breeze/sfx2/res/logo.png differ
diff --git a/icon-themes/colibre/sfx2/res/logo.png 
b/icon-themes/colibre/sfx2/res/logo.png
index ace737a89fd9..e2cd4aaa3aea 100644
Binary files a/icon-themes/colibre/sfx2/res/logo.png and 
b/icon-themes/colibre/sfx2/res/logo.png differ
diff --git a/icon-themes/elementary/sfx2/res/logo.png 
b/icon-themes/elementary/sfx2/res/logo.png
index ace737a89fd9..e2cd4aaa3aea 100755
Binary files a/icon-themes/elementary/sfx2/res/logo.png and 
b/icon-themes/elementary/sfx2/res/logo.png differ
diff --git a/icon-themes/karasa_jaga/sfx2/res/logo.png 
b/icon-themes/karasa_jaga/sfx2/res/logo.png
index ace737a89fd9..e2cd4aaa3aea 100644
Binary files a/icon-themes/karasa_jaga/sfx2/res/logo.png and 
b/icon-themes/karasa_jaga/sfx2/res/logo.png differ
diff --git a/icon-themes/sifr/sfx2/res/logo.png 
b/icon-themes/sifr/sfx2/res/logo.png
index ace737a89fd9..e2cd4aaa3aea 100755
Binary files a/icon-themes/sifr/sfx2/res/logo.png and 
b/icon-themes/sifr/sfx2/res/logo.png differ
diff --git a/icon-themes/tango/sfx2/res/logo.png 
b/icon-themes/tango/sfx2/res/logo.png
index ace737a89fd9..e2cd4aaa3aea 100644
Binary files a/icon-themes/tango/sfx2/res/logo.png and 
b/icon-themes/tango/sfx2/res/logo.png differ
diff --git 
a/instsetoo_native/inc_common/windows/msi_templates/Binary/Banner.bmp 
b/instsetoo_native/inc_common/windows/msi_templates/Binary/Banner.bmp
index f734f3a2eeaf..8f9ce2d0ba44 100644
Binary files 
a/instsetoo_native/inc_common/windows/msi_templates/Binary/Banner.bmp and 
b/instsetoo_native/inc_common/windows/msi_templates/Binary/Banner.bmp differ
diff --git a/instsetoo_native/inc_common/windows/msi_templates/Binary/Image.bmp 
b/instsetoo_native/inc_common/windows/msi_templates/Binary/Image.bmp
index f1aa5699dff7..a6cf9c7a816c 100644
Binary files 
a/instsetoo_native/inc_common/windows/msi_templates/Binary/Image.bmp and 
b/instsetoo_native/inc_common/windows/msi_templates/Binary/Image.bmp differ


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

2022-08-24 Thread Miklos Vajna (via logerrit)
 oox/source/shape/WpgContext.cxx |2 +-
 oox/source/shape/WpgContext.hxx |2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 71954eae45173618f7da1a839d674e888f64bab2
Author: Miklos Vajna 
AuthorDate: Wed Aug 24 20:57:04 2022 +0200
Commit: Miklos Vajna 
CommitDate: Thu Aug 25 08:13:02 2022 +0200

oox: avoid unnecessary value parameter

This parameter is copied for each invocation but only used as a const
reference; make it a const reference.

Change-Id: Iff80fb1b8d2374b93eca718b932659aca8142713
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138775
Tested-by: Jenkins
Reviewed-by: Miklos Vajna 

diff --git a/oox/source/shape/WpgContext.cxx b/oox/source/shape/WpgContext.cxx
index cf65491e0f26..8d83758b7316 100644
--- a/oox/source/shape/WpgContext.cxx
+++ b/oox/source/shape/WpgContext.cxx
@@ -20,7 +20,7 @@ using namespace com::sun::star;
 
 namespace oox::shape
 {
-WpgContext::WpgContext(FragmentHandler2 const& rParent, 
oox::drawingml::ShapePtr pMaster)
+WpgContext::WpgContext(FragmentHandler2 const& rParent, const 
oox::drawingml::ShapePtr& pMaster)
 : FragmentHandler2(rParent)
 , m_bFullWPGSupport(false)
 {
diff --git a/oox/source/shape/WpgContext.hxx b/oox/source/shape/WpgContext.hxx
index 643a2a49357b..edd11644b214 100644
--- a/oox/source/shape/WpgContext.hxx
+++ b/oox/source/shape/WpgContext.hxx
@@ -20,7 +20,7 @@ class WpgContext final : public oox::core::FragmentHandler2
 {
 public:
 explicit WpgContext(oox::core::FragmentHandler2 const& rParent,
-oox::drawingml::ShapePtr pMaster);
+const oox::drawingml::ShapePtr& pMaster);
 ~WpgContext() override;
 
 oox::core::ContextHandlerRef onCreateContext(sal_Int32 nElementToken,


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

2022-08-24 Thread Noel Grandin (via logerrit)
 sw/source/core/inc/unoparaframeenum.hxx |7 ++-
 sw/source/core/unocore/unoobj2.cxx  |   18 --
 2 files changed, 10 insertions(+), 15 deletions(-)

New commits:
commit 497fd09add19ccb834aa40226b60c642299e210e
Author: Noel Grandin 
AuthorDate: Wed Aug 24 21:18:16 2022 +0200
Commit: Noel Grandin 
CommitDate: Thu Aug 25 07:58:14 2022 +0200

no need to use shared_ptr for m_vFrames

we can use unique_ptr and move the objects around

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

diff --git a/sw/source/core/inc/unoparaframeenum.hxx 
b/sw/source/core/inc/unoparaframeenum.hxx
index 80da5eb50525..81a653aac57f 100644
--- a/sw/source/core/inc/unoparaframeenum.hxx
+++ b/sw/source/core/inc/unoparaframeenum.hxx
@@ -42,19 +42,16 @@ struct FrameClientSortListEntry
 {
 sal_Int32 nIndex;
 sal_uInt32 nOrder;
-std::shared_ptr pFrameClient;
+std::unique_ptr pFrameClient;
 
 FrameClientSortListEntry (sal_Int32 const i_nIndex,
-sal_uInt32 const i_nOrder, std::shared_ptr 
i_pClient)
+sal_uInt32 const i_nOrder, std::unique_ptr 
i_pClient)
 : nIndex(i_nIndex), nOrder(i_nOrder), 
pFrameClient(std::move(i_pClient)) { }
 };
 
 typedef std::deque< FrameClientSortListEntry >
 FrameClientSortList_t;
 
-typedef std::deque< std::shared_ptr >
-FrameClientList_t;
-
 // #i28701# - adjust 4th parameter
 void CollectFrameAtNode( const SwNode& rNd,
  FrameClientSortList_t& rFrames,
diff --git a/sw/source/core/unocore/unoobj2.cxx 
b/sw/source/core/unocore/unoobj2.cxx
index a20e89d1ca1c..cec097c7faba 100644
--- a/sw/source/core/unocore/unoobj2.cxx
+++ b/sw/source/core/unocore/unoobj2.cxx
@@ -127,8 +127,7 @@ struct FrameClientSortListLess
 const auto nIdx =
 rFormat.GetAnchor().GetContentAnchor()->GetContentIndex();
 const auto nOrder = rFormat.GetAnchor().GetOrder();
-FrameClientSortListEntry entry(nIdx, nOrder, 
std::make_shared(&rFormat));
-rFrames.push_back(entry);
+rFrames.emplace_back(nIdx, nOrder, 
std::make_unique(&rFormat));
 }
 }
 }
@@ -174,8 +173,7 @@ void CollectFrameAtNode( const SwNode& rNd,
 const sal_Int32 nIndex = pAnchorPos->GetContentIndex();
 sal_uInt32 nOrder = rAnchor.GetOrder();
 
-FrameClientSortListEntry entry(nIndex, nOrder, 
std::make_shared(const_cast(pFormat)));
-rFrames.push_back(entry);
+rFrames.emplace_back(nIndex, nOrder, 
std::make_unique(const_cast(pFormat)));
 }
 }
 std::sort(rFrames.begin(), rFrames.end(), FrameClientSortListLess());
@@ -1707,14 +1705,14 @@ struct SwXParaFrameEnumerationImpl final : public 
SwXParaFrameEnumeration
 {
 // removing orphaned Clients
 const auto iter = std::remove_if(m_vFrames.begin(), 
m_vFrames.end(),
-[] (std::shared_ptr& rEntry) -> bool { 
return !rEntry->GetRegisteredIn(); });
+[] (std::unique_ptr& rEntry) -> bool { 
return !rEntry->GetRegisteredIn(); });
 m_vFrames.erase(iter, m_vFrames.end());
 }
 }
 void FillFrame();
 bool CreateNextObject();
 uno::Reference< text::XTextContent > m_xNextObject;
-FrameClientList_t m_vFrames;
+std::deque< std::unique_ptr > m_vFrames;
 ::sw::UnoCursorPointer m_pUnoCursor;
 };
 
@@ -1739,11 +1737,11 @@ 
SwXParaFrameEnumerationImpl::SwXParaFrameEnumerationImpl(
 ::CollectFrameAtNode(rPaM.GetPoint()->GetNode(), vFrames, false);
 std::transform(vFrames.begin(), vFrames.end(),
 std::back_inserter(m_vFrames),
-[] (const FrameClientSortListEntry& rEntry) { return 
rEntry.pFrameClient; });
+[] (FrameClientSortListEntry& rEntry) { return 
std::move(rEntry.pFrameClient); });
 }
 else if (pFormat)
 {
-m_vFrames.push_back(std::make_shared(pFormat));
+m_vFrames.push_back(std::make_unique(pFormat));
 }
 else if ((PARAFRAME_PORTION_CHAR == eParaFrameMode) ||
  (PARAFRAME_PORTION_TEXTRANGE == eParaFrameMode))
@@ -1754,7 +1752,7 @@ SwXParaFrameEnumerationImpl::SwXParaFrameEnumerationImpl(
 for(const SwPosFlyFrame& rFlyFrame : 
rPaM.GetDoc().GetAllFlyFormats(&GetCursor(), false, true))
 {
 const auto pFrameFormat = 
const_cast(&rFlyFrame.GetFormat());
-
m_vFrames.push_back(std::make_shared(pFrameFormat));
+
m_vFrames.push_back(std::make_unique(pFrameFormat));
 }
 }
 FillFrame();
@@ -1774,7 +1772,7 @@ void SwXParaFrameEnumerationImpl::FillFrame()
 return;
 const SwFormatFlyCnt& rFlyCnt = pTextAttr->GetFlyCnt();
 SwFrameFormat* const pFram

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

2022-08-24 Thread Noel Grandin (via logerrit)
 sw/inc/flypos.hxx   |   22 --
 sw/qa/extras/ww8export/ww8export.cxx|4 ++--
 sw/qa/extras/ww8import/ww8import.cxx|8 
 sw/source/core/doc/DocumentDrawModelManager.cxx |4 ++--
 sw/source/core/doc/doclay.cxx   |   10 +-
 sw/source/core/layout/flypos.cxx|   24 +++-
 sw/source/core/unocore/unoobj2.cxx  |4 ++--
 sw/source/filter/html/htmlfly.cxx   |2 +-
 sw/source/filter/html/htmlflywriter.cxx |6 +++---
 sw/source/filter/ww8/writerhelper.cxx   |6 +++---
 10 files changed, 37 insertions(+), 53 deletions(-)

New commits:
commit 3369a24c48781fd5b8afe9bb707f92588825f6c3
Author: Noel Grandin 
AuthorDate: Wed Aug 24 21:03:01 2022 +0200
Commit: Noel Grandin 
CommitDate: Thu Aug 25 07:57:57 2022 +0200

Use SwNode instead of SwNodeIndex in SwPosFlyFrame

part of hiding the internals of SwPosition.

Also
(*) Just define the whole class in the header, it is a
dead simple data carrier.
Then the virtual destructor and the SAL_DLLPUBLIC_RTTI
becomes unnecessary.
(*) No need to use shared_ptr, these are never
shared, the call sites read the data and then discard
them.

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

diff --git a/sw/inc/flypos.hxx b/sw/inc/flypos.hxx
index fc098c4ffaab..d04ff03bff24 100644
--- a/sw/inc/flypos.hxx
+++ b/sw/inc/flypos.hxx
@@ -24,31 +24,25 @@
 #include 
 
 class SwFrameFormat;
-class SwNodeIndex;
+class SwNode;
 
 /// For querying current flys in document.
-class SAL_DLLPUBLIC_RTTI SwPosFlyFrame final
+class SwPosFlyFrame final
 {
 const SwFrameFormat* m_pFrameFormat;///< FlyFrameFormat
-SwNodeIndex* m_pNodeIndex;///< Index for node is sufficient.
+const SwNode* m_pNode;
 sal_uInt32 m_nOrdNum;
+
 public:
-SwPosFlyFrame( const SwNodeIndex& , const SwFrameFormat*, sal_uInt16 
nArrPos );
-virtual ~SwPosFlyFrame(); ///< Virtual for Writer (DLL !!)
+SwPosFlyFrame(const SwNode& rNd, const SwFrameFormat* pFormat, sal_uInt16 
nArrPos);
 
 const SwFrameFormat& GetFormat() const { return *m_pFrameFormat; }
-const SwNodeIndex& GetNdIndex() const { return *m_pNodeIndex; }
+const SwNode& GetNode() const { return *m_pNode; }
 sal_uInt32 GetOrdNum() const { return m_nOrdNum; }
 };
 
-// define needed classes to safely handle an array of allocated 
SwPosFlyFrame(s).
-// SwPosFlyFrames can be handled by value (as return value), only refcounts to
-// contained SwPosFlyFrame* will be copied. When releasing the last 
SwPosFlyFramePtr
-// instance the allocated instance will be freed. The array is sorted by
-// GetNdIndex by using a std::set container.
-typedef std::shared_ptr< SwPosFlyFrame > SwPosFlyFramePtr;
-struct SwPosFlyFrameCmp { bool operator()(const SwPosFlyFramePtr& rA, const 
SwPosFlyFramePtr& rB) const; };
-typedef std::set< SwPosFlyFramePtr, SwPosFlyFrameCmp > SwPosFlyFrames;
+struct SwPosFlyFrameCmp { bool operator()(const SwPosFlyFrame& rA, const 
SwPosFlyFrame& rB) const; };
+typedef std::set< SwPosFlyFrame, SwPosFlyFrameCmp > SwPosFlyFrames;
 
 #endif // INCLUDED_SW_INC_FLYPOS_HXX
 
diff --git a/sw/qa/extras/ww8export/ww8export.cxx 
b/sw/qa/extras/ww8export/ww8export.cxx
index 998b67971e3f..802717ad1ed5 100644
--- a/sw/qa/extras/ww8export/ww8export.cxx
+++ b/sw/qa/extras/ww8export/ww8export.cxx
@@ -809,9 +809,9 @@ DECLARE_WW8EXPORT_TEST(testTdf122425_2, "tdf122425_2.doc")
 SwPosFlyFrames aPosFlyFrames = pDoc->GetAllFlyFormats(nullptr, false);
 // There is one fly frame in the document: the text box
 CPPUNIT_ASSERT_EQUAL(size_t(1), aPosFlyFrames.size());
-for (const auto& rPosFlyFrame : aPosFlyFrames)
+for (const SwPosFlyFrame& rPosFlyFrame : aPosFlyFrames)
 {
-const SwFrameFormat& rFormat = rPosFlyFrame->GetFormat();
+const SwFrameFormat& rFormat = rPosFlyFrame.GetFormat();
 const SfxPoolItem* pItem = nullptr;
 
 // Check for correct explicitly-set values of UL spacings. Previously 
this was "DEFAULT",
diff --git a/sw/qa/extras/ww8import/ww8import.cxx 
b/sw/qa/extras/ww8import/ww8import.cxx
index ab35fa9d7346..c41b86d2f8e2 100644
--- a/sw/qa/extras/ww8import/ww8import.cxx
+++ b/sw/qa/extras/ww8import/ww8import.cxx
@@ -156,9 +156,9 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf121734)
 SwPosFlyFrames aPosFlyFrames = pDoc->GetAllFlyFormats(nullptr, false);
 // There is only one fly frame in the document: the one with the imported 
floating table
 CPPUNIT_ASSERT_EQUAL(size_t(1), aPosFlyFrames.size());
-for (const auto& rPosFlyFrame : aPosFlyFrames)
+for (const SwPosFlyFrame& rPosFlyFrame : aPosFlyFrames)
 {
-const SwFrameFormat& rFormat = rPosFlyFrame->GetFormat();
+const Sw

[Libreoffice-commits] core.git: configure.ac

2022-08-24 Thread Rene Engelhard (via logerrit)
 configure.ac |7 +++
 1 file changed, 3 insertions(+), 4 deletions(-)

New commits:
commit f7e170eb084cd4e92818de966b287330184749a8
Author: Rene Engelhard 
AuthorDate: Wed Aug 24 09:55:33 2022 +0200
Commit: René Engelhard 
CommitDate: Thu Aug 25 07:52:18 2022 +0200

Make configure work with gpgme >= 1.18

Sam James wrote:
> gpgme-1.18.0 dropped a bunch of internal symbols,
> including progress_callback (see e.g. callbacks.h
> which has a comment at the top saying it's internal).

Plausibly the workaround to not link against older KDE-specific distro
packages is not needed anymore.

Check for main as a workaround as we do for other C++ libraries, too.

Change-Id: I57065a5b5b23b9eadb73b01e4f3a289552c3bde4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138667
Tested-by: Jenkins
Reviewed-by: Sam James 
Reviewed-by: René Engelhard 

diff --git a/configure.ac b/configure.ac
index 24cb01aa0db0..61806988b94b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -12539,12 +12539,11 @@ elif test \( \( "$_os" = "Linux" -o "$_os" = "Darwin" 
\) -a "$ENABLE_NSS" = TRUE
 # C++ library doesn't come with fancy gpgmepp-config, check for 
headers the old-fashioned way
 AC_CHECK_HEADER(gpgme++/gpgmepp_version.h, [ 
GPGMEPP_CFLAGS=-I/usr/include/gpgme++ ],
 [AC_MSG_ERROR([gpgmepp headers not found, install gpgmepp >= 1.14 
development package])], [])
-# progress_callback is the only func with plain C linkage
-# checking for it also filters out older, KDE-dependent libgpgmepp 
versions
-AC_CHECK_LIB(gpgmepp, progress_callback, [ GPGMEPP_LIBS=-lgpgmepp ],
-[AC_MSG_ERROR(gpgmepp not found or not functional)], [])
 AC_CHECK_HEADER(gpgme.h, [],
 [AC_MSG_ERROR([gpgme headers not found, install gpgme development 
package])], [])
+AC_CHECK_LIB(gpgmepp, main, [],
+[AC_MSG_ERROR(gpgmepp not found or not functional)], [])
+   GPGMEPP_LIBS=-lgpgmepp
 else
 AC_MSG_RESULT([internal])
 BUILD_TYPE="$BUILD_TYPE LIBGPGERROR LIBASSUAN GPGMEPP"


[Libreoffice-commits] core.git: Branch 'distro/collabora/co-22.05' - officecfg/registry

2022-08-24 Thread Mike Kaganski (via logerrit)
 officecfg/registry/data/org/openoffice/Office/UI/MathCommands.xcu |5 +
 1 file changed, 5 insertions(+)

New commits:
commit 144feb83c3d627dcec35bc1ff31c9281b216e717
Author: Mike Kaganski 
AuthorDate: Wed Aug 24 20:21:02 2022 +0300
Commit: Mike Kaganski 
CommitDate: Thu Aug 25 07:30:47 2022 +0200

Add .uno:SidebarDeck.ElementsDeck to MathCommands.xcu

Change-Id: I341daedb72bc09183b881bf19514936b683ffc31
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138774
Tested-by: Jenkins
Reviewed-by: Mike Kaganski 
(cherry picked from commit d053e987941ab93901756f81eef755f8e914c702)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138552
Tested-by: Jenkins CollaboraOffice 

diff --git a/officecfg/registry/data/org/openoffice/Office/UI/MathCommands.xcu 
b/officecfg/registry/data/org/openoffice/Office/UI/MathCommands.xcu
index 8adebca5535a..edf6b520fb9f 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/MathCommands.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/MathCommands.xcu
@@ -203,6 +203,11 @@
   ~Others
 
   
+  
+
+  Open the Elements Deck
+
+  
 
   
 


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

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/source/view/main/SeriesPlotterContainer.cxx |6 ++
 chart2/source/view/main/SeriesPlotterContainer.hxx |1 +
 2 files changed, 7 insertions(+)

New commits:
commit 073df6cd47f14f8401c158336b8440187008a9e6
Author: Tomaž Vajngerl 
AuthorDate: Sat Aug 13 23:29:01 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Thu Aug 25 07:28:50 2022 +0200

chart2: for a data table we need to force shift category position

To be able to show the data table correctly we need to always
show the categories "between tick marks" as otherwise the table
columns wouldn't align correctly. This forces that the shift
position is always enabled.

Change-Id: Ia6a627931fcaba64f0f974faf1d8763405ad410d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138337
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 
(cherry picked from commit d50bfb406900ddea3a4b2e0c59e0b983798780d4)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138784
Tested-by: Jenkins CollaboraOffice 

diff --git a/chart2/source/view/main/SeriesPlotterContainer.cxx 
b/chart2/source/view/main/SeriesPlotterContainer.cxx
index b72d2f1bba42..ca1044d11046 100644
--- a/chart2/source/view/main/SeriesPlotterContainer.cxx
+++ b/chart2/source/view/main/SeriesPlotterContainer.cxx
@@ -167,6 +167,9 @@ void 
SeriesPlotterContainer::initializeCooSysAndSeriesPlotter(ChartModel& rChart
 DBG_UNHANDLED_EXCEPTION("chart2");
 }
 
+if (xDiagram->getDataTable().is())
+m_bForceShiftPosition = true;
+
 //prepare for autoscaling and shape creation
 // - create plotter for charttypes (for each first scale group at each 
plotter, as they are independent)
 // - add series to plotter (thus each charttype can provide minimum and 
maximum values for autoscaling)
@@ -354,6 +357,9 @@ void 
SeriesPlotterContainer::initializeCooSysAndSeriesPlotter(ChartModel& rChart
 bool SeriesPlotterContainer::isCategoryPositionShifted(const 
chart2::ScaleData& rSourceScale,
bool 
bHasComplexCategories)
 {
+if (m_bForceShiftPosition)
+return true;
+
 if (rSourceScale.AxisType == AxisType::CATEGORY)
 return bHasComplexCategories || rSourceScale.ShiftedCategoryPosition
|| m_bChartTypeUsesShiftedCategoryPositionPerDefault;
diff --git a/chart2/source/view/main/SeriesPlotterContainer.hxx 
b/chart2/source/view/main/SeriesPlotterContainer.hxx
index ccecac059027..64ab89583aee 100644
--- a/chart2/source/view/main/SeriesPlotterContainer.hxx
+++ b/chart2/source/view/main/SeriesPlotterContainer.hxx
@@ -156,6 +156,7 @@ private:
 sal_Int32 m_nMaxAxisIndex;
 
 bool m_bChartTypeUsesShiftedCategoryPositionPerDefault;
+bool m_bForceShiftPosition = false;
 sal_Int32 m_nDefaultDateNumberFormat;
 };
 


[Libreoffice-commits] core.git: Branch 'distro/collabora/co-22.05' - 2 commits - chart2/source

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/source/controller/itemsetwrapper/SchWhichPairs.hxx |1 
 chart2/source/view/axes/VAxisProperties.cxx   |   13 ++
 chart2/source/view/axes/VAxisProperties.hxx   |3 
 chart2/source/view/axes/VCartesianAxis.cxx|   72 --
 chart2/source/view/axes/VCartesianAxis.hxx|2 
 chart2/source/view/inc/DataTableView.hxx  |9 +
 chart2/source/view/main/DataTableView.cxx |   70 +
 7 files changed, 119 insertions(+), 51 deletions(-)

New commits:
commit 387e01bb088c958a4dbc3eec5bb98bf655b48ccb
Author: Tomaž Vajngerl 
AuthorDate: Sat Aug 13 14:14:00 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Thu Aug 25 07:28:35 2022 +0200

chart2: support data table rendering when the X axis is swapped

In case when the X axis is swapped, so the Y axis is rendered in
the place of X axis, we need to render the data table below the
Y-axis labels. This is best done to put the data table into the
Y-axis instead, so we get the correct size and position of the
data table, and then just allow rendering of the axis labels and
(re)position the table below Y-axis.

Change-Id: I74aa79402a5638133b0d1ed83bbd8aad6f6c9d1d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138336
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 
(cherry picked from commit addcd016bf1bed16299697fd18b8f9b1faf2cf3f)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138783
Tested-by: Jenkins CollaboraOffice 

diff --git a/chart2/source/view/axes/VAxisProperties.cxx 
b/chart2/source/view/axes/VAxisProperties.cxx
index 48cc3569f46d..0cbf487453f5 100644
--- a/chart2/source/view/axes/VAxisProperties.cxx
+++ b/chart2/source/view/axes/VAxisProperties.cxx
@@ -258,7 +258,7 @@ void AxisProperties::init( bool bCartesian )
 
 if( bCartesian )
 {
-if (m_nDimensionIndex == 0)
+if ((!m_bSwapXAndY && m_nDimensionIndex == 0) || (m_bSwapXAndY && 
m_nDimensionIndex == 1))
 {
 m_bDisplayDataTable = m_xDataTableModel.is();
 }
@@ -333,6 +333,17 @@ void AxisProperties::init( bool bCartesian )
 {
 TOOLS_WARN_EXCEPTION("chart2", "" );
 }
+
+if (m_bDisplayDataTable)
+{
+m_bDataTableAlignAxisValuesWithColumns = (m_nDimensionIndex == 0);
+
+if (m_nDimensionIndex == 0)
+{
+m_bDisplayLabels = false;
+}
+
+}
 }
 
 AxisLabelProperties::AxisLabelProperties()
diff --git a/chart2/source/view/axes/VAxisProperties.hxx 
b/chart2/source/view/axes/VAxisProperties.hxx
index 425792da689b..15f9da910e5d 100644
--- a/chart2/source/view/axes/VAxisProperties.hxx
+++ b/chart2/source/view/axes/VAxisProperties.hxx
@@ -109,7 +109,10 @@ struct AxisProperties final
 
 AxisLabelAlignment maLabelAlignment;
 
+// Data table
 bool m_bDisplayDataTable;
+bool m_bDataTableAlignAxisValuesWithColumns;
+
 bool m_bDisplayLabels;
 
 // Compatibility option: starting from LibreOffice 5.1 the rotated
diff --git a/chart2/source/view/axes/VCartesianAxis.cxx 
b/chart2/source/view/axes/VCartesianAxis.cxx
index 76884e8fc255..d5da1d3bf966 100644
--- a/chart2/source/view/axes/VCartesianAxis.cxx
+++ b/chart2/source/view/axes/VCartesianAxis.cxx
@@ -1675,35 +1675,43 @@ void VCartesianAxis::doStaggeringOfLabels( const 
AxisLabelProperties& rAxisLabel
 }
 }
 
-void VCartesianAxis::createLabels()
+void VCartesianAxis::createDataTableShape(std::unique_ptr 
const& rpTickFactory2D)
 {
-if( !prepareShapeCreation() )
+// Check if we can create the data table shape
+// Data table view and m_bDisplayDataTable must be true
+if (!m_pDataTableView || !m_aAxisProperties.m_bDisplayDataTable)
 return;
 
-std::unique_ptr apTickFactory2D(createTickFactory2D()); // 
throws on failure
+m_pDataTableView->initializeShapes(m_xDataTableTarget);
+basegfx::B2DVector aStart = rpTickFactory2D->getXaxisStartPos();
+basegfx::B2DVector aEnd = rpTickFactory2D->getXaxisEndPos();
 
-if (m_pDataTableView && m_aAxisProperties.m_bDisplayDataTable)
-{
-m_pDataTableView->initializeShapes(m_xDataTableTarget);
-basegfx::B2DVector aStart = apTickFactory2D->getXaxisStartPos();
-basegfx::B2DVector aEnd = apTickFactory2D->getXaxisEndPos();
+rpTickFactory2D->updateScreenValues(m_aAllTickInfos);
 
-apTickFactory2D->updateScreenValues(m_aAllTickInfos);
+sal_Int32 nDistance = -1;
 
-sal_Int32 nDistance = -1;
+std::unique_ptr apTickIter(createLabelTickIterator(0));
+if (apTickIter)
+{
+nDistance = TickFactory2D::getTickScreenDistance(*apTickIter);
+if (getTextLevelCount() > 1)
+nDistance *= 2;
+}
 
-std::unique_ptr apTickIter(createLabelTickIterator(0));
-if (apTickIter)
-{
-nDistance = TickFactory2D::getTickScreenDistance(*apTickIter);
-if (getTextLevelCount(

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

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/source/controller/inc/DataTableItemConverter.hxx|3 +--
 chart2/source/controller/itemsetwrapper/DataTableItemConverter.cxx |6 
++
 chart2/source/controller/main/ChartController_Properties.cxx   |6 
+-
 3 files changed, 4 insertions(+), 11 deletions(-)

New commits:
commit 4d406ce5f7ca5fe5c40324d83cc4898fa4646437
Author: Tomaž Vajngerl 
AuthorDate: Fri Aug 12 23:21:34 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Thu Aug 25 07:27:49 2022 +0200

chart2: don't use ref-size property when converting data table

Change-Id: I4dd93d84879274721ded01be1a47b62487066b4e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138334
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 
(cherry picked from commit fc909263a1bb9326f838326f3299b16b80318f42)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138781
Tested-by: Jenkins CollaboraOffice 

diff --git a/chart2/source/controller/inc/DataTableItemConverter.hxx 
b/chart2/source/controller/inc/DataTableItemConverter.hxx
index 5a8f86bc39ec..d5e0eb0df0cf 100644
--- a/chart2/source/controller/inc/DataTableItemConverter.hxx
+++ b/chart2/source/controller/inc/DataTableItemConverter.hxx
@@ -37,8 +37,7 @@ public:
 DataTableItemConverter(
 const css::uno::Reference& rPropertySet, 
SfxItemPool& rItemPool,
 SdrModel& rDrawModel,
-css::uno::Reference const& 
xNamedPropertyContainerFactory,
-const css::awt::Size* pRefSize);
+css::uno::Reference const& 
xNamedPropertyContainerFactory);
 
 virtual ~DataTableItemConverter() override;
 
diff --git a/chart2/source/controller/itemsetwrapper/DataTableItemConverter.cxx 
b/chart2/source/controller/itemsetwrapper/DataTableItemConverter.cxx
index 693f67b593c9..d02517e55857 100644
--- a/chart2/source/controller/itemsetwrapper/DataTableItemConverter.cxx
+++ b/chart2/source/controller/itemsetwrapper/DataTableItemConverter.cxx
@@ -50,14 +50,12 @@ ItemPropertyMapType& lclDataTablePropertyMap()
 
 DataTableItemConverter::DataTableItemConverter(
 const uno::Reference& rPropertySet, SfxItemPool& 
rItemPool,
-SdrModel& rDrawModel, uno::Reference const& 
xFactory,
-const awt::Size* pRefSize)
+SdrModel& rDrawModel, uno::Reference const& 
xFactory)
 : ItemConverter(rPropertySet, rItemPool)
 {
 m_aConverters.emplace_back(new GraphicPropertyItemConverter(
 rPropertySet, rItemPool, rDrawModel, xFactory, 
GraphicObjectType::LineProperties));
-m_aConverters.emplace_back(
-new CharacterPropertyItemConverter(rPropertySet, rItemPool, pRefSize, 
"ReferencePageSize"));
+m_aConverters.emplace_back(new 
CharacterPropertyItemConverter(rPropertySet, rItemPool));
 }
 
 DataTableItemConverter::~DataTableItemConverter() = default;
diff --git a/chart2/source/controller/main/ChartController_Properties.cxx 
b/chart2/source/controller/main/ChartController_Properties.cxx
index 69e1a2dd7d62..0967cc47af68 100644
--- a/chart2/source/controller/main/ChartController_Properties.cxx
+++ b/chart2/source/controller/main/ChartController_Properties.cxx
@@ -290,13 +290,9 @@ wrapper::ItemConverter* createItemConverter(
 break;
 case OBJECTTYPE_DATA_TABLE:
 {
-std::unique_ptr pRefSize;
-if (pRefSizeProvider)
-pRefSize.reset(new 
awt::Size(pRefSizeProvider->getPageSize()));
-
 pItemConverter =  new wrapper::DataTableItemConverter(
 xObjectProperties, 
rDrawModel.GetItemPool(),
-rDrawModel, 
uno::Reference(xChartModel, uno::UNO_QUERY), 
pRefSize.get());
+rDrawModel, 
uno::Reference(xChartModel, uno::UNO_QUERY));
 }
 break;
 default: //OBJECTTYPE_UNKNOWN


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

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/source/view/main/DataTableView.cxx |3 +++
 1 file changed, 3 insertions(+)

New commits:
commit 4f548157e44ccbf91a5662ba3cfd0870759384df
Author: Tomaž Vajngerl 
AuthorDate: Fri Aug 12 17:36:23 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Thu Aug 25 07:27:32 2022 +0200

chart2: use the FillColor property as CharBackColor

For chart data table, the fill is always setting the char background
(highlight). As we don't support other fill types in LibreOffice for
the char background, we can't set anything else when rendering. We
need to extend editeng and UNO API with the support for this.

Change-Id: I47d342e02ad2347bac0515a62cc0de4391f98150
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138331
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 
(cherry picked from commit 65021c6acc655b61cbba74d01829beb1c4181c97)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138780
Tested-by: Tomaž Vajngerl 

diff --git a/chart2/source/view/main/DataTableView.cxx 
b/chart2/source/view/main/DataTableView.cxx
index e7f577f04af3..e8de2ff0846c 100644
--- a/chart2/source/view/main/DataTableView.cxx
+++ b/chart2/source/view/main/DataTableView.cxx
@@ -140,6 +140,9 @@ void DataTableView::setCellCharAndParagraphProperties(
 copyProperty(xPropertySet, xDataTableProperties, "CharWeightComplex");
 copyProperty(xPropertySet, xDataTableProperties, "CharWordMode");
 
+xPropertySet->setPropertyValue("CharBackColor",
+   
xDataTableProperties->getPropertyValue("FillColor"));
+
 xPropertySet->setPropertyValue("ParaAdjust", 
uno::makeAny(style::ParagraphAdjust_CENTER));
 }
 


[Libreoffice-commits] core.git: Changes to 'refs/tags/libreoffice-7.4.1.1'

2022-08-24 Thread Christian Lohmaier (via logerrit)
Tag 'libreoffice-7.4.1.1' created by Christian Lohmaier 
 at 2022-08-24 16:22 +

Tag libreoffice-7.4.1.1
-BEGIN PGP SIGNATURE-

iQIzBAABCAAdFiEEwoOeytlAj76VMcPp9DSh76/urqMFAmMGUF8ACgkQ9DSh76/u
rqPrOQ/9E3euVJEr8NRotDwT4F9+kgiFJ66FHSXAQA1ooz3/rzc9loHdPq74GuKE
Xs1IjS7VujSbQQZiS9Ng7AF7OHYC/EWuoCjK22QNURmGlmomKEwFayrq3nmuAG8A
4eVzBV1nwsAxnaLZ7iqP5wtKoK3ZJc6dKW/UP2d+lP/LjvLkRPDwz8MYbQL4RT4Y
TFjtS/ZtsNiXk9b1Y1wLXrcg66iGJlIdlPmm56jCBNAn7cF1/QncxRnoQRX1SgqS
I4a2xaE3We9TTJdiKJZEKOqstpC94wQJM0r/Jm4UcqflSt5gQlVS/+UoPsqkzyLn
jLLqdNIhz7WoegaVhYbVA/3Cfk4WYJpfvEgBtTtJnpNlZoG3wgWKcTmzsn6WIyGe
s6MDgvUQrVi98w086v/f08lWqbuQM5VtYq2Fa+o19iUVxdbnFRprwRpC7ZqefQp2
ZYVxsEivGdF6NqBL/c2u3qWcpSKchKzroMcuG/h23ONmTpCeLeZtmIfXy+bDoS91
jL3GN3uaJ8SueHxNZ1jniPjUh0DNCKZ3ed07uiwgcGV0+/zVCK6SaVBdYX7HCdtF
AIdCrmIPlb/bzq67vceW2Dn61hSPR0I9Qg5lzORqjWvuPJoLyHS5PjpfWlZif2W6
5jI2yKVfM0S0OsfiIai9vjE8h2GEEAh/BgabVnfMI1d12Loaftg=
=W2RH
-END PGP SIGNATURE-

Changes since libreoffice-7-4-branch-point-501:
---
 0 files changed
---


[Libreoffice-commits] dictionaries.git: Changes to 'refs/tags/libreoffice-7.4.1.1'

2022-08-24 Thread Christian Lohmaier (via logerrit)
Tag 'libreoffice-7.4.1.1' created by Christian Lohmaier 
 at 2022-08-24 16:22 +

Tag libreoffice-7.4.1.1
-BEGIN PGP SIGNATURE-

iQIzBAABCAAdFiEEwoOeytlAj76VMcPp9DSh76/urqMFAmMGUFwACgkQ9DSh76/u
rqNkVQ//RHR6byl2e3+GQXbmS6mgd73OZ+ze3pkaZpQk+MtrgegOmjH8h/WQF2o3
KkEC6+qnBJpE809wpNmO0DCvx6Jcod24XjCNVtmqP23FxqMzXOAiMkkuvF87yXy3
56aoKkk/Y+1KT2oZFbkZRadAJU+Z74ZyMIdylJSTTBW1nzmqibgpFNHHvZFmknDg
PpTaqiOGGOYGaOTl1eYH4olqWTpmM6t9iEStmf8pTYMxXGVfvpRfQhoP9GsyvFC9
aGOZjaxYISycCEHd/EBHb82jCshUsJD0L814IeTm50nF8BLQUO6Cn27bDo21/i2T
MCoorcsGccxzB1KkUtJ9aWGNJSH/jnFM5sSVN1oQIeZmwt1Vn9BU/kJF/gAxs4Ug
pxuhuHbyNRRFesao7r6CgQGm3iryd+F4MWylh5Zi2yLqiUHwRRdB2wWoDcB8mb2P
fPwYEejNXP+eTn01Epl/qwfldP4/pIMiAettfOouqhP5iax8Q7zYXJW1vYcdqOkI
9xl+QYN/dYfsJVMSDPWRrIYdme/9T6ORJg4rT0idWt61M4spebFGUg3iOGgAtpQ9
NFFx0KJW8V+W9OLXre1m3jwsP9Ffw/S72Uep/Jlw+n3SWBBMti9voGO0x2X9lVXi
LjZN7TvnzAl/W6CiPKOxl3rMWOx/obdvlOJCGpkNAhkSqeXHXEU=
=c6gn
-END PGP SIGNATURE-

Changes since libreoffice-7-4-branch-point-3:
---
 0 files changed
---


[Libreoffice-commits] core.git: Changes to 'libreoffice-7-4-1'

2022-08-24 Thread Christian Lohmaier (via logerrit)
New branch 'libreoffice-7-4-1' available with the following commits:
commit b5a5ab2a5f8cc928ca7f597836e3845fa804abab
Author: Christian Lohmaier 
Date:   Wed Aug 24 18:19:48 2022 +0200

Branch libreoffice-7-4-1

This is 'libreoffice-7-4-1' - the stable branch for the 7.4.1 release.
Only very safe changes, reviewed by three people are allowed.

If you want to commit more complicated fix for the next 7.4.x release,
please use the 'libreoffice-7-4' branch.

If you want to build something cool, unstable, and risky, use master.



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

2022-08-24 Thread Regina Henschel (via logerrit)
 xmloff/qa/unit/data/tdf150407_PosRelBottomMargin.docx   |binary
 xmloff/qa/unit/data/tdf150407_PosRelTopMargin.docx  |binary
 xmloff/qa/unit/data/tdf150407_WritingModeBTLR_style.odt |binary
 xmloff/qa/unit/style.cxx|  191 
 xmloff/source/style/xmlexppr.cxx|   51 ++--
 5 files changed, 217 insertions(+), 25 deletions(-)

New commits:
commit 89552d1652bbe026f9572325056056b449d74716
Author: Regina Henschel 
AuthorDate: Sat Aug 20 20:56:11 2022 +0200
Commit: Michael Stahl 
CommitDate: Wed Aug 24 16:28:36 2022 +0200

tdf#150407 do not use loext in save in ODF strict

The 'bt-lr' attribute value of 'writing-mode' attribute and the
'page-content-bottom' and 'page-content-top' values of 'vertical-rel'
attribute are not part of ODF 1.3. Therefore they need to be saved in
'loext' extended namespace.

Error was, that this was done too, if the current ODF version is
strict. That results in an invalid file in a productive build and a
failed assert in SvXMLNamespaceMap::GetQNameByKey() in a debug build.

Change-Id: Ie9ba99fdd02de21a2467b236409daa951933f011
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138595
Tested-by: Jenkins
Reviewed-by: Regina Henschel 
(cherry picked from commit 64be7052ba7e02e24841098e07a5f4106456)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138541
Reviewed-by: Michael Stahl 
(cherry picked from commit 34edaf8249107c4216fdaffe450d287a1908a0de)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138547

diff --git a/xmloff/qa/unit/data/tdf150407_PosRelBottomMargin.docx 
b/xmloff/qa/unit/data/tdf150407_PosRelBottomMargin.docx
new file mode 100644
index ..0264f89f98a6
Binary files /dev/null and 
b/xmloff/qa/unit/data/tdf150407_PosRelBottomMargin.docx differ
diff --git a/xmloff/qa/unit/data/tdf150407_PosRelTopMargin.docx 
b/xmloff/qa/unit/data/tdf150407_PosRelTopMargin.docx
new file mode 100644
index ..48f981506243
Binary files /dev/null and b/xmloff/qa/unit/data/tdf150407_PosRelTopMargin.docx 
differ
diff --git a/xmloff/qa/unit/data/tdf150407_WritingModeBTLR_style.odt 
b/xmloff/qa/unit/data/tdf150407_WritingModeBTLR_style.odt
new file mode 100644
index ..2ad2ca1219b2
Binary files /dev/null and 
b/xmloff/qa/unit/data/tdf150407_WritingModeBTLR_style.odt differ
diff --git a/xmloff/qa/unit/style.cxx b/xmloff/qa/unit/style.cxx
index 1f63cbe1355a..93634ad5170d 100644
--- a/xmloff/qa/unit/style.cxx
+++ b/xmloff/qa/unit/style.cxx
@@ -23,6 +23,9 @@
 #include 
 
 #include 
+#include 
+#include 
+#include 
 #include 
 #include 
 #include 
@@ -45,6 +48,7 @@ public:
 void registerNamespaces(xmlXPathContextPtr& pXmlXpathCtx) override;
 uno::Reference& getComponent() { return mxComponent; }
 void load(std::u16string_view rURL);
+void save(const OUString& rFilterName, utl::TempFile& rTempFile);
 };
 
 void XmloffStyleTest::setUp()
@@ -73,6 +77,16 @@ void XmloffStyleTest::load(std::u16string_view rFileName)
 mxComponent = loadFromDesktop(aURL);
 }
 
+void XmloffStyleTest::save(const OUString& rFilterName, utl::TempFile& 
rTempFile)
+{
+uno::Reference xStorable(mxComponent, uno::UNO_QUERY);
+utl::MediaDescriptor aMediaDescriptor;
+aMediaDescriptor["FilterName"] <<= rFilterName;
+rTempFile.EnableKillingFile();
+xStorable->storeToURL(rTempFile.GetURL(), 
aMediaDescriptor.getAsConstPropertyValueList());
+validate(rTempFile.GetFileName(), test::ODF);
+}
+
 CPPUNIT_TEST_FIXTURE(XmloffStyleTest, testFillImageBase64)
 {
 // Load a flat ODG that has base64-encoded bitmap as a fill style.
@@ -197,6 +211,183 @@ CPPUNIT_TEST_FIXTURE(XmloffStyleTest, testRtlGutter)
 CPPUNIT_ASSERT(bRtlGutter);
 }
 
+CPPUNIT_TEST_FIXTURE(XmloffStyleTest, testWritingModeBTLR)
+{
+// Load document. It has a frame style with writing-mode bt-lr.
+// In ODF 1.3 extended it is written as loext:writing-mode="bt-lr".
+// In ODF 1.3 strict, there must not be an attribute at all.
+getComponent() = 
loadFromDesktop(m_directories.getURLFromSrc(DATA_DIRECTORY)
+ + 
"tdf150407_WritingModeBTLR_style.odt",
+ "com.sun.star.text.TextDocument");
+
+Resetter _([]() {
+std::shared_ptr pBatch(
+comphelper::ConfigurationChanges::create());
+officecfg::Office::Common::Save::ODF::DefaultVersion::set(3, pBatch);
+return pBatch->commit();
+});
+
+// Save to ODF 1.3 extended. Adapt 3 (=ODFVER_LATEST) to a to be 
ODFVER_013_EXTENDED when
+// attribute value "bt-lr" is included in ODF strict.
+{
+std::shared_ptr pBatch(
+comphelper::ConfigurationChanges::create());
+officecfg::Office::Common::Save::ODF::DefaultVersion::set(3, pBatch);
+pBatch->commit();
+utl::TempFile aTempFile;
+save("writer8", aTempFile);
+
+  

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

2022-08-24 Thread Noel Grandin (via logerrit)
 sw/source/filter/ww8/WW8TableInfo.cxx |6 +++---
 sw/source/filter/ww8/docxexport.cxx   |2 +-
 sw/source/filter/ww8/rtfexport.cxx|7 +++
 sw/source/filter/ww8/wrtw8sty.cxx |2 +-
 sw/source/filter/ww8/wrtww8.cxx   |8 
 5 files changed, 12 insertions(+), 13 deletions(-)

New commits:
commit 006fd925feafcf9beecf01279907fb330d704a89
Author: Noel Grandin 
AuthorDate: Wed Aug 24 13:02:37 2022 +0200
Commit: Noel Grandin 
CommitDate: Wed Aug 24 14:49:42 2022 +0200

Use more SwPosition::Assign

to keep the internal fields of SwPosition in sync.

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

diff --git a/sw/source/filter/ww8/WW8TableInfo.cxx 
b/sw/source/filter/ww8/WW8TableInfo.cxx
index f5c318b6df23..e087d515fc5f 100644
--- a/sw/source/filter/ww8/WW8TableInfo.cxx
+++ b/sw/source/filter/ww8/WW8TableInfo.cxx
@@ -589,7 +589,7 @@ WW8TableInfo::processSwTableByLayout(const SwTable * 
pTable, RowEndInners_t &rLa
 bDone = true;
 }
 
-aPam.GetPoint()->nNode++;
+aPam.GetPoint()->Adjust(SwNodeOffset(1));
 }
 while (!bDone);
 }
@@ -708,7 +708,7 @@ WW8TableInfo::processTableBoxLines(const SwTableBox * pBox,
 if (aPaM.GetPoint()->GetNode() == aEndPaM.GetPoint()->GetNode())
 bDone = true;
 else
-aPaM.GetPoint()->nNode++;
+aPaM.GetPoint()->Adjust(SwNodeOffset(1));
 }
 }
 
@@ -804,7 +804,7 @@ WW8TableInfo::processTableBox(const SwTable * pTable,
 bDone = true;
 }
 
-aPaM.GetPoint()->nNode++;
+aPaM.GetPoint()->Adjust(SwNodeOffset(1));
 }
 while (!bDone);
 
diff --git a/sw/source/filter/ww8/docxexport.cxx 
b/sw/source/filter/ww8/docxexport.cxx
index 4894400011f1..52090fc74891 100644
--- a/sw/source/filter/ww8/docxexport.cxx
+++ b/sw/source/filter/ww8/docxexport.cxx
@@ -1872,7 +1872,7 @@ void DocxExport::WriteMainText()
 // body
 m_pDocumentFS->startElementNS(XML_w, XML_body);
 
-m_pCurPam->GetPoint()->nNode = 
m_rDoc.GetNodes().GetEndOfContent().StartOfSectionNode()->GetIndex();
+
m_pCurPam->GetPoint()->Assign(*m_rDoc.GetNodes().GetEndOfContent().StartOfSectionNode());
 
 // the text
 WriteText();
diff --git a/sw/source/filter/ww8/rtfexport.cxx 
b/sw/source/filter/ww8/rtfexport.cxx
index 7a7d110ca835..a48e70c8efe1 100644
--- a/sw/source/filter/ww8/rtfexport.cxx
+++ b/sw/source/filter/ww8/rtfexport.cxx
@@ -500,13 +500,12 @@ void RtfExport::WriteMainText()
 SwTableNode* pTableNode = m_pCurPam->GetPointNode().FindTableNode();
 if (m_pWriter && m_pWriter->m_bWriteOnlyFirstTable && pTableNode != 
nullptr)
 {
-m_pCurPam->GetPoint()->nNode = *pTableNode;
-m_pCurPam->GetMark()->nNode = *(pTableNode->EndOfSectionNode());
+m_pCurPam->GetPoint()->Assign(*pTableNode);
+m_pCurPam->GetMark()->Assign(*pTableNode->EndOfSectionNode());
 }
 else
 {
-m_pCurPam->GetPoint()->nNode
-= 
m_rDoc.GetNodes().GetEndOfContent().StartOfSectionNode()->GetIndex();
+
m_pCurPam->GetPoint()->Assign(*m_rDoc.GetNodes().GetEndOfContent().StartOfSectionNode());
 }
 
 WriteText();
diff --git a/sw/source/filter/ww8/wrtw8sty.cxx 
b/sw/source/filter/ww8/wrtw8sty.cxx
index ff5af1a68785..06c930ba339d 100644
--- a/sw/source/filter/ww8/wrtw8sty.cxx
+++ b/sw/source/filter/ww8/wrtw8sty.cxx
@@ -1013,7 +1013,7 @@ MSWordSections::MSWordSections( MSWordExportBase& rExport 
)
 if ( SectionType::ToxContent == pSectNd->GetSection().GetType() )
 {
 pNd = pSectNd;
-rExport.m_pCurPam->GetPoint()->nNode = *pNd;
+rExport.m_pCurPam->GetPoint()->Assign(*pNd);
 }
 
 if ( SectionType::Content == pSectNd->GetSection().GetType() )
diff --git a/sw/source/filter/ww8/wrtww8.cxx b/sw/source/filter/ww8/wrtww8.cxx
index d2eb7a99e95c..331b0038cdb9 100644
--- a/sw/source/filter/ww8/wrtww8.cxx
+++ b/sw/source/filter/ww8/wrtww8.cxx
@@ -1883,7 +1883,7 @@ void MSWordExportBase::SetCurPam(SwNodeOffset nStt, 
SwNodeOffset nEnd)
 if ( nStt != m_pCurPam->GetMark()->GetNodeIndex() &&
  m_rDoc.GetNodes()[ nStt ]->IsTableNode() )
 {
-m_pCurPam->GetMark()->nNode = nStt;
+m_pCurPam->GetMark()->Assign(nStt);
 }
 
 m_pOrigPam = m_pCurPam.get(); // ???
@@ -2919,7 +2919,7 @@ void MSWordExportBase::WriteText()
 if (pNextNode != nullptr)
 m_pCurPam->GetPoint()->Assign(*pNextNode);
 else
-++m_pCurPam->GetPoint()->nNode;
+m_pCurPam->GetPoint()->Adjust(SwNodeOffset(1));
 
 SwNodeOffset nPos = m_pCurPam->GetPoint()->GetNodeIndex();
 ::SetProgressState( sal_Int32(nPos), m_pCurPam->GetDoc().GetDo

[Libreoffice-commits] core.git: Branch 'distro/collabora/co-22.05' - 2 commits - chart2/source

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/source/controller/dialogs/dlg_ObjectProperties.cxx |1 
 chart2/source/view/main/DataTableView.cxx |   58 ++
 2 files changed, 44 insertions(+), 15 deletions(-)

New commits:
commit 25cf1afd485d6ff7a7278aa2260082596ca4d0f7
Author: Tomaž Vajngerl 
AuthorDate: Fri Aug 12 17:29:36 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Wed Aug 24 22:49:09 2022 +0200

chart2: always set text props. of the first paragraph and not cell

When setting the properties of the data table it is important to
differentiate when we set the properties of the text of the (first
and only) paragraph or set the properties for the current cell.

In this chage we refactor the code so that we always set the text
via UNO text::XText call for the current cell, and in the next step
get the XPropertySet of the first paragraph and set the properties
relevant for the text from the DataTable model.

Change-Id: Ibe82b21c3416083cfe8e86b95443d77984da05f5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138330
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 
(cherry picked from commit 81a5f33101c18fb22a952b865c0c90418fd6a490)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138605
Tested-by: Jenkins CollaboraOffice 

diff --git a/chart2/source/view/main/DataTableView.cxx 
b/chart2/source/view/main/DataTableView.cxx
index aa1e7adb9e77..e7f577f04af3 100644
--- a/chart2/source/view/main/DataTableView.cxx
+++ b/chart2/source/view/main/DataTableView.cxx
@@ -58,6 +58,29 @@ void copyProperty(uno::Reference& xOut,
 {
 xOut->setPropertyValue(sPropertyName, 
xIn->getPropertyValue(sPropertyName));
 }
+
+uno::Reference getFirstParagraph(uno::Reference 
const& xText)
+{
+uno::Reference xParagraph;
+uno::Reference xEnumAccess(xText, 
uno::UNO_QUERY);
+if (!xEnumAccess.is())
+return xParagraph;
+uno::Reference 
xEnumeration(xEnumAccess->createEnumeration());
+xParagraph.set(xEnumeration->nextElement(), uno::UNO_QUERY);
+return xParagraph;
+}
+
+uno::Reference
+getFirstParagraphProperties(uno::Reference const& xText)
+{
+uno::Reference xPropertySet;
+auto xParagraph = getFirstParagraph(xText);
+if (!xParagraph.is())
+return xPropertySet;
+xPropertySet.set(xParagraph, uno::UNO_QUERY);
+return xPropertySet;
+}
+
 } // end anonymous namespace
 
 DataTableView::DataTableView(uno::Reference const& 
xChartDoc,
@@ -67,8 +90,8 @@ 
DataTableView::DataTableView(uno::Reference const& xChar
 , m_xDataTableModel(rDataTableModel)
 , m_xComponentContext(rComponentContext)
 {
-uno::Reference xProp(m_xDataTableModel);
-m_aLineProperties.initFromPropertySet(xProp);
+uno::Reference xPropertySet(m_xDataTableModel);
+m_aLineProperties.initFromPropertySet(xPropertySet);
 }
 
 void DataTableView::setCellCharAndParagraphProperties(
@@ -275,14 +298,18 @@ void DataTableView::createShapes(basegfx::B2DVector 
const& rStart, basegfx::B2DV
 uno::Reference xCellTextRange(xCell, uno::UNO_QUERY);
 if (xCellTextRange.is())
 {
-xCellTextRange->setString(rString);
+auto xText = xCellTextRange->getText();
+xText->insertString(xText->getStart(), rString, false);
+auto xTextPropertySet = getFirstParagraphProperties(xText);
+if (!xTextPropertySet.is())
+continue;
 
 bool bLeft
 = (bOutline && nColumn == 1) || (bVBorder && nColumn > 1 && 
nColumn < nColumnCount);
 bool bRight = (bOutline && nColumn == nColumnCount)
   || (bVBorder && nColumn > 1 && nColumn < 
nColumnCount);
+setCellCharAndParagraphProperties(xTextPropertySet);
 setCellProperties(xPropertySet, bLeft, bOutline, bRight, bOutline);
-setCellCharAndParagraphProperties(xPropertySet);
 }
 nColumn++;
 }
@@ -321,17 +348,14 @@ void DataTableView::createShapes(basegfx::B2DVector 
const& rStart, basegfx::B2DV
 bool bTop = (bOutline && nRow == 1) || (bHBorder && nRow > 1 && 
nRow < nRowCount);
 bool bBottom
 = (bOutline && nRow == nRowCount) || (bHBorder && nRow > 1 && 
nRow < nRowCount);
-setCellProperties(xCellPropertySet, bOutline, bTop, bOutline, 
bBottom);
 
 auto xText = xCellTextRange->getText();
 xText->insertString(xText->getStart(), rSeriesName, false);
-uno::Reference xEnumAccess(xText, 
uno::UNO_QUERY);
-uno::Reference 
xEnumeration(xEnumAccess->createEnumeration());
-uno::Reference 
xParagraph(xEnumeration->nextElement(),
-uno::UNO_QUERY);
-uno::Reference xTextPropertySet(xParagraph, 
uno::UNO_QUERY);
-
+auto xTextPropertySet = getFirstParagraphProperties(xText);
+if (!xTextPropertySet.is())
+conti

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

2022-08-24 Thread Noel Grandin (via logerrit)
 sw/source/filter/ww8/ww8par2.cxx |   31 +++
 sw/source/filter/ww8/ww8par5.cxx |2 +-
 sw/source/filter/ww8/ww8par6.cxx |8 
 3 files changed, 20 insertions(+), 21 deletions(-)

New commits:
commit 6ba1f58c58857812d85e7c57d2f612ca80216786
Author: Noel Grandin 
AuthorDate: Wed Aug 24 09:46:41 2022 +0200
Commit: Noel Grandin 
CommitDate: Wed Aug 24 11:35:47 2022 +0200

Use more SwPosition::Adjust

to keep the internal fields of SwPosition in sync.

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

diff --git a/sw/source/filter/ww8/ww8par2.cxx b/sw/source/filter/ww8/ww8par2.cxx
index d075cd1d8d93..9b6cdfe6c754 100644
--- a/sw/source/filter/ww8/ww8par2.cxx
+++ b/sw/source/filter/ww8/ww8par2.cxx
@@ -198,7 +198,7 @@ sal_uInt16 SwWW8ImplReader::End_Footnote()
 {
 sChar += OUStringChar(pText->GetText()[--nPos]);
 m_pPaM->SetMark();
---m_pPaM->GetMark()->nContent;
+m_pPaM->GetMark()->AdjustContent(-1);
 std::shared_ptr xLastAnchorCursor(m_oLastAnchorPos ? 
m_rDoc.CreateUnoCursor(*m_oLastAnchorPos) : nullptr);
 m_oLastAnchorPos.reset();
 m_rDoc.getIDocumentContentOperations().DeleteRange( *m_pPaM );
@@ -251,9 +251,9 @@ sal_uInt16 SwWW8ImplReader::End_Footnote()
 as usual. Might not be if the user has already deleted it, e.g.
 #i14737#
 */
-SwNodeIndex& rNIdx = m_pPaM->GetPoint()->nNode;
-rNIdx = pSttIdx->GetIndex() + 1;
-SwTextNode* pTNd = rNIdx.GetNode().GetTextNode();
+SwPosition& rPaMPointPos = *m_pPaM->GetPoint();
+rPaMPointPos.Assign(pSttIdx->GetIndex() + 1);
+SwTextNode* pTNd = rPaMPointPos.GetNode().GetTextNode();
 if (pTNd && !pTNd->GetText().isEmpty() && !sChar.isEmpty())
 {
 const OUString &rText = pTNd->GetText();
@@ -269,12 +269,12 @@ sal_uInt16 SwWW8ImplReader::End_Footnote()
 nFirstLineIndent = 
pLRSpace->GetTextFirstLineOffset();
 }
 
-m_pPaM->GetPoint()->nContent.Assign( pTNd, 0 );
+rPaMPointPos.SetContent(0);
 m_pPaM->SetMark();
 // Strip out aesthetic tabs we may have inserted on export 
#i24762#
 if (nFirstLineIndent < 0 && rText.getLength() > 1 && 
rText[1] == 0x09)
-++m_pPaM->GetMark()->nContent;
-++m_pPaM->GetMark()->nContent;
+m_pPaM->GetMark()->AdjustContent(1);
+m_pPaM->GetMark()->AdjustContent(1);
 m_xReffingStck->Delete(*m_pPaM);
 m_rDoc.getIDocumentContentOperations().DeleteRange( 
*m_pPaM );
 m_pPaM->DeleteMark();
@@ -2740,11 +2740,11 @@ void WW8TabDesc::ParkPaM()
 {
 do
 {
-m_pIo->m_pPaM->GetPoint()->nNode = nSttNd;
+m_pIo->m_pPaM->GetPoint()->Assign(nSttNd);
 }
 while (m_pIo->m_pPaM->GetPointNode().GetNodeType() != SwNodeType::Text 
&& ++nSttNd < nEndNd);
 
-
m_pIo->m_pPaM->GetPoint()->nContent.Assign(m_pIo->m_pPaM->GetPointContentNode(),
 0);
+m_pIo->m_pPaM->GetPoint()->SetContent(0);
 m_pIo->m_rDoc.SetTextFormatColl(*m_pIo->m_pPaM, 
const_cast(m_pIo->m_pDfltTextFormatColl));
 }
 }
@@ -2983,10 +2983,10 @@ void WW8TabDesc::SetPamInCell(short nWwCol, bool bPam)
 {
 do
 {
-m_pIo->m_pPaM->GetPoint()->nNode = nSttNd;
+m_pIo->m_pPaM->GetPoint()->Assign(nSttNd);
 }
 while (m_pIo->m_pPaM->GetPointNode().GetNodeType() != SwNodeType::Text 
&& ++nSttNd < nEndNd);
-
m_pIo->m_pPaM->GetPoint()->nContent.Assign(m_pIo->m_pPaM->GetPointContentNode(),
 0);
+m_pIo->m_pPaM->GetPoint()->SetContent(0);
 // Precautionally set now, otherwise the style is not set for cells
 // that are inserted for margin balancing.
 m_pIo->m_rDoc.SetTextFormatColl(*m_pIo->m_pPaM, 
const_cast(m_pIo->m_pDfltTextFormatColl));
@@ -2995,7 +2995,8 @@ void WW8TabDesc::SetPamInCell(short nWwCol, bool bPam)
 }
 
 // Better to turn Snap to Grid off for all paragraphs in tables
-SwTextNode *pNd = m_pIo->m_pPaM->GetPointNode().GetTextNode();
+SwPosition* pGridPos = m_pIo->m_pPaM->GetPoint();
+SwTextNode *pNd = pGridPos->GetNode().GetTextNode();
 if(!pNd)
 return;
 
@@ -3008,12 +3009,10 @@ void WW8TabDesc::SetPamInCell(short nWwCol, bool bPam)
 SvxParaGridItem aGridItem( rSnapToGrid );
 aGridItem.SetValue(false);
 
-SwPosition* pGridPos = m_pIo->m_pPaM->GetPoint();
-
 const sal_Int32 nEnd = pGridPos->GetContentIndex();
-pGridPos->nContent.Assign(m_pIo->m_pPaM->GetPointContentNode(), 0);
+pGridPos->SetContent

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

2022-08-24 Thread Eike Rathke (via logerrit)
 sc/inc/compiler.hxx  |2 +-
 sc/source/core/tool/compiler.cxx |8 ++--
 2 files changed, 7 insertions(+), 3 deletions(-)

New commits:
commit 65747afbb644607c0d2a1fbf354a1a080292b285
Author: Eike Rathke 
AuthorDate: Tue Aug 23 15:40:09 2022 +0200
Commit: Eike Rathke 
CommitDate: Tue Aug 23 22:09:48 2022 +0200

Make static ScCompiler::GetCharClassLocalized() public as well

... and mutex guard it.

Change-Id: Ief9c6deaf7974ac43c7ae439a0fb73c29eced283
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138733
Reviewed-by: Eike Rathke 
Tested-by: Jenkins

diff --git a/sc/inc/compiler.hxx b/sc/inc/compiler.hxx
index 5f6c521d11cf..965232485049 100644
--- a/sc/inc/compiler.hxx
+++ b/sc/inc/compiler.hxx
@@ -378,8 +378,8 @@ private:
 
 bool HasPossibleNamedRangeConflict(SCTAB nTab) const;
 
-static const CharClass* GetCharClassLocalized();
 public:
+static const CharClass* GetCharClassLocalized();
 static const CharClass* GetCharClassEnglish();
 
 public:
diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx
index d4ee9a19fd14..ecd1dfed63f6 100644
--- a/sc/source/core/tool/compiler.cxx
+++ b/sc/source/core/tool/compiler.cxx
@@ -242,8 +242,12 @@ const CharClass* ScCompiler::GetCharClassLocalized()
 {
 // Switching UI language requires restart; if not, we would have to
 // keep track of that.
-pCharClassLocalized = new CharClass(
-::comphelper::getProcessComponentContext(), 
Application::GetSettings().GetUILanguageTag());
+osl::MutexGuard aGuard(maMutex);
+if (!pCharClassLocalized)
+{
+pCharClassLocalized = new CharClass( 
::comphelper::getProcessComponentContext(),
+Application::GetSettings().GetUILanguageTag());
+}
 }
 return pCharClassLocalized;
 }


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

2022-08-24 Thread Khaled Hosny (via logerrit)
 cui/source/dialogs/FontFeaturesDialog.cxx |   11 +++
 cui/source/inc/FontFeaturesDialog.hxx |4 ++--
 include/vcl/font/Feature.hxx  |6 +++---
 include/vcl/font/FeatureParser.hxx|2 +-
 vcl/source/font/Feature.cxx   |   10 +-
 vcl/source/font/FeatureCollector.cxx  |2 +-
 vcl/source/font/FeatureParser.cxx |9 +++--
 7 files changed, 22 insertions(+), 22 deletions(-)

New commits:
commit 783f166793915a1c5a008de7142f773ad3898683
Author: Khaled Hosny 
AuthorDate: Tue Aug 23 14:22:23 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Tue Aug 23 16:59:56 2022 +0200

tdf#127423: Allow disabling default features in Font Features dialog

In OpenType fonts we have no way if detecting what features are on by
default and what not (short of hard-coding this, since HarfBuzz has no
API of giving us this information, and it is also not a fixed set
per-font, depends also on the text being shaped).

The dialog currently does not differentiate between a disabled feature
and unset feature. To make this distinction, feature value is now signed
and negative value means the feature is unset (i.e. the default is
used), and the checkbox is now a try state one to reflect this.

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

diff --git a/cui/source/dialogs/FontFeaturesDialog.cxx 
b/cui/source/dialogs/FontFeaturesDialog.cxx
index 0d5d512bf053..53ca5f12f3c1 100644
--- a/cui/source/dialogs/FontFeaturesDialog.cxx
+++ b/cui/source/dialogs/FontFeaturesDialog.cxx
@@ -100,7 +100,7 @@ int 
FontFeaturesDialog::fillGrid(std::vector const& rFontFea
 
 m_aFeatureItems.emplace_back(m_xContentGrid.get());
 
-uint32_t nValue = 0;
+int32_t nValue = 0;
 if (aExistingFeatures.find(nFontFeatureCode) != 
aExistingFeatures.end())
 nValue = aExistingFeatures.at(nFontFeatureCode);
 else
@@ -133,7 +133,10 @@ int 
FontFeaturesDialog::fillGrid(std::vector const& rFontFea
 }
 else
 {
-aCurrentItem.m_xCheck->set_active(nValue > 0);
+if (nValue < 0)
+aCurrentItem.m_xCheck->set_state(TRISTATE_INDET);
+else
+aCurrentItem.m_xCheck->set_state(nValue > 0 ? TRISTATE_TRUE : 
TRISTATE_FALSE);
 aCurrentItem.m_xCheck->set_label(aDefinition.getDescription());
 aCurrentItem.m_xCheck->connect_toggled(aCheckBoxToggleHandler);
 aCurrentItem.m_xCheck->show();
@@ -183,7 +186,7 @@ OUString FontFeaturesDialog::createFontNameWithFeatures()
 {
 if (rItem.m_xCheck->get_visible())
 {
-if (sal_uInt32(rItem.m_xCheck->get_active()) != rItem.m_nDefault)
+if (rItem.m_xCheck->get_state() != TRISTATE_INDET)
 {
 if (!bFirst)
 sNameSuffix.append(vcl::font::FeatureSeparator);
@@ -191,7 +194,7 @@ OUString FontFeaturesDialog::createFontNameWithFeatures()
 bFirst = false;
 
 
sNameSuffix.append(vcl::font::featureCodeAsString(rItem.m_aFeatureCode));
-if (!rItem.m_xCheck->get_active())
+if (rItem.m_xCheck->get_state() == TRISTATE_FALSE)
 sNameSuffix.append("=0");
 }
 }
diff --git a/cui/source/inc/FontFeaturesDialog.hxx 
b/cui/source/inc/FontFeaturesDialog.hxx
index f542566ae2f5..6b30a33111b2 100644
--- a/cui/source/inc/FontFeaturesDialog.hxx
+++ b/cui/source/inc/FontFeaturesDialog.hxx
@@ -22,7 +22,7 @@ struct FontFeatureItem
 {
 FontFeatureItem(weld::Widget* pParent)
 : m_aFeatureCode(0)
-, m_nDefault(0)
+, m_nDefault(-1)
 , m_xBuilder(Application::CreateBuilder(pParent, 
"cui/ui/fontfragment.ui"))
 , m_xContainer(m_xBuilder->weld_widget("fontentry"))
 , m_xText(m_xBuilder->weld_label("label"))
@@ -32,7 +32,7 @@ struct FontFeatureItem
 }
 
 sal_uInt32 m_aFeatureCode;
-sal_uInt32 m_nDefault;
+sal_Int32 m_nDefault;
 std::unique_ptr m_xBuilder;
 std::unique_ptr m_xContainer;
 std::unique_ptr m_xText;
diff --git a/include/vcl/font/Feature.hxx b/include/vcl/font/Feature.hxx
index e66c7e2a4d72..addc4836e6ee 100644
--- a/include/vcl/font/Feature.hxx
+++ b/include/vcl/font/Feature.hxx
@@ -59,7 +59,7 @@ private:
 TranslateId m_pDescriptionID;
 OUString m_sNumericPart;
 uint32_t m_nCode;
-uint32_t m_nDefault;
+int32_t m_nDefault;
 FeatureParameterType m_eType;
 // the index of the parameter defines the enum value, string is the 
description
 std::vector m_aEnumParameters;
@@ -70,7 +70,7 @@ public:
   FeatureParameterType eType = FeatureParameterType::BOOL,
   std::vector&& rEnumParameters
   = std::vector

[Libreoffice-commits] core.git: Branch 'libreoffice-7-4' - vcl/source

2022-08-24 Thread Xisco Fauli (via logerrit)
 vcl/source/window/syswin.cxx |   29 +
 1 file changed, 17 insertions(+), 12 deletions(-)

New commits:
commit 105d129683b0e88bbb8e682d308786a587aa895f
Author: Xisco Fauli 
AuthorDate: Fri Aug 19 12:53:16 2022 +0200
Commit: Xisco Fauli 
CommitDate: Tue Aug 23 11:30:15 2022 +0200

tdf#150236: Revert "avoid uninitialized data when handling WindowState"

This reverts commit 8b46093b27b065ac9b537348ed909530b5ffd588.

Reason for revert: Considering the number of bugs already reported
for this issue since LibreOffice 7.4 was released, I would like
to revert this commit only on libreoffice-7-4 branch.
In master, the issue got fixed by 8b6000f6075725b2e17b8fa745251ea96d7185f1
< WIN drop window state redundancies > but reading the discussion
in https://gerrit.libreoffice.org/c/core/+/135809, it might be risky
to backport it to libreoffice-7-4, thus I prefer to revert this patch

Change-Id: I5c78d165afed59a3d578f53356682425c9de2cd3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138534
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
Reviewed-by: Luboš Luňák 
Reviewed-by: Xisco Fauli 

diff --git a/vcl/source/window/syswin.cxx b/vcl/source/window/syswin.cxx
index 113b2da02689..fa053499d623 100644
--- a/vcl/source/window/syswin.cxx
+++ b/vcl/source/window/syswin.cxx
@@ -755,10 +755,7 @@ void SystemWindow::GetWindowState(vcl::WindowData& rData) 
const
 return;
 
 if ( mbSysChild )
-{
-rData.setMask( vcl::WindowDataMask::NONE );
 return;
-}
 
 const vcl::Window* pWindow = this;
 while ( pWindow->mpWindowImpl->mpBorderWindow )
@@ -767,11 +764,9 @@ void SystemWindow::GetWindowState(vcl::WindowData& rData) 
const
 if ( pWindow->mpWindowImpl->mbFrame )
 {
 vcl::WindowData aState;
+aState.setMask(vcl::WindowDataMask::All);
 if ( mpWindowImpl->mpFrame->GetWindowState( &aState ) )
 {
-// Limit mask only to what we've received, the rest is not set.
-nValidMask &= aState.mask();
-rData.setMask( nValidMask );
 if ( nValidMask & vcl::WindowDataMask::X )
 rData.setX( aState.x() );
 if ( nValidMask & vcl::WindowDataMask::Y )
@@ -780,14 +775,26 @@ void SystemWindow::GetWindowState(vcl::WindowData& rData) 
const
 rData.setWidth( aState.width() );
 if ( nValidMask & vcl::WindowDataMask::Height )
 rData.setHeight( aState.height() );
-if ( nValidMask & vcl::WindowDataMask::MaximizedX )
+if ( aState.mask() & vcl::WindowDataMask::MaximizedX )
+{
 rData.SetMaximizedX( aState.GetMaximizedX() );
-if ( nValidMask & vcl::WindowDataMask::MaximizedY )
+nValidMask |= vcl::WindowDataMask::MaximizedX;
+}
+if ( aState.mask() & vcl::WindowDataMask::MaximizedY )
+{
 rData.SetMaximizedY( aState.GetMaximizedY() );
-if ( nValidMask & vcl::WindowDataMask::MaximizedWidth )
+nValidMask |= vcl::WindowDataMask::MaximizedY;
+}
+if ( aState.mask() & vcl::WindowDataMask::MaximizedWidth )
+{
 rData.SetMaximizedWidth( aState.GetMaximizedWidth() );
-if ( nValidMask & vcl::WindowDataMask::MaximizedHeight )
+nValidMask |= vcl::WindowDataMask::MaximizedWidth;
+}
+if ( aState.mask() & vcl::WindowDataMask::MaximizedHeight )
+{
 rData.SetMaximizedHeight( aState.GetMaximizedHeight() );
+nValidMask |= vcl::WindowDataMask::MaximizedHeight;
+}
 if ( nValidMask & vcl::WindowDataMask::State )
 {
 // #94144# allow Minimize again, should be masked out when 
read from configuration
@@ -807,8 +814,6 @@ void SystemWindow::GetWindowState(vcl::WindowData& rData) 
const
 SizeaSize = GetSizePixel();
 vcl::WindowState nState = vcl::WindowState::NONE;
 
-nValidMask &= vcl::WindowDataMask::PosSizeState;
-rData.setMask( nValidMask );
 if (nValidMask & vcl::WindowDataMask::X)
 rData.setX(aPos.X());
 if (nValidMask & vcl::WindowDataMask::Y)


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

2022-08-24 Thread László Németh (via logerrit)
 sw/qa/extras/uiwriter/uiwriter3.cxx |   70 
 sw/source/core/frmedt/fetab.cxx |   23 +++
 2 files changed, 93 insertions(+)

New commits:
commit 24087697d5cf78aac346d4dcea0596373e15a95c
Author: László Németh 
AuthorDate: Wed Aug 24 17:10:56 2022 +0200
Commit: László Németh 
CommitDate: Wed Aug 24 22:24:45 2022 +0200

tdf#150576 sw: fix cursor pos deleting at rows deleted already

Instead of jumping in the start of the document, set cursor
after (or deleting the last row, before) the rows deleted
already in Hide Changes mode with enabled change tracking.

Regression from commit a74c51025fa4519caaf461492e4ed8e68bd34885
"tdf#146962 sw: hide deleted row at deletion in Hide Changes".

Follow-up to commit 189aa05c6ea17a8e823b4eab18ea0d1131d9d73e
"tdf#148849 sw: fix cursor pos at tracked DeleteRow in Hide Changes".

Change-Id: Ifc2a7f41a57f413d27d9b464a0e464643d15f404
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138772
Tested-by: Jenkins
Reviewed-by: László Németh 

diff --git a/sw/qa/extras/uiwriter/uiwriter3.cxx 
b/sw/qa/extras/uiwriter/uiwriter3.cxx
index 775e3472b812..8b661082e8ba 100644
--- a/sw/qa/extras/uiwriter/uiwriter3.cxx
+++ b/sw/qa/extras/uiwriter/uiwriter3.cxx
@@ -3661,6 +3661,76 @@ CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testTdf148849)
 CPPUNIT_ASSERT_EQUAL(OUString("Row 2"), rNode.GetTextNode()->GetText());
 }
 
+CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testTdf150576)
+{
+// load a document with a table and an empty paragraph before the table
+SwDoc* pDoc = createSwDoc(DATA_DIRECTORY, "tdf148849.fodt");
+SwWrtShell* pWrtShell = pDoc->GetDocShell()->GetWrtShell();
+
+// record changes
+pDoc->getIDocumentRedlineAccess().SetRedlineFlags(RedlineFlags::On | 
RedlineFlags::ShowDelete
+  | 
RedlineFlags::ShowInsert);
+CPPUNIT_ASSERT_MESSAGE("redlining should be on",
+   pDoc->getIDocumentRedlineAccess().IsRedlineOn());
+// hide changes
+dispatchCommand(mxComponent, ".uno:ShowTrackedChanges", {});
+CPPUNIT_ASSERT(pWrtShell->GetLayout()->IsHideRedlines());
+
+uno::Reference xTablesSupplier(mxComponent, 
uno::UNO_QUERY);
+uno::Reference 
xTables(xTablesSupplier->getTextTables(),
+uno::UNO_QUERY);
+CPPUNIT_ASSERT_EQUAL(sal_Int32(1), xTables->getCount());
+
+// Check deletion of the first row, if the second row deleted already
+
+// put cursor in the second table row
+pWrtShell->Down(/*bSelect=*/false, /*nCount=*/2);
+SwNode& rNode = pWrtShell->GetCursor()->GetPoint()->GetNode();
+CPPUNIT_ASSERT_EQUAL(OUString("Row 2"), rNode.GetTextNode()->GetText());
+
+// delete the second table row
+pWrtShell->DeleteRow();
+
+// check cursor position (row 3)
+SwNode& rNode2 = pWrtShell->GetCursor()->GetPoint()->GetNode();
+CPPUNIT_ASSERT_EQUAL(OUString("Row 3"), rNode2.GetTextNode()->GetText());
+
+// put cursor in the first row
+pWrtShell->Up(/*bSelect=*/false, /*nCount=*/1);
+SwNode& rNode3 = pWrtShell->GetCursor()->GetPoint()->GetNode();
+CPPUNIT_ASSERT_EQUAL(OUString("12"), rNode3.GetTextNode()->GetText());
+
+// delete the first row
+pWrtShell->DeleteRow();
+
+// This was empty (cursor jumped in the start of the document instead of
+// the next not deleted row)
+SwNode& rNode4 = pWrtShell->GetCursor()->GetPoint()->GetNode();
+CPPUNIT_ASSERT_EQUAL(OUString("Row 3"), rNode4.GetTextNode()->GetText());
+
+// Check skipping previous lines
+
+// restore deleted rows
+dispatchCommand(mxComponent, ".uno:Undo", {});
+dispatchCommand(mxComponent, ".uno:Undo", {});
+Scheduler::ProcessEventsToIdle();
+SwNode& rNode5 = pWrtShell->GetCursor()->GetPoint()->GetNode();
+CPPUNIT_ASSERT_EQUAL(OUString("Row 2"), rNode5.GetTextNode()->GetText());
+
+// delete the second row
+pWrtShell->DeleteRow();
+SwNode& rNode7 = pWrtShell->GetCursor()->GetPoint()->GetNode();
+CPPUNIT_ASSERT_EQUAL(OUString("Row 3"), rNode7.GetTextNode()->GetText());
+
+// delete the third, i.e. last row
+pWrtShell->DeleteRow();
+SwNode& rNode8 = pWrtShell->GetCursor()->GetPoint()->GetNode();
+
+// This was empty (cursor jumped in the start of the document instead of
+// the previous not deleted row)
+CPPUNIT_ASSERT_EQUAL(OUString("12"), rNode8.GetTextNode()->GetText());
+}
+
 CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testTdf132603)
 {
 createSwDoc();
diff --git a/sw/source/core/frmedt/fetab.cxx b/sw/source/core/frmedt/fetab.cxx
index ef6f558ca8aa..35655febd031 100644
--- a/sw/source/core/frmedt/fetab.cxx
+++ b/sw/source/core/frmedt/fetab.cxx
@@ -416,6 +416,16 @@ bool SwFEShell::DeleteRow(bool bCompleteTable)
 }
 SwTableBox* pNextBox = pDelLine->FindNextBox( pTableNd->GetTable(),
   

[Libreoffice-commits] help.git: Branch 'libreoffice-7-4' - source/text

2022-08-24 Thread Olivier Hallot (via logerrit)
 source/text/shared/06/youtubevideos.xhp |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 278086ec01e796c7668de4760a1f2cde09bbf370
Author: Olivier Hallot 
AuthorDate: Thu Aug 18 08:59:28 2022 -0300
Commit: Adolfo Jayme Barrientos 
CommitDate: Tue Aug 23 06:20:00 2022 +0200

Update LO7.4 new features video

(no translation needed)

Change-Id: Ic1290ef2d90aca04f1bf6df1aae5d19f64f5919f
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/138486
Tested-by: Jenkins
Reviewed-by: Olivier Hallot 
(cherry picked from commit a37e043d12c969f3c12686ff09bc9087130b91aa)
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/138425
Reviewed-by: Adolfo Jayme Barrientos 

diff --git a/source/text/shared/06/youtubevideos.xhp 
b/source/text/shared/06/youtubevideos.xhp
index f21c009ac..298682104 100644
--- a/source/text/shared/06/youtubevideos.xhp
+++ b/source/text/shared/06/youtubevideos.xhp
@@ -17,7 +17,7 @@
 
 
 
-
+
 
 
 


Re: Build failure with gpgme-1.18.0

2022-08-24 Thread Sam James


> On 22 Aug 2022, at 13:15, Andreas Radke  wrote:
> 
> Am Mon, 22 Aug 2022 11:37:35 +0200
> schrieb Thorsten Behrens :
> 
>> Hi,
>> 
>> Sam James wrote:
>> [...]
>> [...]
>> Up for removal:
>> - https://gerrit.libreoffice.org/c/core/+/138667
>> 
>> Andreas, if you could perhaps paste your error logs in that patch, so
>> there's a record? I'll then look into it.
>> 
>> Cheers,
>> 
>> -- Thorsten
> 
> I don't have a gerrit account so some notes here:
> 
> I had tried to remove these lines 12564-12567 from configure.ac to pass the 
> configure check.
> 

Please share a diff of what you removed. You can't simply remove the 
AC_CHECK_LIB
line with no other changes because GPGMEPP_LIBS will then be blank.

> https://cgit.freedesktop.org/libreoffice/core/tree/configure.ac?h=libreoffice-7-4-0#n12564
> 
> This leads to this build error later:
> [snip]
> I can give your patch a try in 7.4.x later
> 

Best,
sam

> -Andy
> Arch Linux



signature.asc
Description: Message signed with OpenPGP


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

2022-08-24 Thread Caolán McNamara (via logerrit)
 vcl/unx/generic/gdi/cairotextrender.cxx |   19 ++-
 1 file changed, 10 insertions(+), 9 deletions(-)

New commits:
commit 96d71754db51bf4eb0fba98a759e90a373e1d10a
Author: Caolán McNamara 
AuthorDate: Mon Aug 22 13:22:04 2022 +0100
Commit: Caolán McNamara 
CommitDate: Mon Aug 22 20:30:01 2022 +0200

tdf#150507 set hint style even if the platform returns no default font 
options

if the platform (e.g. gen/kf5) doesn't return anything for
GetCairoFontOptions() but we have need for specific font options then we
also need to set them

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

diff --git a/vcl/unx/generic/gdi/cairotextrender.cxx 
b/vcl/unx/generic/gdi/cairotextrender.cxx
index 7300562d5d68..1e2e75c01d79 100644
--- a/vcl/unx/generic/gdi/cairotextrender.cxx
+++ b/vcl/unx/generic/gdi/cairotextrender.cxx
@@ -191,14 +191,15 @@ void CairoTextRender::DrawTextLayout(const 
GenericSalLayout& rLayout, const SalG
 __lsan_disable();
 #endif
 
-if (const cairo_font_options_t* pFontOptions = 
GetSalInstance()->GetCairoFontOptions())
-{
-const StyleSettings& rStyleSettings = 
Application::GetSettings().GetStyleSettings();
-bool bDisableAA = !rStyleSettings.GetUseFontAAFromSystem() && 
!rGraphics.getAntiAlias();
+const StyleSettings& rStyleSettings = 
Application::GetSettings().GetStyleSettings();
+const bool bDisableAA = !rStyleSettings.GetUseFontAAFromSystem() && 
!rGraphics.getAntiAlias();
+const bool bResolutionIndependentLayoutEnabled = 
rGraphics.getTextRenderModeForResolutionIndependentLayoutEnabled();
 
-const bool bResolutionIndependentLayoutEnabled = 
rGraphics.getTextRenderModeForResolutionIndependentLayoutEnabled();
-cairo_hint_style_t eHintStyle = 
cairo_font_options_get_hint_style(pFontOptions);
-cairo_hint_metrics_t eHintMetricsStyle = 
cairo_font_options_get_hint_metrics(pFontOptions);
+const cairo_font_options_t* pFontOptions = 
GetSalInstance()->GetCairoFontOptions();
+if (pFontOptions || bDisableAA || bResolutionIndependentLayoutEnabled)
+{
+cairo_hint_style_t eHintStyle = pFontOptions ? 
cairo_font_options_get_hint_style(pFontOptions) : CAIRO_HINT_STYLE_DEFAULT;
+cairo_hint_metrics_t eHintMetricsStyle = pFontOptions ? 
cairo_font_options_get_hint_metrics(pFontOptions) : CAIRO_HINT_METRICS_DEFAULT;
 bool bAllowedHintStyle = !bResolutionIndependentLayoutEnabled || 
(eHintStyle == CAIRO_HINT_STYLE_NONE);
 bool bAllowedHintMetricStyle = !bResolutionIndependentLayoutEnabled || 
(eHintMetricsStyle == CAIRO_HINT_METRICS_OFF);
 
@@ -206,7 +207,7 @@ void CairoTextRender::DrawTextLayout(const 
GenericSalLayout& rLayout, const SalG
 {
 // Disable font AA in case global AA setting is supposed to affect
 // font rendering (not the default) and AA is disabled.
-cairo_font_options_t* pOptions = 
cairo_font_options_copy(pFontOptions);
+cairo_font_options_t* pOptions = pFontOptions ? 
cairo_font_options_copy(pFontOptions) : cairo_font_options_create();
 if (bDisableAA)
 cairo_font_options_set_antialias(pOptions, 
CAIRO_ANTIALIAS_NONE);
 if (!bAllowedHintMetricStyle)
@@ -216,7 +217,7 @@ void CairoTextRender::DrawTextLayout(const 
GenericSalLayout& rLayout, const SalG
 cairo_set_font_options(cr, pOptions);
 cairo_font_options_destroy(pOptions);
 }
-else
+else if (pFontOptions)
 cairo_set_font_options(cr, pFontOptions);
 }
 


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

2022-08-24 Thread László Németh (via logerrit)
 sw/qa/extras/uiwriter/data/tdf148849.fodt |   53 ++
 sw/qa/extras/uiwriter/uiwriter3.cxx   |   34 +++
 sw/source/core/frmedt/fetab.cxx   |   27 ++-
 3 files changed, 106 insertions(+), 8 deletions(-)

New commits:
commit 189aa05c6ea17a8e823b4eab18ea0d1131d9d73e
Author: László Németh 
AuthorDate: Mon Aug 22 11:18:23 2022 +0200
Commit: László Németh 
CommitDate: Mon Aug 22 18:08:05 2022 +0200

tdf#148849 sw: fix cursor pos at tracked DeleteRow in Hide Changes

In Hide Changes mode, the text cursor jumped to the start of the
document after tracked deletion of a table row, instead of
remaining in the table in the next table row.

Regression from commit a74c51025fa4519caaf461492e4ed8e68bd34885
"tdf#146962 sw: hide deleted row at deletion in Hide Changes".

Change-Id: Iff959c9a9940db013827e1c827bcb92c07b4b26a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138683
Tested-by: Jenkins
Reviewed-by: László Németh 

diff --git a/sw/qa/extras/uiwriter/data/tdf148849.fodt 
b/sw/qa/extras/uiwriter/data/tdf148849.fodt
new file mode 100644
index ..07efa8bb6dbd
--- /dev/null
+++ b/sw/qa/extras/uiwriter/data/tdf148849.fodt
@@ -0,0 +1,53 @@
+
+
+http://www.w3.org/TR/css3-text/"; 
xmlns:grddl="http://www.w3.org/2003/g/data-view#"; 
xmlns:xhtml="http://www.w3.org/1999/xhtml"; 
xmlns:formx="urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0"
 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns:xsd="http://www.w3.org/2001/XMLSchema"; 
xmlns:dom="http://www.w3.org/2001/xml-events"; 
xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" 
xmlns:xforms="http://www.w3.org/2002/xforms"; 
xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0" 
xmlns:loext="urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.0"
 xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0" 
xmlns:drawooo="http://openoffice.org/2010/draw"; 
xmlns:math="http://www.w3.org/1998/Math/MathML"; 
xmlns:tableooo="http://openoffice.org/2009/table"; 
xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" 
xmlns:oooc="http://openoffice.org/2004/calc"; 
xmlns:ooow="http://openoffice.org/200
 4/writer" 
xmlns:calcext="urn:org:documentfoundation:names:experimental:calc:xmlns:calcext:1.0"
 xmlns:config="urn:oasis:names:tc:opendocument:xmlns:config:1.0" 
xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" 
xmlns:xlink="http://www.w3.org/1999/xlink"; 
xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" 
xmlns:dc="http://purl.org/dc/elements/1.1/"; 
xmlns:ooo="http://openoffice.org/2004/office"; 
xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" 
xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" 
xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" 
xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" 
xmlns:rpt="http://openoffice.org/2005/report"; 
xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" 
xmlns:officeooo="http://openoffice.org/2009/office"; 
xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" 
xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" 
xmlns:table="urn:oasis:names:tc:open
 document:xmlns:table:1.0" 
xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" 
office:version="1.3" office:mimetype="application/vnd.oasis.opendocument.text">
+ 
+  
+   
+
+ 
+  
+   xxx4
+   2021-09-21T14:41:20
+  
+ 
+
+
+ 
+  
+   xxx4
+   2021-09-21T14:41:20
+  
+ 
+
+   
+   
+
+
+
+
+
+   
+   
+   
+
+
+ 
+  12
+ 
+
+
+ 
+  Row 2
+ 
+
+
+ 
+  Row 3
+ 
+
+   
+   
+  
+ 
+
diff --git a/sw/qa/extras/uiwriter/uiwriter3.cxx 
b/sw/qa/extras/uiwriter/uiwriter3.cxx
index 24d34f512388..775e3472b812 100644
--- a/sw/qa/extras/uiwriter/uiwriter3.cxx
+++ b/sw/qa/extras/uiwriter/uiwriter3.cxx
@@ -3627,6 +3627,40 @@ CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testTdf146573)
 CPPUNIT_ASSERT_EQUAL(OUString("204"), xCellA4->getString());
 }
 
+CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testTdf148849)
+{
+// load a document with a table and an empty paragraph before the table
+SwDoc* pDoc = createSwDoc(DATA_DIRECTORY, "tdf148849.fodt");
+SwWrtShell* pWrtShell = pDoc->GetDocShell()->GetWrtShell();
+
+// record changes
+pDoc->getIDocumentRedlineAccess().SetRedlineFlags(RedlineFlags::On | 
RedlineFlags::ShowDelete
+  | 
RedlineFlags::ShowInsert);
+CPPUNIT_ASSERT_MESSAGE("redlining should be on",
+   pDoc->getIDocumentRedlineAccess().IsRedlineOn());
+// hide changes
+dispatchCommand(mxComponent, ".uno:ShowTrackedChanges", {});
+CPPUNIT_ASSERT(pWrtShell->GetLayout()->IsHideRedlines());
+
+uno::Reference xTable

Re: Build failure with gpgme-1.18.0

2022-08-24 Thread Andreas Radke
Am Mon, 22 Aug 2022 11:37:35 +0200
schrieb Thorsten Behrens :

> Hi,
> 
> Sam James wrote:
>  [...]  
>  [...]  
> Up for removal:
>  - https://gerrit.libreoffice.org/c/core/+/138667
> 
> Andreas, if you could perhaps paste your error logs in that patch, so
> there's a record? I'll then look into it.
> 
> Cheers,
> 
> -- Thorsten

I don't have a gerrit account so some notes here:

I had tried to remove these lines 12564-12567 from configure.ac to pass the 
configure check.

https://cgit.freedesktop.org/libreoffice/core/tree/configure.ac?h=libreoffice-7-4-0#n12564

This leads to this build error later:


[build CXX] idl/source/prj/command.cxx
/usr/bin/ld: /tmp/cccDZPYB.ltrans9.ltrans.o: in function 
`comphelper::DocPasswordHelper::decryptGpgSession(com::sun::star::uno::Sequence
 > const&)':
:(.text+0x796e): undefined reference to `GpgME::initializeLibrary()'
/usr/bin/ld: :(.text+0x7980): undefined reference to 
`GpgME::checkEngine(GpgME::Protocol)'
/usr/bin/ld: :(.text+0x7998): undefined reference to 
`GpgME::Context::createForProtocol(GpgME::Protocol)'
/usr/bin/ld: :(.text+0x79be): undefined reference to 
`GpgME::Context::setArmor(bool)'
/usr/bin/ld: :(.text+0x7a6e): undefined reference to 
`GpgME::Data::Data(char const*, unsigned long, bool)'
/usr/bin/ld: :(.text+0x7a7e): undefined reference to 
`GpgME::Data::Data()'
/usr/bin/ld: :(.text+0x7a9f): undefined reference to 
`GpgME::Context::decrypt(GpgME::Data const&, GpgME::Data&)'
/usr/bin/ld: :(.text+0x7aac): undefined reference to 
`GpgME::Data::seek(long, int)'
/usr/bin/ld: :(.text+0x7adb): undefined reference to 
`GpgME::Data::read(void*, unsigned long)'
/usr/bin/ld: :(.text+0x7e09): undefined reference to 
`GpgME::Error::isCanceled() const'
/usr/bin/ld: :(.text+0x7e25): undefined reference to 
`GpgME::Error::isCanceled() const'
/usr/bin/ld: :(.text+0x7ee0): undefined reference to 
`GpgME::Data::seek(long, int)'
/usr/bin/ld: :(.text+0x7f33): undefined reference to 
`GpgME::Data::read(void*, unsigned long)'
/usr/bin/ld: /tmp/cccDZPYB.ltrans13.ltrans.o: in function 
`comphelper::OStorageHelper::CreateGpgPackageEncryptionData()':
:(.text+0x750e): undefined reference to 
`GpgME::checkEngine(GpgME::Protocol)'
/usr/bin/ld: :(.text+0x7526): undefined reference to 
`GpgME::Context::createForProtocol(GpgME::Protocol)'
/usr/bin/ld: :(.text+0x754c): undefined reference to 
`GpgME::Context::setArmor(bool)'
/usr/bin/ld: :(.text+0x765d): undefined reference to 
`GpgME::Context::key(char const*, GpgME::Error&, bool)'
/usr/bin/ld: :(.text+0x76ec): undefined reference to 
`GpgME::Data::Data(char const*, unsigned long, bool)'
/usr/bin/ld: :(.text+0x7703): undefined reference to 
`GpgME::Data::Data()'
/usr/bin/ld: :(.text+0x7735): undefined reference to 
`GpgME::Context::encrypt(std::vector > 
const&, GpgME::Data const&, GpgME::Data&, GpgME::Context::EncryptionFlags)'
/usr/bin/ld: :(.text+0x7742): undefined reference to 
`GpgME::Data::seek(long, int)'
/usr/bin/ld: :(.text+0x776b): undefined reference to 
`GpgME::Data::read(void*, unsigned long)'
/usr/bin/ld: :(.text+0x77c9): undefined reference to 
`GpgME::Data::seek(long, int)'
/usr/bin/ld: :(.text+0x780e): undefined reference to 
`GpgME::Data::read(void*, unsigned long)'
/usr/bin/ld: :(.text+0x80a1): undefined reference to 
`GpgME::Error::isCanceled() const'
/usr/bin/ld: :(.text+0x84ed): undefined reference to 
`GpgME::Error::isCanceled() const'
collect2: error: ld returned 1 exit status
make[1]: *** 
[/build/libreoffice-fresh/src/libreoffice-7.4.0.3/comphelper/Library_comphelper.mk:20:
 
/build/libreoffice-fresh/src/libreoffice-7.4.0.3/instdir/program/libcomphelper.so]
 Error 1
make[1]: *** Waiting for unfinished jobs
make: *** [Makefile:289: build] Error 2
==> ERROR: A failure occurred in build().


I can give your patch a try in 7.4.x later

-Andy
Arch Linux


pgpPtGKtWc4M6.pgp
Description: Digitale Signatur von OpenPGP


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

2022-08-24 Thread Miklos Vajna (via logerrit)
 sw/qa/core/text/text.cxx   |   43 +
 sw/source/core/text/itrtxt.cxx |   37 ++-
 sw/source/core/text/porrst.cxx |   16 ++-
 sw/source/core/text/txtfly.cxx |   19 --
 4 files changed, 107 insertions(+), 8 deletions(-)

New commits:
commit 11d0ac7643b2a558a84931ac38e0e77b48e1e380
Author: Miklos Vajna 
AuthorDate: Mon Aug 15 15:00:47 2022 +0200
Commit: Michael Stahl 
CommitDate: Mon Aug 22 11:36:52 2022 +0200

tdf#148289 sw clearing breaks: fix vertical layout

There were 3 problems here:

1) SwTextFly::GetMaxBottom() gets an already swapped frame, so going via
   the aRectFnSet abstraction is not correct, need to use Left() and
   similar functions directly.

2) SwTextCursor::AdjustBaseLine() centers portions in the vertical case,
   so a clearing break portion with larger height will push the other
   portions towards the left, and this is not wanted. Fix this by
   filtering out the (logic) height of the clearing break portions in
   the vertical case.

3) The fix for 2) has the side effect that the non-printable line break
   indicator character now has the wrong (logic) top position in
   SwBreakPortion::Paint(). Fix this by compensating for the offset done in
   AdjustBaseLine().

No functional changes intended for the horizontal layout.

Change-Id: I9ea27b4247944cbab8e96c5c5e2c8f82bbbd731c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138314
Reviewed-by: Miklos Vajna 
Tested-by: Jenkins
(cherry picked from commit 251589c17c0dfa33cf5e5e5bb1ed782d2293a67c)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138420
Reviewed-by: Michael Stahl 

diff --git a/sw/qa/core/text/text.cxx b/sw/qa/core/text/text.cxx
index d94fb4c63e3b..0e608b097d9d 100644
--- a/sw/qa/core/text/text.cxx
+++ b/sw/qa/core/text/text.cxx
@@ -412,6 +412,49 @@ CPPUNIT_TEST_FIXTURE(SwCoreTextTest, 
testClearingLineBreakLeftRTL)
 assertXPath(pXmlDoc, "//SwParaPortion/SwLineLayout[1]", "height", "276");
 }
 
+CPPUNIT_TEST_FIXTURE(SwCoreTextTest, testClearingLineBreakVertical)
+{
+// Given a document with an anchored object in a vertical page and a 
clearing break (type=all):
+loadURL("private:factory/swriter", nullptr);
+uno::Reference xFactory(mxComponent, 
uno::UNO_QUERY);
+uno::Reference xDocument(mxComponent, uno::UNO_QUERY);
+uno::Reference xText = xDocument->getText();
+uno::Reference xCursor = xText->createTextCursor();
+uno::Reference 
xStandard(getStyles("PageStyles")->getByName("Standard"),
+  uno::UNO_QUERY);
+xStandard->setPropertyValue("WritingMode", 
uno::Any(text::WritingMode2::TB_RL));
+{
+uno::Reference xShape(
+xFactory->createInstance("com.sun.star.drawing.RectangleShape"), 
uno::UNO_QUERY);
+xShape->setSize(awt::Size(5000, 5000));
+uno::Reference xShapeProps(xShape, 
uno::UNO_QUERY);
+xShapeProps->setPropertyValue("AnchorType",
+  
uno::Any(text::TextContentAnchorType_AT_CHARACTER));
+uno::Reference xShapeContent(xShape, 
uno::UNO_QUERY);
+xText->insertTextContent(xCursor, xShapeContent, /*bAbsorb=*/false);
+}
+uno::Reference xLineBreak(
+xFactory->createInstance("com.sun.star.text.LineBreak"), 
uno::UNO_QUERY);
+uno::Reference xLineBreakProps(xLineBreak, 
uno::UNO_QUERY);
+auto eClear = static_cast(SwLineBreakClear::ALL);
+xLineBreakProps->setPropertyValue("Clear", uno::Any(eClear));
+xText->insertString(xCursor, "foo", /*bAbsorb=*/false);
+xText->insertTextContent(xCursor, xLineBreak, /*bAbsorb=*/false);
+xText->insertString(xCursor, "bar", /*bAbsorb=*/false);
+
+// When laying out that document:
+calcLayout();
+
+// Then make sure the "bar" does jump (logic) down the correct amount:
+xmlDocUniquePtr pXmlDoc = parseLayoutDump();
+// Without the accompanying fix in place, this test would have failed with:
+// - Expected: 2837
+// - Actual  : 7135
+// i.e. the expected break height is the twips value of the 5cm rectangle 
size, it was much
+// more.
+assertXPath(pXmlDoc, "//SwParaPortion/SwLineLayout[1]/SwBreakPortion", 
"height", "2837");
+}
+
 CPPUNIT_TEST_FIXTURE(SwCoreTextTest, testClearingLineBreakHeader)
 {
 // Given a document with a shape in the header and a clearing break in the 
body text:
diff --git a/sw/source/core/text/itrtxt.cxx b/sw/source/core/text/itrtxt.cxx
index 53e084b03736..1d1eed3e0837 100644
--- a/sw/source/core/text/itrtxt.cxx
+++ b/sw/source/core/text/itrtxt.cxx
@@ -27,6 +27,7 @@
 #include 
 #include 
 #include "porfld.hxx"
+#include "porrst.hxx"
 
 #include "itrtxt.hxx"
 #include 
@@ -283,7 +284,41 @@ SwTwips SwTextCursor::AdjustBaseLine( const SwLineLayout& 
rLine,
 if (GetInfo().GetT

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

2022-08-24 Thread Mike Kaganski (via logerrit)
 desktop/source/lib/init.cxx   |4 ++--
 vcl/source/control/button.cxx |4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

New commits:
commit 5b9fd9222a10ce9fcf632e940ed720f990e183da
Author: Mike Kaganski 
AuthorDate: Mon Aug 22 09:00:03 2022 +0300
Commit: Mike Kaganski 
CommitDate: Mon Aug 22 10:22:52 2022 +0200

Use comphelper::Base64::encode taking OStringBuffer where applicable

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

diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index 2f378ada3a6a..91f6b771a8f1 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -4587,7 +4587,7 @@ static bool encodeImageAsHTML(
 // Encode in base64.
 auto aSeq = Sequence(reinterpret_cast(aRet.getStr()),
aRet.getLength());
-OUStringBuffer aBase64Data;
+OStringBuffer aBase64Data;
 comphelper::Base64::encode(aBase64Data, aSeq);
 
 // Embed in HTML.
@@ -4598,7 +4598,7 @@ static bool encodeImageAsHTML(
 + getGenerator().toUtf8()
 + "\"/>"
 "";
++ aBase64Data + "\"/>";
 
 return true;
 }
diff --git a/vcl/source/control/button.cxx b/vcl/source/control/button.cxx
index 6b7265d8e85f..ae97d953b4c3 100644
--- a/vcl/source/control/button.cxx
+++ b/vcl/source/control/button.cxx
@@ -628,9 +628,9 @@ void Button::DumpAsPropertyTree(tools::JsonWriter& 
rJsonWriter)
 if(GraphicConverter::Export(aOStm, GetModeImage().GetBitmapEx(), 
ConvertDataFormat::PNG) == ERRCODE_NONE)
 {
 css::uno::Sequence aSeq( static_cast(aOStm.GetData()), aOStm.Tell());
-OUStringBuffer aBuffer("data:image/png;base64,");
+OStringBuffer aBuffer("data:image/png;base64,");
 ::comphelper::Base64::encode(aBuffer, aSeq);
-rJsonWriter.put("image", aBuffer.makeStringAndClear());
+rJsonWriter.put("image", aBuffer);
 }
 }
 


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

2022-08-24 Thread Mike Kaganski (via logerrit)
 comphelper/source/misc/base64.cxx |   38 +++---
 1 file changed, 15 insertions(+), 23 deletions(-)

New commits:
commit 02cf7ccf3f1abc245c494fd400ac19512c3904e6
Author: Mike Kaganski 
AuthorDate: Mon Aug 22 09:46:34 2022 +0300
Commit: Mike Kaganski 
CommitDate: Mon Aug 22 10:06:22 2022 +0200

Optimize and deduplicate Base64::encode a bit

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

diff --git a/comphelper/source/misc/base64.cxx 
b/comphelper/source/misc/base64.cxx
index 5e3e3ca0afb5..2646f297d7aa 100644
--- a/comphelper/source/misc/base64.cxx
+++ b/comphelper/source/misc/base64.cxx
@@ -61,15 +61,11 @@ const
 //p   q   r   s   t   u   v   w   x   y   z
 
 
-static void ThreeByteToFourByte(const sal_Int8* pBuffer, const sal_Int32 
nStart, const sal_Int32 nFullLen, char* aCharBuffer)
+template 
+static void ThreeByteToFourByte(const sal_Int8* pBuffer, const sal_Int32 
nStart, const sal_Int32 nFullLen, C* aCharBuffer)
 {
-sal_Int32 nLen(nFullLen - nStart);
-if (nLen > 3)
-nLen = 3;
-if (nLen == 0)
-{
-return;
-}
+const sal_Int32 nLen(std::min(nFullLen - nStart, sal_Int32(3)));
+assert(nLen > 0); // We are never expected to leave the output buffer 
uninitialized
 
 sal_Int32 nBinaer;
 switch (nLen)
@@ -94,7 +90,7 @@ static void ThreeByteToFourByte(const sal_Int8* pBuffer, 
const sal_Int32 nStart,
 break;
 }
 
-aCharBuffer[0] = aCharBuffer[1] = aCharBuffer[2] = aCharBuffer[3] = '=';
+aCharBuffer[2] = aCharBuffer[3] = '=';
 
 sal_uInt8 nIndex (static_cast((nBinaer & 0xFC) >> 18));
 aCharBuffer[0] = aBase64EncodeTable [nIndex];
@@ -113,32 +109,28 @@ static void ThreeByteToFourByte(const sal_Int8* pBuffer, 
const sal_Int32 nStart,
 }
 }
 
-void Base64::encode(OStringBuffer& aStrBuffer, const uno::Sequence& 
aPass)
+template 
+static void base64encode(Buffer& aStrBuffer, const uno::Sequence& 
aPass)
 {
 sal_Int32 i(0);
 sal_Int32 nBufferLength(aPass.getLength());
+aStrBuffer.ensureCapacity(aStrBuffer.getLength() + (nBufferLength * 4 + 2) 
/ 3);
 const sal_Int8* pBuffer = aPass.getConstArray();
 while (i < nBufferLength)
 {
-char aCharBuffer[4];
-ThreeByteToFourByte(pBuffer, i, nBufferLength, aCharBuffer);
-aStrBuffer.append(aCharBuffer, std::size(aCharBuffer));
+ThreeByteToFourByte(pBuffer, i, nBufferLength, 
aStrBuffer.appendUninitialized(4));
 i += 3;
 }
 }
 
+void Base64::encode(OStringBuffer& aStrBuffer, const uno::Sequence& 
aPass)
+{
+base64encode(aStrBuffer, aPass);
+}
+
 void Base64::encode(OUStringBuffer& aStrBuffer, const uno::Sequence& 
aPass)
 {
-sal_Int32 i(0);
-sal_Int32 nBufferLength(aPass.getLength());
-const sal_Int8* pBuffer = aPass.getConstArray();
-while (i < nBufferLength)
-{
-char aCharBuffer[4];
-ThreeByteToFourByte(pBuffer, i, nBufferLength, aCharBuffer);
-aStrBuffer.appendAscii(aCharBuffer, std::size(aCharBuffer));
-i += 3;
-}
+base64encode(aStrBuffer, aPass);
 }
 
 void Base64::decode(uno::Sequence& aBuffer, std::u16string_view 
sBuffer)


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

2022-08-24 Thread Caolán McNamara (via logerrit)
 sw/source/core/draw/dpage.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit c831f667d28640e6877b9b6fcf090db663c368f6
Author: Caolán McNamara 
AuthorDate: Sat Aug 20 11:00:32 2022 +0100
Commit: Caolán McNamara 
CommitDate: Sat Aug 20 16:30:19 2022 +0200

cid#1509231 Explicit null dereferenced

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

diff --git a/sw/source/core/draw/dpage.cxx b/sw/source/core/draw/dpage.cxx
index fc1c1ebb7524..ea3c0c83f191 100644
--- a/sw/source/core/draw/dpage.cxx
+++ b/sw/source/core/draw/dpage.cxx
@@ -212,7 +212,7 @@ bool SwDPage::RequestHelp( vcl::Window* pWindow, SdrView 
const * pView,
 MouseEvent 
aMEvt(pWindow->ScreenToOutputPixel(rEvt.GetMousePosPixel()), 1,
  MouseEventModifiers::NONE, MOUSE_LEFT);
 pView->PickAnything(aMEvt, SdrMouseEventKind::BUTTONDOWN, aVEvt);
-if (aVEvt.meEvent == SdrEventKind::ExecuteUrl)
+if (aVEvt.meEvent == SdrEventKind::ExecuteUrl && aVEvt.mpURLField)
 {
 sText = aVEvt.mpURLField->GetURL();
 aPixRect = pWindow->LogicToPixel(aVEvt.mpObj->GetLogicRect());


[Libreoffice-commits] core.git: Branch 'feature/wasm' - 13 commits - android/default-document config_host/config_wasm_strip.h.in config_host.mk.in configure.ac desktop/Executable_soffice_bin.mk deskto

2022-08-24 Thread Balazs Varga (via logerrit)
Rebased ref, commits from common ancestor:
commit 51a5ed689802a475157c6957aa5aca4e0f238c18
Author: Balazs Varga 
AuthorDate: Mon Aug 8 10:49:20 2022 +0200
Commit: Thorsten Behrens 
CommitDate: Fri Aug 19 14:12:16 2022 +0200

WIP: WASM activate and fix the Calc build and running

It was needed to allow accessibility for wasm calc build,
due to many addictions in calc.

This commit also revert: 26603bc9ef0116ed31c510dab82b69d3666447b5
(WASM fix orcus native exception handling (NEH))
Because Calc import using liborcus for loading styles.xml.

Change-Id: I4c330ef8eea7d08214bf357531ee0bf7383ab788

diff --git a/RepositoryModule_host.mk b/RepositoryModule_host.mk
index 287bd12b8323..7c30540dfe0c 100644
--- a/RepositoryModule_host.mk
+++ b/RepositoryModule_host.mk
@@ -50,14 +50,12 @@ endif
 
 $(eval $(call gb_Module_add_moduledirs,libreoffice,\
android \
-$(if $(ENABLE_WASM_STRIP_BASIC_CALC_DRAW_MATH_IMPRESS),, \
+$(if $(ENABLE_WASM_STRIP_BASIC_DRAW_MATH_IMPRESS),, \
animations \
 ) \
apple_remote \
avmedia \
-$(if $(ENABLE_WASM_STRIP_BASIC_CALC_DRAW_MATH_IMPRESS),, \
basctl \
-) \
basegfx \
basic \
bean \
@@ -129,28 +127,26 @@ $(eval $(call gb_Module_add_moduledirs,libreoffice,\
sal \
salhelper \
sax \
-$(if $(ENABLE_WASM_STRIP_BASIC_CALC_DRAW_MATH_IMPRESS),, \
sc \
scaddins \
sccomp \
-) \
$(call gb_Helper_optional,DESKTOP,scp2) \
scripting \
-$(if $(ENABLE_WASM_STRIP_BASIC_CALC_DRAW_MATH_IMPRESS),, \
+$(if $(ENABLE_WASM_STRIP_BASIC_DRAW_MATH_IMPRESS),, \
sd \
sdext \
 ) \
$(call gb_Helper_optional,DESKTOP,setup_native) \
sfx2 \
shell \
-$(if $(ENABLE_WASM_STRIP_BASIC_CALC_DRAW_MATH_IMPRESS),, \
+$(if $(ENABLE_WASM_STRIP_BASIC_DRAW_MATH_IMPRESS),, \
slideshow \
 ) \
smoketest \
solenv \
soltools \
sot \
-$(if $(ENABLE_WASM_STRIP_BASIC_CALC_DRAW_MATH_IMPRESS),, \
+$(if $(ENABLE_WASM_STRIP_BASIC_DRAW_MATH_IMPRESS),, \
starmath \
 ) \
 $(if $(ENABLE_CUSTOMTARGET_COMPONENTS),static) \
diff --git a/android/default-document/example_test.ods 
b/android/default-document/example_test.ods
new file mode 100644
index ..4ee7cb7e60ea
Binary files /dev/null and b/android/default-document/example_test.ods differ
diff --git a/config_host.mk.in b/config_host.mk.in
index 5afb150745d3..6956ec936d6e 100644
--- a/config_host.mk.in
+++ b/config_host.mk.in
@@ -214,8 +214,8 @@ export ENABLE_SKIA_DEBUG=@ENABLE_SKIA_DEBUG@
 export ENABLE_SYMBOLS_FOR=@ENABLE_SYMBOLS_FOR@
 export ENABLE_VALGRIND=@ENABLE_VALGRIND@
 export ENABLE_WASM_EXCEPTIONS=@ENABLE_WASM_EXCEPTIONS@
-export ENABLE_WASM_STRIP_ACCESSIBILITY=@ENABLE_WASM_STRIP@
-export ENABLE_WASM_STRIP_BASIC_CALC_DRAW_MATH_IMPRESS=@ENABLE_WASM_STRIP@
+export ENABLE_WASM_STRIP_ACCESSIBILITY=
+export ENABLE_WASM_STRIP_BASIC_DRAW_MATH_IMPRESS=@ENABLE_WASM_STRIP@
 export ENABLE_WASM_STRIP_CANVAS=@ENABLE_WASM_STRIP@
 export ENABLE_WASM_STRIP_CHART=
 export ENABLE_WASM_STRIP_DBACCESS=@ENABLE_WASM_STRIP@
@@ -231,6 +231,7 @@ export ENABLE_WASM_STRIP_RECENT=@ENABLE_WASM_STRIP@
 export ENABLE_WASM_STRIP_RECOVERYUI=@ENABLE_WASM_STRIP@
 export ENABLE_WASM_STRIP_SPLASH=@ENABLE_WASM_STRIP@
 export ENABLE_WASM_STRIP_SWEXPORTS=@ENABLE_WASM_STRIP@
+export ENABLE_WASM_STRIP_SCEXPORTS=@ENABLE_WASM_STRIP@
 export ENABLE_WERROR=@ENABLE_WERROR@
 export ENABLE_Z7_DEBUG=@ENABLE_Z7_DEBUG@
 export ENDIANNESS=@ENDIANNESS@
diff --git a/config_host/config_wasm_strip.h.in 
b/config_host/config_wasm_strip.h.in
index 3150a960995c..f1e63fbede53 100644
--- a/config_host/config_wasm_strip.h.in
+++ b/config_host/config_wasm_strip.h.in
@@ -15,5 +15,6 @@
 #define ENABLE_WASM_STRIP_RECOVERYUI 0
 #define ENABLE_WASM_STRIP_SPLASH 0
 #define ENABLE_WASM_STRIP_SWEXPORTS 0
+#define ENABLE_WASM_STRIP_SCEXPORTS 0
 
 #endif
diff --git a/configure.ac b/configure.ac
index 93982e20b899..6bd4587da6c4 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3048,7 +3048,7 @@ if test "$enable_wasm_strip" = "yes"; then
 test "${with_fonts+set}" = set || with_fonts=yes
 test "${with_locales+set}" = set || with_locales=en
 
-AC_DEFINE(ENABLE_WASM_STRIP_ACCESSIBILITY)
+#AC_DEFINE(ENABLE_WASM_STRIP_ACCESSIBILITY)
 AC_DEFINE(ENABLE_WASM_STRIP_CANVAS)
 #AC_DEFINE(ENABLE_WASM_STRIP_CHART)
 AC_DEFINE(ENABLE_WASM_STRIP_DBACCESS)
@@ -3063,6 +3063,7 @@ if test "$enable_wasm_strip" = "yes"; then
 AC_DEFINE(ENABLE_WASM_STRIP_RECOVERYUI)
 AC_DEFINE(ENABLE_WASM_STRIP_SPLASH)
 AC_DEFINE(ENABLE_WASM_STRIP_SWEXPORTS)
+AC_DEFINE(ENABLE_WASM_STRIP_SCEXPORTS)
 fi
 
 EMSCRIPTEN_NEH_MAJOR=3
diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk
index 8b3a20127637..327314fb4250 100644
--- a/extensions/Module_extensions.mk
+++ b/extensions/Module_extensions.mk
@@ -56,7 +5

[Libreoffice-commits] help.git: Changes to 'libreoffice-7-3-6'

2022-08-24 Thread Christian Lohmaier (via logerrit)
New branch 'libreoffice-7-3-6' available with the following commits:
commit 85fc209ef1d847a17879960cf223e483bace338e
Author: Christian Lohmaier 
Date:   Thu Aug 18 19:35:24 2022 +0200

Branch libreoffice-7-3-6

This is 'libreoffice-7-3-6' - the stable branch for the 7.3.6 release.
Only very safe changes, reviewed by three people are allowed.

If you want to commit more complicated fix for the next 7.3.x release,
please use the 'libreoffice-7-3' branch.

If you want to build something cool, unstable, and risky, use master.

Change-Id: If6bc7fccbe8cf6e52d50a3e926c91189d3e94d46



[Libreoffice-commits] core.git: officecfg/registry

2022-08-24 Thread Mike Kaganski (via logerrit)
 officecfg/registry/data/org/openoffice/Office/UI/MathCommands.xcu |5 +
 1 file changed, 5 insertions(+)

New commits:
commit 7b5e13a4df115b5aeb046ae78e5d26d3df63b354
Author: Mike Kaganski 
AuthorDate: Wed Aug 24 20:21:02 2022 +0300
Commit: Mike Kaganski 
CommitDate: Wed Aug 24 21:09:36 2022 +0200

Add .uno:SidebarDeck.ElementsDeck to MathCommands.xcu

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

diff --git a/officecfg/registry/data/org/openoffice/Office/UI/MathCommands.xcu 
b/officecfg/registry/data/org/openoffice/Office/UI/MathCommands.xcu
index 8adebca5535a..edf6b520fb9f 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/MathCommands.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/MathCommands.xcu
@@ -203,6 +203,11 @@
   ~Others
 
   
+  
+
+  Open the Elements Deck
+
+  
 
   
 


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

2022-08-24 Thread Caolán McNamara (via logerrit)
 connectivity/source/parse/sqlbison.y  |3 ++-
 connectivity/source/parse/sqlnode.cxx |3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)

New commits:
commit f6e24b10c9148f1cf6a2a93359ffcc0c7ec56152
Author: Caolán McNamara 
AuthorDate: Thu Aug 18 12:25:02 2022 +0100
Commit: Caolán McNamara 
CommitDate: Thu Aug 18 16:05:53 2022 +0200

cid#1500536 silence Resource leak

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

diff --git a/connectivity/source/parse/sqlbison.y 
b/connectivity/source/parse/sqlbison.y
index e0e9969ab68a..dd500ce2548b 100644
--- a/connectivity/source/parse/sqlbison.y
+++ b/connectivity/source/parse/sqlbison.y
@@ -4605,7 +4605,8 @@ std::unique_ptr 
OSQLParser::parseTree(OUString& rErrorMessage,
 
// clear the garbage collector
(*s_pGarbageCollector)->clearAndDelete();
-   m_pParseTree.release(); // because the garbage collector 
deleted it
+   // coverity[leaked_storage : FALSE] - because the garbage 
collector deleted it
+   m_pParseTree.release();
return nullptr;
}
else
diff --git a/connectivity/source/parse/sqlnode.cxx 
b/connectivity/source/parse/sqlnode.cxx
index ab93c41511ad..c62c17f5faff 100644
--- a/connectivity/source/parse/sqlnode.cxx
+++ b/connectivity/source/parse/sqlnode.cxx
@@ -1295,7 +1295,8 @@ std::unique_ptr 
OSQLParser::predicateTree(OUString& rErrorMessage
 
 // clear the garbage collector
 (*s_pGarbageCollector)->clearAndDelete();
-m_pParseTree.release(); // because the garbage collector deleted it
+// coverity[leaked_storage : FALSE] - because the garbage collector 
deleted it
+m_pParseTree.release();
 return nullptr;
 }
 else


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

2022-08-24 Thread Christian Lohmaier (via logerrit)
 desktop/source/app/crashreport.cxx |2 ++
 sc/source/ui/docshell/olinefun.cxx |3 +++
 2 files changed, 5 insertions(+)

New commits:
commit de3fcf4bea142fa376b043862ef2bde1db32098f
Author: Christian Lohmaier 
AuthorDate: Tue Aug 16 20:19:21 2022 +0200
Commit: Christian Lohmaier 
CommitDate: Thu Aug 18 16:06:46 2022 +0200

crashreport: __cpuid/__cpuidex are not available on arm64

…and from a quick glance similar features are not exposed to userland
applications on arm64:

https://docs.kernel.org/arm64/cpu-feature-registers.html
"The ARM architecture defines a set of feature registers, which describe
the capabilities of the CPU/system. Access to these system registers is
restricted from EL0 and there is no reliable way for an application to
extract this information to make better decisions at runtime.[…]"

Thus the CPU information would have to be gathered from the OS, probably
from the Windows registry, at least it should be possible to read the
name/model that way…

Change-Id: I39e3679a7c4c581d8e3e4f71842d7ea7cdc2ba67
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138380
Tested-by: Jenkins
Reviewed-by: Christian Lohmaier 

diff --git a/desktop/source/app/crashreport.cxx 
b/desktop/source/app/crashreport.cxx
index a14527c621e2..0458edf9793a 100644
--- a/desktop/source/app/crashreport.cxx
+++ b/desktop/source/app/crashreport.cxx
@@ -346,6 +346,7 @@ void CrashReporter::writeSystemInfo()
 #elif defined _WIN32
 void CrashReporter::writeSystemInfo()
 {
+#if !defined(_ARM64_)
 // Get CPU model name and flags.
 // See https://docs.microsoft.com/en-us/cpp/intrinsics/cpuid-cpuidex
 // and https://en.wikipedia.org/wiki/CPUID .
@@ -456,6 +457,7 @@ void CrashReporter::writeSystemInfo()
 }
 if( !flags.isEmpty())
 addKeyValue( "CPUFlags", flags.makeStringAndClear(), AddItem );
+#endif
 // Get total memory.
 MEMORYSTATUSEX memoryStatus;
 memoryStatus.dwLength = sizeof( memoryStatus );
commit 64c60a67930ebf9a1b19b4396c9fea3c4c973e62
Author: Caolán McNamara 
AuthorDate: Thu Aug 18 12:45:45 2022 +0100
Commit: Caolán McNamara 
CommitDate: Thu Aug 18 16:06:33 2022 +0200

cid#1509305 Dereference null return value

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

diff --git a/sc/source/ui/docshell/olinefun.cxx 
b/sc/source/ui/docshell/olinefun.cxx
index 76ea01eae3bc..70fafd8e1e2a 100644
--- a/sc/source/ui/docshell/olinefun.cxx
+++ b/sc/source/ui/docshell/olinefun.cxx
@@ -640,6 +640,9 @@ void ScOutlineDocFunc::ShowOutline( SCTAB nTab, bool 
bColumns, sal_uInt16 nLevel
 bRecord = false;
 
 ScOutlineTable* pTable = rDoc.GetOutlineTable( nTab );
+if (!pTable)
+return;
+
 ScOutlineArray& rArray = bColumns ? pTable->GetColArray() : 
pTable->GetRowArray();
 ScOutlineEntry* pEntry = rArray.GetEntry( nLevel, nEntry );
 SCCOLROW nStart = pEntry->GetStart();


[Libreoffice-commits] core.git: schema/libreoffice

2022-08-24 Thread Andrea Gelmini (via logerrit)
 schema/libreoffice/OpenDocument-v1.3+libreoffice-schema.rng |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 712901b388d8645d94e14b474288f97761f5a4e5
Author: Andrea Gelmini 
AuthorDate: Mon Aug 15 13:58:34 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Thu Aug 18 09:59:50 2022 +0200

Fix typo

Change-Id: Ie0757b332f4ddb0e9d9d6e2c97b7497766221dec
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138310
Tested-by: Jenkins
Reviewed-by: Julien Nabet 
Reviewed-by: Tomaž Vajngerl 

diff --git a/schema/libreoffice/OpenDocument-v1.3+libreoffice-schema.rng 
b/schema/libreoffice/OpenDocument-v1.3+libreoffice-schema.rng
index fe5c94a45ee4..5109a13687d6 100644
--- a/schema/libreoffice/OpenDocument-v1.3+libreoffice-schema.rng
+++ b/schema/libreoffice/OpenDocument-v1.3+libreoffice-schema.rng
@@ -2462,7 +2462,7 @@ 
xmlns:loext="urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.
 
   
 
-
+
   
 
   


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

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/inc/strings.hrc|3 -
 chart2/source/controller/dialogs/ObjectNameProvider.cxx   |2 
 chart2/source/controller/dialogs/dlg_ObjectProperties.cxx |2 
 chart2/source/controller/main/ChartController_Insert.cxx  |6 +-
 sw/source/core/crsr/crstrvl.cxx   |2 
 sw/source/core/crsr/pam.cxx   |4 -
 sw/source/core/doc/DocumentContentOperationsManager.cxx   |   16 ++---
 sw/source/core/doc/docbm.cxx  |4 -
 sw/source/core/doc/docedt.cxx |2 
 sw/source/core/doc/docglbl.cxx|4 -
 sw/source/core/doc/docsort.cxx|2 
 sw/source/core/doc/tblcpy.cxx |2 
 sw/source/core/docnode/nodes.cxx  |2 
 sw/source/core/edit/edfmt.cxx |2 
 sw/source/core/frmedt/fecopy.cxx  |2 
 sw/source/core/layout/sortedobjs.cxx  |2 
 sw/source/core/table/swtable.cxx  |2 
 sw/source/core/txtnode/modeltoviewhelper.cxx  |6 +-
 sw/source/core/undo/undobj.cxx|   38 +++---
 sw/source/core/unocore/unoobj2.cxx|4 -
 sw/source/core/unocore/unotext.cxx|2 
 sw/source/filter/html/htmltab.cxx |2 
 sw/source/filter/ww8/wrtww8.cxx   |2 
 sw/source/filter/ww8/ww8par2.cxx  |4 -
 24 files changed, 58 insertions(+), 59 deletions(-)

New commits:
commit 66faff4d3c9756e4a83933a07e2f9329ede9e043
Author: Tomaž Vajngerl 
AuthorDate: Tue Aug 16 16:44:55 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Thu Aug 18 08:47:53 2022 +0200

chart2: use only one "Data Table" string to simplify translation

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

diff --git a/chart2/inc/strings.hrc b/chart2/inc/strings.hrc
index 9a9943df1f3c..a60da15e0004 100644
--- a/chart2/inc/strings.hrc
+++ b/chart2/inc/strings.hrc
@@ -48,7 +48,6 @@
 #define STR_PAGE_APPEARANCE NC_("STR_PAGE_APPEARANCE", 
"Appearance")
 #define STR_PAGE_ILLUMINATION   
NC_("STR_PAGE_ILLUMINATION", "Illumination")
 #define STR_PAGE_ASIAN  NC_("STR_PAGE_ASIAN", 
"Asian Typography")
-#define STR_PAGE_DATA_TABLE NC_("STR_PAGE_DATA_TABLE", 
"Data Table")
 #define STR_OBJECT_AVERAGE_LINE_WITH_PARAMETERS 
NC_("STR_OBJECT_AVERAGE_LINE_WITH_PARAMETERS", "Mean value line with value 
%AVERAGE_VALUE and standard deviation %STD_DEVIATION")
 #define STR_OBJECT_AXIS NC_("STR_OBJECT_AXIS", 
"Axis")
 #define STR_OBJECT_AXIS_X   NC_("STR_OBJECT_AXIS_X", 
"X Axis")
@@ -98,7 +97,6 @@
 #define STR_OBJECT_DIAGRAM_WALL 
NC_("STR_OBJECT_DIAGRAM_WALL", "Chart Wall")
 #define STR_OBJECT_DIAGRAM_FLOOR
NC_("STR_OBJECT_DIAGRAM_FLOOR", "Chart Floor")
 #define STR_OBJECT_SHAPENC_("STR_OBJECT_SHAPE", 
"Drawing Object")
-#define STR_OBJECT_DATA_TABLE   
NC_("STR_OBJECT_DATA_TABLE", "Data Table")
 #define STR_TIP_DATASERIES  NC_("STR_TIP_DATASERIES", 
"Data Series '%SERIESNAME'")
 #define STR_TIP_DATAPOINT_INDEX 
NC_("STR_TIP_DATAPOINT_INDEX", "Data Point %POINTNUMBER")
 #define STR_TIP_DATAPOINT_VALUES
NC_("STR_TIP_DATAPOINT_VALUES", "Values: %POINTVALUES")
@@ -147,6 +145,7 @@
 #define STR_TEXT_DIRECTION_SUPER
NC_("STR_TEXT_DIRECTION_SUPER", "Use superordinate object settings")
 #define STR_PROPERTY_ROLE_FILLCOLOR 
NC_("STR_PROPERTY_ROLE_FILLCOLOR", "Fill Color")
 #define STR_PROPERTY_ROLE_BORDERCOLOR   
NC_("STR_PROPERTY_ROLE_BORDERCOLOR", "Border Color")
+#define STR_DATA_TABLE  NC_("STR_DATA_TABLE", 
"Data Table")
 
 #define STR_CONTROLTEXT_ERROR_BARS_FROM_DATA
NC_("STR_CONTROLTEXT_ERROR_BARS_FROM_DATA", "From Data Table")
 #define STR_REGRESSION_LINEAR   
NC_("STR_REGRESSION_LINEAR", "Linear")
diff --git a/chart2/source/controller/dialogs/ObjectNameProvider.cxx 
b/chart2/source/controller/dialogs/ObjectNameProvider.cxx
index b105ecc61211..84230ff14da7 100644
--- a/chart2/source/controller/dialogs/ObjectNameProvider.cxx
+++ b/chart2/source/controller/dialogs/ObjectNameProvider.cxx
@@ -315,7 +315,7 @@ OUString ObjectNameProvider::getName( ObjectType 
eObjectType, bool bPlural )
 aRet=SchResId(STR_OBJECT_CURVE_EQUATION);
 break;
 case OBJECTTYPE_DATA_TABLE:
-aRet=Sc

[Libreoffice-commits] core.git: Branch 'libreoffice-7-3' - sc/inc sc/source

2022-08-24 Thread Xisco Fauli (via logerrit)
 sc/inc/columnspanset.hxx  |3 +--
 sc/source/core/data/columnspanset.cxx |6 +++---
 2 files changed, 4 insertions(+), 5 deletions(-)

New commits:
commit 633a175914f0ab960965aae7de04dc8d99edb33c
Author: Xisco Fauli 
AuthorDate: Wed Aug 17 16:29:44 2022 +0200
Commit: Xisco Fauli 
CommitDate: Wed Aug 17 18:09:51 2022 +0200

tdf#150170: Revert "flatten TableType in ColumnSpanSet"

This reverts commit 99cd1d8834bb708afc81c825ff2b7992b7acb37d.

This commit is only reverted in libreoffice-7-3 branch.
In master and libreoffice-7-4 the issue is not reproducible
after the default Calc number of columns was increased to 16384

Change-Id: I28dcc1c56c803d49ea101dbb0ace7085f7a78820
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138445
Reviewed-by: Noel Grandin 
Tested-by: Jenkins
Reviewed-by: Xisco Fauli 

diff --git a/sc/inc/columnspanset.hxx b/sc/inc/columnspanset.hxx
index 926f0520e8a1..214bd90db16d 100644
--- a/sc/inc/columnspanset.hxx
+++ b/sc/inc/columnspanset.hxx
@@ -11,7 +11,6 @@
 
 #include "address.hxx"
 
-#include 
 #include 
 #include 
 
@@ -60,7 +59,7 @@ private:
 ColumnType(SCROW nStart, SCROW nEnd, bool bInit);
 };
 
-typedef std::vector> TableType;
+typedef std::vector> TableType;
 
 std::vector maTables;
 
diff --git a/sc/source/core/data/columnspanset.cxx 
b/sc/source/core/data/columnspanset.cxx
index a38ea7fffe35..8d9775e0cbfc 100644
--- a/sc/source/core/data/columnspanset.cxx
+++ b/sc/source/core/data/columnspanset.cxx
@@ -74,7 +74,7 @@ ColumnSpanSet::ColumnType& ColumnSpanSet::getColumn(const 
ScDocument& rDoc, SCTA
 rTab.resize(nCol+1);
 
 if (!rTab[nCol])
-rTab[nCol].emplace(0, rDoc.MaxRow(), /*bInit*/false);
+rTab[nCol].reset(new ColumnType(0, rDoc.MaxRow(), /*bInit*/false));
 
 return *rTab[nCol];
 }
@@ -156,7 +156,7 @@ void ColumnSpanSet::executeAction(Action& ac) const
 continue;
 
 ac.startColumn(nTab, nCol);
-const ColumnType& rCol = *rTab[nCol];
+ColumnType& rCol = *rTab[nCol];
 ColumnSpansType::const_iterator it = rCol.maSpans.begin(), itEnd = 
rCol.maSpans.end();
 SCROW nRow1, nRow2;
 nRow1 = it->first;
@@ -199,7 +199,7 @@ void ColumnSpanSet::executeColumnAction(ScDocument& rDoc, 
ColumnAction& ac) cons
 
 ScColumn& rColumn = pTab->aCol[nCol];
 ac.startColumn(&rColumn);
-const ColumnType& rCol = *rTab[nCol];
+ColumnType& rCol = *rTab[nCol];
 ColumnSpansType::const_iterator it = rCol.maSpans.begin(), itEnd = 
rCol.maSpans.end();
 SCROW nRow1, nRow2;
 nRow1 = it->first;


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

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/source/view/main/DataTableView.cxx |   21 -
 1 file changed, 16 insertions(+), 5 deletions(-)

New commits:
commit 79b066055797b1f48aac3feccd86f1c8d21ca76d
Author: Tomaž Vajngerl 
AuthorDate: Thu Aug 11 22:44:56 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Wed Aug 24 20:15:07 2022 +0200

chart2: render line legend symbols better in a data table

Change-Id: I556b4f249688a3836bbeeb3f554cb9ecf1d31f65
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138301
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 
(cherry picked from commit e4e5d77bcc30beb1d976fadf5da0247f00f5b9cc)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138603
Tested-by: Jenkins CollaboraOffice 

diff --git a/chart2/source/view/main/DataTableView.cxx 
b/chart2/source/view/main/DataTableView.cxx
index 77d9943ab9ec..aa1e7adb9e77 100644
--- a/chart2/source/view/main/DataTableView.cxx
+++ b/chart2/source/view/main/DataTableView.cxx
@@ -288,17 +288,23 @@ void DataTableView::createShapes(basegfx::B2DVector 
const& rStart, basegfx::B2DV
 }
 
 // ROW HEADER
-// Prepare keys
+// Prepare keys (symbols)
+sal_Int32 nMaxSymbolWidth = 0;
 if (bKeys)
 {
-awt::Size aMaxSymbolExtent(300, 300);
+uno::Reference xFactory(m_xChartModel, 
uno::UNO_QUERY);
 for (VSeriesPlotter* pSeriesPlotter : m_pSeriesPlotterList)
 {
 if (pSeriesPlotter)
 {
-uno::Reference 
xFactory(m_xChartModel, uno::UNO_QUERY);
+sal_Int32 nSymbolWidth = 300;
+if (pSeriesPlotter->getLegendSymbolStyle() == 
LegendSymbolStyle::Line)
+nSymbolWidth = 600;
+
+nMaxSymbolWidth = std::max(nSymbolWidth, nMaxSymbolWidth);
+
 std::vector aNewEntries = 
pSeriesPlotter->createSymbols(
-aMaxSymbolExtent, m_xTarget, xFactory, 
m_xComponentContext);
+{ nSymbolWidth, 300 }, m_xTarget, xFactory, 
m_xComponentContext);
 aSymbols.insert(aSymbols.end(), aNewEntries.begin(), 
aNewEntries.end());
 }
 }
@@ -330,7 +336,10 @@ void DataTableView::createShapes(basegfx::B2DVector const& 
rStart, basegfx::B2DV
 xCellPropertySet->setPropertyValue("ParaAdjust",

uno::makeAny(style::ParagraphAdjust_LEFT));
 if (bKeys)
-xCellPropertySet->setPropertyValue("ParaLeftMargin", 
uno::makeAny(sal_Int32(500)));
+{
+xCellPropertySet->setPropertyValue("ParaLeftMargin",
+   
uno::makeAny(nMaxSymbolWidth + sal_Int32(200)));
+}
 }
 nRow++;
 }
@@ -379,6 +388,7 @@ void DataTableView::createShapes(basegfx::B2DVector const& 
rStart, basegfx::B2DV
 pTableObject->DistributeColumns(0, nColumnCount - 1, true, true);
 pTableObject->DistributeRows(0, nRowCount - 1, true, true);
 
+xBroadcaster->lockBroadcasts();
 uno::Reference 
xPropertySet(xTableColumns->getByIndex(0), uno::UNO_QUERY);
 sal_Int32 nWidth = 0;
 xPropertySet->getPropertyValue("Width") >>= nWidth;
@@ -412,6 +422,7 @@ void DataTableView::createShapes(basegfx::B2DVector const& 
rStart, basegfx::B2DV
 nTotalHeight += nHeight;
 }
 }
+xBroadcaster->unlockBroadcasts();
 }
 
 void DataTableView::initializeShapes(const 
css::uno::Reference& xTarget)


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

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/source/view/main/DataTableView.cxx |   19 +++
 1 file changed, 15 insertions(+), 4 deletions(-)

New commits:
commit 0ce3d7dd14e45bf239d55b63671aa416a0a91fc1
Author: Tomaž Vajngerl 
AuthorDate: Thu Aug 11 22:40:27 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Wed Aug 24 20:14:50 2022 +0200

chart2: fix rendering of table borders of row/column headers

The row/column headers didn't enable/disable the table borders
correctly when outline was enabled and horizontal and vertical
borders properties were disabled.

Change-Id: Ifcb059dd7d39890bbcaf55d3a68dce41eef586cf
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138300
Tested-by: Tomaž Vajngerl 
Reviewed-by: Tomaž Vajngerl 
(cherry picked from commit 5dcfa8f3750d549d895246c50285bb38690f9734)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138602

diff --git a/chart2/source/view/main/DataTableView.cxx 
b/chart2/source/view/main/DataTableView.cxx
index 1fe3b191b878..77d9943ab9ec 100644
--- a/chart2/source/view/main/DataTableView.cxx
+++ b/chart2/source/view/main/DataTableView.cxx
@@ -265,6 +265,8 @@ void DataTableView::createShapes(basegfx::B2DVector const& 
rStart, basegfx::B2DV
 sal_Int32 nColumn;
 sal_Int32 nRow;
 
+// COLUMN HEADER
+
 nColumn = 1;
 for (auto const& rString : m_aXValues)
 {
@@ -274,13 +276,19 @@ void DataTableView::createShapes(basegfx::B2DVector 
const& rStart, basegfx::B2DV
 if (xCellTextRange.is())
 {
 xCellTextRange->setString(rString);
-bool bLeft = bOutline || (bVBorder && nColumn > 1);
-setCellProperties(xPropertySet, bLeft, bOutline, bOutline, 
bOutline);
+
+bool bLeft
+= (bOutline && nColumn == 1) || (bVBorder && nColumn > 1 && 
nColumn < nColumnCount);
+bool bRight = (bOutline && nColumn == nColumnCount)
+  || (bVBorder && nColumn > 1 && nColumn < 
nColumnCount);
+setCellProperties(xPropertySet, bLeft, bOutline, bRight, bOutline);
 setCellCharAndParagraphProperties(xPropertySet);
 }
 nColumn++;
 }
 
+// ROW HEADER
+// Prepare keys
 if (bKeys)
 {
 awt::Size aMaxSymbolExtent(300, 300);
@@ -304,8 +312,10 @@ void DataTableView::createShapes(basegfx::B2DVector const& 
rStart, basegfx::B2DV
 uno::Reference xCellTextRange(xCell, uno::UNO_QUERY);
 if (xCellTextRange.is())
 {
-bool bTop = bOutline || (bHBorder && nRow > 1);
-setCellProperties(xCellPropertySet, bOutline, bTop, bOutline, 
bOutline);
+bool bTop = (bOutline && nRow == 1) || (bHBorder && nRow > 1 && 
nRow < nRowCount);
+bool bBottom
+= (bOutline && nRow == nRowCount) || (bHBorder && nRow > 1 && 
nRow < nRowCount);
+setCellProperties(xCellPropertySet, bOutline, bTop, bOutline, 
bBottom);
 
 auto xText = xCellTextRange->getText();
 xText->insertString(xText->getStart(), rSeriesName, false);
@@ -325,6 +335,7 @@ void DataTableView::createShapes(basegfx::B2DVector const& 
rStart, basegfx::B2DV
 nRow++;
 }
 
+// TABLE
 nRow = 1;
 for (auto const& rSeries : m_pDataSeriesValues)
 {


[Libreoffice-commits] core.git: Branch 'distro/collabora/co-22.05' - chart2/inc chart2/source include/svx svx/source

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/inc/ChartView.hxx   |5 
 chart2/source/view/axes/VAxisBase.cxx  |3 
 chart2/source/view/axes/VAxisBase.hxx  |5 
 chart2/source/view/axes/VCartesianAxis.cxx |5 
 chart2/source/view/axes/VCartesianAxis.hxx |4 
 chart2/source/view/axes/VCartesianCoordinateSystem.cxx |5 
 chart2/source/view/axes/VCartesianCoordinateSystem.hxx |3 
 chart2/source/view/axes/VCoordinateSystem.cxx  |3 
 chart2/source/view/axes/VPolarCoordinateSystem.cxx |3 
 chart2/source/view/axes/VPolarCoordinateSystem.hxx |3 
 chart2/source/view/charttypes/VSeriesPlotter.cxx   |  142 +
 chart2/source/view/inc/DataTableView.hxx   |   17 +-
 chart2/source/view/inc/LegendEntryProvider.hxx |9 +
 chart2/source/view/inc/VCoordinateSystem.hxx   |4 
 chart2/source/view/inc/VSeriesPlotter.hxx  |   15 +
 chart2/source/view/main/ChartView.cxx  |   13 -
 chart2/source/view/main/DataTableView.cxx  |  127 +++
 include/svx/svdotable.hxx  |2 
 svx/source/table/svdotable.cxx |   12 +
 19 files changed, 328 insertions(+), 52 deletions(-)

New commits:
commit 45556e32ef38188e555a3dc565b4fb2ca74aa05c
Author: Tomaž Vajngerl 
AuthorDate: Mon Jul 18 08:12:19 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Wed Aug 24 20:14:29 2022 +0200

chart2: Data table rendering of keys (legend symbols)

Change-Id: Iff13b188df18fe8f9919274869774f53f2ea323b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138299
Tested-by: Tomaž Vajngerl 
Reviewed-by: Tomaž Vajngerl 
(cherry picked from commit 9d6ffcc0572cc7917651489c69ca4b3452e89a89)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138585
Tested-by: Jenkins CollaboraOffice 

diff --git a/chart2/inc/ChartView.hxx b/chart2/inc/ChartView.hxx
index 2830e89309f8..e489a2d7d68e 100644
--- a/chart2/inc/ChartView.hxx
+++ b/chart2/inc/ChartView.hxx
@@ -181,6 +181,8 @@ public:
 
 void setViewDirty();
 
+css::uno::Reference const& 
getComponentContext() { return m_xCC;}
+
 /// See sfx2::XmlDump::dumpAsXml().
 void dumpAsXml(xmlTextWriterPtr pWriter) const override;
 
@@ -206,8 +208,7 @@ private: //methods
 private: //member
 ::osl::Mutex m_aMutex;
 
-css::uno::Reference< css::uno::XComponentContext>
-m_xCC;
+css::uno::Reference< css::uno::XComponentContext> m_xCC;
 
 chart::ChartModel& mrChartModel;
 
diff --git a/chart2/source/view/axes/VAxisBase.cxx 
b/chart2/source/view/axes/VAxisBase.cxx
index 209fc508f624..86f530a34a1f 100644
--- a/chart2/source/view/axes/VAxisBase.cxx
+++ b/chart2/source/view/axes/VAxisBase.cxx
@@ -247,7 +247,8 @@ void VAxisBase::updateUnscaledValuesAtTicks( TickIter& 
rIter )
 
 void 
VAxisBase::createDataTableView(std::vector>& 
/*rSeriesPlotterList*/,
 
uno::Reference const& /*xNumberFormatsSupplier*/,
-uno::Reference 
const& /*xChartDoc*/)
+uno::Reference 
const& /*xChartDoc*/,
+uno::Reference 
const& /*rComponentContext*/)
 {
 }
 
diff --git a/chart2/source/view/axes/VAxisBase.hxx 
b/chart2/source/view/axes/VAxisBase.hxx
index 6992ff05fd89..e64df679d458 100644
--- a/chart2/source/view/axes/VAxisBase.hxx
+++ b/chart2/source/view/axes/VAxisBase.hxx
@@ -24,6 +24,7 @@
 #include "Tickmarks.hxx"
 
 namespace com::sun::star::util { class XNumberFormatsSupplier; }
+namespace com::sun::star::uno { class XComponentContext; }
 
 namespace chart
 {
@@ -31,6 +32,7 @@ namespace chart
 class VSeriesPlotter;
 class DataTableView;
 class ChartModel;
+class LegendEntryProvider;
 
 class VAxisBase : public VAxisOrGridBase
 {
@@ -66,7 +68,8 @@ public:
 
 virtual void 
createDataTableView(std::vector>& 
rSeriesPlotterList,
  
css::uno::Reference const& 
xNumberFormatsSupplier,
- 
css::uno::Reference const& xChartDoc);
+ 
css::uno::Reference const& xChartDoc,
+ 
css::uno::Reference const& rComponentContext);
 
 std::shared_ptr getDataTableView() { return 
m_pDataTableView; }
 
diff --git a/chart2/source/view/axes/VCartesianAxis.cxx 
b/chart2/source/view/axes/VCartesianAxis.cxx
index 0a731bf086d2..76884e8fc255 100644
--- a/chart2/source/view/axes/VCartesianAxis.cxx
+++ b/chart2/source/view/axes/VCartesianAxis.cxx
@@ -2009,11 +2009,12 @@ void VCartesianAxis::createShapes()
 
 void 
VCartesianAxis::createDataTableView(std::vector>&
 rSeriesPlotterList,
  
uno::Reference const& xNumberFormatsSupplier,
- 
uno::Reference const& xChartDoc)
+

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

2022-08-24 Thread Caolán McNamara (via logerrit)
 sc/source/filter/xml/XMLChangeTrackingImportHelper.cxx |   21 +++--
 1 file changed, 9 insertions(+), 12 deletions(-)

New commits:
commit 36e1834c9893deae9a45cd2026eb7d02e6a16bd9
Author: Caolán McNamara 
AuthorDate: Tue Aug 16 12:41:47 2022 +0100
Commit: Caolán McNamara 
CommitDate: Wed Aug 17 09:53:55 2022 +0200

cid#1509241 rearrange to silence Dereference after null check

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

diff --git a/sc/source/filter/xml/XMLChangeTrackingImportHelper.cxx 
b/sc/source/filter/xml/XMLChangeTrackingImportHelper.cxx
index 1d2d7a40a01d..b8737d663d97 100644
--- a/sc/source/filter/xml/XMLChangeTrackingImportHelper.cxx
+++ b/sc/source/filter/xml/XMLChangeTrackingImportHelper.cxx
@@ -476,18 +476,15 @@ void 
ScXMLChangeTrackingImportHelper::CreateGeneratedActions(std::vectorCreateCell(rDoc);
-
-if (!aCell.isEmpty())
-{
-rGenerated.nID = pTrack->AddLoadedGenerated(aCell, 
rGenerated.aBigRange, rGenerated.pCellInfo->sInputString);
-OSL_ENSURE(rGenerated.nID, "could not insert generated 
action");
-}
-}
+if (rGenerated.nID != 0)
+continue;
+if (!rGenerated.pCellInfo)
+continue;
+ScCellValue aCell = rGenerated.pCellInfo->CreateCell(rDoc);
+if (aCell.isEmpty())
+continue;
+rGenerated.nID = pTrack->AddLoadedGenerated(aCell, 
rGenerated.aBigRange, rGenerated.pCellInfo->sInputString);
+OSL_ENSURE(rGenerated.nID, "could not insert generated action");
 }
 }
 


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

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/source/controller/inc/DataTableItemConverter.hxx|3 +--
 chart2/source/controller/itemsetwrapper/DataTableItemConverter.cxx |6 
++
 chart2/source/controller/main/ChartController_Properties.cxx   |6 
+-
 3 files changed, 4 insertions(+), 11 deletions(-)

New commits:
commit fc909263a1bb9326f838326f3299b16b80318f42
Author: Tomaž Vajngerl 
AuthorDate: Fri Aug 12 23:21:34 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Tue Aug 16 16:14:44 2022 +0200

chart2: don't use ref-size property when converting data table

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

diff --git a/chart2/source/controller/inc/DataTableItemConverter.hxx 
b/chart2/source/controller/inc/DataTableItemConverter.hxx
index 65483f0f16f1..5dbfaf60bba9 100644
--- a/chart2/source/controller/inc/DataTableItemConverter.hxx
+++ b/chart2/source/controller/inc/DataTableItemConverter.hxx
@@ -35,8 +35,7 @@ class DataTableItemConverter final : public ItemConverter
 public:
 DataTableItemConverter(const 
css::uno::Reference& rPropertySet,
SfxItemPool& rItemPool, SdrModel& rDrawModel,
-   const rtl::Reference<::chart::ChartModel>& 
xChartDoc,
-   const css::awt::Size* pRefSize);
+   const rtl::Reference<::chart::ChartModel>& 
xChartDoc);
 
 virtual ~DataTableItemConverter() override;
 
diff --git a/chart2/source/controller/itemsetwrapper/DataTableItemConverter.cxx 
b/chart2/source/controller/itemsetwrapper/DataTableItemConverter.cxx
index 462cd2517e54..2f05efaaa447 100644
--- a/chart2/source/controller/itemsetwrapper/DataTableItemConverter.cxx
+++ b/chart2/source/controller/itemsetwrapper/DataTableItemConverter.cxx
@@ -53,15 +53,13 @@ ItemPropertyMapType& lclDataTablePropertyMap()
 
 DataTableItemConverter::DataTableItemConverter(
 const uno::Reference& rPropertySet, SfxItemPool& 
rItemPool,
-SdrModel& rDrawModel, const rtl::Reference<::chart::ChartModel>& xChartDoc,
-const awt::Size* pRefSize)
+SdrModel& rDrawModel, const rtl::Reference<::chart::ChartModel>& xChartDoc)
 : ItemConverter(rPropertySet, rItemPool)
 , m_xChartDoc(xChartDoc)
 {
 m_aConverters.emplace_back(new GraphicPropertyItemConverter(
 rPropertySet, rItemPool, rDrawModel, xChartDoc, 
GraphicObjectType::LineProperties));
-m_aConverters.emplace_back(
-new CharacterPropertyItemConverter(rPropertySet, rItemPool, pRefSize, 
"ReferencePageSize"));
+m_aConverters.emplace_back(new 
CharacterPropertyItemConverter(rPropertySet, rItemPool));
 }
 
 DataTableItemConverter::~DataTableItemConverter() = default;
diff --git a/chart2/source/controller/main/ChartController_Properties.cxx 
b/chart2/source/controller/main/ChartController_Properties.cxx
index feb8cc6c8a59..8352d4e01ff1 100644
--- a/chart2/source/controller/main/ChartController_Properties.cxx
+++ b/chart2/source/controller/main/ChartController_Properties.cxx
@@ -290,13 +290,9 @@ wrapper::ItemConverter* createItemConverter(
 break;
 case OBJECTTYPE_DATA_TABLE:
 {
-std::unique_ptr pRefSize;
-if (pRefSizeProvider)
-pRefSize.reset(new 
awt::Size(pRefSizeProvider->getPageSize()));
-
 pItemConverter =  new wrapper::DataTableItemConverter(
 xObjectProperties, 
rDrawModel.GetItemPool(),
-rDrawModel, xChartModel, 
pRefSize.get());
+rDrawModel, xChartModel);
 }
 break;
 default: //OBJECTTYPE_UNKNOWN


[Libreoffice-commits] core.git: Branch 'distro/collabora/co-22.05' - 2 commits - chart2/Library_chartcore.mk chart2/qa chart2/source offapi/com offapi/UnoApi_offapi.mk

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/Library_chartcore.mk|2 
 chart2/qa/extras/chart2export.cxx  |3 
 chart2/source/chartcore.component  |7 
 chart2/source/inc/DataTable.hxx|   90 ++
 chart2/source/model/inc/Diagram.hxx|   15 +
 chart2/source/model/main/DataTable.cxx |  248 +
 chart2/source/model/main/Diagram.cxx   |   55 ++-
 chart2/source/view/axes/VAxisBase.cxx  |8 
 chart2/source/view/axes/VAxisBase.hxx  |   11 
 chart2/source/view/axes/VAxisProperties.cxx|4 
 chart2/source/view/axes/VAxisProperties.hxx|3 
 chart2/source/view/axes/VCartesianAxis.cxx |   40 ++
 chart2/source/view/axes/VCartesianAxis.hxx |2 
 chart2/source/view/axes/VCartesianCoordinateSystem.cxx |3 
 chart2/source/view/axes/VCartesianCoordinateSystem.hxx |3 
 chart2/source/view/axes/VCoordinateSystem.cxx  |2 
 chart2/source/view/axes/VPolarCoordinateSystem.cxx |2 
 chart2/source/view/axes/VPolarCoordinateSystem.hxx |3 
 chart2/source/view/charttypes/VSeriesPlotter.cxx   |   62 +++-
 chart2/source/view/inc/DataTableView.hxx   |   39 ++
 chart2/source/view/inc/VCoordinateSystem.hxx   |5 
 chart2/source/view/inc/VSeriesPlotter.hxx  |   18 -
 chart2/source/view/main/ChartView.cxx  |2 
 chart2/source/view/main/DataTableView.cxx  |  217 ++
 offapi/UnoApi_offapi.mk|2 
 offapi/com/sun/star/chart2/DataTable.idl   |   48 +++
 offapi/com/sun/star/chart2/Diagram.idl |6 
 offapi/com/sun/star/chart2/XDataTable.idl  |   28 +
 offapi/com/sun/star/chart2/XDiagram.idl|9 
 29 files changed, 882 insertions(+), 55 deletions(-)

New commits:
commit 87c0b77d3262daf30ab3c3d7e4b4735f25c4e63e
Author: Tomaž Vajngerl 
AuthorDate: Mon May 16 15:27:46 2022 +0900
Commit: Tomaž Vajngerl 
CommitDate: Tue Aug 16 16:13:28 2022 +0200

[API-CHANGE] chart data table implementation

Adds new service DataTable, which is reposible for the properties
of a data table for a chart. Also removes the existing properties
related to the data table from Diagram service, which were added
prematurely in the past, without a data table actually being
supported by the chart module.

Also adds an implementation of the DataTable service in chart2
module.

Change-Id: I0c6b32163745704c623d04baaf0ce0e208c107f5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/136789
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 
(cherry picked from commit 212f03a3cd33a1c276e93ee693dc1173a5c1b051)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138308
Tested-by: Jenkins CollaboraOffice 

diff --git a/chart2/Library_chartcore.mk b/chart2/Library_chartcore.mk
index 5afb3e5b862a..72539f1a5bdf 100644
--- a/chart2/Library_chartcore.mk
+++ b/chart2/Library_chartcore.mk
@@ -136,6 +136,7 @@ $(eval $(call gb_Library_add_exception_objects,chartcore,\
 chart2/source/model/main/DataPointProperties \
 chart2/source/model/main/DataSeries \
 chart2/source/model/main/DataSeriesProperties \
+chart2/source/model/main/DataTable \
 chart2/source/model/main/Diagram \
 chart2/source/model/main/FormattedString \
 chart2/source/model/main/GridProperties \
diff --git a/chart2/qa/extras/chart2export.cxx 
b/chart2/qa/extras/chart2export.cxx
index 78529b9423c9..1e64ab5fb261 100644
--- a/chart2/qa/extras/chart2export.cxx
+++ b/chart2/qa/extras/chart2export.cxx
@@ -623,6 +623,8 @@ void Chart2ExportTest::testScatterXAxisCategories()
 
 void Chart2ExportTest::testChartDataTable()
 {
+/*  Disable test temporarily until OOXML filter is updated
+
 load(u"/chart2/qa/extras/data/docx/", "testChartDataTable.docx");
 
 xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open 
XML Text");
@@ -630,6 +632,7 @@ void Chart2ExportTest::testChartDataTable()
 assertXPath(pXmlDoc, 
"/c:chartSpace/c:chart/c:plotArea/c:dTable/c:showHorzBorder", "val", "1");
 assertXPath(pXmlDoc, 
"/c:chartSpace/c:chart/c:plotArea/c:dTable/c:showVertBorder", "val", "1");
 assertXPath(pXmlDoc, 
"/c:chartSpace/c:chart/c:plotArea/c:dTable/c:showOutline", "val", "1");
+*/
 }
 
 void Chart2ExportTest::testChartExternalData()
diff --git a/chart2/source/chartcore.component 
b/chart2/source/chartcore.component
index f58ba98ba3ac..d15c808919df 100644
--- a/chart2/source/chartcore.component
+++ b/chart2/source/chartcore.component
@@ -219,6 +219,13 @@
 
 
 
+  
+
+
+
+
+
   
   
diff --git a/chart2/source/inc/DataTable.hxx b/chart2/source/inc/DataTable.hxx
new file mode 100644
index ..52fe42c34ee6
--- /dev/null
+++ b/chart2/source/inc/DataTable

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

2022-08-24 Thread Mike Kaganski (via logerrit)
 framework/source/services/frame.cxx |8 +++-
 1 file changed, 3 insertions(+), 5 deletions(-)

New commits:
commit 0aa2b700aae306674d768356875998f5b8f14f0f
Author: Mike Kaganski 
AuthorDate: Tue Aug 16 12:29:35 2022 +0300
Commit: Mike Kaganski 
CommitDate: Tue Aug 16 14:41:29 2022 +0200

No need to use throwing Reference ctor from 'this'

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

diff --git a/framework/source/services/frame.cxx 
b/framework/source/services/frame.cxx
index c2efdecd50ca..23caecf79fb1 100644
--- a/framework/source/services/frame.cxx
+++ b/framework/source/services/frame.cxx
@@ -798,8 +798,7 @@ void SAL_CALL XFrameImpl::initialize( const 
css::uno::Reference< css::awt::XWind
 lcl_enableLayoutManager(xLayoutManager, this);
 
 // create progress helper
-css::uno::Reference< css::frame::XFrame > xThis (static_cast< 
css::frame::XFrame* >(this),
- 
css::uno::UNO_QUERY_THROW);
+css::uno::Reference< css::frame::XFrame > xThis (this);
 css::uno::Reference< css::task::XStatusIndicatorFactory > 
xIndicatorFactory =
 css::task::StatusIndicatorFactory::createWithFrame(m_xContext, xThis,

false/*DisableReschedule*/, true/*AllowParentShow*/ );
commit 84fbb174d6c773ecd284398a9dc4fee9f142a193
Author: Mike Kaganski 
AuthorDate: Tue Aug 16 12:17:45 2022 +0300
Commit: Mike Kaganski 
CommitDate: Tue Aug 16 14:41:18 2022 +0200

Drop redundant warning after throwing check

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

diff --git a/framework/source/services/frame.cxx 
b/framework/source/services/frame.cxx
index d722b5e0b98d..c2efdecd50ca 100644
--- a/framework/source/services/frame.cxx
+++ b/framework/source/services/frame.cxx
@@ -765,15 +765,14 @@ void SAL_CALL XFrameImpl::initialize( const 
css::uno::Reference< css::awt::XWind
 /* SAFE AREA 
---
 */
 SolarMutexResettableGuard aWriteLock;
 
+// This must be the first call of this method!
+// We should initialize our object and open it for working.
 if ( m_xContainerWindow.is() )
 throw css::uno::RuntimeException(
 "XFrameImpl::initialized() is called more than once, which is 
not useful nor allowed.",
 static_cast< css::frame::XFrame* >(this));
 
-// This must be the first call of this method!
-// We should initialize our object and open it for working.
 // Set the new window.
-SAL_WARN_IF( m_xContainerWindow.is(), "fwk.frame", 
"XFrameImpl::initialize(): Leak detected! This state should never occur ..." );
 m_xContainerWindow = xWindow;
 
 // if window is initially visible, we will never get a windowShowing event


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

2022-08-24 Thread Caolán McNamara (via logerrit)
 svx/source/dialog/svxruler.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 2fbf1082cde79b7259f0139a6c8978fe797be86c
Author: Caolán McNamara 
AuthorDate: Tue Aug 16 09:14:24 2022 +0100
Commit: Caolán McNamara 
CommitDate: Tue Aug 16 12:58:37 2022 +0200

cid#1500455 Dereference after null check

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

diff --git a/svx/source/dialog/svxruler.cxx b/svx/source/dialog/svxruler.cxx
index 98c9211efb01..e1308ff749c3 100644
--- a/svx/source/dialog/svxruler.cxx
+++ b/svx/source/dialog/svxruler.cxx
@@ -2709,7 +2709,7 @@ void SvxRuler::CalcMinMax()
 nMaxLeft = lNullPix;
 else
 nMaxLeft = mpBorders[nIdx - 1].nPos + mpBorders[nIdx - 
1].nWidth + lNullPix;
-if(nIdx == mxColumnItem->GetActColumn())
+if (mxColumnItem && nIdx == mxColumnItem->GetActColumn())
 {
 if(bRTL)
 {


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

2022-08-24 Thread Caolán McNamara (via logerrit)
 tools/source/datetime/ttime.cxx |8 
 1 file changed, 4 insertions(+), 4 deletions(-)

New commits:
commit da46f3db22814c03fbc303275342f7182ea288b4
Author: Caolán McNamara 
AuthorDate: Tue Aug 16 00:14:42 2022 +0100
Commit: Caolán McNamara 
CommitDate: Tue Aug 16 09:52:55 2022 +0200

cid#1509285 Use of 32-bit time_t

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

diff --git a/tools/source/datetime/ttime.cxx b/tools/source/datetime/ttime.cxx
index ee9e427205ef..148bf0cbecc6 100644
--- a/tools/source/datetime/ttime.cxx
+++ b/tools/source/datetime/ttime.cxx
@@ -412,17 +412,17 @@ Time tools::Time::GetUTCOffset()
 {
 nTime = time( nullptr );
 localtime_r( &nTime, &aTM );
-sal_Int32 nLocalTime = mktime( &aTM );
+auto nLocalTime = mktime( &aTM );
 #if defined(__sun)
 // Solaris gmtime_r() seems not to handle daylight saving time
 // flags correctly
-nUTC = nLocalTime + ( aTM.tm_isdst == 0 ? timezone : altzone );
+auto nUTC = nLocalTime + ( aTM.tm_isdst == 0 ? timezone : altzone );
 #elif defined( LINUX )
 // Linux mktime() seems not to handle tm_isdst correctly
-sal_Int32 nUTC = nLocalTime - aTM.tm_gmtoff;
+auto nUTC = nLocalTime - aTM.tm_gmtoff;
 #else
 gmtime_r( &nTime, &aTM );
-sal_Int32 nUTC = mktime( &aTM );
+auto nUTC = mktime( &aTM );
 #endif
 nCacheTicks = nTicks;
 nCacheSecOffset = (nLocalTime-nUTC) / 60;


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

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/source/view/main/DataTableView.cxx |   58 ++
 1 file changed, 43 insertions(+), 15 deletions(-)

New commits:
commit 81a5f33101c18fb22a952b865c0c90418fd6a490
Author: Tomaž Vajngerl 
AuthorDate: Fri Aug 12 17:29:36 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Tue Aug 16 08:16:27 2022 +0200

chart2: always set text props. of the first paragraph and not cell

When setting the properties of the data table it is important to
differentiate when we set the properties of the text of the (first
and only) paragraph or set the properties for the current cell.

In this chage we refactor the code so that we always set the text
via UNO text::XText call for the current cell, and in the next step
get the XPropertySet of the first paragraph and set the properties
relevant for the text from the DataTable model.

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

diff --git a/chart2/source/view/main/DataTableView.cxx 
b/chart2/source/view/main/DataTableView.cxx
index ae90b475e75a..d413372e87c6 100644
--- a/chart2/source/view/main/DataTableView.cxx
+++ b/chart2/source/view/main/DataTableView.cxx
@@ -57,6 +57,29 @@ void copyProperty(uno::Reference& xOut,
 {
 xOut->setPropertyValue(sPropertyName, 
xIn->getPropertyValue(sPropertyName));
 }
+
+uno::Reference getFirstParagraph(uno::Reference 
const& xText)
+{
+uno::Reference xParagraph;
+uno::Reference xEnumAccess(xText, 
uno::UNO_QUERY);
+if (!xEnumAccess.is())
+return xParagraph;
+uno::Reference 
xEnumeration(xEnumAccess->createEnumeration());
+xParagraph.set(xEnumeration->nextElement(), uno::UNO_QUERY);
+return xParagraph;
+}
+
+uno::Reference
+getFirstParagraphProperties(uno::Reference const& xText)
+{
+uno::Reference xPropertySet;
+auto xParagraph = getFirstParagraph(xText);
+if (!xParagraph.is())
+return xPropertySet;
+xPropertySet.set(xParagraph, uno::UNO_QUERY);
+return xPropertySet;
+}
+
 } // end anonymous namespace
 
 DataTableView::DataTableView(
@@ -67,8 +90,8 @@ DataTableView::DataTableView(
 , m_xDataTableModel(rDataTableModel)
 , m_xComponentContext(rComponentContext)
 {
-uno::Reference xProp(m_xDataTableModel);
-m_aLineProperties.initFromPropertySet(xProp);
+uno::Reference xPropertySet(m_xDataTableModel);
+m_aLineProperties.initFromPropertySet(xPropertySet);
 }
 
 void DataTableView::setCellCharAndParagraphProperties(
@@ -274,14 +297,18 @@ void DataTableView::createShapes(basegfx::B2DVector 
const& rStart, basegfx::B2DV
 uno::Reference xCellTextRange(xCell, uno::UNO_QUERY);
 if (xCellTextRange.is())
 {
-xCellTextRange->setString(rString);
+auto xText = xCellTextRange->getText();
+xText->insertString(xText->getStart(), rString, false);
+auto xTextPropertySet = getFirstParagraphProperties(xText);
+if (!xTextPropertySet.is())
+continue;
 
 bool bLeft
 = (bOutline && nColumn == 1) || (bVBorder && nColumn > 1 && 
nColumn < nColumnCount);
 bool bRight = (bOutline && nColumn == nColumnCount)
   || (bVBorder && nColumn > 1 && nColumn < 
nColumnCount);
+setCellCharAndParagraphProperties(xTextPropertySet);
 setCellProperties(xPropertySet, bLeft, bOutline, bRight, bOutline);
-setCellCharAndParagraphProperties(xPropertySet);
 }
 nColumn++;
 }
@@ -319,17 +346,14 @@ void DataTableView::createShapes(basegfx::B2DVector 
const& rStart, basegfx::B2DV
 bool bTop = (bOutline && nRow == 1) || (bHBorder && nRow > 1 && 
nRow < nRowCount);
 bool bBottom
 = (bOutline && nRow == nRowCount) || (bHBorder && nRow > 1 && 
nRow < nRowCount);
-setCellProperties(xCellPropertySet, bOutline, bTop, bOutline, 
bBottom);
 
 auto xText = xCellTextRange->getText();
 xText->insertString(xText->getStart(), rSeriesName, false);
-uno::Reference xEnumAccess(xText, 
uno::UNO_QUERY);
-uno::Reference 
xEnumeration(xEnumAccess->createEnumeration());
-uno::Reference 
xParagraph(xEnumeration->nextElement(),
-uno::UNO_QUERY);
-uno::Reference xTextPropertySet(xParagraph, 
uno::UNO_QUERY);
-
+auto xTextPropertySet = getFirstParagraphProperties(xText);
+if (!xTextPropertySet.is())
+continue;
 setCellCharAndParagraphProperties(xTextPropertySet);
+setCellProperties(xCellPropertySet, bOutline, bTop, bOutline, 
bBottom);
 
 xCellPropertySet->setPropertyValue("ParaAdjust", 
uno::Any(style::ParagraphAdjust_LEFT));
 if (bKeys)
@@ -349,11 +373,15 @

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

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/inc/ChartView.hxx   |8 
 chart2/source/view/axes/VAxisBase.cxx  |3 
 chart2/source/view/axes/VAxisBase.hxx  |5 
 chart2/source/view/axes/VCartesianAxis.cxx |5 
 chart2/source/view/axes/VCartesianAxis.hxx |4 
 chart2/source/view/axes/VCartesianCoordinateSystem.cxx |5 
 chart2/source/view/axes/VCartesianCoordinateSystem.hxx |3 
 chart2/source/view/axes/VCoordinateSystem.cxx  |3 
 chart2/source/view/axes/VPolarCoordinateSystem.cxx |3 
 chart2/source/view/axes/VPolarCoordinateSystem.hxx |3 
 chart2/source/view/charttypes/VSeriesPlotter.cxx   |  139 +
 chart2/source/view/inc/DataTableView.hxx   |   16 +
 chart2/source/view/inc/LegendEntryProvider.hxx |9 +
 chart2/source/view/inc/VCoordinateSystem.hxx   |4 
 chart2/source/view/inc/VSeriesPlotter.hxx  |   11 +
 chart2/source/view/main/ChartView.cxx  |   13 -
 chart2/source/view/main/DataTableView.cxx  |  121 +++---
 include/svx/svdotable.hxx  |2 
 svx/source/table/svdotable.cxx |   12 +
 19 files changed, 317 insertions(+), 52 deletions(-)

New commits:
commit 9d6ffcc0572cc7917651489c69ca4b3452e89a89
Author: Tomaž Vajngerl 
AuthorDate: Mon Jul 18 08:12:19 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Tue Aug 16 08:15:00 2022 +0200

chart2: Data table rendering of keys (legend symbols)

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

diff --git a/chart2/inc/ChartView.hxx b/chart2/inc/ChartView.hxx
index 3fe2fedcf7e8..5c7e70e97900 100644
--- a/chart2/inc/ChartView.hxx
+++ b/chart2/inc/ChartView.hxx
@@ -104,8 +104,7 @@ private:
 
 public:
 ChartView() = delete;
-ChartView(css::uno::Reference< css::uno::XComponentContext > xContext,
-   ChartModel& rModel);
+ChartView(css::uno::Reference xContext, 
ChartModel& rModel);
 
 virtual ~ChartView() override;
 
@@ -185,6 +184,8 @@ public:
 
 void setViewDirty();
 
+css::uno::Reference const& 
getComponentContext() { return m_xCC;}
+
 /// See sfx2::XmlDump::dumpAsXml().
 void dumpAsXml(xmlTextWriterPtr pWriter) const override;
 
@@ -210,8 +211,7 @@ private: //methods
 private: //member
 ::osl::Mutex m_aMutex;
 
-css::uno::Reference< css::uno::XComponentContext>
-m_xCC;
+css::uno::Reference< css::uno::XComponentContext> m_xCC;
 
 chart::ChartModel& mrChartModel;
 
diff --git a/chart2/source/view/axes/VAxisBase.cxx 
b/chart2/source/view/axes/VAxisBase.cxx
index 814d3afd7858..30aead187dcb 100644
--- a/chart2/source/view/axes/VAxisBase.cxx
+++ b/chart2/source/view/axes/VAxisBase.cxx
@@ -244,7 +244,8 @@ void VAxisBase::updateUnscaledValuesAtTicks( TickIter& 
rIter )
 
 void 
VAxisBase::createDataTableView(std::vector>& 
/*rSeriesPlotterList*/,
 
uno::Reference const& /*xNumberFormatsSupplier*/,
-rtl::Reference<::chart::ChartModel> const& 
/*xChartDoc*/)
+rtl::Reference<::chart::ChartModel> const& 
/*xChartDoc*/,
+
css::uno::Reference const& /*rComponentContext*/)
 {
 }
 
diff --git a/chart2/source/view/axes/VAxisBase.hxx 
b/chart2/source/view/axes/VAxisBase.hxx
index 2c4123ba951d..4ee4f5e288ae 100644
--- a/chart2/source/view/axes/VAxisBase.hxx
+++ b/chart2/source/view/axes/VAxisBase.hxx
@@ -23,6 +23,7 @@
 #include "Tickmarks.hxx"
 
 namespace com::sun::star::util { class XNumberFormatsSupplier; }
+namespace com::sun::star::uno { class XComponentContext; }
 
 namespace chart
 {
@@ -30,6 +31,7 @@ namespace chart
 class VSeriesPlotter;
 class DataTableView;
 class ChartModel;
+class LegendEntryProvider;
 
 class VAxisBase : public VAxisOrGridBase
 {
@@ -65,7 +67,8 @@ public:
 
 virtual void 
createDataTableView(std::vector>& 
rSeriesPlotterList,
  
css::uno::Reference const& 
xNumberFormatsSupplier,
- rtl::Reference<::chart::ChartModel> 
const& xChartDoc);
+ rtl::Reference<::chart::ChartModel> 
const& xChartDoc,
+ 
css::uno::Reference const& rComponentContext);
 
 std::shared_ptr getDataTableView() { return 
m_pDataTableView; }
 
diff --git a/chart2/source/view/axes/VCartesianAxis.cxx 
b/chart2/source/view/axes/VCartesianAxis.cxx
index d7e78d5d2e85..293d1f0479a8 100644
--- a/chart2/source/view/axes/VCartesianAxis.cxx
+++ b/chart2/source/view/axes/VCartesianAxis.cxx
@@ -1995,11 +1995,12 @@ void VCartesianAxis::createShapes()
 
 void 
VCartesianAxis::createDataTableView(std::vector>&
 rSeriesPlotterList,
   

[Libreoffice-commits] core.git: Branch 'distro/cib/libreoffice-6-4' - officecfg/registry

2022-08-24 Thread Gabor Kelemen (via logerrit)
 officecfg/registry/data/org/openoffice/Setup.xcu |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit f11b5422d7b8a6f6bd4df0646d89c06f127c465f
Author: Gabor Kelemen 
AuthorDate: Wed Aug 24 19:12:25 2022 +0200
Commit: Gabor Kelemen 
CommitDate: Wed Aug 24 19:16:16 2022 +0200

[CIBO] Migrate user profile from old brand profile dir

Change-Id: I7d440b0d5bda7730026e2a509099b6c2b2df

diff --git a/officecfg/registry/data/org/openoffice/Setup.xcu 
b/officecfg/registry/data/org/openoffice/Setup.xcu
index 0472de91f20e..acd6503c7914 100644
--- a/officecfg/registry/data/org/openoffice/Setup.xcu
+++ b/officecfg/registry/data/org/openoffice/Setup.xcu
@@ -781,7 +781,7 @@
   10
 
 
-  Libreoffice 3=libreoffice/3,Openoffice.org 
3=openoffice.org/3,OpenOffice.org 2=openoffice.org2,StarOffice 
8=staroffice8,StarSuite 8=starsuite8
+  LibreOffice powered by 
CIB=LibreOfficepoweredbyCIB/4,Libreoffice 3=libreoffice/3,Openoffice.org 
3=openoffice.org/3,OpenOffice.org 2=openoffice.org2,StarOffice 
8=staroffice8,StarSuite 8=starsuite8
 
 
   


[Libreoffice-commits] core.git: 2 commits - vcl/inc vcl/Library_vclplug_qt5.mk vcl/Library_vclplug_qt6.mk vcl/qt5 vcl/qt6

2022-08-24 Thread Michael Weghorn (via logerrit)
 vcl/Library_vclplug_qt5.mk   |1 
 vcl/Library_vclplug_qt6.mk   |1 
 vcl/inc/qt5/QtAccessibleRegistry.hxx |   41 +++
 vcl/inc/qt6/QtAccessibleRegistry.hxx |   12 +
 vcl/qt5/QtAccessibleRegistry.cxx |   45 +++
 vcl/qt5/QtAccessibleWidget.cxx   |   43 ++---
 vcl/qt6/QtAccessibleRegistry.cxx |   12 +
 7 files changed, 141 insertions(+), 14 deletions(-)

New commits:
commit 61c0c1286dbd9015809ba8ee5ee687b612438bef
Author: Michael Weghorn 
AuthorDate: Wed Aug 24 13:47:25 2022 +0200
Commit: Michael Weghorn 
CommitDate: Wed Aug 24 19:05:54 2022 +0200

qt a11y: Remember associated QObject also for non-QtXAcccessible case

This is similar to what
Change-Id Ic890a387ff016e889f25dba70c82d0d81ae7a9e3
("qt a11y: Remember and reuse existing QObject for XAccessible")
does to avoid creating another `QtXAccessible` for an `XAccessible`
if one has been created earlier.

However, there is an additional case that needs to be
covered to avoid creating multiple `QObjects` for
a single `XAccessible`:

`QtAccessibleWidget::customFactory` not only gets called
by explicitly calling `QAccessible::queryAccessibleInterface`
from within LibreOffice code, but the Qt library itself
also calls this method, in which case no entry associating
the `XAccessible` with its `QObject` had been inserted into
the map handled by our `QtAccessibleRegistry` previously.

This would result in a "new" `QtXAccessible` object
being created later when a `QObject` would be needed
for that `XAccessible`, rather than using the
`QtWidget` that is the actual `QObject` associated
with the object.

Prevent that from happening by inserting an entry
into the map for this case as well.

With this and two Accerciser fixes [1] [2] in place, jumping
to bookmarks in Accerciser's treeview of the LO a11y
hierarchy now generally works with the qt6 VCL plugin.

It previously failed due to the fact that a new object
was created and navigating the tree up to the root application
object from the bookmarked object would then fail.

The fact that there were two objects could be seen e.g. by
using the following commands in Accerciser's IPython console
with the root "soffice.bin" application a11y object
selected in the treeview after starting Calc:

In [25]: acc[1][0][0].get_parent().path
Out[25]: '/org/a11y/atspi/accessible/2147483672'
In [26]: acc[1][0].path
Out[26]: '/org/a11y/atspi/accessible/2147483648'

-> Two different IDs/paths for what should be the same object.
(The parent of the first child of the object at tree path 1,0
should be the object itself, but here it wasn't.)

With this change in place, this now works as expected:

In [28]: acc[1][0][0].get_parent().path
Out[28]: '/org/a11y/atspi/accessible/2147483648'
In [29]: acc[1][0].path
Out[29]: '/org/a11y/atspi/accessible/2147483648'

Together with
Change-Id Ic890a387ff016e889f25dba70c82d0d81ae7a9e3
("qt a11y: Remember and reuse existing QObject for XAccessible"),
this also addresses the remaining issue mentioned in

commit 99640693d28ca11b31a1d3855e104d2d8c5122d7
Author: Michael Weghorn 
Date:   Wed Aug 3 16:49:48 2022 +0200

> Note however that this change alone is not yet sufficient
> for a window to actually be returned for any arbitrary a11y
> object deeper down the hierarchy. This is because
> walking up the a11y hierarchy currently results in new
> Qt a11y objects being created for the parents instead of
> using existing ones, and the newly created ones lack
> the association to the widgets.
> (This works in a WIP branch that remembers/caches
> a11y objects, but that needs some additional work before
> it can be merged.)

Note that there are still cases where navigation
to bookmarks in Accerciser's tree view doesn't work
(reliably), but those would need to be looked at
separately and might not be specific to the qt6
VCL plugin. (At least I have come across such
cases with gtk3 as well.)

[1] 
https://gitlab.gnome.org/GNOME/accerciser/-/commit/c2a3e9f1eb1fcd6eb059f1f2fe6e629b86521335
[2] 
https://gitlab.gnome.org/GNOME/accerciser/-/commit/a092dc933985fafd5b1e2cc3374c7bbc0fb2d12e

Change-Id: I02262014a45a4b024cdc1bbd385da8a35a2c304a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138764
Tested-by: Jenkins
Reviewed-by: Michael Weghorn 

diff --git a/vcl/inc/qt5/QtAccessibleRegistry.hxx 
b/vcl/inc/qt5/QtAccessibleRegistry.hxx
index 00acf80fd68c..87781752f704 100644
--- a/vcl/inc/qt5/QtAccessibleRegistry.hxx
+++ b/vcl/inc/qt5/QtAccessibleRegistry.hxx
@@ -33,6 +33,7 @@

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

2022-08-24 Thread Julien Nabet (via logerrit)
 comphelper/source/misc/SelectionMultiplex.cxx |9 +
 include/comphelper/SelectionMultiplex.hxx |2 ++
 reportdesign/source/ui/dlg/Navigator.cxx  |1 +
 3 files changed, 12 insertions(+)

New commits:
commit 9931d6b1fb0406e16d56e186812884511738dcfa
Author: Julien Nabet 
AuthorDate: Wed Aug 24 16:42:54 2022 +0200
Commit: Julien Nabet 
CommitDate: Wed Aug 24 19:00:34 2022 +0200

tdf#150575: REPORTBUILDER: Crash when closing report when used report 
navigator

0  0x7fe062bdda64 in 
comphelper::OSelectionChangeMultiplexer::disposing(com::sun::star::lang::EventObject
 const&) (this=0x55fe72b7b680, _rSource=...) at 
comphelper/source/misc/SelectionMultiplex.cxx:82
1  0x7fdf90a97a6b in 
comphelper::OInterfaceContainerHelper3::disposeAndClear(com::sun::star::lang::EventObject
 const&) (this=0x55fe6c94b6d0, rEvt=...)
at include/comphelper/interfacecontainer3.hxx:362
2  0x7fdf90a6ace4 in rptui::OReportController::disposing() 
(this=0x55fe6c94b200) at reportdesign/source/ui/report/ReportController.cxx:341
3  0x7fe062539b5d in cppu::WeakComponentImplHelperBase::dispose() 
(this=0x55fe6c94b200) at cppuhelper/source/implbase.cxx:104
4  0x7fe0393b76e5 in 
cppu::PartialWeakComponentImplHelper::dispose() (this=0x55fe6c94b200) 
at include/cppuhelper/compbase.hxx:90
5  0x7fe0393af9d3 in dbaui::OGenericUnoController::dispose() 
(this=0x55fe6c94b200) at dbaccess/source/ui/browser/genericcontroller.cxx:1207

See full bt here:
https://bugs.documentfoundation.org/attachment.cgi?id=181994

"addSelectionChangeListener" is called when "OSelectionChangeMultiplexer" 
is instantiated in "NavigatorTree" ctr
225 m_pSelectionListener = new 
OSelectionChangeMultiplexer(this,&m_rController);

but "removeSelectionChangeListener" was never called so add the mechanism 
to call it.

Change-Id: I157b147f7a17244dbbfa7d12743fc7d48e7d5f7d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138773
Reviewed-by: Noel Grandin 
Tested-by: Jenkins
Reviewed-by: Julien Nabet 

diff --git a/comphelper/source/misc/SelectionMultiplex.cxx 
b/comphelper/source/misc/SelectionMultiplex.cxx
index 267266388c71..e4fb824a0ba3 100644
--- a/comphelper/source/misc/SelectionMultiplex.cxx
+++ b/comphelper/source/misc/SelectionMultiplex.cxx
@@ -95,7 +95,16 @@ void SAL_CALL OSelectionChangeMultiplexer::selectionChanged( 
const  EventObject&
 m_pListener->_selectionChanged(_rEvent);
 }
 
+void OSelectionChangeMultiplexer::dispose()
+{
+osl_atomic_increment(&m_refCount);
+{
+Reference< XSelectionChangeListener> xPreventDelete(this);
+m_xSet->removeSelectionChangeListener(xPreventDelete);
+}
+osl_atomic_decrement(&m_refCount);
 }
 
+}
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/comphelper/SelectionMultiplex.hxx 
b/include/comphelper/SelectionMultiplex.hxx
index c1a1842f2ee0..ab980984aa16 100644
--- a/include/comphelper/SelectionMultiplex.hxx
+++ b/include/comphelper/SelectionMultiplex.hxx
@@ -80,6 +80,8 @@ namespace comphelper
 voidunlock();
 /// get the lock count
 sal_Int32   locked() const { return m_nLockCount; }
+
+void dispose();
 };
 
 
diff --git a/reportdesign/source/ui/dlg/Navigator.cxx 
b/reportdesign/source/ui/dlg/Navigator.cxx
index bdc2a646905b..586494bbe2b9 100644
--- a/reportdesign/source/ui/dlg/Navigator.cxx
+++ b/reportdesign/source/ui/dlg/Navigator.cxx
@@ -239,6 +239,7 @@ NavigatorTree::~NavigatorTree()
 delete pData;
 return false;
 });
+m_pSelectionListener->dispose();
 m_pReportListener->dispose();
 }
 


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

2022-08-24 Thread Noel Grandin (via logerrit)
 sw/inc/IDocumentMarkAccess.hxx  |8 -
 sw/source/core/doc/DocumentContentOperationsManager.cxx |6 
 sw/source/core/doc/docbm.cxx|  102 
 sw/source/core/inc/MarkManager.hxx  |6 
 sw/source/core/inc/mvsave.hxx   |8 -
 sw/source/filter/html/htmltab.cxx   |2 
 6 files changed, 73 insertions(+), 59 deletions(-)

New commits:
commit 077cbb5faecf75b333531afad04d2c9622a47c91
Author: Noel Grandin 
AuthorDate: Mon Aug 15 10:44:50 2022 +0200
Commit: Noel Grandin 
CommitDate: Mon Aug 15 16:54:05 2022 +0200

pass SwNode and sal_Int32 to deleteMarks

instead of SwNodeIndex and SwContentIndex. Part of the process
of hiding the implementation of SwPosition.

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

diff --git a/sw/inc/IDocumentMarkAccess.hxx b/sw/inc/IDocumentMarkAccess.hxx
index 0790a27ef1ea..98037c7917e3 100644
--- a/sw/inc/IDocumentMarkAccess.hxx
+++ b/sw/inc/IDocumentMarkAccess.hxx
@@ -225,11 +225,11 @@ class IDocumentMarkAccess
 
 */
 virtual void deleteMarks(
-const SwNodeIndex& rStt,
-const SwNodeIndex& rEnd,
+const SwNode& rStt,
+const SwNode& rEnd,
 std::vector< ::sw::mark::SaveBookmark>* pSaveBkmk, // Ugly: 
SaveBookmark is core-internal
-const SwContentIndex* pSttIdx,
-const SwContentIndex* pEndIdx) =0;
+std::optional oStartContentIdx,
+std::optional oEndContentIdx) =0;
 
 /** Deletes a mark.
 
diff --git a/sw/source/core/doc/DocumentContentOperationsManager.cxx 
b/sw/source/core/doc/DocumentContentOperationsManager.cxx
index 1972be388df2..91534b7e6863 100644
--- a/sw/source/core/doc/DocumentContentOperationsManager.cxx
+++ b/sw/source/core/doc/DocumentContentOperationsManager.cxx
@@ -2524,8 +2524,8 @@ bool DocumentContentOperationsManager::MoveRange( SwPaM& 
rPaM, SwPosition& rPos,
 for(auto& rBkmk : aSaveBkmks)
 rBkmk.SetInDoc(
 &m_rDoc,
-rPaM.GetMark()->nNode,
-&rPaM.GetMark()->nContent);
+rPaM.GetMark()->GetNode(),
+rPaM.GetMark()->GetContentIndex());
 *rPaM.GetPoint() = *aSavePam.End();
 
 // Move the Flys to the new position.
@@ -2645,7 +2645,7 @@ bool DocumentContentOperationsManager::MoveNodeRange( 
SwNodeRange& rRange, SwNod
 
 // Add the Bookmarks back to the Document
 for(auto& rBkmk : aSaveBkmks)
-rBkmk.SetInDoc(&m_rDoc, aIdx);
+rBkmk.SetInDoc(&m_rDoc, aIdx.GetNode());
 
 if( !aSavRedlInsPosArr.empty() )
 {
diff --git a/sw/source/core/doc/docbm.cxx b/sw/source/core/doc/docbm.cxx
index 914e1374554c..512c139b41fe 100644
--- a/sw/source/core/doc/docbm.cxx
+++ b/sw/source/core/doc/docbm.cxx
@@ -185,12 +185,12 @@ bool IDocumentMarkAccess::iterator::operator>=(iterator 
const& rOther) const
 
 namespace
 {
-bool lcl_GreaterThan( const SwPosition& rPos, const SwNodeIndex& rNdIdx, 
const SwContentIndex* pIdx )
+bool lcl_GreaterThan( const SwPosition& rPos, const SwNode& rNdIdx, 
std::optional oContentIdx )
 {
-return pIdx != nullptr
+return oContentIdx.has_value()
? ( rPos.nNode > rNdIdx
|| ( rPos.nNode == rNdIdx
-&& rPos.nContent >= pIdx->GetIndex() ) )
+&& rPos.nContent >= *oContentIdx ) )
: rPos.nNode >= rNdIdx;
 }
 
@@ -202,6 +202,14 @@ namespace
 && rPos.nContent < pIdx->GetIndex() );
 }
 
+bool lcl_Lower( const SwPosition& rPos, const SwNode& rNdIdx, 
std::optional oContentIdx )
+{
+return rPos.nNode < rNdIdx
+   || ( oContentIdx.has_value()
+&& rPos.nNode == rNdIdx
+&& rPos.nContent < *oContentIdx );
+}
+
 bool lcl_MarkOrderingByStart(const ::sw::mark::MarkBase *const pFirst,
  const ::sw::mark::MarkBase *const pSecond)
 {
@@ -246,7 +254,7 @@ namespace
 
 void lcl_PositionFromContentNode(
 std::optional& rFoundPos,
-SwContentNode * const pContentNode,
+const SwContentNode * const pContentNode,
 const bool bAtEnd)
 {
 rFoundPos.emplace(*pContentNode);
@@ -259,21 +267,21 @@ namespace
 // else set it to the ContentNode of the Pos outside the Range
 void lcl_FindExpelPosition(
 std::optional& rFoundPos,
-const SwNodeIndex& rStt,
-const SwNodeIndex& rEnd,
+const SwNode& rStt,
+const SwNode& rEnd,
 const SwPosition& rOtherPosition)
 {
-SwContentNode * pNode = rEnd.GetNode().GetContentNode();
+const SwContentNode * pNode = rEnd.GetContentNode();
 bool bPosAtEndOfNode

[Libreoffice-commits] core.git: Branch 'libreoffice-7-4' - desktop/qa filter/qa svx/qa svx/source vcl/qa

2022-08-24 Thread Caolán McNamara (via logerrit)
 desktop/qa/desktop_lib/test_desktop_lib.cxx |2 ++
 filter/qa/pdf.cxx   |9 -
 svx/qa/unit/core.cxx|2 ++
 svx/source/svdraw/svdpdf.cxx|2 +-
 vcl/qa/cppunit/filter/ipdf/ipdf.cxx |2 ++
 5 files changed, 15 insertions(+), 2 deletions(-)

New commits:
commit a1a5f60d388a6d367b5aee0ff6241e26fad9b530
Author: Caolán McNamara 
AuthorDate: Wed Aug 10 09:00:34 2022 +0100
Commit: Michael Stahl 
CommitDate: Mon Aug 15 11:25:52 2022 +0200

some --disable-pdfium fixes

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

diff --git a/desktop/qa/desktop_lib/test_desktop_lib.cxx 
b/desktop/qa/desktop_lib/test_desktop_lib.cxx
index ba9009cb0f30..1898d3f1377f 100644
--- a/desktop/qa/desktop_lib/test_desktop_lib.cxx
+++ b/desktop/qa/desktop_lib/test_desktop_lib.cxx
@@ -697,6 +697,8 @@ void DesktopLOKTest::testSaveAsJsonOptions()
 SvMemoryStream aMemory;
 aMemory.WriteStream(aFile);
 std::shared_ptr pPDFium = vcl::pdf::PDFiumLibrary::get();
+if (!pPDFium)
+return;
 std::unique_ptr pPdfDocument
 = pPDFium->openDocument(aMemory.GetData(), aMemory.GetSize(), 
OString());
 CPPUNIT_ASSERT(pPdfDocument);
diff --git a/filter/qa/pdf.cxx b/filter/qa/pdf.cxx
index 04bd4170c17e..207fa803b0cb 100644
--- a/filter/qa/pdf.cxx
+++ b/filter/qa/pdf.cxx
@@ -59,6 +59,10 @@ constexpr OUStringLiteral DATA_DIRECTORY = 
u"/filter/qa/data/";
 
 CPPUNIT_TEST_FIXTURE(Test, testSignCertificateSubjectName)
 {
+std::shared_ptr pPDFium = vcl::pdf::PDFiumLibrary::get();
+if (!pPDFium)
+return;
+
 uno::Reference xSEInitializer
 = xml::crypto::SEInitializer::create(mxComponentContext);
 uno::Reference xSecurityContext
@@ -98,7 +102,6 @@ CPPUNIT_TEST_FIXTURE(Test, testSignCertificateSubjectName)
 xFilter->filter(aDescriptor);
 
 // Then make sure the resulting PDF has a signature:
-std::shared_ptr pPDFium = vcl::pdf::PDFiumLibrary::get();
 std::unique_ptr pPdfDocument
 = pPDFium->openDocument(aStream.GetData(), aStream.GetSize(), 
OString());
 // Without the accompanying fix in place, this test would have failed, as 
signing was enabled
@@ -109,6 +112,10 @@ CPPUNIT_TEST_FIXTURE(Test, testSignCertificateSubjectName)
 
 CPPUNIT_TEST_FIXTURE(Test, testPdfDecompositionSize)
 {
+std::shared_ptr pPDFium = vcl::pdf::PDFiumLibrary::get();
+if (!pPDFium)
+return;
+
 // Given an empty Writer document:
 getComponent().set(
 loadFromDesktop("private:factory/swriter", 
"com.sun.star.text.TextDocument"));
diff --git a/svx/qa/unit/core.cxx b/svx/qa/unit/core.cxx
index 27e5783e20db..3966010012e6 100644
--- a/svx/qa/unit/core.cxx
+++ b/svx/qa/unit/core.cxx
@@ -70,6 +70,8 @@ CPPUNIT_TEST_FIXTURE(Test, testChartExportToPdf)
 
 // Then make sure we get a valid, non-empty PDF:
 auto pPdfium = vcl::pdf::PDFiumLibrary::get();
+if (!pPdfium)
+return;
 SvMemoryStream aMemory;
 aMemory.WriteStream(*aTempFile.GetStream(StreamMode::READ));
 std::unique_ptr pPdfDocument
diff --git a/svx/source/svdraw/svdpdf.cxx b/svx/source/svdraw/svdpdf.cxx
index 9f9cd2c5a8de..7beba145a1ea 100644
--- a/svx/source/svdraw/svdpdf.cxx
+++ b/svx/source/svdraw/svdpdf.cxx
@@ -115,7 +115,7 @@ ImpSdrPdfImport::ImpSdrPdfImport(SdrModel& rModel, 
SdrLayerID nLay, const tools:
 auto const& rVectorGraphicData = rGraphic.getVectorGraphicData();
 auto* pData = rVectorGraphicData->getBinaryDataContainer().getData();
 sal_Int32 nSize = rVectorGraphicData->getBinaryDataContainer().getSize();
-mpPdfDocument = mpPDFium->openDocument(pData, nSize, OString());
+mpPdfDocument = mpPDFium ? mpPDFium->openDocument(pData, nSize, OString()) 
: nullptr;
 if (!mpPdfDocument)
 return;
 
diff --git a/vcl/qa/cppunit/filter/ipdf/ipdf.cxx 
b/vcl/qa/cppunit/filter/ipdf/ipdf.cxx
index b57ead0f6702..c34bb4794700 100644
--- a/vcl/qa/cppunit/filter/ipdf/ipdf.cxx
+++ b/vcl/qa/cppunit/filter/ipdf/ipdf.cxx
@@ -129,6 +129,8 @@ CPPUNIT_TEST_FIXTURE(VclFilterIpdfTest, 
testPDFAddVisibleSignatureLastPage)
 
 // Then: count the # of shapes on the signature widget/annotation.
 std::shared_ptr pPDFium = vcl::pdf::PDFiumLibrary::get();
+if (!pPDFium)
+return;
 SvFileStream aFile(aTempFile.GetURL(), StreamMode::READ);
 SvMemoryStream aMemory;
 aMemory.WriteStream(aFile);


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

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/source/model/main/DataTable.cxx |   11 +++
 1 file changed, 11 insertions(+)

New commits:
commit cc54063b915a58db9133c919c151ec7e6209f4cd
Author: Tomaž Vajngerl 
AuthorDate: Thu Jun 30 23:43:52 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Sun Aug 14 20:43:40 2022 +0200

chart2: add some data table default properties

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

diff --git a/chart2/source/model/main/DataTable.cxx 
b/chart2/source/model/main/DataTable.cxx
index 5f3a5eb18403..c8ae688dfc4d 100644
--- a/chart2/source/model/main/DataTable.cxx
+++ b/chart2/source/model/main/DataTable.cxx
@@ -70,6 +70,17 @@ private:
  true);
 ::chart::PropertyHelper::setPropertyValueDefault(aMap, 
DataTableProperty_Outilne, true);
 ::chart::PropertyHelper::setPropertyValueDefault(aMap, 
DataTableProperty_Keys, false);
+
+::chart::PropertyHelper::setPropertyValue(
+aMap, ::chart::LinePropertiesHelper::PROP_LINE_WIDTH, 
uno::Any(sal_Int32(1)));
+
+float fDefaultCharHeight = 10.0;
+::chart::PropertyHelper::setPropertyValue(
+aMap, ::chart::CharacterProperties::PROP_CHAR_CHAR_HEIGHT, 
fDefaultCharHeight);
+::chart::PropertyHelper::setPropertyValue(
+aMap, ::chart::CharacterProperties::PROP_CHAR_ASIAN_CHAR_HEIGHT, 
fDefaultCharHeight);
+::chart::PropertyHelper::setPropertyValue(
+aMap, ::chart::CharacterProperties::PROP_CHAR_COMPLEX_CHAR_HEIGHT, 
fDefaultCharHeight);
 }
 };
 


[Libreoffice-commits] core.git: Branch 'libreoffice-7-4' - configure.ac

2022-08-24 Thread Christian Lohmaier (via logerrit)
 configure.ac |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 8845009d81c50bd34947a84b6508a2f9065a299b
Author: Christian Lohmaier 
AuthorDate: Wed Aug 24 18:24:55 2022 +0200
Commit: Christian Lohmaier 
CommitDate: Wed Aug 24 18:24:55 2022 +0200

correctly bump product version to 7.4.2.0.0+

Change-Id: Ib09ad097b321963de4f68a73fc962f3df89dce4d

diff --git a/configure.ac b/configure.ac
index b2fea0b55470..e5d202bfe82f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -9,7 +9,7 @@ dnl in order to create a configure script.
 # several non-alphanumeric characters, those are split off and used only for 
the
 # ABOUTBOXPRODUCTVERSIONSUFFIX in openoffice.lst. Why that is necessary, no 
idea.
 
-AC_INIT([LibreOffice],[7.4.1.1.0+],[],[],[http://documentfoundation.org/])
+AC_INIT([LibreOffice],[7.4.2.0.0+],[],[],[http://documentfoundation.org/])
 
 dnl libnumbertext needs autoconf 2.68, but that can pick up autoconf268 just 
fine if it is installed
 dnl whereas aclocal (as run by autogen.sh) insists on using autoconf and fails 
hard


[Libreoffice-commits] help.git: Changes to 'refs/tags/libreoffice-7.4.1.1'

2022-08-24 Thread Christian Lohmaier (via logerrit)
Tag 'libreoffice-7.4.1.1' created by Christian Lohmaier 
 at 2022-08-24 16:22 +

Tag libreoffice-7.4.1.1
-BEGIN PGP SIGNATURE-

iQIzBAABCAAdFiEEwoOeytlAj76VMcPp9DSh76/urqMFAmMGUF8ACgkQ9DSh76/u
rqMT6hAAopMD5/EBzgnJFutjGL1vnZkltDyHF8RR0VqZVTZEgU7wHNcW6GIm8J59
zwaq8KAXxEln1XhSha79VKR7AWGYGINat3fO4dkDq3KqSWlZTQNr5WDi+9dAfGOO
bsauGEZfDdZNvz8i2baQ2EHh8Ii7uBFdy3/AsU9R2+ruf0EtAw3f8YefzZZQ7X4A
zRWmd8ERXhMtiO8gwdwmg2L8TEZmzoFr2rJqXy1DxqDOVcU8mliJfYdajr34hy5s
pE5p0vsobriw1fvLxAT+Jc2Nn54llrcsHLjUM65G9X+z1cRvk0G1CNX+GQuSQAz2
i2BpAmqkmYtdUBl1V9yjgPLDHmemNnp2YPh9TAo4Glut3bxm7kn2Ngpby82+SaZ3
jX1WisDcbrS2G7Mxm7LmmZI5805zuKbFkC3oSDCouXbWPuRjOwoqhni2USBQ8bU1
GmzTDw3DBvsWXZkcwPnjVhZVSiRn/VVIjx1TRyMH15J90OnRzE8rlzi1p99EvG84
aJhv1/JjpvD+KQCPZaz7FfgcUjJXMVV9IYCz9kzBKsF9HgfUs5jPvlondkuTv80w
d+DmBMEUUdcGRNjlC3mwPYxlCwf0E2ZCyYhZNWRBsS8gjuTvsDyqK8bIL13bIJyA
l8eEX3P334InDk+EnheRAe9Mp6oeAk3xfMo8t28qljp6aLFnzJo=
=pY+U
-END PGP SIGNATURE-

Changes since libreoffice-7-4-branch-point-53:
---
 0 files changed
---


[Libreoffice-commits] core.git: Branch 'libreoffice-7-4-1' - configure.ac

2022-08-24 Thread Christian Lohmaier (via logerrit)
 configure.ac |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 4b760d15067d96591dd351d1a8b3dd59251e1aa8
Author: Christian Lohmaier 
AuthorDate: Wed Aug 24 18:23:29 2022 +0200
Commit: Christian Lohmaier 
CommitDate: Wed Aug 24 18:23:29 2022 +0200

bump product version to 7.4.1.1.0+

Change-Id: I405c97c02a3b1c77756dbbfec6743a327f5a0f7d

diff --git a/configure.ac b/configure.ac
index 846a5bf184ff..b2fea0b55470 100644
--- a/configure.ac
+++ b/configure.ac
@@ -9,7 +9,7 @@ dnl in order to create a configure script.
 # several non-alphanumeric characters, those are split off and used only for 
the
 # ABOUTBOXPRODUCTVERSIONSUFFIX in openoffice.lst. Why that is necessary, no 
idea.
 
-AC_INIT([LibreOffice],[7.4.1.0.0+],[],[],[http://documentfoundation.org/])
+AC_INIT([LibreOffice],[7.4.1.1.0+],[],[],[http://documentfoundation.org/])
 
 dnl libnumbertext needs autoconf 2.68, but that can pick up autoconf268 just 
fine if it is installed
 dnl whereas aclocal (as run by autogen.sh) insists on using autoconf and fails 
hard


[Libreoffice-commits] translations.git: Changes to 'refs/tags/libreoffice-7.4.1.1'

2022-08-24 Thread Christian Lohmaier (via logerrit)
Tag 'libreoffice-7.4.1.1' created by Christian Lohmaier 
 at 2022-08-24 16:22 +

Tag libreoffice-7.4.1.1
-BEGIN PGP SIGNATURE-

iQIzBAABCAAdFiEEwoOeytlAj76VMcPp9DSh76/urqMFAmMGUF8ACgkQ9DSh76/u
rqMUHg//efiiWbGwoF8mAazyOtNmGnL/MnWdu7IDpgPNKJZruVLNKWZ1pz4W6aMT
1CYwv/kH3/w06iGPkjD+KNb3Yqrc0sPQfeNXfQOapCfSddbJhsVwvy72jELG3WYi
ynmpQ6n8mSfMXHDsnDw+ceWlvO57ZC3yM7uamxmaLvLi5PbFzJ1Vg2UQMTpNv+zq
rAidM6+e0jROhnheee8/Mtgl5kGfXIpHtvIefJChog78fw1/KwYrL/PmkSf+JTwc
6DWGO6PCKxlJB5YYdXUjIe6viPQYPT6iq2WxJXCSCpr0y6hh0xQ783v3Dnr9UYcy
SlZGCT4+kffLoL4BTCImwXZCR14Hmtkc/0dzOfcsP6kdEHdkiQkyVwiMsSUfy6EJ
MOvnVYJuIx9LZCAAacwD+hNOtpU5MX/N8PScST9hLVFCW3V6OXaT2K2nddzbmo3t
G5Z7cypjd0pG+a3g8kaTDKXRiCqf5aIZxtOt/af67n5DxT+9JW0aNYQ+BIs0XFSP
49ys1V2lmsPZ7g/hKahWdragrj5gWNRtmbUK23lXaesdDoz8L8XEDQXrYtbJ54Yq
0axWSuJluTq0REhv779aPzPoYA+hoojUIFT1EqWTchFKYfFw35pMt1PKJ/duHinw
VlP5qOzpEo+uwU0C0ygVHTEBnA9wsvsGQV4xsff9SExochFKnng=
=EXur
-END PGP SIGNATURE-

Changes since libreoffice-7-4-branch-point-16:
---
 0 files changed
---


[Libreoffice-commits] core.git: Branch 'libreoffice-7-4' - configure.ac

2022-08-24 Thread Christian Lohmaier (via logerrit)
 configure.ac |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit ef616ff471d867ec9e411f81d57c762998a1ff4c
Author: Christian Lohmaier 
AuthorDate: Wed Aug 24 18:20:54 2022 +0200
Commit: Christian Lohmaier 
CommitDate: Wed Aug 24 18:20:54 2022 +0200

bump product version to 7.4.1.1.0+

Change-Id: Ifec4e22a9b03bf588199f2d3c4a1672ceb9677cf

diff --git a/configure.ac b/configure.ac
index 846a5bf184ff..b2fea0b55470 100644
--- a/configure.ac
+++ b/configure.ac
@@ -9,7 +9,7 @@ dnl in order to create a configure script.
 # several non-alphanumeric characters, those are split off and used only for 
the
 # ABOUTBOXPRODUCTVERSIONSUFFIX in openoffice.lst. Why that is necessary, no 
idea.
 
-AC_INIT([LibreOffice],[7.4.1.0.0+],[],[],[http://documentfoundation.org/])
+AC_INIT([LibreOffice],[7.4.1.1.0+],[],[],[http://documentfoundation.org/])
 
 dnl libnumbertext needs autoconf 2.68, but that can pick up autoconf268 just 
fine if it is installed
 dnl whereas aclocal (as run by autogen.sh) insists on using autoconf and fails 
hard


[Libreoffice-commits] help.git: Changes to 'libreoffice-7-4-1'

2022-08-24 Thread Christian Lohmaier (via logerrit)
New branch 'libreoffice-7-4-1' available with the following commits:
commit b6d6b706671c38708339388f4d2fdc93f77f4e66
Author: Christian Lohmaier 
Date:   Wed Aug 24 18:19:23 2022 +0200

Branch libreoffice-7-4-1

This is 'libreoffice-7-4-1' - the stable branch for the 7.4.1 release.
Only very safe changes, reviewed by three people are allowed.

If you want to commit more complicated fix for the next 7.4.x release,
please use the 'libreoffice-7-4' branch.

If you want to build something cool, unstable, and risky, use master.

Change-Id: If1be49befd16f18703b19caa0b3762d35bb006a5



[Libreoffice-commits] translations.git: Changes to 'libreoffice-7-4-1'

2022-08-24 Thread Christian Lohmaier (via logerrit)
New branch 'libreoffice-7-4-1' available with the following commits:
commit fef0ef275c1ae9f65b983496c025ba3cd1e26d71
Author: Christian Lohmaier 
Date:   Wed Aug 24 18:19:23 2022 +0200

Branch libreoffice-7-4-1

This is 'libreoffice-7-4-1' - the stable branch for the 7.4.1 release.
Only very safe changes, reviewed by three people are allowed.

If you want to commit more complicated fix for the next 7.4.x release,
please use the 'libreoffice-7-4' branch.

If you want to build something cool, unstable, and risky, use master.

Change-Id: I855cc1cdd6c3490982df61f78fcb247d8e7baad7



[Libreoffice-commits] dictionaries.git: Changes to 'libreoffice-7-4-1'

2022-08-24 Thread Christian Lohmaier (via logerrit)
New branch 'libreoffice-7-4-1' available with the following commits:
commit a3413650eff3832680a452539ee31d3157e2b5d9
Author: Christian Lohmaier 
Date:   Wed Aug 24 18:19:23 2022 +0200

Branch libreoffice-7-4-1

This is 'libreoffice-7-4-1' - the stable branch for the 7.4.1 release.
Only very safe changes, reviewed by three people are allowed.

If you want to commit more complicated fix for the next 7.4.x release,
please use the 'libreoffice-7-4' branch.

If you want to build something cool, unstable, and risky, use master.

Change-Id: I3baf2a9f9494efbd78d09e9f5050fcc69ab81496



[Libreoffice-commits] core.git: Branch 'libreoffice-7-4' - sw/source

2022-08-24 Thread Michael Stahl (via logerrit)
 sw/source/core/text/porlay.cxx |4 
 1 file changed, 4 insertions(+)

New commits:
commit da7833bf6f8990a8916e3d38090426cb430633a4
Author: Michael Stahl 
AuthorDate: Fri Aug 12 17:39:18 2022 +0200
Commit: Caolán McNamara 
CommitDate: Sun Aug 14 12:57:58 2022 +0200

sw: fix crash in InitBookmarks() with forum-mso-en-8410.docx

Error: attempt to dereference a past-the-end iterator.

Probably this only crashes in the assert(iter->pNode...) as the rest of
the function already checks that "iter == end".

(regression from commit 46e04a712e97f9095ef4da7f0e52f50cf2bfbb32)

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

diff --git a/sw/source/core/text/porlay.cxx b/sw/source/core/text/porlay.cxx
index 8e61614a6ef1..d91edd87ca0b 100644
--- a/sw/source/core/text/porlay.cxx
+++ b/sw/source/core/text/porlay.cxx
@@ -1051,6 +1051,10 @@ static void InitBookmarks(
 break;
 }
 }
+if (iter == end)
+{
+break; // remaining marks are hidden
+}
 }
 }
 


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

2022-08-24 Thread Noel Grandin (via logerrit)
 sw/source/core/inc/UndoTable.hxx |2 +-
 sw/source/core/undo/untbl.cxx|   10 ++
 2 files changed, 7 insertions(+), 5 deletions(-)

New commits:
commit 912278671718d5d3d45fce25a3ca76228c81f7f3
Author: Noel Grandin 
AuthorDate: Tue Aug 9 15:41:39 2022 +0200
Commit: Noel Grandin 
CommitDate: Sat Aug 13 14:29:58 2022 +0200

unique_ptr->optional in SwUndoInsTable

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

diff --git a/sw/source/core/inc/UndoTable.hxx b/sw/source/core/inc/UndoTable.hxx
index 0507f531ae12..749f4873d77b 100644
--- a/sw/source/core/inc/UndoTable.hxx
+++ b/sw/source/core/inc/UndoTable.hxx
@@ -58,7 +58,7 @@ class SwUndoInsTable final : public SwUndo
 OUString m_sTableName;
 SwInsertTableOptions m_aInsTableOptions;
 std::unique_ptr m_pDDEFieldType;
-std::unique_ptr> m_pColumnWidth;
+std::optional> m_oColumnWidth;
 std::unique_ptr  m_pRedlineData;
 std::unique_ptr m_pAutoFormat;
 SwNodeOffset m_nStartNode;
diff --git a/sw/source/core/undo/untbl.cxx b/sw/source/core/undo/untbl.cxx
index f17c8419741c..98a67a3b6996 100644
--- a/sw/source/core/undo/untbl.cxx
+++ b/sw/source/core/undo/untbl.cxx
@@ -242,7 +242,7 @@ SwUndoInsTable::SwUndoInsTable( const SwPosition& rPos, 
sal_uInt16 nCl, sal_uInt
 {
 if( pColArr )
 {
-m_pColumnWidth.reset( new std::vector(*pColArr) );
+m_oColumnWidth.emplace( *pColArr );
 }
 if( pTAFormat )
 m_pAutoFormat.reset( new SwTableAutoFormat( *pTAFormat ) );
@@ -261,7 +261,7 @@ SwUndoInsTable::SwUndoInsTable( const SwPosition& rPos, 
sal_uInt16 nCl, sal_uInt
 SwUndoInsTable::~SwUndoInsTable()
 {
 m_pDDEFieldType.reset();
-m_pColumnWidth.reset();
+m_oColumnWidth.reset();
 m_pRedlineData.reset();
 m_pAutoFormat.reset();
 }
@@ -315,7 +315,8 @@ void SwUndoInsTable::RedoImpl(::sw::UndoRedoContext & 
rContext)
 SwPosition const aPos(rDoc.GetNodes(), m_nStartNode);
 const SwTable* pTable = rDoc.InsertTable( m_aInsTableOptions, aPos, 
m_nRows, m_nColumns,
 m_nAdjust,
-m_pAutoFormat.get(), 
m_pColumnWidth.get() );
+m_pAutoFormat.get(),
+m_oColumnWidth ? &*m_oColumnWidth 
: nullptr );
 rDoc.GetEditShell()->MoveTable( GotoPrevTable, fnTableStart );
 static_cast(pTable->GetFrameFormat())->SetFormatName( 
m_sTableName );
 SwTableNode* pTableNode = rDoc.GetNodes()[m_nStartNode]->GetTableNode();
@@ -355,7 +356,8 @@ void SwUndoInsTable::RepeatImpl(::sw::RepeatContext & 
rContext)
 {
 rContext.GetDoc().InsertTable(
 m_aInsTableOptions, *rContext.GetRepeatPaM().GetPoint(),
-m_nRows, m_nColumns, m_nAdjust, m_pAutoFormat.get(), 
m_pColumnWidth.get() );
+m_nRows, m_nColumns, m_nAdjust, m_pAutoFormat.get(),
+m_oColumnWidth ? &*m_oColumnWidth : nullptr );
 }
 
 SwRewriter SwUndoInsTable::GetRewriter() const


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

2022-08-24 Thread ehsan (via logerrit)
 tools/source/generic/poly.cxx |   14 +++---
 1 file changed, 7 insertions(+), 7 deletions(-)

New commits:
commit 9b5f0234da27a674a939941d89975bc5a365f7ae
Author: ehsan 
AuthorDate: Sun Jul 10 19:05:56 2022 +0430
Commit: Hossein 
CommitDate: Sat Aug 13 12:09:17 2022 +0200

tdf#145614 Convert #define to constexpr

Change-Id: If783e2fbb65cae8e9c79ad9718f344dedf9dfe4f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135074
Tested-by: Jenkins
Reviewed-by: Hossein 

diff --git a/tools/source/generic/poly.cxx b/tools/source/generic/poly.cxx
index 166803b38f04..25f15d5fd00a 100644
--- a/tools/source/generic/poly.cxx
+++ b/tools/source/generic/poly.cxx
@@ -44,13 +44,13 @@
 #include 
 #include 
 
-#define EDGE_LEFT   1
-#define EDGE_TOP2
-#define EDGE_RIGHT  4
-#define EDGE_BOTTOM 8
-#define EDGE_HORZ   (EDGE_RIGHT | EDGE_LEFT)
-#define EDGE_VERT   (EDGE_TOP | EDGE_BOTTOM)
-#define SMALL_DVALUE0.001
+constexpr int EDGE_LEFT   = 1;
+constexpr int EDGE_TOP= 2;
+constexpr int EDGE_RIGHT  = 4;
+constexpr int EDGE_BOTTOM = 8;
+constexpr int EDGE_HORZ   = EDGE_RIGHT | EDGE_LEFT;
+constexpr int EDGE_VERT   = EDGE_TOP | EDGE_BOTTOM;
+constexpr double SMALL_DVALUE = 0.001;
 #define FSQRT2  1.4142135623730950488016887242097
 
 static double ImplGetParameter( const Point& rCenter, const Point& rPt, double 
fWR, double fHR )


list numbering is wrong when the table contains the vertically merged cells(DOCX)

2022-08-24 Thread satya kompella
Hi Team,
I am working on a bug where the list numbering is wrong when the table
contains the vertically merged cells. The same issue was already fixed a
while ago but the fix is only working for .DOC files but not for .DOCX
files(see here for the fix https://gerrit.libreoffice.org/c/core/+/32512/).

Now, I am trying to fix it for DOCX files.

I am new to the Libreoffice source code, But I did set up a debug
environment and am able to debug the code using VS 2019. Please provide
some inputs where I should look into to fix this issue.

Regards,
Satya


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

2022-08-24 Thread Caolán McNamara (via logerrit)
 sd/source/ui/view/sdview2.cxx |4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit ff38fc027ac04baecd0c5a17a5b795169a4273da
Author: Caolán McNamara 
AuthorDate: Wed Aug 24 12:52:30 2022 +0100
Commit: Caolán McNamara 
CommitDate: Wed Aug 24 17:13:17 2022 +0200

cid#1509260 silence Dereference null return value

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

diff --git a/sd/source/ui/view/sdview2.cxx b/sd/source/ui/view/sdview2.cxx
index a5b3d44132b6..17449a6b8a86 100644
--- a/sd/source/ui/view/sdview2.cxx
+++ b/sd/source/ui/view/sdview2.cxx
@@ -437,7 +437,9 @@ sal_Int8 View::AcceptDrop( const AcceptDropEvent& rEvt, 
DropTargetHelper& rTarge
 if( nLayer != SDRLAYER_NOTFOUND )
 {
 SdrLayerAdmin& rLayerAdmin = mrDoc.GetLayerAdmin();
-aLayerName = rLayerAdmin.GetLayerPerID(nLayer)->GetName();
+SdrLayer* pLayer = rLayerAdmin.GetLayerPerID(nLayer);
+assert(pLayer && "layer missing");
+aLayerName = pLayer->GetName();
 }
 
 if( mbIsDropAllowed && !pPV->IsLayerLocked( aLayerName ) && 
pPV->IsLayerVisible( aLayerName ) )


[Libreoffice-commits] core.git: Branch 'libreoffice-7-4' - sfx2/source sfx2/uiconfig

2022-08-24 Thread Rafael Lima (via logerrit)
 sfx2/source/doc/templatedlg.cxx |3 +++
 sfx2/uiconfig/ui/templatedlg.ui |3 +--
 2 files changed, 4 insertions(+), 2 deletions(-)

New commits:
commit 271711523e5f0d1191012009de311cc15b2096c2
Author: Rafael Lima 
AuthorDate: Sat Jul 9 00:43:13 2022 +0200
Commit: Christian Lohmaier 
CommitDate: Wed Aug 24 17:13:08 2022 +0200

tdf#149768 Do not fix Templates dialog width and height in pixels

This patch removes the fixed size of the Templates dialog in pixels so it 
works better in HiDPI displays.

This patch also makes the dialog a bit wider and non-resizable.

Change-Id: I256d8d5c8b76c8e32a4f008f3a235f80bf59634d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/136922
Reviewed-by: Heiko Tietze 
Tested-by: Heiko Tietze 
(cherry picked from commit 410bff99a708371eed6a82677b44e2151a4a990a)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138546
Tested-by: Jenkins
Reviewed-by: Christian Lohmaier 

diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index ac3015ceb8c0..42e570e75dfb 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -203,6 +203,9 @@ SfxTemplateManagerDlg::SfxTemplateManagerDlg(weld::Window 
*pParent)
 
 mxLocalView->ShowTooltips(true);
 
+// Set width and height of the templates thumbnail viewer to acommodate 3 
rows and 4 columns of items
+mxLocalViewWeld->set_size_request(TEMPLATE_ITEM_MAX_WIDTH * 5, 
TEMPLATE_ITEM_MAX_HEIGHT_SUB * 3);
+
 mxOKButton->connect_clicked(LINK(this, SfxTemplateManagerDlg, OkClickHdl));
 // FIXME: rather than disabling make 
dispatchCommand(".uno:AdditionsDialog") work in start center
 if ( !SfxModule::GetActiveModule() )
diff --git a/sfx2/uiconfig/ui/templatedlg.ui b/sfx2/uiconfig/ui/templatedlg.ui
index 013eacb2a467..7f7fe31d6371 100644
--- a/sfx2/uiconfig/ui/templatedlg.ui
+++ b/sfx2/uiconfig/ui/templatedlg.ui
@@ -39,11 +39,10 @@
 
   
   
-740
-500
 False
 6
 Templates
+False
 True
 0
 0


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

2022-08-24 Thread Caolán McNamara (via logerrit)
 sc/source/ui/app/inputhdl.cxx|6 +-
 sd/source/ui/unoidl/unocpres.cxx |4 ++--
 2 files changed, 7 insertions(+), 3 deletions(-)

New commits:
commit ee7b7acba288d265001237e3d81a1791e322ed28
Author: Caolán McNamara 
AuthorDate: Wed Aug 24 13:04:28 2022 +0100
Commit: Caolán McNamara 
CommitDate: Wed Aug 24 17:12:51 2022 +0200

cid#1509194 Dereference after null check

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

diff --git a/sc/source/ui/app/inputhdl.cxx b/sc/source/ui/app/inputhdl.cxx
index bfbb446e1364..f16e52af8fb6 100644
--- a/sc/source/ui/app/inputhdl.cxx
+++ b/sc/source/ui/app/inputhdl.cxx
@@ -3458,10 +3458,14 @@ void ScInputHandler::CancelHandler()
 
 eMode = SC_INPUT_NONE;
 StopInputWinEngine( true );
+SCCOL nMaxCol(MAXCOL);
 if (pExecuteSh)
+{
 pExecuteSh->StopEditShell();
+nMaxCol = pExecuteSh->GetViewData().GetDocument().MaxCol();
+}
 
-aCursorPos.Set(pExecuteSh->GetViewData().GetDocument().MaxCol()+1,0,0); // 
Invalid flag
+aCursorPos.Set(nMaxCol+1,0,0); // Invalid flag
 mpEditEngine->SetTextCurrentDefaults(OUString());
 
 if ( !pLastState && pExecuteSh )
commit 2f05a65a4eafcbda3438e50bd0b6518248c04d5d
Author: Caolán McNamara 
AuthorDate: Wed Aug 24 12:56:43 2022 +0100
Commit: Caolán McNamara 
CommitDate: Wed Aug 24 17:12:36 2022 +0200

cid#1509207 Dereference after null check

remove useless null checks left behind after

commit bb674aa5503ff40a5619d1fb4c9f310da5f5c983
Date:   Thu Nov 17 13:16:30 2016 +0200

loplugin:unusedfields

showed they weren't consumed anyway

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

diff --git a/sd/source/ui/unoidl/unocpres.cxx b/sd/source/ui/unoidl/unocpres.cxx
index cc57b1e7941a..1f9bde3b98da 100644
--- a/sd/source/ui/unoidl/unocpres.cxx
+++ b/sd/source/ui/unoidl/unocpres.cxx
@@ -98,10 +98,10 @@ void SAL_CALL SdXCustomPresentation::insertByIndex( 
sal_Int32 Index, const uno::
 
 if(pPage)
 {
-if( nullptr == mpModel )
+if (!mpModel)
 mpModel = pPage->GetModel();
 
-if( nullptr != mpModel && nullptr == mpSdCustomShow && 
mpModel->GetDoc() )
+if (!mpSdCustomShow)
 mpSdCustomShow = new SdCustomShow;
 
 
mpSdCustomShow->PagesVector().insert(mpSdCustomShow->PagesVector().begin() + 
Index,


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

2022-08-24 Thread Noel Grandin (via logerrit)
 sw/inc/ndarr.hxx  |6 +++---
 sw/source/core/crsr/crsrsh.cxx|5 ++---
 sw/source/core/docnode/ndsect.cxx |3 +--
 sw/source/core/docnode/ndtbl.cxx  |   13 -
 sw/source/core/docnode/nodes.cxx  |   34 --
 sw/source/core/layout/frmtool.cxx |5 ++---
 sw/source/core/txtnode/ndtxt.cxx  |3 +--
 7 files changed, 29 insertions(+), 40 deletions(-)

New commits:
commit cfa942249162d5503b8a34d5813fddfb1182283a
Author: Noel Grandin 
AuthorDate: Wed Aug 24 14:11:01 2022 +0200
Commit: Noel Grandin 
CommitDate: Wed Aug 24 16:20:31 2022 +0200

pass SwNode to FindPrvNxtFrameNode instead of SwNodeIndex

part of the process of hiding the internals of SwPosition

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

diff --git a/sw/inc/ndarr.hxx b/sw/inc/ndarr.hxx
index 902f227800c3..0dabda23ec9f 100644
--- a/sw/inc/ndarr.hxx
+++ b/sw/inc/ndarr.hxx
@@ -311,10 +311,10 @@ public:
 const   SwDoc& GetDoc() const   { return m_rMyDoc; }
 
 /** Search previous / next content node or table node with frames.
- Search is started backward with the one before rFrameIdx and
+ Search is started backward with the one before rFrameNd and
  forward after pEnd.
- If no valid node is found, return 0. rFrameIdx points to the node with 
frames. **/
-SwNode* FindPrvNxtFrameNode( SwNodeIndex& rFrameIdx,
+ If no valid node is found, return nullptr. **/
+SwNode* FindPrvNxtFrameNode( const SwNode& rFrameNd,
 const SwNode* pEnd,
 SwRootFrame const* pLayout = nullptr) const;
 
diff --git a/sw/source/core/crsr/crsrsh.cxx b/sw/source/core/crsr/crsrsh.cxx
index 2e34d4696be2..bcc0b2433c1f 100644
--- a/sw/source/core/crsr/crsrsh.cxx
+++ b/sw/source/core/crsr/crsrsh.cxx
@@ -1517,12 +1517,11 @@ static bool lcl_CheckHiddenSection( SwNodeIndex& rIdx )
 const SwSectionNode* pSectNd = rIdx.GetNode().FindSectionNode();
 if( pSectNd && pSectNd->GetSection().IsHiddenFlag() )
 {
-SwNodeIndex aTmp( *pSectNd );
 const SwNode* pFrameNd =
-rIdx.GetNodes().FindPrvNxtFrameNode( aTmp, 
pSectNd->EndOfSectionNode() );
+rIdx.GetNodes().FindPrvNxtFrameNode( *pSectNd, 
pSectNd->EndOfSectionNode() );
 bOk = pFrameNd != nullptr;
 SAL_WARN_IF(!bOk, "sw.core", "found no Node with Frames");
-rIdx = aTmp;
+rIdx = *(bOk ? pFrameNd : pSectNd);
 }
 return bOk;
 }
diff --git a/sw/source/core/docnode/ndsect.cxx 
b/sw/source/core/docnode/ndsect.cxx
index 5fb4438bb438..d97c08d278ff 100644
--- a/sw/source/core/docnode/ndsect.cxx
+++ b/sw/source/core/docnode/ndsect.cxx
@@ -919,8 +919,7 @@ SwSectionNode* SwNodes::InsertTextSection(SwNode& rNd,
 std::optional oNode2Layout;
 if( bInsFrame )
 {
-SwNodeIndex aTmp( *pSectNd );
-if( !pSectNd->GetNodes().FindPrvNxtFrameNode( aTmp, 
pSectNd->EndOfSectionNode() ) )
+if( !pSectNd->GetNodes().FindPrvNxtFrameNode( *pSectNd, 
pSectNd->EndOfSectionNode() ) )
 // Collect all Uppers
 oNode2Layout.emplace(*pSectNd);
 }
diff --git a/sw/source/core/docnode/ndtbl.cxx b/sw/source/core/docnode/ndtbl.cxx
index 556f9a11a869..fe2fc3b6822b 100644
--- a/sw/source/core/docnode/ndtbl.cxx
+++ b/sw/source/core/docnode/ndtbl.cxx
@@ -1583,8 +1583,8 @@ bool SwNodes::TableToText( const SwNodeRange& rRange, 
sal_Unicode cCh,
 
 // If the Table was alone in a Section, create the Frames via the Table's 
Upper
 std::optional oNode2Layout;
-SwNodeIndex aFrameIdx( rRange.aStart );
-SwNode* pFrameNd = FindPrvNxtFrameNode( aFrameIdx, &rRange.aEnd.GetNode() 
);
+SwNode* pFrameNd = FindPrvNxtFrameNode( rRange.aStart.GetNode(), 
&rRange.aEnd.GetNode() );
+SwNodeIndex aFrameIdx( pFrameNd ? *pFrameNd: rRange.aStart.GetNode() );
 if( !pFrameNd )
 // Collect all Uppers
 oNode2Layout.emplace(*pTableNd);
@@ -2382,10 +2382,13 @@ void 
SwTableNode::MakeFramesForAdjacentContentNode(const SwNodeIndex & rIdx)
 void SwTableNode::MakeOwnFrames(SwNodeIndex* pIdxBehind)
 {
 OSL_ENSURE( pIdxBehind, "No Index" );
-*pIdxBehind = *this;
-SwNode *pNd = GetNodes().FindPrvNxtFrameNode( *pIdxBehind, 
EndOfSectionNode() );
+SwNode *pNd = GetNodes().FindPrvNxtFrameNode( *this, EndOfSectionNode() );
 if( !pNd )
-return ;
+{
+*pIdxBehind = *this;
+return;
+}
+*pIdxBehind = *pNd;
 
 SwFrame *pFrame( nullptr );
 SwLayoutFrame *pUpper( nullptr );
diff --git a/sw/source/core/docnode/nodes.cxx b/sw/source/core/docnode/nodes.cxx
index 48c135861686..93384c28d12a 100644
--- a/sw/source/core/docnode/nodes.cxx
+++ b/sw/source/core/docnode/nodes.cxx
@@ -366,8 +366,7 @@ void SwNodes::ChgNode( SwNodeIndex const & rDelPos, 
SwNodeOffset nSz,
 
 //

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

2022-08-24 Thread Mike Kaganski (via logerrit)
 svx/source/form/formcontroller.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 59f30175bfc557aa7c752ab0b45af9d34215d4dc
Author: Mike Kaganski 
AuthorDate: Wed Aug 24 10:49:47 2022 +0200
Commit: Mike Kaganski 
CommitDate: Wed Aug 24 15:48:11 2022 +0200

tdf#150577: Revert "Micro-optim in FormController::approveRowChange"

This reverts commit e005ab5d40d358adb75a64e140d46f4bf605647d.

XColumn::wasNull is documented [1] to require a previous call to a get*
method. The reverted change internally queried the *previous* column's
wasNull.

[1] 
https://api.libreoffice.org/docs/idl/ref/interfacecom_1_1sun_1_1star_1_1sdb_1_1XColumn.html#a0d482c20564f9119052b1962f830190e

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

diff --git a/svx/source/form/formcontroller.cxx 
b/svx/source/form/formcontroller.cxx
index 3d57d36e3ca9..ba666fd3829d 100644
--- a/svx/source/form/formcontroller.cxx
+++ b/svx/source/form/formcontroller.cxx
@@ -3647,7 +3647,7 @@ sal_Bool SAL_CALL FormController::approveRowChange(const 
RowChangeEvent& _rEvent
 }
 
 // TODO: in case of binary fields, this "getString" below is 
extremely expensive
-if ( !rColInfo.xColumn->wasNull() || 
!rColInfo.xColumn->getString().isEmpty() )
+if ( !rColInfo.xColumn->getString().isEmpty() || 
!rColInfo.xColumn->wasNull() )
 continue;
 
 OUString sMessage( SvxResId( RID_ERR_FIELDREQUIRED ) );


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

2022-08-24 Thread Miklos Vajna (via logerrit)
 svx/qa/unit/data/video-snapshot.pptx |binary
 svx/qa/unit/svdraw.cxx   |   23 +++
 svx/source/svdraw/svdomedia.cxx  |9 +
 3 files changed, 32 insertions(+)

New commits:
commit 8fa1d453c94cdbb03dac646fb8db2ebd1a0e84bd
Author: Miklos Vajna 
AuthorDate: Wed Aug 24 13:53:38 2022 +0200
Commit: Miklos Vajna 
CommitDate: Wed Aug 24 15:45:12 2022 +0200

Related: tdf#149971 svx: support explicitly provided snapshots for media 
shapes

Snapshots / previews for media objects are used when the shape's video
is not playing. This is generated by seeking to the 3rd second in the
video, probably to avoid initial black frames.

The trouble is that PowerPoint takes the initial frame (at least in case
of the bugdoc), so our snapshot doesn't match the reference.

We already import a bitmap snapshot from PPTX files since commit
e2d46da076f43a7c0d56fc486b9f15339243f7c9 (avmedia: add doc model for
bitmap fill of slide narrations, 2021-01-21), fix the problem by
changing the snapshot generation to prefer this bitmap over generating
one from the video.

The crop properties of this bitmap / the video are still not yet handled
from PPTX.

Change-Id: Id985ed5e4222d9a98203d054e08a0f97a0f7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138763
Reviewed-by: Miklos Vajna 
Tested-by: Jenkins

diff --git a/svx/qa/unit/data/video-snapshot.pptx 
b/svx/qa/unit/data/video-snapshot.pptx
new file mode 100644
index ..9a0ec9ebd867
Binary files /dev/null and b/svx/qa/unit/data/video-snapshot.pptx differ
diff --git a/svx/qa/unit/svdraw.cxx b/svx/qa/unit/svdraw.cxx
index 9ad02060d68e..1bb9a6dab4db 100644
--- a/svx/qa/unit/svdraw.cxx
+++ b/svx/qa/unit/svdraw.cxx
@@ -36,6 +36,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 
@@ -483,6 +484,28 @@ CPPUNIT_TEST_FIXTURE(SvdrawTest, testMaterialSpecular)
 // The first light is harsh, the second light soft. So the 3D scene should 
have 6 lights (1+1+4).
 assertXPath(pXmlDoc, "//light", 6);
 }
+
+CPPUNIT_TEST_FIXTURE(SvdrawTest, testVideoSnapshot)
+{
+// Given a slide with a media shape, containing a 4 sec video, 
red-green-blue-black being the 4
+// seconds:
+OUString aURL = 
m_directories.getURLFromSrc(u"svx/qa/unit/data/video-snapshot.pptx");
+mxComponent = loadFromDesktop(aURL, 
"com.sun.star.presentation.PresentationDocument");
+SdrPage* pSdrPage = getFirstDrawPageWithAssert();
+auto pSdrMediaObj = dynamic_cast(pSdrPage->GetObj(0));
+
+// When getting the red snapshot of the video:
+Graphic aSnapshot(pSdrMediaObj->getSnapshot());
+
+// Then make sure the color is correct:
+const BitmapEx& rBitmap = aSnapshot.GetBitmapExRef();
+// Without the accompanying fix in place, this test would have failed with:
+// - Expected: rgba[ffff]
+// - Actual  : rgba[00ff]
+// i.e. the preview was black, not red; since we seeked 3 secs into the 
video, while PowerPoint
+// doesn't do that.
+CPPUNIT_ASSERT_EQUAL(Color(0xff, 0x0, 0x0), rBitmap.GetPixelColor(0, 0));
+}
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/svdraw/svdomedia.cxx b/svx/source/svdraw/svdomedia.cxx
index f36e8aaa92e8..15a0e1179098 100644
--- a/svx/source/svdraw/svdomedia.cxx
+++ b/svx/source/svdraw/svdomedia.cxx
@@ -151,6 +151,15 @@ uno::Reference< graphic::XGraphic > const & 
SdrMediaObj::getSnapshot() const
 #if HAVE_FEATURE_AVMEDIA
 if( !m_xImpl->m_xCachedSnapshot.is() )
 {
+Graphic aGraphic = m_xImpl->m_MediaProperties.getGraphic();
+if (!aGraphic.IsNone())
+{
+// We have an explicit graphic for this media object, then go with 
that instead of
+// generating our own one.
+m_xImpl->m_xCachedSnapshot = aGraphic.GetXGraphic();
+return m_xImpl->m_xCachedSnapshot;
+}
+
 OUString aRealURL = m_xImpl->m_MediaProperties.getTempURL();
 if( aRealURL.isEmpty() )
 aRealURL = m_xImpl->m_MediaProperties.getURL();


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

2022-08-24 Thread Tomaž Vajngerl (via logerrit)
 chart2/source/controller/main/ChartController_Insert.cxx |   19 ++-
 chart2/source/model/main/Diagram.cxx |5 +++
 2 files changed, 23 insertions(+), 1 deletion(-)

New commits:
commit 0d2c6df11e876d1afdf0f9bdfb5e9e0ce7583f68
Author: Tomaž Vajngerl 
AuthorDate: Wed Aug 10 12:06:42 2022 +0200
Commit: Tomaž Vajngerl 
CommitDate: Wed Aug 24 15:40:41 2022 +0200

chart2: Add undo/redo for the data table

Change-Id: I6b25a7a82957705481952bc3cd181a6d0c1fce0e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138298
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 
(cherry picked from commit fcf839cd4b76254d03426a849e17927b2a845352)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138584
Tested-by: Jenkins CollaboraOffice 

diff --git a/chart2/source/controller/main/ChartController_Insert.cxx 
b/chart2/source/controller/main/ChartController_Insert.cxx
index 40f0675d76af..02c0e681579a 100644
--- a/chart2/source/controller/main/ChartController_Insert.cxx
+++ b/chart2/source/controller/main/ChartController_Insert.cxx
@@ -162,6 +162,9 @@ void ChartController::executeDispatch_InsertGrid()
 void ChartController::executeDispatch_OpenInsertDataTableDialog()
 {
 SolarMutexGuard aGuard;
+auto aUndoDescription = 
ActionDescriptionProvider::createDescription(ActionDescriptionProvider::ActionType::Insert,
 SchResId(STR_OBJECT_DATA_TABLE));
+UndoGuard aUndoGuard(aUndoDescription, m_xUndoManager);
+
 uno::Reference xDiagram = 
ChartModelHelper::findDiagram(getModel());
 
 InsertDataTableDialog aDialog(GetChartFrame());
@@ -196,12 +199,14 @@ void 
ChartController::executeDispatch_OpenInsertDataTableDialog()
 // show the dialog
 if (aDialog.run() == RET_OK)
 {
-auto& rDialogData = aDialog.getDataTableDialogData();
+bool bChanged = false;
 
+auto& rDialogData = aDialog.getDataTableDialogData();
 auto xDataTable = xDiagram->getDataTable();
 if (!rDialogData.mbShow && xDataTable.is())
 {
 xDiagram->setDataTable(uno::Reference());
+bChanged = true;
 }
 else if (rDialogData.mbShow && !xDataTable.is())
 {
@@ -209,6 +214,7 @@ void 
ChartController::executeDispatch_OpenInsertDataTableDialog()
 if (xNewDataTable.is())
 {
 xDiagram->setDataTable(xNewDataTable);
+bChanged = true;
 }
 }
 
@@ -221,13 +227,20 @@ void 
ChartController::executeDispatch_OpenInsertDataTableDialog()
 xProperties->setPropertyValue("VBorder" , 
uno::Any(rDialogData.mbVerticalBorders));
 xProperties->setPropertyValue("Outline" , 
uno::Any(rDialogData.mbOutline));
 xProperties->setPropertyValue("Keys" , 
uno::Any(rDialogData.mbKeys));
+bChanged = true;
 }
+
+if (bChanged)
+aUndoGuard.commit();
 }
 }
 
 void ChartController::executeDispatch_InsertDataTable()
 {
 SolarMutexGuard aGuard;
+auto aUndoDescription = 
ActionDescriptionProvider::createDescription(ActionDescriptionProvider::ActionType::Insert,
 SchResId(STR_OBJECT_DATA_TABLE));
+UndoGuard aUndoGuard(aUndoDescription, m_xUndoManager);
+
 uno::Reference xDiagram = 
ChartModelHelper::findDiagram(getModel());
 auto xDataTable = xDiagram->getDataTable();
 if (!xDataTable.is())
@@ -236,6 +249,7 @@ void ChartController::executeDispatch_InsertDataTable()
 if (xNewDataTable.is())
 {
 xDiagram->setDataTable(xNewDataTable);
+aUndoGuard.commit();
 }
 }
 }
@@ -243,11 +257,14 @@ void ChartController::executeDispatch_InsertDataTable()
 void ChartController::executeDispatch_DeleteDataTable()
 {
 SolarMutexGuard aGuard;
+auto aUndoDescription = 
ActionDescriptionProvider::createDescription(ActionDescriptionProvider::ActionType::Delete,
 SchResId(STR_OBJECT_DATA_TABLE));
+UndoGuard aUndoGuard(aUndoDescription, m_xUndoManager);
 uno::Reference xDiagram = 
ChartModelHelper::findDiagram(getModel());
 auto xDataTable = xDiagram->getDataTable();
 if (xDataTable.is())
 {
 xDiagram->setDataTable(uno::Reference());
+aUndoGuard.commit();
 }
 }
 
diff --git a/chart2/source/model/main/Diagram.cxx 
b/chart2/source/model/main/Diagram.cxx
index 2a310863aca6..518a765820c7 100644
--- a/chart2/source/model/main/Diagram.cxx
+++ b/chart2/source/model/main/Diagram.cxx
@@ -264,10 +264,14 @@ Diagram::Diagram( const Diagram & rOther ) :
 m_xTitle.set( CloneHelper::CreateRefClone< chart2::XTitle >()( 
rOther.m_xTitle ));
 m_xLegend.set( CloneHelper::CreateRefClone< chart2::XLegend >()( 
rOther.m_xLegend ));
 
+if (rOther.m_xDataTable.is())
+m_xDataTable.set(new DataTable(*rOther.m_xDataTable));
+
 ModifyListenerHelper::addListener( m_xWall, m_xModifyEventForwarder );
 ModifyListenerHelper::addListener( m_xFloor, m_xModifyEventForwarder );
 

[Libreoffice-commits] core.git: Branch 'libreoffice-7-4' - unotools/source

2022-08-24 Thread Eike Rathke (via logerrit)
 unotools/source/i18n/localedatawrapper.cxx |   20 +++-
 1 file changed, 7 insertions(+), 13 deletions(-)

New commits:
commit df6601c2432fa6353c9641cedea918fc524ae31d
Author: Eike Rathke 
AuthorDate: Mon Aug 22 16:16:08 2022 +0200
Commit: Christian Lohmaier 
CommitDate: Wed Aug 24 15:32:06 2022 +0200

Resolves: tdf#150288 Do not prepend the locale's full date acceptance 
pattern

... if it wasn't present as first, but take the date acceptance
patterns as specified by the user.

Change-Id: Ife2fd39731bac0e0b121f22392f22b48ffc9c978
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138694
Reviewed-by: Eike Rathke 
Tested-by: Jenkins
(cherry picked from commit 5061f59ae538a35c9531c366574c64007cb9f0be)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138545
Reviewed-by: Christian Lohmaier 

diff --git a/unotools/source/i18n/localedatawrapper.cxx 
b/unotools/source/i18n/localedatawrapper.cxx
index 55cde4a360a4..25a3fc2f5218 100644
--- a/unotools/source/i18n/localedatawrapper.cxx
+++ b/unotools/source/i18n/localedatawrapper.cxx
@@ -1550,19 +1550,13 @@ void LocaleDataWrapper::loadDateAcceptancePatterns(
 }
 }
 
-// Never overwrite the locale's full date pattern! The first.
-if (std::as_const(aDateAcceptancePatterns)[0] == rPatterns[0])
-aDateAcceptancePatterns = comphelper::containerToSequence(rPatterns);  
  // sane
-else
-{
-// Copy existing full date pattern and append the sequence passed.
-/* TODO: could check for duplicates and shrink target sequence */
-Sequence< OUString > aTmp( rPatterns.size() + 1 );
-auto it = aTmp.getArray();
-*it = std::as_const(aDateAcceptancePatterns)[0];
-std::copy(rPatterns.begin(), rPatterns.end(), std::next(it));
-aDateAcceptancePatterns = aTmp;
-}
+// Earlier versions checked for presence of the full date pattern with
+// aDateAcceptancePatterns[0] == rPatterns[0] and prepended that if not.
+// This lead to confusion if the patterns were intentionally specified
+// without, giving entirely a different DMY order, see tdf#150288.
+// Not checking this and accepting the given patterns as is may result in
+// the user shooting themself in the foot, but we can't have both.
+aDateAcceptancePatterns = comphelper::containerToSequence(rPatterns);
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */


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

2022-08-24 Thread Caolán McNamara (via logerrit)
 drawinglayer/source/processor2d/vclprocessor2d.cxx |4 
 svx/source/styles/CommonStylePreviewRenderer.cxx   |1 +
 2 files changed, 1 insertion(+), 4 deletions(-)

New commits:
commit 87de096032b0665abebed521f2f07f0ad893de0c
Author: Caolán McNamara 
AuthorDate: Wed Aug 24 12:39:21 2022 +0100
Commit: Caolán McNamara 
CommitDate: Wed Aug 24 15:13:03 2022 +0200

cid#1510129 Logically dead code

triggered by the recent flatten, but there since:

commit 36f21914b31a28f75ec2195c266424a18408f747
Date:   Tue Oct 29 17:40:43 2013 +

Resolves: i123564 corrected some aspects when working with bitmaps...
with low color depth or small size

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

diff --git a/drawinglayer/source/processor2d/vclprocessor2d.cxx 
b/drawinglayer/source/processor2d/vclprocessor2d.cxx
index 5c4b15a906c9..a9be11911e82 100644
--- a/drawinglayer/source/processor2d/vclprocessor2d.cxx
+++ b/drawinglayer/source/processor2d/vclprocessor2d.cxx
@@ -519,10 +519,6 @@ bool VclProcessor2D::RenderFillGraphicPrimitive2DImpl(
 const sal_Int32 nBWidth(std::max(sal_Int32(1), 
basegfx::fround(aGraphicRange.getWidth(;
 const sal_Int32 nBHeight(std::max(sal_Int32(1), 
basegfx::fround(aGraphicRange.getHeight(;
 
-// only do something when bitmap fill has a size in discrete units
-if (nBWidth <= 0 || nBHeight <= 0)
-return true;
-
 // nBWidth, nBHeight is the pixel size of the needed bitmap. To not need 
to scale it
 // in vcl many times, create a size-optimized version
 const Size aNeededBitmapSizePixel(nBWidth, nBHeight);
commit c61c70e51cd6bc1721ec0d840aad28b5ed284ae7
Author: Caolán McNamara 
AuthorDate: Wed Aug 24 12:35:29 2022 +0100
Commit: Caolán McNamara 
CommitDate: Wed Aug 24 15:12:49 2022 +0200

cid#1510131 Uninitialized scalar field

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

diff --git a/svx/source/styles/CommonStylePreviewRenderer.cxx 
b/svx/source/styles/CommonStylePreviewRenderer.cxx
index 66fbb9e72603..3a78a3df22f8 100644
--- a/svx/source/styles/CommonStylePreviewRenderer.cxx
+++ b/svx/source/styles/CommonStylePreviewRenderer.cxx
@@ -53,6 +53,7 @@ CommonStylePreviewRenderer::CommonStylePreviewRenderer(
 , maFontColor(COL_AUTO)
 , maHighlightColor(COL_AUTO)
 , maBackgroundColor(COL_AUTO)
+, mnHeight(0)
 , maStyleName(mpStyle->GetName())
 {
 }


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

2022-08-24 Thread Noel Grandin (via logerrit)
 sw/source/filter/ww8/ww8glsy.cxx |   33 +++--
 sw/source/filter/ww8/ww8glsy.hxx |2 +-
 sw/source/filter/ww8/ww8par.cxx  |   18 +-
 3 files changed, 21 insertions(+), 32 deletions(-)

New commits:
commit 55c638eb0d6aeacb7b5a8b0345add9b44aa6c889
Author: Noel Grandin 
AuthorDate: Wed Aug 24 11:04:48 2022 +0200
Commit: Noel Grandin 
CommitDate: Wed Aug 24 14:29:41 2022 +0200

use SwNode instead of SwNodeIndex in HasBareGraphicEnd method

part of the process of hiding the internals of SwPosition

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

diff --git a/sw/source/filter/ww8/ww8glsy.cxx b/sw/source/filter/ww8/ww8glsy.cxx
index 8b8c92482510..2ad84960dcb1 100644
--- a/sw/source/filter/ww8/ww8glsy.cxx
+++ b/sw/source/filter/ww8/ww8glsy.cxx
@@ -56,7 +56,7 @@ WW8Glossary::WW8Glossary(tools::SvRef 
&refStrm, sal_uInt8 nVer
 }
 }
 
-bool WW8Glossary::HasBareGraphicEnd(SwDoc *pDoc,SwNodeIndex const &rIdx)
+bool WW8Glossary::HasBareGraphicEnd(SwDoc *pDoc, SwNode const &rIdx)
 {
 bool bRet=false;
 for( sal_uInt16 nCnt = pDoc->GetSpzFrameFormats()->size(); nCnt; )
@@ -70,7 +70,7 @@ bool WW8Glossary::HasBareGraphicEnd(SwDoc *pDoc,SwNodeIndex 
const &rIdx)
 if (pAPos &&
 ((RndStdIds::FLY_AT_PARA == rAnchor.GetAnchorId()) ||
  (RndStdIds::FLY_AT_CHAR == rAnchor.GetAnchorId())) &&
-rIdx == pAPos->GetNodeIndex() )
+rIdx == pAPos->GetNode() )
 {
 bRet=true;
 break;
@@ -115,29 +115,28 @@ bool WW8Glossary::MakeEntries(SwDoc *pD, SwTextBlocks 
&rBlocks,
 do {
 SwPaM aPam( aStart );
 {
-SwNodeIndex& rIdx = aPam.GetPoint()->nNode;
-++rIdx;
-pCNd = rIdx.GetNode().GetTextNode();
+SwPosition& rPos = *aPam.GetPoint();
+rPos.Adjust(SwNodeOffset(1));
+pCNd = rPos.GetNode().GetTextNode();
 if( nullptr == pCNd )
 {
-pCNd = pD->GetNodes().MakeTextNode( rIdx.GetNode(), pColl 
);
-rIdx = *pCNd;
+pCNd = pD->GetNodes().MakeTextNode( rPos.GetNode(), pColl 
);
+rPos.Assign(*pCNd);
 }
 }
-aPam.GetPoint()->nContent.Assign( pCNd, 0 );
 aPam.SetMark();
 {
-SwNodeIndex& rIdx = aPam.GetPoint()->nNode;
-rIdx = aStart.GetNode().EndOfSectionIndex() - 1;
-if(( nullptr == ( pCNd = rIdx.GetNode().GetContentNode() ) )
-|| HasBareGraphicEnd(pD,rIdx))
+SwPosition& rPos = *aPam.GetPoint();
+rPos.Assign(aStart.GetNode().EndOfSectionIndex() - 1);
+if(( nullptr == ( pCNd = rPos.GetNode().GetContentNode() ) )
+|| HasBareGraphicEnd(pD,rPos.GetNode()))
 {
-++rIdx;
-pCNd = pD->GetNodes().MakeTextNode( rIdx.GetNode(), pColl 
);
-rIdx = *pCNd;
+rPos.Adjust(SwNodeOffset(1));
+pCNd = pD->GetNodes().MakeTextNode( rPos.GetNode(), pColl 
);
+rPos.Assign(*pCNd);
 }
 }
-aPam.GetPoint()->nContent.Assign( pCNd, pCNd->Len() );
+aPam.GetPoint()->SetContent( pCNd->Len() );
 
 // now we have the right selection for one entry.  Copy this to
 // the defined TextBlock, but only if it is not an autocorrection
@@ -221,8 +220,6 @@ bool WW8Glossary::Load( SwTextBlocks &rBlocks, bool 
bSaveRelFile )
 pD->GetNodes().GoNext( &aIdx );
 }
 SwPaM aPamo( aIdx );
-
aPamo.GetPoint()->nContent.Assign(aIdx.GetNode().GetContentNode(),
-0);
 std::unique_ptr xRdr(new SwWW8ImplReader(
 m_xGlossary->m_nVersion, m_xStg.get(), m_rStrm.get(), *pD, 
rBlocks.GetBaseURL(),
 true, false, *aPamo.GetPoint()));
diff --git a/sw/source/filter/ww8/ww8glsy.hxx b/sw/source/filter/ww8/ww8glsy.hxx
index bff76efedecd..35babac1d07f 100644
--- a/sw/source/filter/ww8/ww8glsy.hxx
+++ b/sw/source/filter/ww8/ww8glsy.hxx
@@ -81,7 +81,7 @@ private:
 static bool MakeEntries(SwDoc *pD, SwTextBlocks &rBlocks, bool 
bSaveRelFile,
 const std::vector& rStrings,
 const std::vector& rExtra);
-static bool HasBareGraphicEnd(SwDoc *pD,SwNodeIndex const &rIdx);
+static bool HasBareGraphicEnd(SwDoc *pD, SwNode const &rIdx);
 
 WW8Glossary(const WW8Glossary&) = delete;
 WW8Glossary& operator=(const WW8Glossary&) = delete;
commit f067bfebf6fbdfb66d545585fea9fe6cec559038
Author: Noel 

[Libreoffice-commits] core.git: Branch 'distro/cib/libreoffice-6-4' - 52 commits - sc/qa sw/CppunitTest_sw_core_edit.mk sw/CppunitTest_sw_core_text.mk sw/inc sw/Module_sw.mk sw/qa sw/source xmloff/sou

2022-08-24 Thread Michael Stahl (via logerrit)
 sc/qa/uitest/calc_tests7/tdf150044.py  |  108 +-
 sw/CppunitTest_sw_core_edit.mk |   74 +
 sw/CppunitTest_sw_core_text.mk |2 
 sw/Module_sw.mk|1 
 sw/inc/IDocumentContentOperations.hxx  |   11 
 sw/inc/crsrsh.hxx  |   13 
 sw/inc/editsh.hxx  |4 
 sw/inc/ndarr.hxx   |8 
 sw/inc/ndtxt.hxx   |2 
 sw/inc/unobaseclass.hxx|   19 
 sw/inc/unosett.hxx |5 
 sw/inc/unotextcursor.hxx   |4 
 sw/inc/unotextrange.hxx|2 
 sw/qa/core/edit/data/redline-hidden.fodt   |   32 
 sw/qa/core/edit/edit.cxx   |   57 +
 sw/qa/core/text/text.cxx   |   51 
 sw/qa/core/uwriter.cxx |2 
 sw/qa/extras/odfexport/data/tdf137199.docx |binary
 sw/qa/extras/odfexport/odfexport.cxx   |   11 
 sw/qa/extras/uiwriter/data/tdf133982.docx  |binary
 sw/qa/extras/uiwriter/data/tdf134021.docx  |binary
 sw/qa/extras/uiwriter/data/tdf139843.odt   |binary
 sw/qa/extras/uiwriter/data/tdf148868.odt   |binary
 sw/qa/extras/uiwriter/data2/tdf135061.odt  |binary
 sw/qa/extras/uiwriter/data2/tdf136452.fodt |   80 +
 sw/qa/extras/uiwriter/data2/tdf141175.odt  |binary
 sw/qa/extras/uiwriter/data2/try2.fodt  |   66 +
 sw/qa/extras/uiwriter/uiwriter.cxx |  262 -
 sw/qa/extras/uiwriter/uiwriter2.cxx|  679 +
 sw/qa/extras/unowriter/unowriter.cxx   |   33 
 sw/qa/extras/ww8export/data/tdf138302_restartNumbering.odt |binary
 sw/qa/extras/ww8export/ww8export3.cxx  |6 
 sw/qa/inc/swmodeltestbase.hxx  |8 
 sw/qa/uitest/data/tdf39721.fodt|   42 
 sw/qa/uitest/writer_tests7/tdf145093.py|   34 
 sw/source/core/crsr/crbm.cxx   |   15 
 sw/source/core/crsr/crsrsh.cxx |9 
 sw/source/core/crsr/crstrvl.cxx|   41 
 sw/source/core/doc/DocumentContentOperationsManager.cxx|  110 +-
 sw/source/core/doc/DocumentRedlineManager.cxx  |6 
 sw/source/core/doc/docedt.cxx  |   11 
 sw/source/core/doc/docnew.cxx  |   27 
 sw/source/core/docnode/ndsect.cxx  |2 
 sw/source/core/docnode/ndtbl.cxx   |2 
 sw/source/core/docnode/node.cxx|6 
 sw/source/core/docnode/nodes.cxx   |  182 ++-
 sw/source/core/edit/acorrect.cxx   |5 
 sw/source/core/edit/autofmt.cxx|   29 
 sw/source/core/edit/edatmisc.cxx   |2 
 sw/source/core/edit/eddel.cxx  |9 
 sw/source/core/edit/edglbldc.cxx   |2 
 sw/source/core/edit/editsh.cxx |4 
 sw/source/core/edit/edlingu.cxx|   19 
 sw/source/core/edit/edws.cxx   |6 
 sw/source/core/fields/reffld.cxx   |4 
 sw/source/core/frmedt/fecopy.cxx   |2 
 sw/source/core/inc/DocumentContentOperationsManager.hxx|9 
 sw/source/core/inc/UndoDelete.hxx  |3 
 sw/source/core/inc/UndoRedline.hxx |8 
 sw/source/core/inc/mvsave.hxx  |5 
 sw/source/core/inc/rootfrm.hxx |2 
 sw/source/core/layout/atrfrm.cxx   |2 
 sw/source/core/layout/frmtool.cxx  |   13 
 sw/source/core/layout/tabfrm.cxx   |7 
 sw/source/core/text/frmform.cxx|   18 
 sw/source/core/text/txtfrm.cxx |1 
 sw/source/core/txtnode/ndtxt.cxx   |   70 -
 sw/source/core/undo/undel.cxx  |   27 
 sw/source/core/undo/undobj.cxx |   19 
 sw/source/core/undo/unins.cxx  |7 
 sw/source/core/undo/unredln.cxx|   38 
 sw/source/core/undo/untbl.cxx  |   14 
 sw/source/core/undo/untblk.cxx |2 
 sw/s

[Libreoffice-commits] core.git: Branch 'distro/lhm/libreoffice-6-4+backports' - sw/inc sw/source

2022-08-24 Thread Michael Stahl (via logerrit)
 sw/inc/crsrsh.hxx |2 ++
 sw/source/core/crsr/crsrsh.cxx|9 -
 sw/source/uibase/docvw/edtwin.cxx |7 ++-
 sw/source/uibase/inc/wrtsh.hxx|1 +
 sw/source/uibase/wrtsh/wrtsh1.cxx |   11 ++-
 5 files changed, 27 insertions(+), 3 deletions(-)

New commits:
commit 12f6f48303348c5bfda6ef03c5aedeffeeb4
Author: Michael Stahl 
AuthorDate: Mon Aug 8 16:15:36 2022 +0200
Commit: Michael Stahl 
CommitDate: Wed Aug 24 13:45:48 2022 +0200

sw: fix infinite recursion in SwEditWin::GetSurroundingTextSelection()

The unexpected problem of calling SwCursorShell::Pop() from there ending
up calling the function itself again, with gtk3 UI, on loading
forum-mso-en-4034.docx and clicking somewhere or scrolling:

466 SwEditWin::GetSurroundingTextSelection() const at 
sw/source/uibase/docvw/edtwin.cxx:6656
467 ImplHandleSurroundingTextRequest(vcl::Window*, rtl::OUString&, 
Selection&) at vcl/source/window/winproc.cxx:2487
468 ImplHandleSalSurroundingTextRequest(vcl::Window*, 
SalSurroundingTextRequestEvent*) at vcl/source/window/winproc.cxx:2497
469 ImplWindowFrameProc(vcl::Window*, SalEvent, void const*) at 
vcl/source/window/winproc.cxx:2826
470 SalFrame::CallCallback(SalEvent, void const*) const at 
vcl/inc/salframe.hxx:306
471 GtkSalFrame::IMHandler::signalIMRetrieveSurrounding(_GtkIMContext*, 
void*) at vcl/unx/gtk3/gtkframe.cxx:5707
472 _gtk_marshal_BOOLEAN__VOIDv () at /lib64/libgtk-3.so.0
473 g_signal_emit_valist () at /lib64/libgobject-2.0.so.0
474 g_signal_emit_by_name () at /lib64/libgobject-2.0.so.0
475 gtk_im_multicontext_retrieve_surrounding_cb () at /lib64/libgtk-3.so.0
476 _gtk_marshal_BOOLEAN__VOIDv () at /lib64/libgtk-3.so.0
477 g_signal_emit_valist () at /lib64/libgobject-2.0.so.0
478 g_signal_emit_by_name () at /lib64/libgobject-2.0.so.0
479 enable () at /lib64/libgtk-3.so.0
480 GtkSalFrame::IMHandler::createIMContext() at 
vcl/unx/gtk3/gtkframe.cxx:5187
481 GtkSalFrame::IMHandler::IMHandler(GtkSalFrame*) at 
vcl/unx/gtk3/gtkframe.cxx:5153
482 GtkSalFrame::SetInputContext(SalInputContext*) at 
vcl/unx/gtk3/gtkframe.cxx:2711
483 vcl::Window::ImplNewInputContext() () at 
vcl/source/window/window.cxx:1781
484 vcl::Window::SetInputContext(InputContext const&) at 
vcl/source/window/window.cxx:2083
485 SwView::CheckReadonlySelection() at sw/source/uibase/uiview/view.cxx:699
486 SwView::AttrChangedNotify(LinkParamNone*) at 
sw/source/uibase/uiview/view.cxx:510
487 SwView::LinkStubAttrChangedNotify(void*, LinkParamNone*) at 
sw/source/uibase/uiview/view.cxx:499
488 Link::Call(LinkParamNone*) const at 
include/tools/link.hxx:111
489 SwCursorShell::CallChgLnk() at sw/source/core/crsr/crsrsh.cxx:2544
490 SwCallLink::~SwCallLink() at sw/source/core/crsr/callnk.cxx:149
491 SwCursorShell::Pop(SwCursorShell::PopMode) at 
sw/source/core/crsr/crsrsh.cxx:2327
492 SwWrtShell::Pop(SwCursorShell::PopMode) at 
sw/source/uibase/wrtsh/wrtsh1.cxx:2016
493 SwEditWin::GetSurroundingTextSelection() const at 
sw/source/uibase/docvw/edtwin.cxx:6656

This SwCallLink looks unnecessary here, but it's triggered because it
compares the state before Pop() to the state after Pop(), instead of the
state before Push() to the state after Pop().

This problem could probably benefit from being solved more generally,
but with 2 functions involved it gets rather ugly as it can't easily be
encapsulated in SwCursorShell.

(probably regression from aac9bd235e65b27faf63e64bba3ecd94837381d6)

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137987
Tested-by: Jenkins
Reviewed-by: Michael Stahl 
(cherry picked from commit 581ba395222e04e43697484bef9181c877d1fd61)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138027
Reviewed-by: Thorsten Behrens 
(cherry picked from commit d7a427d9c869729c21285df7c32106f934f66a04)

Change-Id: Ief176b54daf96da378d2e5d57f3dd5b4a0817299
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138737
Tested-by: Michael Stahl 
Reviewed-by: Michael Stahl 

diff --git a/sw/inc/crsrsh.hxx b/sw/inc/crsrsh.hxx
index 2fa79345b240..b6173fdee6f0 100644
--- a/sw/inc/crsrsh.hxx
+++ b/sw/inc/crsrsh.hxx
@@ -45,6 +45,7 @@
 
 class SfxItemSet;
 class SfxPoolItem;
+class SwCallLink;
 class SwContentFrame;
 class SwUnoCursor;
 class SwFormatField;
@@ -437,6 +438,7 @@ public:
  *  stack
  *  @return  if there was one on the stack,  otherwise
  */
+bool Pop(PopMode, ::std::unique_ptr pLink);
 bool Pop(PopMode);
 /*
  * Combine 2 Cursors.
diff --git a/sw/source/core/crsr/crsrsh.cxx b/sw/source/core/crsr/crsrsh.cxx
index 0d8d273f34be..bf3f1718e67c 100644
--- a/sw/source/core/crsr/crsrsh.cxx
+++ b/sw/source/core/crsr/crsrsh.cxx
@@ -2244,7 +2244,14 @@ void SwCursorShell::Push()
 */
 bool SwCursorShell::Pop(PopMode const eDelet

New Defects reported by Coverity Scan for LibreOffice

2022-08-24 Thread scan-admin
Hi,

Please find the latest report on new defect(s) introduced to LibreOffice found 
with Coverity Scan.

4 new defect(s) introduced to LibreOffice found with Coverity Scan.
11 defect(s), reported by Coverity Scan earlier, were marked fixed in the 
recent build analyzed by Coverity Scan.

New defect(s) Reported-by: Coverity Scan
Showing 4 of 4 defect(s)


** CID 1510132:(UNINIT)



*** CID 1510132:(UNINIT)
/svx/source/tbxctrls/tbcontrl.cxx: 1303 in 
::SvxStyleBox_Base::UserDrawEntry(OutputDevice &, const 
tools::Rectangle &, const tools::Rectangle &, const rtl::OUString &, const 
std::vector<::ScriptInfo, std::allocator<::ScriptInfo>> &)()
1297 nStart = nEnd;
1298 nEnd = rScriptChanges[nIdx].changePos;
1299 nScript = rScriptChanges[nIdx].scriptType;
1300 }
1301 else
1302 break;
>>> CID 1510132:(UNINIT)
>>> Using uninitialized value "oFont._M_payload._M_payload" when calling 
>>> "~optional".
1303 }
1304 while(true);
1305 }
1306 
1307 static bool GetWhich(const SfxItemSet& rSet, sal_uInt16 nSlot, 
sal_uInt16& rWhich)
1308 {
/svx/source/tbxctrls/tbcontrl.cxx: 1302 in 
::SvxStyleBox_Base::UserDrawEntry(OutputDevice &, const 
tools::Rectangle &, const tools::Rectangle &, const rtl::OUString &, const 
std::vector<::ScriptInfo, std::allocator<::ScriptInfo>> &)()
1296 {
1297 nStart = nEnd;
1298 nEnd = rScriptChanges[nIdx].changePos;
1299 nScript = rScriptChanges[nIdx].scriptType;
1300 }
1301 else
>>> CID 1510132:(UNINIT)
>>> Using uninitialized value "oFont._M_payload._M_payload" when calling 
>>> "~optional".
1302 break;
1303 }
1304 while(true);
1305 }
1306 
1307 static bool GetWhich(const SfxItemSet& rSet, sal_uInt16 nSlot, 
sal_uInt16& rWhich)

** CID 1510131:  Uninitialized members  (UNINIT_CTOR)
/svx/source/styles/CommonStylePreviewRenderer.cxx: 58 in 
svx::CommonStylePreviewRenderer::CommonStylePreviewRenderer(const 
SfxObjectShell &, OutputDevice &, SfxStyleSheetBase *, long)()



*** CID 1510131:  Uninitialized members  (UNINIT_CTOR)
/svx/source/styles/CommonStylePreviewRenderer.cxx: 58 in 
svx::CommonStylePreviewRenderer::CommonStylePreviewRenderer(const 
SfxObjectShell &, OutputDevice &, SfxStyleSheetBase *, long)()
52 : StylePreviewRenderer(rShell, rOutputDev, pStyle, nMaxHeight)
53 , maFontColor(COL_AUTO)
54 , maHighlightColor(COL_AUTO)
55 , maBackgroundColor(COL_AUTO)
56 , maStyleName(mpStyle->GetName())
57 {
>>> CID 1510131:  Uninitialized members  (UNINIT_CTOR)
>>> Non-static class member "mnHeight" is not initialized in this 
>>> constructor nor in any functions that it calls.
58 }
59 
60 CommonStylePreviewRenderer::~CommonStylePreviewRenderer()
61 {}
62 
63 static bool GetWhich(const SfxItemSet& rSet, sal_uInt16 nSlot, 
sal_uInt16& rWhich)

** CID 1510130:(UNINIT)



*** CID 1510130:(UNINIT)
/svx/source/styles/CommonStylePreviewRenderer.cxx: 393 in 
svx::CommonStylePreviewRenderer::render(const tools::Rectangle &, 
sfx2::StylePreviewRenderer::RenderAlign)()
387 nStart = nEnd;
388 nEnd = maScriptChanges[nIdx].changePos;
389 nScript = maScriptChanges[nIdx].scriptType;
390 }
391 else
392 break;
>>> CID 1510130:(UNINIT)
>>> Using uninitialized value "oFont._M_payload._M_payload" when calling 
>>> "~optional".
393 }
394 while(true);
395 
396 mrOutputDev.Pop();
397 
398 return true;
/svx/source/styles/CommonStylePreviewRenderer.cxx: 392 in 
svx::CommonStylePreviewRenderer::render(const tools::Rectangle &, 
sfx2::StylePreviewRenderer::RenderAlign)()
386 {
387 nStart = nEnd;
388 nEnd = maScriptChanges[nIdx].changePos;
389 nScript = maScriptChanges[nIdx].scriptType;
390 }
391 else
>>> CID 1510130:(UNINIT)
>>> Using uninitialized value "oFont._M_payload._M_payload" when calling 
>>> "~optional".
392 break;
393 }
394 while(true);
395 
396 mrOutputDev.Pop();
397 

** CID 1510129:  Control flow issues  (DEADCODE)
/drawinglayer/source/processor2d/vclprocessor2d.cxx: 524 in 
drawinglayer::processor2d::VclProcessor2D::RenderFillGraphicPrimitive2DImpl(const
 drawinglayer::primitive2d::FillGraphicPrimitive2D &)()


__

[Libreoffice-commits] core.git: Branch 'libreoffice-7-4' - translations

2022-08-24 Thread Christian Lohmaier (via logerrit)
 translations |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit b7ebcf15704fe8b6d4c64d8ad13e66797007eaa2
Author: Christian Lohmaier 
AuthorDate: Wed Aug 24 13:09:49 2022 +0200
Commit: Gerrit Code Review 
CommitDate: Wed Aug 24 13:09:49 2022 +0200

Update git submodules

* Update translations from branch 'libreoffice-7-4'
  to dd84244a0ff314c710e71f609bd32f2afa483d95
  - update tranlsations for 7.4.1 rc1/master

and force-fix errors using pocheck

Change-Id: I3c03169b1a7d7ee775b8dbefca7eee140611ea8f
(cherry picked from commit eb38107f17dbae1029eca4e4449128fbc2b9adf4)

diff --git a/translations b/translations
index 767b3a0d2b0d..dd84244a0ff3 16
--- a/translations
+++ b/translations
@@ -1 +1 @@
-Subproject commit 767b3a0d2b0d3a888c200fdb1ad2da2cdc84d9bb
+Subproject commit dd84244a0ff314c710e71f609bd32f2afa483d95


[Libreoffice-commits] translations.git: Branch 'libreoffice-7-4' - source/ab source/af source/am source/an source/ar source/as source/ast source/az source/be source/bg source/bn source/bn-IN source/bo

2022-08-24 Thread Christian Lohmaier (via logerrit)
 source/ab/sfx2/messages.po|   16 
 source/ab/vcl/messages.po |  132 ++--
 source/af/sfx2/messages.po|   16 
 source/af/vcl/messages.po |  132 ++--
 source/am/sfx2/messages.po|   16 
 source/am/vcl/messages.po |  132 ++--
 source/an/sfx2/messages.po|   18 
 source/an/vcl/messages.po |  134 ++--
 source/ar/sfx2/messages.po|   16 
 source/ar/vcl/messages.po |  134 ++--
 source/as/sfx2/messages.po|   16 
 source/as/vcl/messages.po |  132 ++--
 source/ast/sfx2/messages.po   |   18 
 source/ast/vcl/messages.po|  134 ++--
 source/az/sfx2/messages.po|   16 
 source/az/vcl/messages.po |  132 ++--
 source/be/sfx2/messages.po|   16 
 source/be/vcl/messages.po |  132 ++--
 source/bg/sfx2/messages.po|   18 
 source/bg/vcl/messages.po |  132 ++--
 source/bn-IN/sfx2/messages.po |   16 
 source/bn-IN/vcl/messages.po  |  132 ++--
 source/bn/sfx2/messages.po|   16 
 source/bn/vcl/messages.po |  132 ++--
 source/bo/sfx2/messages.po|   16 
 source/bo/vcl/messages.po |  132 ++--
 source/br/sfx2/messages.po|   16 
 source/br/vcl/messages.po |  132 ++--
 source/brx/sfx2/messages.po   |   16 
 source/brx/vcl/messages.po|  132 ++--
 source/bs/sfx2/messages.po|   16 
 source/bs/vcl/messages.po |  132 ++--
 source/ca-valencia/sfx2/messages.po   |   16 
 source/ca-valencia/vcl/messages.po|  132 ++--
 source/ca/sfx2/messages.po|   18 
 source/ca/vcl/messages.po |  134 ++--
 source/ckb/sfx2/messages.po   |   16 
 source/ckb/vcl/messages.po|  132 ++--
 source/cs/helpcontent2/source/text/shared/00.po   |4 
 source/cs/sfx2/messages.po|   18 
 source/cs/vcl/messages.po |  132 ++--
 source/cy/sfx2/messages.po|   18 
 source/cy/vcl/messages.po |  132 ++--
 source/da/sfx2/messages.po|   16 
 source/da/vcl/messages.po |  132 ++--
 source/de/sfx2/messages.po|   18 
 source/de/vcl/messages.po |  134 ++--
 source/dgo/sfx2/messages.po   |   16 
 source/dgo/vcl/messages.po|  132 ++--
 source/dsb/sfx2/messages.po   |   18 
 source/dsb/vcl/messages.po|  134 ++--
 source/dz/sfx2/messages.po|   16 
 source/dz/vcl/messages.po |  132 ++--
 source/el/sfx2/messages.po|   18 
 source/el/vcl/messages.po |  132 ++--
 source/en-GB/sfx2/messages.po |   18 
 source/en-GB/vcl/messages.po  |  132 ++--
 source/en-ZA/sfx2/messages.po |   16 
 source/en-ZA/vcl/messages.po  |  132 ++--
 source/eo/sfx2/messages.po|   18 
 source/eo/vcl/messages.po |  132 ++--
 source/es/helpcontent2/source/text/sbasic/shared/03.po|   22 
 source/es/helpcontent2/source/text/sdatabase.po   |   40 -
 source/es/helpcontent2/source/text/simpress/guide.po  |4 
 source/es/helpcontent2/source/text/swriter/01.po  |4 
 source/es/officecfg/registry/data/org/openoffice/Office/UI.po |6 
 source/es/sd/messages.po  |6 
 source/es/sfx2/messages.po|   18 
 source/es/sw/messages.po 

[Libreoffice-commits] core.git: translations

2022-08-24 Thread Christian Lohmaier (via logerrit)
 translations |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit a310d3f4669650b9b33eb81c1e9f7e9be679b1e2
Author: Christian Lohmaier 
AuthorDate: Wed Aug 24 13:05:44 2022 +0200
Commit: Gerrit Code Review 
CommitDate: Wed Aug 24 13:05:44 2022 +0200

Update git submodules

* Update translations from branch 'master'
  to eb38107f17dbae1029eca4e4449128fbc2b9adf4
  - update tranlsations for 7.4.1 rc1/master

and force-fix errors using pocheck

Change-Id: I3c03169b1a7d7ee775b8dbefca7eee140611ea8f

diff --git a/translations b/translations
index f69bba3fa11f..eb38107f17db 16
--- a/translations
+++ b/translations
@@ -1 +1 @@
-Subproject commit f69bba3fa11f5345ec32bea471dbdfbbad3134a3
+Subproject commit eb38107f17dbae1029eca4e4449128fbc2b9adf4


[Libreoffice-commits] translations.git: source/ab source/af source/am source/an source/ar source/as source/ast source/az source/be source/bg source/bn source/bn-IN source/bo source/br source/brx sourc

2022-08-24 Thread Christian Lohmaier (via logerrit)
 source/ab/sfx2/messages.po|   16 
 source/ab/vcl/messages.po |  132 ++--
 source/af/sfx2/messages.po|   16 
 source/af/vcl/messages.po |  132 ++--
 source/am/sfx2/messages.po|   16 
 source/am/vcl/messages.po |  132 ++--
 source/an/sfx2/messages.po|   18 
 source/an/vcl/messages.po |  134 ++--
 source/ar/sfx2/messages.po|   16 
 source/ar/vcl/messages.po |  134 ++--
 source/as/sfx2/messages.po|   16 
 source/as/vcl/messages.po |  132 ++--
 source/ast/sfx2/messages.po   |   18 
 source/ast/vcl/messages.po|  134 ++--
 source/az/sfx2/messages.po|   16 
 source/az/vcl/messages.po |  132 ++--
 source/be/sfx2/messages.po|   16 
 source/be/vcl/messages.po |  132 ++--
 source/bg/sfx2/messages.po|   18 
 source/bg/vcl/messages.po |  132 ++--
 source/bn-IN/sfx2/messages.po |   16 
 source/bn-IN/vcl/messages.po  |  132 ++--
 source/bn/sfx2/messages.po|   16 
 source/bn/vcl/messages.po |  132 ++--
 source/bo/sfx2/messages.po|   16 
 source/bo/vcl/messages.po |  132 ++--
 source/br/sfx2/messages.po|   16 
 source/br/vcl/messages.po |  132 ++--
 source/brx/sfx2/messages.po   |   16 
 source/brx/vcl/messages.po|  132 ++--
 source/bs/sfx2/messages.po|   16 
 source/bs/vcl/messages.po |  132 ++--
 source/ca-valencia/sfx2/messages.po   |   16 
 source/ca-valencia/vcl/messages.po|  132 ++--
 source/ca/sfx2/messages.po|   18 
 source/ca/vcl/messages.po |  134 ++--
 source/ckb/sfx2/messages.po   |   16 
 source/ckb/vcl/messages.po|  132 ++--
 source/cs/helpcontent2/source/text/shared/00.po   |4 
 source/cs/sfx2/messages.po|   18 
 source/cs/vcl/messages.po |  132 ++--
 source/cy/sfx2/messages.po|   18 
 source/cy/vcl/messages.po |  132 ++--
 source/da/sfx2/messages.po|   16 
 source/da/vcl/messages.po |  132 ++--
 source/de/sfx2/messages.po|   18 
 source/de/vcl/messages.po |  134 ++--
 source/dgo/sfx2/messages.po   |   16 
 source/dgo/vcl/messages.po|  132 ++--
 source/dsb/sfx2/messages.po   |   18 
 source/dsb/vcl/messages.po|  134 ++--
 source/dz/sfx2/messages.po|   16 
 source/dz/vcl/messages.po |  132 ++--
 source/el/sfx2/messages.po|   18 
 source/el/vcl/messages.po |  132 ++--
 source/en-GB/sfx2/messages.po |   18 
 source/en-GB/vcl/messages.po  |  132 ++--
 source/en-ZA/sfx2/messages.po |   16 
 source/en-ZA/vcl/messages.po  |  132 ++--
 source/eo/sfx2/messages.po|   18 
 source/eo/vcl/messages.po |  132 ++--
 source/es/helpcontent2/source/text/sbasic/shared/03.po|   22 
 source/es/helpcontent2/source/text/sdatabase.po   |   40 -
 source/es/helpcontent2/source/text/simpress/guide.po  |4 
 source/es/helpcontent2/source/text/swriter/01.po  |4 
 source/es/officecfg/registry/data/org/openoffice/Office/UI.po |6 
 source/es/sd/messages.po  |6 
 source/es/sfx2/messages.po|   18 
 source/es/sw/messages.po 

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

2022-08-24 Thread Noel Grandin (via logerrit)
 sw/source/core/bastyp/index.cxx  |2 +-
 sw/source/filter/ww8/ww8par.cxx  |2 +-
 sw/source/filter/ww8/ww8par2.cxx |6 +++---
 sw/source/filter/ww8/ww8par5.cxx |6 +++---
 4 files changed, 8 insertions(+), 8 deletions(-)

New commits:
commit 2476104c9168969b4970bd613a11078fec699435
Author: Noel Grandin 
AuthorDate: Wed Aug 24 11:37:40 2022 +0200
Commit: Noel Grandin 
CommitDate: Wed Aug 24 12:51:08 2022 +0200

fix ubsan signed integer overflow

after
commit 6b544507b01d479b991d3ba7c949cb70696a3f2e
Author: Noel Grandin 
Date:   Tue Aug 23 11:42:38 2022 +0200
Use more SwPosition::Adjust

ubsan started to complain because the SAL_WARN_IF here assumes that nVal
is >= 0. Make it work if nVal is < 0.

/sw/source/core/bastyp/index.cxx:332:5: runtime error: signed integer
overflow: 2147483647 - -1 cannot be represented in type 'int'
/sw/source/core/bastyp/index.cxx:332:5
/sw/source/core/crsr/pam.cxx:257:14
SwPaM*) /sw/source/uibase/wrtsh/wrtsh2.cxx:129:52
/sw/source/uibase/fldui/fldmgr.cxx:1490:39
SfxRequest const&) /sw/source/uibase/wrtsh/wrtsh1.cxx:2284:19

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

diff --git a/sw/source/core/bastyp/index.cxx b/sw/source/core/bastyp/index.cxx
index f7868e8901e0..c7ded156ea26 100644
--- a/sw/source/core/bastyp/index.cxx
+++ b/sw/source/core/bastyp/index.cxx
@@ -329,7 +329,7 @@ sal_Int32 SwContentIndex::operator--()
 
 sal_Int32 SwContentIndex::operator+=( sal_Int32 const nVal )
 {
-SAL_WARN_IF( !(m_nIndex <= SAL_MAX_INT32 - nVal), "sw.core",
+SAL_WARN_IF( !(nVal > 0 ? m_nIndex <= SAL_MAX_INT32 - nVal : m_nIndex >= 
nVal), "sw.core",
  "SwContentIndex SwContentIndex::operator+=(sal_Int32) wraps 
around" );
 return ChgValue( *this, m_nIndex + nVal ).m_nIndex;
 }
commit 47d51286103dc6fa2c4ddfa871bde4878aef17ef
Author: Noel Grandin 
AuthorDate: Wed Aug 24 09:56:51 2022 +0200
Commit: Noel Grandin 
CommitDate: Wed Aug 24 12:50:57 2022 +0200

Use more SwPosition::Adjust

to keep the internal fields of SwPosition in sync.

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

diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index 078d2aae5ddc..e18ab2e655c7 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -6720,7 +6720,7 @@ bool SwWW8ImplReader::InEqualApo(int nLvl) const
 namespace sw::hack
 {
 Position::Position(const SwPosition &rPos)
-: maPtNode(rPos.nNode), mnPtContent(rPos.GetContentIndex())
+: maPtNode(rPos.GetNode()), mnPtContent(rPos.GetContentIndex())
 {
 }
 
diff --git a/sw/source/filter/ww8/ww8par2.cxx b/sw/source/filter/ww8/ww8par2.cxx
index 9b6cdfe6c754..08b7e8017a46 100644
--- a/sw/source/filter/ww8/ww8par2.cxx
+++ b/sw/source/filter/ww8/ww8par2.cxx
@@ -2366,7 +2366,7 @@ void wwSectionManager::PrependedInlineNode(const 
SwPosition &rPos,
 {
 OSL_ENSURE(!maSegments.empty(),
 "should not be possible, must be at least one segment");
-if ((!maSegments.empty()) && (maSegments.back().maStart == rPos.nNode))
+if ((!maSegments.empty()) && (maSegments.back().maStart == rPos.GetNode()))
 maSegments.back().maStart.Assign(rNode);
 }
 
@@ -2649,13 +2649,13 @@ void WW8TabDesc::MergeCells()
 if( rCell.bVertMerge && !rCell.bVertRestart )
 {
 SwPaM aPam( *m_pTabBox->GetSttNd(), 0 );
-aPam.GetPoint()->nNode++;
+aPam.GetPoint()->Adjust(SwNodeOffset(1));
 SwTextNode* pNd = aPam.GetPointNode().GetTextNode();
 while( pNd )
 {
 pNd->SetCountedInList( false );
 
-aPam.GetPoint()->nNode++;
+aPam.GetPoint()->Adjust(SwNodeOffset(1));
 pNd = aPam.GetPointNode().GetTextNode();
 }
 }
diff --git a/sw/source/filter/ww8/ww8par5.cxx b/sw/source/filter/ww8/ww8par5.cxx
index 12b940b96a9d..f137dfec72a4 100644
--- a/sw/source/filter/ww8/ww8par5.cxx
+++ b/sw/source/filter/ww8/ww8par5.cxx
@@ -529,7 +529,7 @@ sal_uInt16 SwWW8ImplReader::End_Field()
 case ww::eFORMTEXT:
 if (bUseEnhFields && m_pPaM!=nullptr && m_pPaM->GetPoint()!=nullptr) {
 SwPosition aEndPos = *m_pPaM->GetPoint();
-SwPaM aFieldPam( m_aFieldStack.back().GetPtNode(), 
m_aFieldStack.back().GetPtContent(), aEndPos.nNode, aEndPos.GetContentIndex());
+SwPaM aFieldPam( m_aFieldStack.back().GetPtNode().GetNode(), 
m_

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

2022-08-24 Thread Noel Grandin (via logerrit)
 sw/source/filter/ww8/ww8par.hxx  |2 +-
 sw/source/filter/ww8/ww8par5.cxx |6 +++---
 2 files changed, 4 insertions(+), 4 deletions(-)

New commits:
commit be9644c5b6aeecdb363d4fc9ba4a113c6280ae80
Author: Noel Grandin 
AuthorDate: Wed Aug 24 09:47:53 2022 +0200
Commit: Noel Grandin 
CommitDate: Wed Aug 24 11:38:27 2022 +0200

use SwNode instead of SwNodeIndex in WillHavePageDescHere method

part of the process of hiding the internals of SwPosition

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

diff --git a/sw/source/filter/ww8/ww8par.hxx b/sw/source/filter/ww8/ww8par.hxx
index 5b9d40230699..e40d0e8d6b33 100644
--- a/sw/source/filter/ww8/ww8par.hxx
+++ b/sw/source/filter/ww8/ww8par.hxx
@@ -880,7 +880,7 @@ public:
 bool CurrentSectionIsProtected() const;
 void PrependedInlineNode(const SwPosition &rPos, const SwNode &rNode);
 sal_uInt16 CurrentSectionColCount() const;
-bool WillHavePageDescHere(const SwNodeIndex& rIdx) const;
+bool WillHavePageDescHere(const SwNode&) const;
 void CreateSep(const tools::Long nTextPos);
 void InsertSegments();
 void JoinNode(const SwPosition &rPos, const SwNode &rNode);
diff --git a/sw/source/filter/ww8/ww8par5.cxx b/sw/source/filter/ww8/ww8par5.cxx
index bd17737753ef..12b940b96a9d 100644
--- a/sw/source/filter/ww8/ww8par5.cxx
+++ b/sw/source/filter/ww8/ww8par5.cxx
@@ -2970,13 +2970,13 @@ sal_uInt16 wwSectionManager::CurrentSectionColCount() 
const
 
 //Will there be a new pagebreak at this position (don't know what type
 //until later)
-bool wwSectionManager::WillHavePageDescHere(const SwNodeIndex& rIdx) const
+bool wwSectionManager::WillHavePageDescHere(const SwNode& rNd) const
 {
 bool bRet = false;
 if (!maSegments.empty())
 {
 if (!maSegments.back().IsContinuous() &&
-maSegments.back().maStart == rIdx)
+maSegments.back().maStart == rNd)
 {
 bRet = true;
 }
@@ -3469,7 +3469,7 @@ eF_ResT SwWW8ImplReader::Read_F_Tox( WW8FieldDesc* pF, 
OUString& rStr )
 
 //Will there be a new pagebreak at this position (don't know what type
 //until later)
-if (m_aSectionManager.WillHavePageDescHere(pPos->nNode))
+if (m_aSectionManager.WillHavePageDescHere(pPos->GetNode()))
 aFltTOX.SetHadPageDescItem(true);
 
 // Set start in stack


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

2022-08-24 Thread Caolán McNamara (via logerrit)
 include/vcl/outdev.hxx |   18 +++---
 vcl/source/outdev/font.cxx |2 +-
 vcl/source/outdev/map.cxx  |   43 ++-
 vcl/source/outdev/text.cxx |4 ++--
 4 files changed, 28 insertions(+), 39 deletions(-)

New commits:
commit 573d6a12a450949246516c8d69e173c8c7680fc2
Author: Caolán McNamara 
AuthorDate: Tue Aug 23 21:39:44 2022 +0100
Commit: Caolán McNamara 
CommitDate: Wed Aug 24 11:25:29 2022 +0200

rename DeviceFontWidth/DeviceFontHeight to DeviceSubPixel

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

diff --git a/include/vcl/outdev.hxx b/include/vcl/outdev.hxx
index 82b3180d212f..3f00d9dcde12 100644
--- a/include/vcl/outdev.hxx
+++ b/include/vcl/outdev.hxx
@@ -1692,7 +1692,7 @@ public:
  @returns Physical point on the device.
  */
 SAL_DLLPRIVATE PointImplLogicToDevicePixel( const Point& rLogicPt 
) const;
-SAL_DLLPRIVATE DevicePoint  ImplLogicToDeviceFontCoordinate(const Point& 
rLogicPt) const;
+SAL_DLLPRIVATE DevicePoint  ImplLogicToDeviceSubPixel(const Point& 
rLogicPt) const;
 
 /** Convert a logical width to a width in units of device pixels.
 
@@ -1705,7 +1705,7 @@ public:
  @returns Width in units of device pixels.
  */
 SAL_DLLPRIVATE tools::Long ImplLogicWidthToDevicePixel( 
tools::Long nWidth ) const;
-SAL_DLLPRIVATE double  
ImplLogicWidthToDeviceFontWidth(tools::Long nWidth) const;
+SAL_DLLPRIVATE double  
ImplLogicWidthToDeviceSubPixel(tools::Long nWidth) const;
 
 /** Convert a logical height to a height in units of device pixels.
 
@@ -1718,7 +1718,7 @@ public:
  @returns Height in units of device pixels.
  */
 SAL_DLLPRIVATE tools::Long ImplLogicHeightToDevicePixel( 
tools::Long nHeight ) const;
-SAL_DLLPRIVATE double  
ImplLogicHeightToDeviceFontHeight(tools::Long nHeight) const;
+SAL_DLLPRIVATE double  
ImplLogicHeightToDeviceSubPixel(tools::Long nHeight) const;
 
 /** Convert device pixels to a width in logical units.
 
diff --git a/vcl/source/outdev/font.cxx b/vcl/source/outdev/font.cxx
index e8887169497e..e24d6ac014db 100644
--- a/vcl/source/outdev/font.cxx
+++ b/vcl/source/outdev/font.cxx
@@ -864,7 +864,7 @@ bool OutputDevice::ImplNewFont() const
 
 // convert to pixel height
 // TODO: replace integer based aSize completely with subpixel accurate type
-float fExactHeight = 
ImplLogicHeightToDeviceFontHeight(maFont.GetFontHeight());
+float fExactHeight = 
ImplLogicHeightToDeviceSubPixel(maFont.GetFontHeight());
 Size aSize = ImplLogicToDevicePixel( maFont.GetFontSize() );
 if ( !aSize.Height() )
 {
diff --git a/vcl/source/outdev/map.cxx b/vcl/source/outdev/map.cxx
index b6269916ad33..c184b255af2b 100644
--- a/vcl/source/outdev/map.cxx
+++ b/vcl/source/outdev/map.cxx
@@ -270,12 +270,12 @@ static tools::Long ImplLogicToPixel(tools::Long n, 
tools::Long nDPI, tools::Long
 return n;
 }
 
-static double ImplLogicToPixel(double n, tools::Long nDPI, tools::Long nMapNum,
+static double ImplLogicToSubPixel(tools::Long n, tools::Long nDPI, tools::Long 
nMapNum,
  tools::Long nMapDenom)
 {
 assert(nDPI > 0);
 assert(nMapDenom != 0);
-return n * nMapNum * nDPI / nMapDenom;
+return static_cast(n) * nMapNum * nDPI / nMapDenom;
 }
 
 static tools::Long ImplPixelToLogic(tools::Long n, tools::Long nDPI, 
tools::Long nMapNum,
@@ -1871,41 +1871,41 @@ DeviceCoordinate 
OutputDevice::LogicWidthToDeviceCoordinate( tools::Long nWidth
 return static_cast(nWidth);
 
 #if VCL_FLOAT_DEVICE_PIXEL
-return ImplLogicToPixel(static_cast(nWidth), mnDPIX, 
maMapRes.mnMapScNumX, maMapRes.mnMapScDenomX);
+return ImplLogicToSubPixel(nWidth, mnDPIX, maMapRes.mnMapScNumX, 
maMapRes.mnMapScDenomX);
 #else
 return ImplLogicToPixel(nWidth, mnDPIX, maMapRes.mnMapScNumX, 
maMapRes.mnMapScDenomX);
 #endif
 }
 
-double OutputDevice::ImplLogicWidthToDeviceFontWidth(tools::Long nWidth) const
+double OutputDevice::ImplLogicWidthToDeviceSubPixel(tools::Long nWidth) const
 {
 if (!mbMap)
 return nWidth;
 
-return ImplLogicToPixel(static_cast(nWidth), mnDPIX,
-maMapRes.mnMapScNumX, maMapRes.mnMapScDenomX);
+return ImplLogicToSubPixel(nWidth, mnDPIX,
+   maMapRes.mnMapScNumX, maMapRes.mnMapScDenomX);
 }
 
-double OutputDevice::ImplLogicHeightToDeviceFontHeight(tools::Long nHeight) 
const
+double OutputDevice::ImplLogicHeightToDeviceSubPixel(tools::Long nHeight) const
 {
 if (!mbMap)
 return nHeight;
 
-return ImplLogicToPixel(static_cast(nHeight), mnDPIY,
-maMapRes.mnMapScNumY, maMapRes.mnMapScDenomY);
+return ImplLogicToSubPixel(nHeight, mnDPIY,
+  

[Libreoffice-commits] core.git: 2 commits - editeng/source emfio/source filter/source formula/source include/tools sc/source sd/source svtools/source svx/source toolkit/source tools/qa tools/source vc

2022-08-24 Thread Chris Sherlock (via logerrit)
 editeng/source/editeng/editview.cxx  |2 
 editeng/source/editeng/impedit2.cxx  |4 
 editeng/source/editeng/impedit3.cxx  |6 
 emfio/source/reader/emfreader.cxx|2 
 emfio/source/reader/wmfreader.cxx|8 
 filter/source/msfilter/eschesdo.cxx  |2 
 formula/source/ui/dlg/formula.cxx|4 
 include/tools/gen.hxx|   14 -
 sc/source/core/data/drwlayer.cxx |2 
 sc/source/core/data/postit.cxx   |2 
 sc/source/core/tool/detfunc.cxx  |8 
 sc/source/filter/excel/xichart.cxx   |2 
 sc/source/ui/condformat/condformatdlg.cxx|2 
 sc/source/ui/miscdlgs/optsolver.cxx  |2 
 sc/source/ui/miscdlgs/simpref.cxx|2 
 sc/source/ui/pagedlg/areasdlg.cxx|2 
 sc/source/ui/view/gridwin4.cxx   |4 
 sc/source/ui/view/output2.cxx|4 
 sd/source/filter/eppt/epptso.cxx |2 
 sd/source/ui/func/fuzoom.cxx |2 
 sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx |2 
 svtools/source/brwbox/brwbox2.cxx|2 
 svx/source/customshapes/EnhancedCustomShape2d.cxx|6 
 svx/source/dialog/contwnd.cxx|2 
 svx/source/engine3d/scene3d.cxx  |6 
 svx/source/svdraw/svdmrkv.cxx|8 
 svx/source/svdraw/svdoashp.cxx   |2 
 svx/source/svdraw/svdobj.cxx |   14 -
 svx/source/svdraw/svdocirc.cxx   |4 
 svx/source/svdraw/svdomeas.cxx   |2 
 svx/source/svdraw/svdopath.cxx   |2 
 svx/source/svdraw/svdorect.cxx   |2 
 svx/source/svdraw/svdotext.cxx   |2 
 svx/source/svdraw/svdotxdr.cxx   |4 
 svx/source/svdraw/svdotxtr.cxx   |2 
 svx/source/svdraw/svdtrans.cxx   |2 
 svx/source/table/svdotable.cxx   |4 
 toolkit/source/hatchwindow/ipwin.cxx |4 
 tools/qa/cppunit/test_rectangle.cxx  |   98 +++
 tools/source/generic/gen.cxx |8 
 tools/source/generic/poly.cxx|6 
 vcl/source/bitmap/BitmapEx.cxx   |2 
 vcl/source/bitmap/bitmappaint.cxx|2 
 vcl/source/control/edit.cxx  |   22 +-
 vcl/source/control/field.cxx |2 
 vcl/source/control/field2.cxx|   14 -
 vcl/source/control/fmtfield.cxx  |4 
 vcl/source/control/imivctl1.cxx  |6 
 vcl/source/control/scrbar.cxx|6 
 vcl/source/control/slider.cxx|2 
 vcl/source/control/spinbtn.cxx   |2 
 vcl/source/gdi/gdimtf.cxx|2 
 vcl/source/gdi/gradient.cxx  |2 
 vcl/source/gdi/metaact.cxx   |2 
 vcl/source/gdi/print.cxx |4 
 vcl/source/outdev/eps.cxx|2 
 vcl/source/outdev/gradient.cxx   |2 
 vcl/source/outdev/rect.cxx   |4 
 vcl/source/outdev/transparent.cxx|2 
 vcl/source/outdev/wallpaper.cxx  |   10 -
 vcl/source/window/window2.cxx|2 
 vcl/source/window/winproc.cxx|2 
 vcl/unx/generic/window/salframe.cxx  |2 
 63 files changed, 227 insertions(+), 129 deletions(-)

New commits:
commit 6c0bb0f9b846b3f1fee3ff07fb67409708449e0a
Author: Chris Sherlock 
AuthorDate: Tue Aug 23 19:30:02 2022 +1000
Commit: Tomaž Vajngerl 
CommitDate: Wed Aug 24 10:55:29 2022 +0200

tools: test Rectangle::Normalize()

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

diff --git a/tools/qa/cppunit/test_rectangle.cxx 
b/tools/qa/cppunit/test_rectangle.cxx
in

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

2022-08-24 Thread Caolán McNamara (via logerrit)
 sd/qa/uitest/impress_tests2/tdf148620.py |   12 
 1 file changed, 12 insertions(+)

New commits:
commit 51d2e734099e5c5c56393ef9f08007a7df441794
Author: Caolán McNamara 
AuthorDate: Wed Aug 24 08:48:52 2022 +0100
Commit: Caolán McNamara 
CommitDate: Wed Aug 24 10:52:18 2022 +0200

try and make test_Tdf148620 more reliable

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

diff --git a/sd/qa/uitest/impress_tests2/tdf148620.py 
b/sd/qa/uitest/impress_tests2/tdf148620.py
index a703d722d8dd..f52284fbaf2c 100644
--- a/sd/qa/uitest/impress_tests2/tdf148620.py
+++ b/sd/qa/uitest/impress_tests2/tdf148620.py
@@ -40,38 +40,50 @@ class Tdf148620(UITestCase):
 
 self.assertEqual("One\nTwo\nThree\nFour\nFive\nsix", 
document.DrawPages[0].getByIndex(1).String)
 
+xToolkit = 
self.xContext.ServiceManager.createInstance('com.sun.star.awt.Toolkit')
+
 xArgs = mkPropertyValues({"KeyModifier": 0})
 self.xUITest.executeCommandWithParameters(".uno:OutlineUp", xArgs)
+xToolkit.processEventsToIdle()
 self.assertEqual("One\nTwo\nThree\nFour\nsix\nFive", 
document.DrawPages[0].getByIndex(1).String)
 
 self.xUITest.executeCommandWithParameters(".uno:OutlineUp", xArgs)
+xToolkit.processEventsToIdle()
 self.assertEqual("One\nTwo\nThree\nsix\nFour\nFive", 
document.DrawPages[0].getByIndex(1).String)
 
 self.xUITest.executeCommandWithParameters(".uno:OutlineUp", xArgs)
+xToolkit.processEventsToIdle()
 self.assertEqual("One\nTwo\nsix\nThree\nFour\nFive", 
document.DrawPages[0].getByIndex(1).String)
 
 self.xUITest.executeCommandWithParameters(".uno:OutlineUp", xArgs)
+xToolkit.processEventsToIdle()
 self.assertEqual("One\nsix\nTwo\nThree\nFour\nFive", 
document.DrawPages[0].getByIndex(1).String)
 
 self.xUITest.executeCommandWithParameters(".uno:OutlineUp", xArgs)
+xToolkit.processEventsToIdle()
 self.assertEqual("six\nOne\nTwo\nThree\nFour\nFive", 
document.DrawPages[0].getByIndex(1).String)
 
 self.xUITest.executeCommandWithParameters(".uno:OutlineDown", 
xArgs)
+xToolkit.processEventsToIdle()
 
 # Without the fix in place, this test would have failed with
 # AssertionError: 'One\nsix\nTwo\nThree\nFour\nFive' != 
'One\nTwo\nsix\nThree\nFour\nFive'
 self.assertEqual("One\nsix\nTwo\nThree\nFour\nFive", 
document.DrawPages[0].getByIndex(1).String)
 
 self.xUITest.executeCommandWithParameters(".uno:OutlineDown", 
xArgs)
+xToolkit.processEventsToIdle()
 self.assertEqual("One\nTwo\nsix\nThree\nFour\nFive", 
document.DrawPages[0].getByIndex(1).String)
 
 self.xUITest.executeCommandWithParameters(".uno:OutlineDown", 
xArgs)
+xToolkit.processEventsToIdle()
 self.assertEqual("One\nTwo\nThree\nsix\nFour\nFive", 
document.DrawPages[0].getByIndex(1).String)
 
 self.xUITest.executeCommandWithParameters(".uno:OutlineDown", 
xArgs)
+xToolkit.processEventsToIdle()
 self.assertEqual("One\nTwo\nThree\nFour\nsix\nFive", 
document.DrawPages[0].getByIndex(1).String)
 
 self.xUITest.executeCommandWithParameters(".uno:OutlineDown", 
xArgs)
+xToolkit.processEventsToIdle()
 self.assertEqual("One\nTwo\nThree\nFour\nFive\nsix", 
document.DrawPages[0].getByIndex(1).String)
 
 # vim: set shiftwidth=4 softtabstop=4 expandtab:


[Libreoffice-commits] core.git: Branch 'distro/vector/vector-7.0' - sw/CppunitTest_sw_uibase_uiview.mk sw/inc sw/qa sw/source

2022-08-24 Thread Miklos Vajna (via logerrit)
 sw/CppunitTest_sw_uibase_uiview.mk |3 
 sw/inc/view.hxx|1 
 sw/qa/uibase/uiview/uiview.cxx |  171 +
 sw/source/uibase/uiview/view.cxx   |   28 ++
 4 files changed, 202 insertions(+), 1 deletion(-)

New commits:
commit 6c1fca897e148ce6200ad57a3b6eaf188448c069
Author: Miklos Vajna 
AuthorDate: Tue Aug 23 11:58:29 2022 +0200
Commit: Miklos Vajna 
CommitDate: Wed Aug 24 10:22:15 2022 +0200

sw: fix missing cache invalidation when switching between images

It is possible to disable toolbar buttons from UNO API client code by
registering a dispatch provider interceptor and then returning an empty
reference when the UNO command associated with that toolbar button is 
queried
for a dispatch. Such querying of a dispatch happens when changing context 
(e.g.
text -> image selection), but not when switching between two images.

A benefit of the current approach is that once a button is disabled this 
way,
it remains disabled without re-querying the dispatch provider, which helps
performance. A downside is that in case the dispatch provider intercepts the
command based on the current selection (e.g. currently selected image), then
switching to an other image won't re-query the dispatch provider, for at 
least
two reasons:

- SfxBindings::Register_Impl() is only called when the dispatcher is an
internal one (e.g. not implemented in Java), so there is no listener that 
would
re-query the state on selection change

- even if we re-query the dispatch provider, the actual toolbar button 
won't be
updated if the initial dispatch was an empty reference, since updating 
works by
registering a status listener on the returned dispatch object in
svt::ToolboxController::bindListener()

Fix the problem by explicitly calling contextChanged() on the current frame
when switching between images (but not changing context), similar to how
SvtCommandOptions_Impl::Notify() invalidates registered dispatch objects 
when
the configuration (on what commands are disabled) changes.

This only helps with images and OLE objects, other object types are kept
unchanged for now.

(cherry picked from commit 31cb5b5538b9fd91dafb067ce961f2540555ad2b)

Change-Id: I7f33dd2804067acf5cb0ca836f6a2a69fa950a8b

diff --git a/sw/CppunitTest_sw_uibase_uiview.mk 
b/sw/CppunitTest_sw_uibase_uiview.mk
index 66c95375bd56..08d0976c13c4 100644
--- a/sw/CppunitTest_sw_uibase_uiview.mk
+++ b/sw/CppunitTest_sw_uibase_uiview.mk
@@ -62,7 +62,8 @@ $(eval $(call 
gb_CppunitTest_use_custom_headers,sw_uibase_uiview,\
 officecfg/registry \
 ))
 
-$(eval $(call gb_CppunitTest_use_configuration,sw_uibase_uiview))
+$(eval $(call gb_CppunitTest_use_instdir_configuration,sw_uibase_uiview))
+$(eval $(call gb_CppunitTest_use_common_configuration,sw_uibase_uiview))
 
 $(eval $(call gb_CppunitTest_use_uiconfigs,sw_uibase_uiview, \
 modules/swriter \
diff --git a/sw/inc/view.hxx b/sw/inc/view.hxx
index 2a7bc89ab7e3..6d9d2cf19c66 100644
--- a/sw/inc/view.hxx
+++ b/sw/inc/view.hxx
@@ -202,6 +202,7 @@ class SW_DLLPUBLIC SwView: public SfxViewShell
 std::unique_ptrm_pDrawActual;
 
 const SwFrameFormat  *m_pLastTableFormat;
+const SwFrameFormat* m_pLastFlyFormat;
 
 std::unique_ptr m_pFormatClipboard; //holds data for 
format paintbrush
 
diff --git a/sw/qa/uibase/uiview/uiview.cxx b/sw/qa/uibase/uiview/uiview.cxx
index b7826bc9ad52..d49e3ee70dc8 100644
--- a/sw/qa/uibase/uiview/uiview.cxx
+++ b/sw/qa/uibase/uiview/uiview.cxx
@@ -14,17 +14,20 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
 #include 
 #include 
 #include 
+#include 
 
 char const DATA_DIRECTORY[] = "/sw/qa/uibase/uiview/data/";
 
@@ -146,6 +149,174 @@ CPPUNIT_TEST_FIXTURE(SwUibaseUiviewTest, testKeepRatio)
 assertXPathContent(pXmlDoc, 
"//config:config-item[@config:name='KeepRatio']", "true");
 }
 
+namespace
+{
+/// Interception implementation that disables .uno:Zoom on Image1, but not on 
Image2.
+struct ImageInterceptor : public 
cppu::WeakImplHelper
+{
+uno::Reference m_xSelectionSupplier;
+uno::Reference m_xMaster;
+uno::Reference m_xSlave;
+int m_nEnabled = 0;
+int m_nDisabled = 0;
+
+public:
+ImageInterceptor(const uno::Reference& xComponent);
+
+// XDispatchProviderInterceptor
+uno::Reference SAL_CALL 
getMasterDispatchProvider() override;
+uno::Reference SAL_CALL 
getSlaveDispatchProvider() override;
+void SAL_CALL setMasterDispatchProvider(
+const uno::Reference& xNewSupplier) override;
+void SAL_CALL
+setSlaveDispatchProvider(const uno::Reference& 
xNewSupplier) override;
+
+// XDispatchProvider
+uno::Reference SAL_CALL queryDispatch(const util::URL& 
rURL,
+const