[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.4' - sdext/source

2020-09-21 Thread Mike Kaganski (via logerrit)
 sdext/source/minimizer/fileopendialog.cxx |8 +---
 1 file changed, 5 insertions(+), 3 deletions(-)

New commits:
commit bfb559d04a08d2a8ebb90d04772c0321e2aaf1dc
Author: Mike Kaganski 
AuthorDate: Sun Aug 16 18:58:48 2020 +0300
Commit: Mike Kaganski 
CommitDate: Tue Sep 22 08:51:31 2020 +0200

tdf#135342: filter list must include extensions

Regression after commit a0dcc8f78061d22d925f31ef8d03ca751ad6dc19.
The commit had added extensions to the filter names sent to file
dialog, but kept internal list of filter names aFilterEntryList
without extensions. Then dialog returned the chosen filter's name
in the form it was sent there, i.e. with extension; and that name
couldn't be found in aFilterEntryList.

So let's keep aFilterEntryList synchronized with the UI names in
the dialog.

Change-Id: Ic21d19d1a8d0b7f64ccfb517a7d0ee8ab36fc6a8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100821
Tested-by: Jenkins
Reviewed-by: Mike Kaganski 
(cherry picked from commit 99c6c89deed41457d35c382fc7d6a4cd5191f7d7)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100792
Reviewed-by: Caolán McNamara 
(cherry picked from commit bbd0d424263a21dd0ffdc42d1201f86e65358f25)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101671
Reviewed-by: Xisco Fauli 
(cherry picked from commit 20e557dc730d66453d32f9268381274c268cabd4)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103061
Tested-by: Jenkins CollaboraOffice 

diff --git a/sdext/source/minimizer/fileopendialog.cxx 
b/sdext/source/minimizer/fileopendialog.cxx
index 68f25f77900a..aab29c03907b 100644
--- a/sdext/source/minimizer/fileopendialog.cxx
+++ b/sdext/source/minimizer/fileopendialog.cxx
@@ -106,7 +106,7 @@ FileOpenDialog::FileOpenDialog( const Reference< 
XComponentContext >& rxContext
 Reference< XNameAccess > xTypes( 
rxContext->getServiceManager()->createInstanceWithContext(
 "com.sun.star.document.TypeDetection", rxContext ), UNO_QUERY_THROW );
 
-for( const auto& rFilterEntry : aFilterEntryList )
+for (auto& rFilterEntry : aFilterEntryList)
 {
 Sequence< PropertyValue > aTypeProperties;
 try
@@ -120,10 +120,12 @@ FileOpenDialog::FileOpenDialog( const Reference< 
XComponentContext >& rxContext
 pProp->Value >>= aExtensions;
 if ( aExtensions.hasElements() )
 {
-// The filter title must be formed in the same way it is
-// currently done in the internal implementation:
+// The filter title must be formed in the same way it is 
currently done in the
+// internal implementation (see 
sfx2::appendFiltersForSave). And we will look
+// for the same string returned from the dialog, so save 
it to maUIName:
 OUString aTitle(
 rFilterEntry.maUIName + " (." + aExtensions[0] + ")");
+rFilterEntry.maUIName = aTitle;
 OUString aFilter("*." + aExtensions[0]);
 mxFilePicker->appendFilter(aTitle, aFilter);
 if ( rFilterEntry.maFlags & 0x100 )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-6-4' - include/svtools svtools/source

2020-09-21 Thread Tomofumi Yagi (via logerrit)
 include/svtools/filechangedchecker.hxx |2 +-
 svtools/source/misc/filechangedchecker.cxx |   21 -
 2 files changed, 13 insertions(+), 10 deletions(-)

New commits:
commit bd1345f9806b1bb9940d208d75610f7c4556f05d
Author: Tomofumi Yagi 
AuthorDate: Fri Sep 18 16:21:43 2020 +0900
Commit: Noel Grandin 
CommitDate: Tue Sep 22 08:40:34 2020 +0200

tdf#134157 fix Edit with external tool causes a CPU hit

Switch Idle to 100ms Timer for fixing the bug

Change-Id: I85a9bdcb173edd28d952d8e91c1b93d748e69206
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102984
Tested-by: Jenkins
Reviewed-by: Noel Grandin 
(cherry picked from commit f110c037114f90d219ac8d149542bf96fe66a2f1)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103055
Reviewed-by: Caolán McNamara 
Signed-off-by: Xisco Fauli 
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103130

diff --git a/include/svtools/filechangedchecker.hxx 
b/include/svtools/filechangedchecker.hxx
index ec8d8a41fdac..a1c2fcb38eaa 100644
--- a/include/svtools/filechangedchecker.hxx
+++ b/include/svtools/filechangedchecker.hxx
@@ -28,7 +28,7 @@ class Timer;
 class SVT_DLLPUBLIC FileChangedChecker
 {
 private:
-IdlemIdle;
+TimermTimer;
 OUString const   mFileName;
 TimeValuemLastModTime;
 ::std::function const mpCallback;
diff --git a/svtools/source/misc/filechangedchecker.cxx 
b/svtools/source/misc/filechangedchecker.cxx
index 09e24c3fafb1..8536eb0bda57 100644
--- a/svtools/source/misc/filechangedchecker.cxx
+++ b/svtools/source/misc/filechangedchecker.cxx
@@ -16,7 +16,7 @@
 
 FileChangedChecker::FileChangedChecker(const OUString& rFilename,
 const ::std::function& rCallback)
-: mIdle("SVTools FileChangedChecker Idle")
+: mTimer("SVTools FileChangedChecker Timer")
 , mFileName(rFilename)
 , mLastModTime()
 , mpCallback(rCallback)
@@ -24,21 +24,24 @@ FileChangedChecker::FileChangedChecker(const OUString& 
rFilename,
 // Get the curren last file modified Status
 getCurrentModTime(mLastModTime);
 
-// associate the callback function for the Idle
-mIdle.SetInvokeHandler(LINK(this, FileChangedChecker, TimerHandler));
+// associate the callback function for the Timer
+mTimer.SetInvokeHandler(LINK(this, FileChangedChecker, TimerHandler));
 
-//start the timer
+// set timer interval
+mTimer.SetTimeout(100);
+
+// start the timer
 resetTimer();
 }
 
 void FileChangedChecker::resetTimer()
 {
-//Start the Idle if it's not active
-if(!mIdle.IsActive())
-mIdle.Start();
+// Start the Idle if it's not active
+if(!mTimer.IsActive())
+mTimer.Start();
 
 // Set lowest Priority
-mIdle.SetPriority(TaskPriority::LOWEST);
+mTimer.SetPriority(TaskPriority::LOWEST);
 }
 
 bool FileChangedChecker::getCurrentModTime(TimeValue& o_rValue) const
@@ -90,7 +93,7 @@ IMPL_LINK_NOARG(FileChangedChecker, TimerHandler, Timer *, 
void)
 mpCallback();
 }
 
-// Reset the Idle in any case
+// Reset the Timer in any case
 resetTimer();
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.4' - svx/source

2020-09-21 Thread Szymon Kłos (via logerrit)
 svx/source/tbxctrls/tbcontrl.cxx |   27 +++
 1 file changed, 19 insertions(+), 8 deletions(-)

New commits:
commit 5d8390a36e45c14a38c02cafd935512ea58fbfe6
Author: Szymon Kłos 
AuthorDate: Fri Sep 18 13:26:41 2020 +0200
Commit: Szymon Kłos 
CommitDate: Tue Sep 22 08:33:05 2020 +0200

Use translated standard styles for styles listbox

In online we can have users with multiple languages.
Select style in sidebar depending on translated name
and also universal/English.

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

diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx
index e49ac60442a8..50e3f6760867 100644
--- a/svx/source/tbxctrls/tbcontrl.cxx
+++ b/svx/source/tbxctrls/tbcontrl.cxx
@@ -2847,7 +2847,7 @@ struct SvxStyleToolBoxControl::Impl
 {
 OUString aClearForm;
 OUString aMore;
-::std::vector< OUString >aDefaultStyles;
+::std::vector< std::pair< OUString, OUString > >aDefaultStyles;
 bool bSpecModeWriter;
 bool bSpecModeCalc;
 
@@ -2893,7 +2893,8 @@ struct SvxStyleToolBoxControl::Impl
 OUString sName;
 xStyle->getPropertyValue("DisplayName") >>= sName;
 if( !sName.isEmpty() )
-aDefaultStyles.push_back(sName);
+aDefaultStyles.push_back(
+std::pair(aStyle, sName) );
 }
 catch( const uno::Exception& )
 {}
@@ -2924,7 +2925,8 @@ struct SvxStyleToolBoxControl::Impl
 OUString sName;
 xStyle->getPropertyValue("DisplayName") >>= sName;
 if( !sName.isEmpty() )
-aDefaultStyles.push_back(sName);
+aDefaultStyles.push_back(
+std::pair(sStyleName, 
sName) );
 }
 }
 catch( const uno::Exception& )
@@ -3100,7 +3102,7 @@ void SvxStyleToolBoxControl::FillStyleBox()
 OUString aName( pStyle->GetName() );
 for( auto const & _i: pImpl->aDefaultStyles )
 {
-if( _i == aName )
+if( _i.first == aName || _i.second == aName )
 {
 bInsert = false;
 break;
@@ -3133,7 +3135,7 @@ void SvxStyleToolBoxControl::FillStyleBox()
 sal_uInt16 nPos = 1;
 for( auto const & _i: pImpl->aDefaultStyles )
 {
-pBox->InsertEntry( _i, nPos );
+pBox->InsertEntry( _i.second, nPos );
 ++nPos;
 }
 
@@ -3169,8 +3171,17 @@ void SvxStyleToolBoxControl::SelectStyle( const 
OUString& rStyleName )
 
 if ( !rStyleName.isEmpty() )
 {
-if ( rStyleName != aStrSel )
-pBox->SetText( rStyleName );
+OUString aNewStyle = rStyleName;
+
+auto aFound = std::find_if(pImpl->aDefaultStyles.begin(), 
pImpl->aDefaultStyles.end(),
+[rStyleName] (auto it) { return it.first == rStyleName || 
it.second == rStyleName; }
+);
+
+if (aFound != pImpl->aDefaultStyles.end())
+aNewStyle = aFound->second;
+
+if ( aNewStyle != aStrSel )
+pBox->SetText( aNewStyle );
 }
 else
 pBox->SetNoSelection();
@@ -3304,7 +3315,7 @@ VclPtr 
SvxStyleToolBoxControl::CreateItemWindow( vcl::Window *pPare
pImpl->aMore,
pImpl->bSpecModeWriter || 
pImpl->bSpecModeCalc );
 if( !pImpl->aDefaultStyles.empty())
-pBox->SetDefaultStyle( pImpl->aDefaultStyles[0] );
+pBox->SetDefaultStyle( pImpl->aDefaultStyles[0].second );
 // Set visibility listener to bind/unbind controller
 pBox->SetVisibilityListener( LINK( this, SvxStyleToolBoxControl, 
VisibilityNotification ));
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: tools/CppunitTest_tools_test.mk tools/qa

2020-09-21 Thread Dr. David Alan Gilbert (via logerrit)
 tools/CppunitTest_tools_test.mk|3 
 tools/qa/cppunit/test_cpu_runtime_detection_AVX2.cxx   |   38 -
 tools/qa/cppunit/test_cpu_runtime_detection_AVX2_check.cxx |   54 +
 tools/qa/cppunit/test_cpu_runtime_detection_x86_checks.hxx |   21 +
 4 files changed, 80 insertions(+), 36 deletions(-)

New commits:
commit afb62b0e96e9bf91ec99857cc16ddb094bcaa3be
Author: Dr. David Alan Gilbert 
AuthorDate: Sun Sep 20 16:36:57 2020 +0100
Commit: Tomaž Vajngerl 
CommitDate: Tue Sep 22 08:32:58 2020 +0200

Fix AVX2 cpuid checks

At the moment test_cpu_runtime_detection_AVX2.cxx is compiled with
-mavx2 to allow it to use the intrinsics; however the compiler jumps
at the chance to use newer instructions outside the actual test;
in my case using AVX in the string manipulation in addTestsToSuite
when my CPU doesn't actually have AVX.

Swing the actual check into a separate file and only compile that
with the extra flag.

We probably need the same change for the SSE* checks as well.

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

diff --git a/tools/CppunitTest_tools_test.mk b/tools/CppunitTest_tools_test.mk
index aa5ac4606d02..48c667425ce4 100644
--- a/tools/CppunitTest_tools_test.mk
+++ b/tools/CppunitTest_tools_test.mk
@@ -32,10 +32,11 @@ $(eval $(call 
gb_CppunitTest_add_exception_objects,tools_test, \
 tools/qa/cppunit/test_xmlwalker \
 tools/qa/cppunit/test_GenericTypeSerializer \
 tools/qa/cppunit/test_cpuid \
+tools/qa/cppunit/test_cpu_runtime_detection_AVX2 \
 ))
 
 $(eval $(call gb_CppunitTest_add_exception_objects,tools_test,\
-tools/qa/cppunit/test_cpu_runtime_detection_AVX2, 
$(CXXFLAGS_INTRINSICS_AVX2) \
+tools/qa/cppunit/test_cpu_runtime_detection_AVX2_check, 
$(CXXFLAGS_INTRINSICS_AVX2) \
 ))
 
 $(eval $(call gb_CppunitTest_add_exception_objects,tools_test,\
diff --git a/tools/qa/cppunit/test_cpu_runtime_detection_AVX2.cxx 
b/tools/qa/cppunit/test_cpu_runtime_detection_AVX2.cxx
index 0c98f2fc8c98..5a3a1ee26638 100644
--- a/tools/qa/cppunit/test_cpu_runtime_detection_AVX2.cxx
+++ b/tools/qa/cppunit/test_cpu_runtime_detection_AVX2.cxx
@@ -8,8 +8,7 @@
  */
 
 #include 
-
-#ifdef LO_AVX2_AVAILABLE
+#include "test_cpu_runtime_detection_x86_checks.hxx"
 
 #include 
 #include 
@@ -23,7 +22,6 @@ namespace
 class CpuRuntimeDetection_AVX2 : public CppUnit::TestFixture
 {
 public:
-void checkAVX2();
 void testCpuRuntimeDetection();
 
 CPPUNIT_TEST_SUITE(CpuRuntimeDetection_AVX2);
@@ -33,43 +31,13 @@ public:
 
 void CpuRuntimeDetection_AVX2::testCpuRuntimeDetection()
 {
-// can only run if this function if CPU supports AVX2
+// can only run this function if CPU supports AVX2
 if (cpuid::isCpuInstructionSetSupported(cpuid::InstructionSetFlags::AVX2))
-checkAVX2();
-}
-
-void CpuRuntimeDetection_AVX2::checkAVX2()
-{
-__m256i a = _mm256_set_epi64x(1, 4, 8, 3);
-__m256i b = _mm256_set_epi64x(2, 1, 1, 5);
-__m256i c = _mm256_xor_si256(a, b);
-
-sal_Int64 values[4];
-_mm256_storeu_si256(reinterpret_cast<__m256i*>(&values), c);
-
-CPPUNIT_ASSERT_EQUAL(sal_Int64(6), values[0]);
-CPPUNIT_ASSERT_EQUAL(sal_Int64(9), values[1]);
-CPPUNIT_ASSERT_EQUAL(sal_Int64(5), values[2]);
-CPPUNIT_ASSERT_EQUAL(sal_Int64(3), values[3]);
-
-__m256i d = _mm256_set_epi64x(3, 5, 1, 0);
-
-__m256i result = _mm256_cmpeq_epi64(d, c);
-
-// Compare equals
-sal_Int64 compare[4];
-_mm256_storeu_si256(reinterpret_cast<__m256i*>(&compare), result);
-
-CPPUNIT_ASSERT_EQUAL(sal_Int64(0), compare[0]);
-CPPUNIT_ASSERT_EQUAL(sal_Int64(0), compare[1]);
-CPPUNIT_ASSERT_EQUAL(sal_Int64(-1), compare[2]);
-CPPUNIT_ASSERT_EQUAL(sal_Int64(-1), compare[3]);
+CpuRuntimeDetectionX86Checks::checkAVX2();
 }
 
 CPPUNIT_TEST_SUITE_REGISTRATION(CpuRuntimeDetection_AVX2);
 
 } // end anonymous namespace
 
-#endif
-
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/tools/qa/cppunit/test_cpu_runtime_detection_AVX2_check.cxx 
b/tools/qa/cppunit/test_cpu_runtime_detection_AVX2_check.cxx
new file mode 100644
index ..b5948223752c
--- /dev/null
+++ b/tools/qa/cppunit/test_cpu_runtime_detection_AVX2_check.cxx
@@ -0,0 +1,54 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#include 
+#include 
+
+#include 
+#include 
+#include 
+#include 
+
+#include "test_cpu_runtime_detection_x86_checks.hxx"
+
+/* WARNING: This file is compiled with AVX2 support, don't call
+ * any function without 

[Libreoffice-commits] core.git: Branch 'private/tvajngerl/staging' - 1088 commits - accessibility/inc accessibility/source animations/source avmedia/inc avmedia/source basctl/inc basctl/sdi basctl/sou

2020-09-21 Thread Tomaž Vajngerl (via logerrit)
Rebased ref, commits from common ancestor:
commit 1c38d602ccab3ef62825662b1b36569c3c702964
Author: Tomaž Vajngerl 
AuthorDate: Tue May 22 14:44:39 2018 +0900
Commit: Tomaž Vajngerl 
CommitDate: Tue Sep 22 08:17:50 2020 +0200

Command Popup

Change-Id: I92cdd3130b8de42ee0863c9e7154e7c7246d9377

diff --git a/include/sfx2/sfxsids.hrc b/include/sfx2/sfxsids.hrc
index 88d708e4cb98..7cf9ccc52ce0 100644
--- a/include/sfx2/sfxsids.hrc
+++ b/include/sfx2/sfxsids.hrc
@@ -382,7 +382,7 @@ class SvxSearchItem;
 
 // default-ids for windows
 
-// free (SID_SFX_START + 610)
+#define SID_COMMAND_POPUP   (SID_SFX_START + 610)
 #define SID_NEWWINDOW   (SID_SFX_START + 620)
 #define SID_CLOSEWIN(SID_SFX_START + 621)
 #define SID_VIEWSHELL   (SID_SFX_START + 623)
diff --git a/officecfg/registry/data/org/openoffice/Office/Accelerators.xcu 
b/officecfg/registry/data/org/openoffice/Office/Accelerators.xcu
index b8a46cfc035a..2db3f82fc808 100644
--- a/officecfg/registry/data/org/openoffice/Office/Accelerators.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/Accelerators.xcu
@@ -313,6 +313,12 @@ Ctrl+Shift+e aka E_SHIFT_MOD1 under GTK/IBUS is for some 
emoji thing
   .uno:OptionsTreeDialog
 
   
+  
+
+  I10N SHORTCUTS - NO 
TRANSLATE
+  .uno:CommandPopup
+
+  
 
 
   
diff --git 
a/officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu 
b/officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu
index 97b8e210924c..4dde5dd0d73d 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu
@@ -6488,6 +6488,14 @@
   1
 
   
+  
+
+  Command Popup
+
+
+  1
+
+  
 
 
   
diff --git a/sfx2/Library_sfx.mk b/sfx2/Library_sfx.mk
index cb0b099eb37d..4c7d994de08d 100644
--- a/sfx2/Library_sfx.mk
+++ b/sfx2/Library_sfx.mk
@@ -296,6 +296,7 @@ $(eval $(call gb_Library_add_exception_objects,sfx,\
 sfx2/source/styles/StyleManager \
 sfx2/source/toolbox/tbxitem \
 sfx2/source/toolbox/weldutils \
+sfx2/source/view/CommandPopup \
 sfx2/source/view/classificationcontroller \
 sfx2/source/view/classificationhelper \
 sfx2/source/view/frame \
diff --git a/sfx2/UIConfig_sfx.mk b/sfx2/UIConfig_sfx.mk
index 5bb91d7ac6f6..da64557e8964 100644
--- a/sfx2/UIConfig_sfx.mk
+++ b/sfx2/UIConfig_sfx.mk
@@ -21,6 +21,7 @@ $(eval $(call gb_UIConfig_add_uifiles,sfx,\
sfx2/uiconfig/ui/classificationbox \
sfx2/uiconfig/ui/cmisinfopage \
sfx2/uiconfig/ui/cmisline \
+   sfx2/uiconfig/ui/commandpopup \
sfx2/uiconfig/ui/custominfopage \
sfx2/uiconfig/ui/descriptioninfopage \
sfx2/uiconfig/ui/dockingwindow \
diff --git a/sfx2/sdi/frmslots.sdi b/sfx2/sdi/frmslots.sdi
index 09aafef95b7d..a7c8a472e73d 100644
--- a/sfx2/sdi/frmslots.sdi
+++ b/sfx2/sdi/frmslots.sdi
@@ -262,6 +262,11 @@ interface TopWindow : BrowseWindow
 ExecMethod = MiscExec_Impl ;
 StateMethod = MiscState_Impl ;
 ]
+SID_COMMAND_POPUP
+[
+ExecMethod = MiscExec_Impl ;
+StateMethod = MiscState_Impl ;
+]
 SID_CLOSEWIN // ole(no) api(final/play/rec)
 [
 ExecMethod = Exec_Impl ;
@@ -307,4 +312,3 @@ shell SfxViewFrame
 StateMethod = GetState_Impl ;
 ]
 }
-
diff --git a/sfx2/sdi/sfx.sdi b/sfx2/sdi/sfx.sdi
index a50b5f1a17a6..813ef070c978 100644
--- a/sfx2/sdi/sfx.sdi
+++ b/sfx2/sdi/sfx.sdi
@@ -1271,6 +1271,23 @@ SfxStringItem FullName SID_DOCFULLNAME
 GroupId = ;
 ]
 
+SfxVoidItem CommandPopup SID_COMMAND_POPUP
+[
+AutoUpdate = TRUE,
+FastCall = FALSE,
+ReadOnlyDoc = TRUE,
+Toggle = FALSE,
+Container = TRUE,
+RecordAbsolute = FALSE,
+RecordPerSet;
+Asynchron;
+
+
+AccelConfig = TRUE,
+MenuConfig = TRUE,
+ToolBoxConfig = TRUE,
+GroupId = SfxGroupId::View;
+]
 
 SfxBoolItem FullScreen SID_WIN_FULLSCREEN
 
diff --git a/sfx2/source/view/CommandPopup.cxx 
b/sfx2/source/view/CommandPopup.cxx
new file mode 100644
index ..0bbe8adba5b2
--- /dev/null
+++ b/sfx2/source/view/CommandPopup.cxx
@@ -0,0 +1,220 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#include "CommandPopup.hxx"
+
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+
+#include 
+#include 
+#include 
+
+#include 
+#include 
+
+#include 
+
+#include 
+
+using namespace css;
+
+CommandListBox::CommandListBox(vcl::Wi

[Libreoffice-commits] core.git: helpcontent2

2020-09-21 Thread Gabor Kelemen (via logerrit)
 helpcontent2 |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit b51fa6d7e4d6a64f822122eac1fa7ad1dec3574b
Author: Gabor Kelemen 
AuthorDate: Tue Sep 22 06:55:12 2020 +0200
Commit: Gerrit Code Review 
CommitDate: Tue Sep 22 06:55:12 2020 +0200

Update git submodules

* Update helpcontent2 from branch 'master'
  to 9b4e021c4ba2cd74ebd81bf0a46efc762ad36931
  - tdf#136071 (related) Remove Spacing submenu from Calc Format menu 
reference

Change-Id: I474811cc3ea234a38537fa2bfed577ae6570ae90
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/103126
Tested-by: Jenkins
Reviewed-by: Ilmari Lauhakangas 

diff --git a/helpcontent2 b/helpcontent2
index 5c93f0a8c123..9b4e021c4ba2 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit 5c93f0a8c1233c584aac64be9dc77d49bf074ade
+Subproject commit 9b4e021c4ba2cd74ebd81bf0a46efc762ad36931
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Gabor Kelemen (via logerrit)
 source/text/scalc/main0105.xhp |1 -
 1 file changed, 1 deletion(-)

New commits:
commit 9b4e021c4ba2cd74ebd81bf0a46efc762ad36931
Author: Gabor Kelemen 
AuthorDate: Mon Sep 21 21:13:40 2020 +0200
Commit: Ilmari Lauhakangas 
CommitDate: Tue Sep 22 06:55:12 2020 +0200

tdf#136071 (related) Remove Spacing submenu from Calc Format menu reference

Change-Id: I474811cc3ea234a38537fa2bfed577ae6570ae90
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/103126
Tested-by: Jenkins
Reviewed-by: Ilmari Lauhakangas 

diff --git a/source/text/scalc/main0105.xhp b/source/text/scalc/main0105.xhp
index 5a8df9642..eb6f4ec8a 100644
--- a/source/text/scalc/main0105.xhp
+++ b/source/text/scalc/main0105.xhp
@@ -35,7 +35,6 @@
 The Format menu contains commands for formatting selected 
cells, objects, and cell contents in your 
document.
 
 
-
 
 
 Cells
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


New Defects reported by Coverity Scan for LibreOffice

2020-09-21 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.
249 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 1467075:  Error handling issues  (CHECKED_RETURN)
/chart2/source/controller/dialogs/DialogModel.cxx: 680 in 
chart::DialogModel::detectArguments(rtl::OUString &, bool &, bool &, bool &) 
const()



*** CID 1467075:  Error handling issues  (CHECKED_RETURN)
/chart2/source/controller/dialogs/DialogModel.cxx: 680 in 
chart::DialogModel::detectArguments(rtl::OUString &, bool &, bool &, bool &) 
const()
674 try
675 {
676 uno::Sequence< sal_Int32 > aSequenceMapping;//todo YYYX
677 
678 // Note: unused data is currently not supported in being passed 
to detectRangeSegmentation
679 if( m_xChartDocument.is())
>>> CID 1467075:  Error handling issues  (CHECKED_RETURN)
>>> Calling "detectRangeSegmentation" without checking return value (as is 
>>> done elsewhere 7 out of 8 times).
680 DataSourceHelper::detectRangeSegmentation(
681 Reference< frame::XModel >( m_xChartDocument, 
uno::UNO_QUERY_THROW ),
682 rOutRangeString, aSequenceMapping, rOutUseColumns, 
rOutFirstCellAsLabel, rOutHasCategories );
683 }
684 catch( const uno::Exception & )
685 {

** CID 1448510:(TAINTED_SCALAR)



*** CID 1448510:(TAINTED_SCALAR)
/sw/source/filter/ww8/docxattributeoutput.cxx: 7043 in 
DocxAttributeOutput::EmbedFontStyle(const rtl::OUString &, int, FontFamily, 
FontItalic, FontWeight, FontPitch)()
7037 xOutStream->closeOutput();
7038 return;
7039 }
7040 if( readSize == 0 )
7041 break;
7042 // coverity[overrun-buffer-arg : FALSE] - coverity has 
difficulty with css::uno::Sequence
>>> CID 1448510:(TAINTED_SCALAR)
>>> Passing tainted variable "buffer" to a tainted sink.
7043 xOutStream->writeBytes( uno::Sequence< sal_Int8 >( 
reinterpret_cast< const sal_Int8* >( buffer ), readSize ));
7044 }
7045 xOutStream->closeOutput();
7046 OString relId = OUStringToOString( 
GetExport().GetFilter().addRelation( m_pSerializer->getOutputStream(),
7047 oox::getRelationship(Relationship::FONT),
7048 "fonts/font" + OUString::number( m_nextFontId ) + ".odttf" 
), RTL_TEXTENCODING_UTF8 );
/sw/source/filter/ww8/docxattributeoutput.cxx: 7022 in 
DocxAttributeOutput::EmbedFontStyle(const rtl::OUString &, int, FontFamily, 
FontItalic, FontWeight, FontPitch)()
7016  i < 16;
7017  ++i )
7018 {
7019 buffer[ i ] ^= fontKey[ i ];
7020 buffer[ i + 16 ] ^= fontKey[ i ];
7021 }
>>> CID 1448510:(TAINTED_SCALAR)
>>> Passing tainted variable "buffer" to a tainted sink.
7022 xOutStream->writeBytes( uno::Sequence< sal_Int8 >( 
reinterpret_cast< const sal_Int8* >( buffer ), 32 ));
7023 for(;;)
7024 {
7025 sal_Bool eof;
7026 if( file.isEndOfFile( &eof ) != osl::File::E_None )
7027 {

** CID 1448420:  Insecure data handling  (TAINTED_SCALAR)



*** CID 1448420:  Insecure data handling  (TAINTED_SCALAR)
/ucb/source/ucp/file/filtask.cxx: 648 in fileaccess::TaskManager::page(int, 
const rtl::OUString &, const 
com::sun::star::uno::Reference &)()
642 do
643 {
644 err = aFile.read( static_cast(BFF),bfz,nrc );
645 if(  err == osl::FileBase::E_None )
646 {
647 // coverity[overrun-buffer-arg : FALSE] - coverity has 
difficulty with css::uno::Sequence
>>> CID 1448420:  Insecure data handling  (TAINTED_SCALAR)
>>> Passing tainted variable "BFF" to a tainted sink.
648 uno::Sequence< sal_Int8 > seq( BFF, 
static_cast(nrc) );
649 try
650 {
651 xOutputStream->writeBytes( seq );
652 }
653 catch (const io::NotConnectedException&)

** CID 1448292:  Insecure data handling  (TAINTED_SCALAR)



*** CID 1448292:  Insecure data handling  (TAINTED_SCALAR)
/xmloff/source/style/XMLFontAutoStylePool.cxx: 646 in 
XMLFontAutoStylePool::e

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

2020-09-21 Thread Samuel Mehrbrodt (via logerrit)
 sw/source/core/crsr/crstrvl.cxx  |2 +-
 sw/source/core/txtnode/ndtxt.cxx |2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

New commits:
commit e60e70d544d67237d11943dd4004d6540d8edce6
Author: Samuel Mehrbrodt 
AuthorDate: Thu Aug 20 15:33:49 2020 +0200
Commit: Thorsten Behrens 
CommitDate: Tue Sep 22 01:06:05 2020 +0200

Related tdf#100492 Detect click into empty field

Change-Id: Ic2937d619a8361b9d17b7dfa16698a5005f34ec6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101076
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt 
(cherry picked from commit 2c7bf3543ab798d1c117d9f3258467e4aef9a8db)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103054
Reviewed-by: Thorsten Behrens 

diff --git a/sw/source/core/crsr/crstrvl.cxx b/sw/source/core/crsr/crstrvl.cxx
index dd0d50c58d2c..4dbb5e7328fa 100644
--- a/sw/source/core/crsr/crstrvl.cxx
+++ b/sw/source/core/crsr/crstrvl.cxx
@@ -961,7 +961,7 @@ bool SwCursorShell::CursorInsideInputField() const
 {
 for(SwPaM& rCursor : GetCursor()->GetRingContainer())
 {
-if (dynamic_cast(GetTextFieldAtCursor(&rCursor, false)))
+if (dynamic_cast(GetTextFieldAtCursor(&rCursor, true)))
 return true;
 }
 return false;
diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx
index 0d272486e295..a3667e53e386 100644
--- a/sw/source/core/txtnode/ndtxt.cxx
+++ b/sw/source/core/txtnode/ndtxt.cxx
@@ -1780,7 +1780,7 @@ SwTextField* SwTextNode::GetFieldTextAttrAt(
 dynamic_cast( GetTextAttrAt(
 nIndex,
 RES_TXTATR_INPUTFIELD,
-bIncludeInputFieldAtStart ? DEFAULT : PARENT ));
+bIncludeInputFieldAtStart ? DEFAULT : EXPAND ));
 }
 
 return pTextField;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Caolán McNamara (via logerrit)
 chart2/source/controller/dialogs/DataBrowser.cxx |   36 
 chart2/uiconfig/ui/chartdatadialog.ui|   68 ---
 2 files changed, 61 insertions(+), 43 deletions(-)

New commits:
commit 34330cbf4cc3cd558b18563582a577ea5306b84e
Author: Caolán McNamara 
AuthorDate: Thu Sep 17 19:31:53 2020 +0100
Commit: Adolfo Jayme Barrientos 
CommitDate: Tue Sep 22 00:36:04 2020 +0200

tdf#133482 don't increase dialog width when new columns added

gtk will expand to fit all children, while vcl will clip.
insert a borderless ScrolledWindow with "external" scrolling
to allow the dialog to clip the children (same thing we do
for our menubar to shrink down past its natural size)

adjust the width calculation to avoid logictopixel rounding

Change-Id: Id2e4f92959f1827c6960360d1530a9c63a4d0c00
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102931
Tested-by: Jenkins
Reviewed-by: Adolfo Jayme Barrientos 

diff --git a/chart2/source/controller/dialogs/DataBrowser.cxx 
b/chart2/source/controller/dialogs/DataBrowser.cxx
index 0aaccdea65cf..d772905dca39 100644
--- a/chart2/source/controller/dialogs/DataBrowser.cxx
+++ b/chart2/source/controller/dialogs/DataBrowser.cxx
@@ -102,9 +102,6 @@ public:
 
 bool HasFocus() const { return m_xControl->has_focus(); }
 
-void Hide() { m_xControl->hide(); }
-void Show() { m_xControl->show(); }
-
 void set_size_request(int nWidth, int nHeight) { 
m_xControl->set_size_request(nWidth, nHeight); }
 void set_margin_left(int nLeft) { m_xControl->set_margin_left(nLeft); }
 
@@ -296,23 +293,18 @@ void SeriesHeader::SetPos()
 m_spSymbol->set_size_request(aSize.Width(), aSize.Height());
 
 // series name edit field
-aSize.setWidth(nSymbolDistance);
-aSize = m_xDevice->LogicToPixel(aSize, MapMode(MapUnit::MapAppFont));
-m_spSeriesName->set_margin_left(aSize.Width() + 2);
-aSize.setWidth( m_nWidth - nSymbolHeight - nSymbolDistance );
-sal_Int32 nHeight = 12;
-aSize.setHeight( nHeight );
+m_spSeriesName->set_margin_left(2);
+
+aSize.setWidth(nSymbolHeight);
+aSize.setHeight(12);
 aSize = m_xDevice->LogicToPixel(aSize, MapMode(MapUnit::MapAppFont));
+aSize.setWidth(m_nWidth - aSize.Width() - 2);
 m_spSeriesName->set_size_request(aSize.Width(), aSize.Height());
 
 // color bar
-aSize.setWidth(1);
-aSize = m_xDevice->LogicToPixel(aSize, MapMode(MapUnit::MapAppFont));
-m_spColorBar->set_margin_left(aSize.Width() + 2);
-nHeight = 3;
-aSize.setWidth( m_nWidth - 1 );
-aSize.setHeight( nHeight );
+aSize.setHeight(3);
 aSize = m_xDevice->LogicToPixel(aSize, MapMode(MapUnit::MapAppFont));
+aSize.setWidth(m_nWidth);
 m_spColorBar->set_size_request(aSize.Width(), aSize.Height());
 
 auto xVirDev(m_spColorBar->create_virtual_device());
@@ -331,7 +323,7 @@ void SeriesHeader::SetWidth( sal_Int32 nWidth )
 
 void SeriesHeader::SetPixelWidth( sal_Int32 nWidth )
 {
-SetWidth( m_xDevice->PixelToLogic(Size(nWidth, 0), 
MapMode(MapUnit::MapAppFont)).getWidth());
+SetWidth(nWidth);
 }
 
 void SeriesHeader::SetChartType(
@@ -356,16 +348,14 @@ void SeriesHeader::SetRange( sal_Int32 nStartCol, 
sal_Int32 nEndCol )
 
 void SeriesHeader::Show()
 {
-m_spSymbol->show();
-m_spSeriesName->Show();
-m_spColorBar->show();
+m_xContainer1->show();
+m_xContainer2->show();
 }
 
 void SeriesHeader::Hide()
 {
-m_spSymbol->hide();
-m_spSeriesName->Hide();
-m_spColorBar->hide();
+m_xContainer1->hide();
+m_xContainer2->hide();
 }
 
 void SeriesHeader::SetEditChangedHdl( const Link & 
rLink )
@@ -1338,7 +1328,7 @@ void DataBrowser::ImplAdjustHeaderControls()
 {
 if( nStartPos < nMaxPos )
 {
-(*aIt)->SetPixelWidth( nCurrentPos - nStartPos - 3 );
+(*aIt)->SetPixelWidth( nCurrentPos - nStartPos );
 (*aIt)->Show();
 
 if (pWin)
diff --git a/chart2/uiconfig/ui/chartdatadialog.ui 
b/chart2/uiconfig/ui/chartdatadialog.ui
index c48c8f2011bd..c8337d30ca89 100644
--- a/chart2/uiconfig/ui/chartdatadialog.ui
+++ b/chart2/uiconfig/ui/chartdatadialog.ui
@@ -210,18 +210,32 @@
 vertical
 6
 
-  
+  
 True
-False
-True
-
-  
-
+True
+external
+never
 
-  
-
-
-  
+  
+True
+False
+
+  
+True
+False
+True
+
+  

[Libreoffice-commits] core.git: Branch 'libreoffice-6-4' - oox/source sd/qa

2020-09-21 Thread Miklos Vajna (via logerrit)
 oox/source/drawingml/shape.cxx |3 
 oox/source/drawingml/textbodypropertiescontext.cxx |5 
 sd/qa/unit/data/pptx/shape-text-alignment.pptx |binary
 sd/qa/unit/data/xml/n762695_0.xml  |6 -
 sd/qa/unit/data/xml/n762695_1.xml  |   10 -
 sd/qa/unit/data/xml/n819614_0.xml  |  114 ++---
 sd/qa/unit/data/xml/n820786_0.xml  |  102 +-
 sd/qa/unit/data/xml/tdf109317_0.xml|   12 +-
 sd/qa/unit/import-tests.cxx|   21 +++
 9 files changed, 149 insertions(+), 124 deletions(-)

New commits:
commit 55505edc8eca0e4ba30f192e81ff18982b8e2f95
Author: Miklos Vajna 
AuthorDate: Fri Sep 18 17:53:33 2020 +0200
Commit: Xisco Fauli 
CommitDate: Mon Sep 21 23:49:52 2020 +0200

tdf#129685 PPTX import: fix unexpected centering of shape text

Regression from commit 89f0af144c18efafe2573801641689a1432c0cae (tdf#113198 
set
default shape paragraph alignment.., 2019-11-19), the old bugdoc had this
markup:

 (centered)

The new bugdoc has 2 shapes with text:

 (aligned to left)
 (should be centered)

"anchor" is about vertical, "anchorCtr" is about horizontal centering of 
text.

Checking what the binary filter does, it maps horizontal centering to
TextHorizontalAdjust, so fix the original bug differently, by leaving
ParaAdjust alone, and tweaking TextHorizontalAdjust intead: this keeps the 
old
bugdoc working but fixes the new one.

This caused a number of "change detector" XML-based tests to fail: all of 
them
are unchanged visually, so the XML files are adapted to the new state.

The tdf#113198 fix itself was fixing a regression from tdf#104722, and that
commit had no testcase, I tested that we don't regress there, manually.

(cherry picked from commit 10bb02efd8afd42e633e370480104e2575546d8e)

Change-Id: I81a7b3e8c76bfbce5c5569d16d5238958ac20f75
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103088
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
Signed-off-by: Xisco Fauli 
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103110

diff --git a/oox/source/drawingml/shape.cxx b/oox/source/drawingml/shape.cxx
index cce8b9ba7bbc..31ea0c696281 100644
--- a/oox/source/drawingml/shape.cxx
+++ b/oox/source/drawingml/shape.cxx
@@ -214,7 +214,8 @@ void Shape::setDefaults(bool bHeight)
 if (bHeight)
 maDefaultShapeProperties.setProperty(PROP_CharHeight, static_cast< 
float >( 18.0 ));
 maDefaultShapeProperties.setProperty(PROP_TextVerticalAdjust, 
TextVerticalAdjust_TOP);
-maDefaultShapeProperties.setProperty(PROP_ParaAdjust, static_cast< 
sal_Int16 >( ParagraphAdjust_CENTER ));
+maDefaultShapeProperties.setProperty(PROP_ParaAdjust,
+ 
static_cast(ParagraphAdjust_LEFT));
 }
 
 ::oox::vml::OleObjectInfo& Shape::setOleObjectType()
diff --git a/oox/source/drawingml/textbodypropertiescontext.cxx 
b/oox/source/drawingml/textbodypropertiescontext.cxx
index d696b4c3ac70..af02c6f981d8 100644
--- a/oox/source/drawingml/textbodypropertiescontext.cxx
+++ b/oox/source/drawingml/textbodypropertiescontext.cxx
@@ -123,6 +123,11 @@ TextBodyPropertiesContext::TextBodyPropertiesContext( 
ContextHandler2Helper cons
 {
 mrTextBodyProp.meVA = GetTextVerticalAdjust( rAttribs.getToken( 
XML_anchor, XML_t ) );
 mrTextBodyProp.maPropertyMap.setProperty( PROP_TextVerticalAdjust, 
mrTextBodyProp.meVA);
+if (mrTextBodyProp.meVA == drawing::TextVerticalAdjust_CENTER)
+{
+mrTextBodyProp.maPropertyMap.setProperty(PROP_TextHorizontalAdjust,
+ 
TextHorizontalAdjust_CENTER);
+}
 }
 
 // Push defaults
diff --git a/sd/qa/unit/data/pptx/shape-text-alignment.pptx 
b/sd/qa/unit/data/pptx/shape-text-alignment.pptx
new file mode 100644
index ..ff4ff06f2fdf
Binary files /dev/null and b/sd/qa/unit/data/pptx/shape-text-alignment.pptx 
differ
diff --git a/sd/qa/unit/data/xml/n762695_0.xml 
b/sd/qa/unit/data/xml/n762695_0.xml
index 710a5039ab69..fe02e3f00d0d 100644
--- a/sd/qa/unit/data/xml/n762695_0.xml
+++ b/sd/qa/unit/data/xml/n762695_0.xml
@@ -1,6 +1,6 @@
 
 
- 
+ 
   
   
   
@@ -86,7 +86,7 @@

   
  
- 
+ 
   
   
   
@@ -163,7 +163,7 @@

   
  
- 
+ 
   
   
   
diff --git a/sd/qa/unit/data/xml/n762695_1.xml 
b/sd/qa/unit/data/xml/n762695_1.xml
index 54b383db40a8..587d22ab2a56 100644
--- a/sd/qa/unit/data/xml/n762695_1.xml
+++ b/sd/qa/unit/data/xml/n762695_1.xml
@@ -1,6 +1,6 @@
 
 
- 
+ 
   
   
   
@@ -86,7 +86,7 @@

   
  
- 
+ 
   
   
   
@@ -172,7 +172,7 @@

   
  
- 
+ 
   
   
   
@@ -325,7 +325,7 @@

   
  
- 
+ 
   
   
   
@@ -478,7 +478,7 @@

   
  
- 
+ 
   
   
   
diff --git a/sd/qa/unit/data/xml/n819614_0.xml 
b/sd/qa/unit/data/xml/n81961

[Libreoffice-commits] core.git: Branch 'libreoffice-6-4' - sc/uiconfig

2020-09-21 Thread Xisco Fauli (via logerrit)
 sc/uiconfig/scalc/ui/searchresults.ui |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 38e0b926203262d90e4ec9b33860416b4074ba63
Author: Xisco Fauli 
AuthorDate: Tue Aug 11 00:21:37 2020 +0200
Commit: Xisco Fauli 
CommitDate: Mon Sep 21 23:49:16 2020 +0200

tdf#131047: expand search results frame

Change-Id: I883c86658f3aa4ee18d03d8c3aa277000f278abe
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100362
Tested-by: Jenkins
Reviewed-by: Adolfo Jayme Barrientos 
(cherry picked from commit bc652f68d988a6fd0e2feb51b0e3ccfee31e6693)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100510
Reviewed-by: Xisco Fauli 

diff --git a/sc/uiconfig/scalc/ui/searchresults.ui 
b/sc/uiconfig/scalc/ui/searchresults.ui
index ca56a9950a7f..645aa3aa64a7 100644
--- a/sc/uiconfig/scalc/ui/searchresults.ui
+++ b/sc/uiconfig/scalc/ui/searchresults.ui
@@ -141,7 +141,7 @@
 
   
   
-False
+True
 True
 1
   
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-6-4' - sdext/source

2020-09-21 Thread Mike Kaganski (via logerrit)
 sdext/source/minimizer/fileopendialog.cxx |8 +---
 1 file changed, 5 insertions(+), 3 deletions(-)

New commits:
commit 20e557dc730d66453d32f9268381274c268cabd4
Author: Mike Kaganski 
AuthorDate: Sun Aug 16 18:58:48 2020 +0300
Commit: Xisco Fauli 
CommitDate: Mon Sep 21 23:48:37 2020 +0200

tdf#135342: filter list must include extensions

Regression after commit a0dcc8f78061d22d925f31ef8d03ca751ad6dc19.
The commit had added extensions to the filter names sent to file
dialog, but kept internal list of filter names aFilterEntryList
without extensions. Then dialog returned the chosen filter's name
in the form it was sent there, i.e. with extension; and that name
couldn't be found in aFilterEntryList.

So let's keep aFilterEntryList synchronized with the UI names in
the dialog.

Change-Id: Ic21d19d1a8d0b7f64ccfb517a7d0ee8ab36fc6a8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100821
Tested-by: Jenkins
Reviewed-by: Mike Kaganski 
(cherry picked from commit 99c6c89deed41457d35c382fc7d6a4cd5191f7d7)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100792
Reviewed-by: Caolán McNamara 
(cherry picked from commit bbd0d424263a21dd0ffdc42d1201f86e65358f25)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101671
Reviewed-by: Xisco Fauli 

diff --git a/sdext/source/minimizer/fileopendialog.cxx 
b/sdext/source/minimizer/fileopendialog.cxx
index 68f25f77900a..aab29c03907b 100644
--- a/sdext/source/minimizer/fileopendialog.cxx
+++ b/sdext/source/minimizer/fileopendialog.cxx
@@ -106,7 +106,7 @@ FileOpenDialog::FileOpenDialog( const Reference< 
XComponentContext >& rxContext
 Reference< XNameAccess > xTypes( 
rxContext->getServiceManager()->createInstanceWithContext(
 "com.sun.star.document.TypeDetection", rxContext ), UNO_QUERY_THROW );
 
-for( const auto& rFilterEntry : aFilterEntryList )
+for (auto& rFilterEntry : aFilterEntryList)
 {
 Sequence< PropertyValue > aTypeProperties;
 try
@@ -120,10 +120,12 @@ FileOpenDialog::FileOpenDialog( const Reference< 
XComponentContext >& rxContext
 pProp->Value >>= aExtensions;
 if ( aExtensions.hasElements() )
 {
-// The filter title must be formed in the same way it is
-// currently done in the internal implementation:
+// The filter title must be formed in the same way it is 
currently done in the
+// internal implementation (see 
sfx2::appendFiltersForSave). And we will look
+// for the same string returned from the dialog, so save 
it to maUIName:
 OUString aTitle(
 rFilterEntry.maUIName + " (." + aExtensions[0] + ")");
+rFilterEntry.maUIName = aTitle;
 OUString aFilter("*." + aExtensions[0]);
 mxFilePicker->appendFilter(aTitle, aFilter);
 if ( rFilterEntry.maFlags & 0x100 )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'private/tvajngerl/staging' - include/sfx2 officecfg/registry sfx2/Library_sfx.mk sfx2/sdi sfx2/source sfx2/uiconfig sfx2/UIConfig_sfx.mk

2020-09-21 Thread Tomaž Vajngerl (via logerrit)
 include/sfx2/sfxsids.hrc |2 
 officecfg/registry/data/org/openoffice/Office/Accelerators.xcu   |6 
 officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu |8 
 sfx2/Library_sfx.mk  |1 
 sfx2/UIConfig_sfx.mk |1 
 sfx2/sdi/frmslots.sdi|6 
 sfx2/sdi/sfx.sdi |   17 
 sfx2/source/view/CommandPopup.cxx|  220 
++
 sfx2/source/view/CommandPopup.hxx|   81 +++
 sfx2/source/view/viewfrm.cxx |   22 -
 sfx2/uiconfig/ui/commandpopup.ui |   78 +++
 11 files changed, 439 insertions(+), 3 deletions(-)

New commits:
commit 860ac13905df486b45e0a13a391be227256f0b64
Author: Tomaž Vajngerl 
AuthorDate: Tue May 22 14:44:39 2018 +0900
Commit: Tomaž Vajngerl 
CommitDate: Mon Sep 21 22:47:47 2020 +0200

Command Popup

Change-Id: I92cdd3130b8de42ee0863c9e7154e7c7246d9377

diff --git a/include/sfx2/sfxsids.hrc b/include/sfx2/sfxsids.hrc
index 88d708e4cb98..7cf9ccc52ce0 100644
--- a/include/sfx2/sfxsids.hrc
+++ b/include/sfx2/sfxsids.hrc
@@ -382,7 +382,7 @@ class SvxSearchItem;
 
 // default-ids for windows
 
-// free (SID_SFX_START + 610)
+#define SID_COMMAND_POPUP   (SID_SFX_START + 610)
 #define SID_NEWWINDOW   (SID_SFX_START + 620)
 #define SID_CLOSEWIN(SID_SFX_START + 621)
 #define SID_VIEWSHELL   (SID_SFX_START + 623)
diff --git a/officecfg/registry/data/org/openoffice/Office/Accelerators.xcu 
b/officecfg/registry/data/org/openoffice/Office/Accelerators.xcu
index b8a46cfc035a..2db3f82fc808 100644
--- a/officecfg/registry/data/org/openoffice/Office/Accelerators.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/Accelerators.xcu
@@ -313,6 +313,12 @@ Ctrl+Shift+e aka E_SHIFT_MOD1 under GTK/IBUS is for some 
emoji thing
   .uno:OptionsTreeDialog
 
   
+  
+
+  I10N SHORTCUTS - NO 
TRANSLATE
+  .uno:CommandPopup
+
+  
 
 
   
diff --git 
a/officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu 
b/officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu
index 3212c283a6b3..c8b8def77cd1 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu
@@ -6496,6 +6496,14 @@
   1
 
   
+  
+
+  Command Popup
+
+
+  1
+
+  
 
 
   
diff --git a/sfx2/Library_sfx.mk b/sfx2/Library_sfx.mk
index cb0b099eb37d..4c7d994de08d 100644
--- a/sfx2/Library_sfx.mk
+++ b/sfx2/Library_sfx.mk
@@ -296,6 +296,7 @@ $(eval $(call gb_Library_add_exception_objects,sfx,\
 sfx2/source/styles/StyleManager \
 sfx2/source/toolbox/tbxitem \
 sfx2/source/toolbox/weldutils \
+sfx2/source/view/CommandPopup \
 sfx2/source/view/classificationcontroller \
 sfx2/source/view/classificationhelper \
 sfx2/source/view/frame \
diff --git a/sfx2/UIConfig_sfx.mk b/sfx2/UIConfig_sfx.mk
index 5e79a8399cbf..aabfffa53cb1 100644
--- a/sfx2/UIConfig_sfx.mk
+++ b/sfx2/UIConfig_sfx.mk
@@ -21,6 +21,7 @@ $(eval $(call gb_UIConfig_add_uifiles,sfx,\
sfx2/uiconfig/ui/classificationbox \
sfx2/uiconfig/ui/cmisinfopage \
sfx2/uiconfig/ui/cmisline \
+   sfx2/uiconfig/ui/commandpopup \
sfx2/uiconfig/ui/custominfopage \
sfx2/uiconfig/ui/descriptioninfopage \
sfx2/uiconfig/ui/dockingwindow \
diff --git a/sfx2/sdi/frmslots.sdi b/sfx2/sdi/frmslots.sdi
index 09aafef95b7d..a7c8a472e73d 100644
--- a/sfx2/sdi/frmslots.sdi
+++ b/sfx2/sdi/frmslots.sdi
@@ -262,6 +262,11 @@ interface TopWindow : BrowseWindow
 ExecMethod = MiscExec_Impl ;
 StateMethod = MiscState_Impl ;
 ]
+SID_COMMAND_POPUP
+[
+ExecMethod = MiscExec_Impl ;
+StateMethod = MiscState_Impl ;
+]
 SID_CLOSEWIN // ole(no) api(final/play/rec)
 [
 ExecMethod = Exec_Impl ;
@@ -307,4 +312,3 @@ shell SfxViewFrame
 StateMethod = GetState_Impl ;
 ]
 }
-
diff --git a/sfx2/sdi/sfx.sdi b/sfx2/sdi/sfx.sdi
index a50b5f1a17a6..813ef070c978 100644
--- a/sfx2/sdi/sfx.sdi
+++ b/sfx2/sdi/sfx.sdi
@@ -1271,6 +1271,23 @@ SfxStringItem FullName SID_DOCFULLNAME
 GroupId = ;
 ]
 
+SfxVoidItem CommandPopup SID_COMMAND_POPUP
+[
+AutoUpdate = TRUE,
+FastCall = FALSE,
+ReadOnlyDoc = TRUE,
+Toggle = FALSE,
+Container = TRUE,
+RecordAbsolute = FALSE,
+RecordPerSet;
+Asynchron;
+
+
+AccelConfig = TRUE,
+MenuConfig = TRUE,
+ToolBoxConfig =

[Libreoffice-commits] core.git: compilerplugins/clang include/rtl

2020-09-21 Thread Stephan Bergmann (via logerrit)
 compilerplugins/clang/unusedmember.cxx |   25 +
 include/rtl/string.hxx |   21 +
 include/rtl/ustring.hxx|   20 
 3 files changed, 58 insertions(+), 8 deletions(-)

New commits:
commit 52a49f9e480ca03e231cfda82640a928393131c9
Author: Stephan Bergmann 
AuthorDate: Mon Sep 21 21:01:40 2020 +0200
Commit: Stephan Bergmann 
CommitDate: Mon Sep 21 22:29:31 2020 +0200

static_assert that O[U]StringLiteral are layout compatible with 
rtl_[u]String

...as was suggested by Mike Kaganski in a comment at
 "Turn OUStringLiteral 
into a
consteval'ed, static-refcound rtl_uString".  Doing so revealed that at least
lopglugin:unusedmember needs to handle InjectedClassNameType as an 
alternative
to RecordType in at least one place.  (More places across compilerplugins 
might
benefit from handling InjectedClassNameType too, but which did not lead to
assertion failures for now and should be addressed in follow-up issues.)

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

diff --git a/compilerplugins/clang/unusedmember.cxx 
b/compilerplugins/clang/unusedmember.cxx
index a32fd341c665..1d3017134892 100644
--- a/compilerplugins/clang/unusedmember.cxx
+++ b/compilerplugins/clang/unusedmember.cxx
@@ -240,7 +240,17 @@ public:
 {
 return true;
 }
-
recordRecordDeclAndBases(expr->getTypeSourceInfo()->getType()->castAs());
+auto const t1 = expr->getTypeSourceInfo()->getType();
+RecordDecl const* d;
+if (auto const t2 = t1->getAs())
+{
+d = t2->getDecl();
+}
+else
+{
+d = t1->castAs()->getDecl();
+}
+recordRecordDeclAndBases(d);
 return true;
 }
 
@@ -276,7 +286,7 @@ public:
 }
 if (auto const t1 = t->getAs())
 {
-recordRecordDeclAndBases(t1);
+recordRecordDeclAndBases(t1->getDecl());
 }
 return true;
 }
@@ -406,18 +416,17 @@ private:
 return t.isTrivialType(compiler.getASTContext()) || 
isWarnUnusedType(t);
 }
 
-void recordRecordDeclAndBases(RecordType const* type)
+void recordRecordDeclAndBases(RecordDecl const* decl)
 {
-auto const d1 = type->getDecl();
-if (!layout_.insert(d1->getCanonicalDecl()).second)
+if (!layout_.insert(decl->getCanonicalDecl()).second)
 {
 return;
 }
-if (auto const d2 = 
dyn_cast_or_null(d1->getDefinition()))
+if (auto const d2 = 
dyn_cast_or_null(decl->getDefinition()))
 {
 for (auto i = d2->bases_begin(); i != d2->bases_end(); ++i)
 {
-recordRecordDeclAndBases(i->getType()->castAs());
+
recordRecordDeclAndBases(i->getType()->castAs()->getDecl());
 }
 //TODO: doesn't iterate vbases, but presence of such would run 
counter to the layout
 // heuristic anyway
@@ -435,7 +444,7 @@ private:
 }
 if (auto const t1 = t->getAs())
 {
-recordRecordDeclAndBases(t1);
+recordRecordDeclAndBases(t1->getDecl());
 }
 break;
 }
diff --git a/include/rtl/string.hxx b/include/rtl/string.hxx
index 7086de15c987..fd65e2dfa477 100644
--- a/include/rtl/string.hxx
+++ b/include/rtl/string.hxx
@@ -24,6 +24,7 @@
 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -32,6 +33,7 @@
 
 #if defined LIBO_INTERNAL_ONLY
 #include 
+#include 
 #endif
 
 #include "rtl/textenc.h"
@@ -114,12 +116,31 @@ public:
 
 constexpr char const * getStr() const SAL_RETURNS_NONNULL { return buffer; 
}
 
+// offsetof needs a complete type, so do not have these static_asserts as 
class template
+// members, but postpone their instantiation to the later non-member 
static_assert that calls
+// detail_assertLayout:
+static constexpr bool detail_assertLayout() {
+static_assert(offsetof(OStringLiteral, refCount) == 
offsetof(rtl_String, refCount));
+static_assert(
+std::is_same_v);
+static_assert(offsetof(OStringLiteral, length) == offsetof(rtl_String, 
length));
+static_assert(std::is_same_v);
+static_assert(offsetof(OStringLiteral, buffer) == offsetof(rtl_String, 
buffer));
+static_assert(
+std::is_same_v<
+std::remove_extent_t,
+std::remove_extent_t>);
+return true;
+}
+
 private:
 // Same layout as rtl_String (include/rtl/string.h):
 oslInterlockedCount refCount = 0x4000; // SAL_STRING_STATIC_FLAG 
(sal/rtl/strimp.hxx)
 sal_Int32

[Libreoffice-commits] core.git: include/rtl

2020-09-21 Thread Stephan Bergmann (via logerrit)
 include/rtl/string.hxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit e79a6a5270d190d6e89a6acf08e22419386d2117
Author: Stephan Bergmann 
AuthorDate: Mon Sep 21 20:48:56 2020 +0200
Commit: Stephan Bergmann 
CommitDate: Mon Sep 21 22:15:56 2020 +0200

No need to make the OString(std::string_view) ctor explicit


"Make std::u16string_view -> OUString construction explicit" (which has
meanwhile been abandoned) had intended to make the 
OUString(std::u16string_view)
ctor explicit, mostly not for the rationale given in the commit message 
there
(it being "a rather expensive operation"), but rather to avoid anticipated
ambiguity issues when introducing e6dfaf9f44f9939abc338c83b3024108431d0f69 
"Turn
OUStringLiteral into a consteval'ed, static-refcound rtl_uString"---but 
which
has ultimately been added in a form that did not give rise to such ambiguity
issues after all.

4b9e440c51be3e40326bc90c33ae69885bfb51e4 "Turn OStringLiteral into a
consteval'ed, static-refcound rtl_String" had added the
OString(std::string_view) ctor as explicit to match the corresponding 
explicit
OUString(std::u16string_view) from the above
.  But as that has now been
abandoned, there is no good reason to keep this ctor explicit, either.

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

diff --git a/include/rtl/string.hxx b/include/rtl/string.hxx
index e59ffba83a62..7086de15c987 100644
--- a/include/rtl/string.hxx
+++ b/include/rtl/string.hxx
@@ -304,7 +304,7 @@ public:
 #endif
 
 #if defined LIBO_INTERNAL_ONLY
-explicit OString(std::string_view sv) {
+OString(std::string_view sv) {
 if (sv.size() > sal_uInt32(std::numeric_limits::max())) {
 throw std::bad_alloc();
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: config_host/config_qrcodegen.h.in config_host.mk.in configure.ac cui/source distro-configs/LibreOfficeOssFuzz.conf external/qrcodegen RepositoryExternal.mk

2020-09-21 Thread Caolán McNamara (via logerrit)
 RepositoryExternal.mk  |9 +
 config_host.mk.in  |1 
 config_host/config_qrcodegen.h.in  |   17 ++
 configure.ac   |   52 ++---
 cui/source/dialogs/QrCodeGenDialog.cxx |   21 +++--
 distro-configs/LibreOfficeOssFuzz.conf |1 
 external/qrcodegen/Module_qrcodegen.mk |4 ++
 7 files changed, 85 insertions(+), 20 deletions(-)

New commits:
commit a2791a8b0de05cec8a94b5bd19a6ff6ee4fd76c5
Author: Caolán McNamara 
AuthorDate: Mon Sep 21 17:02:31 2020 +0100
Commit: Caolán McNamara 
CommitDate: Mon Sep 21 21:39:27 2020 +0200

add an explicit --disable-qrcodegen configure option

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

diff --git a/RepositoryExternal.mk b/RepositoryExternal.mk
index 1a4acbb80437..19421d4df8d4 100644
--- a/RepositoryExternal.mk
+++ b/RepositoryExternal.mk
@@ -4191,6 +4191,8 @@ gb_ExternalProject__use_qrcodegen :=
 
 else # !SYSTEM_QRCODEGEN
 
+ifneq ($(ENABLE_QRCODEGEN),)
+
 define gb_LinkTarget__use_qrcodegen
 $(call gb_LinkTarget_use_unpacked,$(1),qrcodegen)
 $(call gb_LinkTarget_set_include,$(1),\
@@ -4208,6 +4210,13 @@ $(call 
gb_ExternalProject_use_static_libraries,$(1),qrcodegen)
 
 endef
 
+else # !ENABLE_QRCODEGEN
+
+define gb_LinkTarget__use_qrcodegen
+endef
+
+endif # ENABLE_QRCODEGEN
+
 endif # SYSTEM_QRCODEGEN
 
 define gb_LinkTarget__use_dtoa
diff --git a/config_host.mk.in b/config_host.mk.in
index 182a80069074..41a3f76c2b44 100644
--- a/config_host.mk.in
+++ b/config_host.mk.in
@@ -501,6 +501,7 @@ export PYTHON_VERSION=@PYTHON_VERSION@
 export PYTHON_VERSION_MAJOR=@PYTHON_VERSION_MAJOR@
 export PYTHON_VERSION_MINOR=@PYTHON_VERSION_MINOR@
 export PYTHONWARNINGS=@PYTHONWARNINGS@
+export ENABLE_QRCODEGEN=@ENABLE_QRCODEGEN@
 export QRCODEGEN_CFLAGS=$(gb_SPACE)@QRCODEGEN_CFLAGS@
 export QRCODEGEN_LIBS=$(gb_SPACE)@QRCODEGEN_LIBS@
 export QT5_CFLAGS=$(gb_SPACE)@QT5_CFLAGS@
diff --git a/config_host/config_qrcodegen.h.in 
b/config_host/config_qrcodegen.h.in
new file mode 100644
index ..63388651699f
--- /dev/null
+++ b/config_host/config_qrcodegen.h.in
@@ -0,0 +1,17 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#ifndef INCLUDED_CONFIG_QRCODEGEN_H
+#define INCLUDED_CONFIG_QRCODEGEN_H
+
+#define ENABLE_QRCODEGEN 0
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/configure.ac b/configure.ac
index 30a2f3c13d36..a8c2e37a726c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2034,6 +2034,10 @@ AC_ARG_WITH(system-hunspell,
 [Use libhunspell already on system.]),,
 [with_system_hunspell="$with_system_libs"])
 
+libo_FUZZ_ARG_ENABLE(qrcodegen,
+AS_HELP_STRING([--disable-qrcodegen],
+[Disable use of qrcodegen external library.]))
+
 AC_ARG_WITH(system-qrcodegen,
 AS_HELP_STRING([--with-system-qrcodegen],
 [Use libqrcodegen already on system.]),,
@@ -10536,26 +10540,39 @@ AC_SUBST(HUNSPELL_LIBS)
 dnl ===
 dnl Check for system qrcodegen
 dnl ===
-AC_MSG_CHECKING([which libqrcodegen to use])
-if test "$with_system_qrcodegen" = "yes"; then
-AC_MSG_RESULT([external])
-SYSTEM_QRCODEGEN=TRUE
-AC_LANG_PUSH([C++])
-AC_CHECK_HEADER(qrcodegen/QrCode.hpp, [],
-[AC_MSG_ERROR(qrcodegen headers not found.)], [#include ])
-AC_CHECK_LIB([qrcodegencpp], [main], [:],
-[ AC_MSG_ERROR(qrcodegen C++ library not found.) ], [])
-QRCODEGEN_LIBS=-lqrcodegencpp
-AC_LANG_POP([C++])
-QRCODEGEN_CFLAGS=$(printf '%s' "$QRCODEGEN_CFLAGS" | sed -e 
"s/-I/${ISYSTEM?}/g")
-FilterLibs "${QRCODEGEN_LIBS}"
-QRCODEGEN_LIBS="${filteredlibs}"
-else
-AC_MSG_RESULT([internal])
+AC_MSG_CHECKING([whether to use libqrcodegen])
+if test "$enable_libqrcodegen" = "no"; then
+AC_MSG_RESULT([no])
+ENABLE_QRCODEGEN=
 SYSTEM_QRCODEGEN=
-BUILD_TYPE="$BUILD_TYPE QRCODEGEN"
+else
+AC_MSG_RESULT([yes])
+ENABLE_QRCODEGEN=TRUE
+AC_MSG_CHECKING([which libqrcodegen to use])
+if test "$with_system_qrcodegen" = "yes"; then
+AC_MSG_RESULT([external])
+SYSTEM_QRCODEGEN=TRUE
+AC_LANG_PUSH([C++])
+AC_CHECK_HEADER(qrcodegen/QrCode.hpp, [],
+[AC_MSG_ERROR(qrcodegen headers not found.)], [#include 
])
+AC_CHECK_LIB([qrcodegencpp], [main], [:],
+[ AC_MSG_ERROR(qrcodegen C++ library not found.) ], [])
+QRCODEGEN_LIBS=-lqrcodegencpp
+

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

2020-09-21 Thread Caolán McNamara (via logerrit)
 sfx2/uiconfig/ui/charmapcontrol.ui |6 +-
 1 file changed, 5 insertions(+), 1 deletion(-)

New commits:
commit c4cd874c4ea7140e03fbcd2d853a5b8b680afaad
Author: Caolán McNamara 
AuthorDate: Mon Sep 21 17:34:40 2020 +0100
Commit: Caolán McNamara 
CommitDate: Mon Sep 21 21:19:46 2020 +0200

tdf#136781 add some spacing to the special character favorites

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

diff --git a/sfx2/uiconfig/ui/charmapcontrol.ui 
b/sfx2/uiconfig/ui/charmapcontrol.ui
index 20b37841a8c5..f3ba26ccc33d 100644
--- a/sfx2/uiconfig/ui/charmapcontrol.ui
+++ b/sfx2/uiconfig/ui/charmapcontrol.ui
@@ -1,5 +1,5 @@
 
-
+
 
   
   
@@ -30,6 +30,8 @@
 True
 False
 start
+3
+3
 
   
 35
@@ -268,6 +270,8 @@
 True
 False
 start
+3
+3
 
   
 35
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Samuel Mehrbrodt (via logerrit)
 sw/source/core/crsr/crstrvl.cxx  |2 +-
 sw/source/core/txtnode/ndtxt.cxx |2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 1d51724adc5719e440ca0b457c80c161d8ca04c8
Author: Samuel Mehrbrodt 
AuthorDate: Thu Aug 20 15:33:49 2020 +0200
Commit: Thorsten Behrens 
CommitDate: Mon Sep 21 20:53:14 2020 +0200

Related tdf#100492 Detect click into empty field

Change-Id: Ic2937d619a8361b9d17b7dfa16698a5005f34ec6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101076
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt 
(cherry picked from commit 2c7bf3543ab798d1c117d9f3258467e4aef9a8db)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103108
Tested-by: Thorsten Behrens 
Reviewed-by: Thorsten Behrens 

diff --git a/sw/source/core/crsr/crstrvl.cxx b/sw/source/core/crsr/crstrvl.cxx
index 9153b8b34e85..7df0ce6ff323 100644
--- a/sw/source/core/crsr/crstrvl.cxx
+++ b/sw/source/core/crsr/crstrvl.cxx
@@ -949,7 +949,7 @@ bool SwCursorShell::CursorInsideInputField() const
 {
 for(SwPaM& rCursor : GetCursor()->GetRingContainer())
 {
-if (dynamic_cast(GetTextFieldAtCursor(&rCursor, false)))
+if (dynamic_cast(GetTextFieldAtCursor(&rCursor, true)))
 return true;
 }
 return false;
diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx
index 3d721ebee00b..28cb96d2c71b 100644
--- a/sw/source/core/txtnode/ndtxt.cxx
+++ b/sw/source/core/txtnode/ndtxt.cxx
@@ -1788,7 +1788,7 @@ SwTextField* SwTextNode::GetFieldTextAttrAt(
 dynamic_cast( GetTextAttrAt(
 nIndex,
 RES_TXTATR_INPUTFIELD,
-bIncludeInputFieldAtStart ? DEFAULT : PARENT ));
+bIncludeInputFieldAtStart ? DEFAULT : EXPAND ));
 }
 
 return pTextField;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread DaeHyun Sung (via logerrit)
 extras/source/autocorr/lang/ko/DocumentList.xml |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 23a5911a67269dcdf02042e0b7e8b187085301a7
Author: DaeHyun Sung 
AuthorDate: Mon Aug 17 15:42:17 2020 +0900
Commit: Adolfo Jayme Barrientos 
CommitDate: Mon Sep 21 20:48:05 2020 +0200

tdf#135727 add Korean auto correct word

add Korean auto correct word
새벽녁 -> 새벽녘

Change-Id: I9b1829c0dd09c420e3ba80ae4231ba2ca08b3e4b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100842
Tested-by: Jenkins
Reviewed-by: DaeHyun Sung 
Reviewed-by: Adolfo Jayme Barrientos 

diff --git a/extras/source/autocorr/lang/ko/DocumentList.xml 
b/extras/source/autocorr/lang/ko/DocumentList.xml
index 9710a1bc0f65..9cd275c1020b 100644
--- a/extras/source/autocorr/lang/ko/DocumentList.xml
+++ b/extras/source/autocorr/lang/ko/DocumentList.xml
@@ -2360,6 +2360,7 @@
   
   
   
+  
   
   
   
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread DaeHyun Sung (via logerrit)
 extras/source/autocorr/lang/ko/DocumentList.xml |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 6e4a5e73bfd22a2410b960132c2702a6597ce6fb
Author: DaeHyun Sung 
AuthorDate: Sun Aug 16 13:11:27 2020 +0900
Commit: Adolfo Jayme Barrientos 
CommitDate: Mon Sep 21 20:48:24 2020 +0200

tdf#135727 add Korean Autocorrect list

Add Korean Auto Correst list
가운대 -> 가운데

Change-Id: Ibbb2c871b5c46cad094e51b49c99aa47a8d50b9b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100812
Tested-by: Jenkins
Reviewed-by: DaeHyun Sung 
Reviewed-by: Adolfo Jayme Barrientos 

diff --git a/extras/source/autocorr/lang/ko/DocumentList.xml 
b/extras/source/autocorr/lang/ko/DocumentList.xml
index 9cd275c1020b..2215c712fcbe 100644
--- a/extras/source/autocorr/lang/ko/DocumentList.xml
+++ b/extras/source/autocorr/lang/ko/DocumentList.xml
@@ -2328,6 +2328,7 @@
   
   
   
+  
   
   
   
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Gabor Kelemen (via logerrit)
 cui/uiconfig/ui/qrcodegen.ui |   26 ++
 1 file changed, 22 insertions(+), 4 deletions(-)

New commits:
commit a27f9de5f738b245ef2534e6a3fb0e7d3393bc04
Author: Gabor Kelemen 
AuthorDate: Fri Aug 7 22:03:18 2020 +0200
Commit: Adolfo Jayme Barrientos 
CommitDate: Mon Sep 21 20:45:13 2020 +0200

tdf#119931 fix a11y warnings in qrcodegen.ui

Change-Id: I7cc6f8edf6ab8d0e1b2a8c6a39e6e7b5c9ada565
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100371
Tested-by: Jenkins
Reviewed-by: Adolfo Jayme Barrientos 

diff --git a/cui/uiconfig/ui/qrcodegen.ui b/cui/uiconfig/ui/qrcodegen.ui
index f33b74557182..a9ff084fae17 100644
--- a/cui/uiconfig/ui/qrcodegen.ui
+++ b/cui/uiconfig/ui/qrcodegen.ui
@@ -1,5 +1,5 @@
 
-
+
 
   
   
@@ -16,9 +16,6 @@
 0
 0
 dialog
-
-  
-
 
   
 False
@@ -171,6 +168,12 @@
 Error Correction:
 True
 0
+
+  
+  
+  
+  
+
   
   
 0
@@ -217,6 +220,9 @@
 0
 True
 True
+
+  
+
 
   
 7% of codewords can be restored.
@@ -239,6 +245,9 @@
 True
 True
 button_low
+
+  
+
 
   
 15% of codewords can be restored.
@@ -261,6 +270,9 @@
 True
 True
 button_low
+
+  
+
 
   
 25% of codewords can be restored.
@@ -283,6 +295,9 @@
 True
 True
 button_low
+
+  
+
 
   
 30% of codewords can be restored.
@@ -334,6 +349,9 @@
   ok
   help
 
+
+  
+
 
   
 Generate QR Code for any text or URL.
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: Branch 'distro/collabora/co-4-2' - loleaflet/src

2020-09-21 Thread mert (via logerrit)
 loleaflet/src/map/handler/Map.TouchGesture.js |   15 +--
 1 file changed, 13 insertions(+), 2 deletions(-)

New commits:
commit 49447ec08c5d3904028e77a0f8f596571ab8a05b
Author: mert 
AuthorDate: Wed Sep 16 17:31:46 2020 +0300
Commit: Andras Timar 
CommitDate: Mon Sep 21 20:29:08 2020 +0200

Fix pinch gesture causes hammer to stuck on Mobile

Change-Id: If0ae311346ae9c9935ebacde3bc5ea874833
Signed-off-by: mert 
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/102873
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Andras Timar 
(cherry picked from commit c43aeb3e35a99c2f35bb817037d2451dc8731ae5)
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/103057

diff --git a/loleaflet/src/map/handler/Map.TouchGesture.js 
b/loleaflet/src/map/handler/Map.TouchGesture.js
index 677d15dec..cd22175a5 100644
--- a/loleaflet/src/map/handler/Map.TouchGesture.js
+++ b/loleaflet/src/map/handler/Map.TouchGesture.js
@@ -53,9 +53,20 @@ L.Map.TouchGesture = L.Handler.extend({
var tripleTap = new Hammer.Tap({event: 'tripletap', 
taps: 3, posThreshold: posThreshold });
this._hammer.add(tripleTap);
tripleTap.recognizeWith([doubleTap, singleTap]);
-
+   var hammer = this._hammer;
if (L.Browser.touch) {
-   L.DomEvent.on(this._map._mapPane, 'touchstart 
touchmove touchend touchcancel', L.DomEvent.preventDefault);
+   L.DomEvent.on(this._map._mapPane, 'touchstart 
touchmove touchcancel', L.DomEvent.preventDefault);
+   L.DomEvent.on(this._map._mapPane, 'touchend', 
function(e) {
+   // sometimes inputs get stuck in hammer 
and further events get mixed with the old ones
+   // this causes to a failure to use all 
the gestures properly.
+   // This is a workaround until it is 
fixed by hammer.js
+   if (hammer.input) {
+   if (hammer.input.store)  {
+   hammer.input.store = [];
+   }
+   }
+   L.DomEvent.preventDefault(e);
+   });
}
 
if (Hammer.prefixed(window, 'PointerEvent') !== 
undefined) {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: basic/inc chart2/inc connectivity/inc cppcanvas/inc cppuhelper/inc cui/inc dbaccess/inc desktop/inc drawinglayer/inc emfio/inc external/liborcus external/pdfium framewo

2020-09-21 Thread Caolán McNamara (via logerrit)
 basic/inc/pch/precompiled_sb.hxx   |3 ++-
 chart2/inc/pch/precompiled_chartcore.hxx   |3 ++-
 connectivity/inc/pch/precompiled_ado.hxx   |2 +-
 cppcanvas/inc/pch/precompiled_cppcanvas.hxx|3 +--
 cppuhelper/inc/pch/precompiled_cppuhelper.hxx  |3 ++-
 cui/inc/pch/precompiled_cui.hxx|3 +--
 dbaccess/inc/pch/precompiled_dba.hxx   |3 +--
 desktop/inc/pch/precompiled_deploymentmisc.hxx |3 +--
 drawinglayer/inc/pch/precompiled_drawinglayer.hxx  |4 +++-
 emfio/inc/pch/precompiled_emfio.hxx|5 -
 external/liborcus/inc/pch/precompiled_orcus-parser.hxx |3 ++-
 external/liborcus/inc/pch/precompiled_orcus.hxx|3 ++-
 external/pdfium/inc/pch/precompiled_pdfium.hxx |4 ++--
 framework/inc/pch/precompiled_fwk.hxx  |3 ++-
 sc/inc/pch/precompiled_scui.hxx|4 +++-
 sc/inc/pch/precompiled_vbaobj.hxx  |3 ++-
 sd/inc/pch/precompiled_sd.hxx  |3 ++-
 sd/inc/pch/precompiled_sdui.hxx|4 +++-
 svtools/inc/pch/precompiled_svt.hxx|3 ++-
 svx/inc/pch/precompiled_svxcore.hxx|6 --
 sw/inc/pch/precompiled_swui.hxx|4 +++-
 unotools/inc/pch/precompiled_utl.hxx   |3 ++-
 uui/inc/pch/precompiled_uui.hxx|3 +--
 vcl/inc/pch/precompiled_vcl.hxx|3 ++-
 writerfilter/inc/pch/precompiled_writerfilter.hxx  |3 ++-
 xmlsecurity/inc/pch/precompiled_xsec_xmlsec.hxx|2 +-
 26 files changed, 53 insertions(+), 33 deletions(-)

New commits:
commit 72fd000cc62534d9003d288f676cda3af15da347
Author: Caolán McNamara 
AuthorDate: Mon Sep 21 15:28:01 2020 +0100
Commit: Caolán McNamara 
CommitDate: Mon Sep 21 20:10:38 2020 +0200

update pches

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

diff --git a/basic/inc/pch/precompiled_sb.hxx b/basic/inc/pch/precompiled_sb.hxx
index f34d602f75cc..6d01a36f2961 100644
--- a/basic/inc/pch/precompiled_sb.hxx
+++ b/basic/inc/pch/precompiled_sb.hxx
@@ -13,7 +13,7 @@
  manual changes will be rewritten by the next run of update_pch.sh (which 
presumably
  also fixes all possible problems, so it's usually better to use it).
 
- Generated on 2020-07-09 17:06:13 using:
+ Generated on 2020-09-21 15:20:14 using:
  ./bin/update_pch basic sb --cutoff=2 --exclude:system --exclude:module 
--include:local
 
  If after updating build fails, use the following command to locate 
conflicting headers:
@@ -27,6 +27,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #endif // PCH_LEVEL >= 1
 #if PCH_LEVEL >= 2
diff --git a/chart2/inc/pch/precompiled_chartcore.hxx 
b/chart2/inc/pch/precompiled_chartcore.hxx
index 017fb9f71fc0..4cfd699eeceb 100644
--- a/chart2/inc/pch/precompiled_chartcore.hxx
+++ b/chart2/inc/pch/precompiled_chartcore.hxx
@@ -13,7 +13,7 @@
  manual changes will be rewritten by the next run of update_pch.sh (which 
presumably
  also fixes all possible problems, so it's usually better to use it).
 
- Generated on 2020-09-03 20:50:38 using:
+ Generated on 2020-09-21 15:20:30 using:
  ./bin/update_pch chart2 chartcore --cutoff=3 --exclude:system 
--exclude:module --include:local
 
  If after updating build fails, use the following command to locate 
conflicting headers:
@@ -24,6 +24,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
diff --git a/connectivity/inc/pch/precompiled_ado.hxx 
b/connectivity/inc/pch/precompiled_ado.hxx
index 9aa55133d8e3..5cee91d28f5b 100644
--- a/connectivity/inc/pch/precompiled_ado.hxx
+++ b/connectivity/inc/pch/precompiled_ado.hxx
@@ -13,7 +13,7 @@
  manual changes will be rewritten by the next run of update_pch.sh (which 
presumably
  also fixes all possible problems, so it's usually better to use it).
 
- Generated on 2020-09-03 20:50:38 using:
+ Generated on 2020-09-21 15:20:33 using:
  ./bin/update_pch connectivity ado --cutoff=2 --exclude:system 
--exclude:module --exclude:local
 
  If after updating build fails, use the following command to locate 
conflicting headers:
diff --git a/cppcanvas/inc/pch/precompiled_cppcanvas.hxx 
b/cppcanvas/inc/pch/precompiled_cppcanvas.hxx
index 1f2059c2dd20..abd03ce5065a 100644
--- a/cppcanvas/inc/pch/precompiled_cppcanvas.hxx
+++ b/cppcanvas/inc/pch/precompiled_cppcanvas.hxx
@@ -13,7 +13,7 @@
  manual changes will be rewritten by the next run of update_pch.sh (which 
presumably
  also fixes all possible problems, so it's usually better to use it).
 
- Generated on 2020-09-01 15:29:33 using:
+ Generated on 2020-09-21 15:20:44 using:
  ./bin/update_pch cppcanvas cppcanvas --cutoff=11 --e

[Libreoffice-commits] core.git: compilerplugins/clang include/sfx2 include/vcl sc/source sfx2/source sfx2/uiconfig sfx2/UIConfig_sfx.mk solenv/sanitizers vcl/source

2020-09-21 Thread Caolán McNamara (via logerrit)
 compilerplugins/clang/constantparam.numbers.results |4 
 include/sfx2/infobar.hxx|   57 +--
 include/sfx2/objsh.hxx  |4 
 include/sfx2/sfxbasecontroller.hxx  |4 
 include/sfx2/viewfrm.hxx|   12 
 include/vcl/weldutils.hxx   |   29 +
 sc/source/ui/docshell/docsh4.cxx|   10 
 sc/source/ui/inc/docsh.hxx  |2 
 sfx2/UIConfig_sfx.mk|2 
 sfx2/source/dialog/infobar.cxx  |  380 ++--
 sfx2/source/doc/objserv.cxx |   10 
 sfx2/source/view/sfxbasecontroller.cxx  |   17 
 sfx2/source/view/viewfrm.cxx|   56 +-
 sfx2/uiconfig/ui/extrabutton.ui |   24 +
 sfx2/uiconfig/ui/infobar.ui |  187 +
 solenv/sanitizers/ui/sfx.suppr  |1 
 vcl/source/app/weldutils.cxx|   58 +++
 17 files changed, 584 insertions(+), 273 deletions(-)

New commits:
commit af90b8089405d6f042207f5639e750f08798ae92
Author: Caolán McNamara 
AuthorDate: Tue Sep 8 09:30:35 2020 +0100
Commit: Caolán McNamara 
CommitDate: Mon Sep 21 20:10:06 2020 +0200

weld infobars

note: "pushed" status listener case dropped. Doesn't seem to be an 
expectation
for it to something in infobars, and there doesn't seem to be a working case
anyway.

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

diff --git a/compilerplugins/clang/constantparam.numbers.results 
b/compilerplugins/clang/constantparam.numbers.results
index 0a808e5f2924..add43943e088 100644
--- a/compilerplugins/clang/constantparam.numbers.results
+++ b/compilerplugins/clang/constantparam.numbers.results
@@ -806,10 +806,6 @@ include/sfx2/frame.hxx:192
 void SfxUnoFrameItem::SfxUnoFrameItem(unsigned short,const class 
com::sun::star::uno::Reference &)
 unsigned short nWhich
 6516
-include/sfx2/infobar.hxx:111
-class VclPtr 
SfxInfoBarContainerWindow::appendInfoBar(const class rtl::OUString &,const 
class rtl::OUString &,const class rtl::OUString &,enum InfobarType,long,_Bool)
-long nMessageStyle
-278528
 include/sfx2/linkmgr.hxx:63
 _Bool sfx2::LinkManager::InsertLink(class sfx2::SvBaseLink *,enum 
sfx2::SvBaseLinkObjectType,enum SfxLinkUpdateMode,const class rtl::OUString *)
 enum SfxLinkUpdateMode nUpdateType
diff --git a/include/sfx2/infobar.hxx b/include/sfx2/infobar.hxx
index 40a1b1ff9fbf..a03c833b957d 100644
--- a/include/sfx2/infobar.hxx
+++ b/include/sfx2/infobar.hxx
@@ -15,11 +15,7 @@
 
 #include 
 #include 
-
-class FixedImage;
-class FixedText;
-class Button;
-class PushButton;
+#include 
 
 // These must match the values in offapi/com/sun/star/frame/InfobarType.idl
 enum class InfobarType
@@ -57,44 +53,59 @@ public:
 void Update();
 };
 
+class ExtraButton;
+
 /** Class representing a single InfoBar to be added in a 
SfxInfoBarContainerWindow.
   */
-class SFX2_DLLPUBLIC SfxInfoBarWindow final : public vcl::Window
+class SFX2_DLLPUBLIC SfxInfoBarWindow final : public InterimItemWindow
 {
 private:
 OUString m_sId;
 InfobarType m_eType;
-VclPtr m_pImage;
-VclPtr m_pPrimaryMessage;
-VclPtr m_pSecondaryMessage;
-VclPtr m_pCloseBtn;
-std::vector> m_aActionBtns;
+Size m_aSize;
+Size m_aMessageSize;
+Size m_aOrigMessageSize;
+bool m_bLayingOut;
+std::unique_ptr m_xImage;
+std::unique_ptr m_xPrimaryMessage;
+std::unique_ptr m_xSecondaryMessage;
+std::unique_ptr m_xButtonBox;
+std::unique_ptr m_xCloseBtn;
+std::vector> m_aActionBtns;
+
+DECL_LINK(SizeAllocHdl, const Size&, void);
 
 void SetForeAndBackgroundColors(InfobarType eType);
+void SetCloseButtonImage();
 
 public:
 SfxInfoBarWindow(vcl::Window* parent, const OUString& sId, const OUString& 
sPrimaryMessage,
  const OUString& sSecondaryMessage, InfobarType 
InfobarType,
- WinBits nMessageStyle, bool bShowCloseButton);
+ bool bShowCloseButton);
+Size DoLayout();
+virtual void Layout() override;
 virtual ~SfxInfoBarWindow() override;
 virtual void dispose() override;
 
 const OUString& getId() const { return m_sId; }
-virtual void Paint(vcl::RenderContext& rRenderContext, const 
tools::Rectangle&) override;
-virtual void Resize() override;
 void Update(const OUString& sPrimaryMessage, const OUString& 
sSecondaryMessage,
 InfobarType eType);
 basegfx::BColor m_aBackgroundColor;
 basegfx::BColor m_aForegroundColor;
 
 /** Add button to Infobar.
- * Infobar takes ownership of the button so the button is
- * destroyed when the infobar gets des

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

2020-09-21 Thread Caolán McNamara (via logerrit)
 sc/source/ui/cctrl/checklistmenu.cxx |   47 +--
 sc/source/ui/inc/checklistmenu.hxx   |8 ++---
 sc/source/ui/view/gridwin.cxx|   10 ++-
 sc/source/ui/view/gridwin2.cxx   |3 +-
 4 files changed, 33 insertions(+), 35 deletions(-)

New commits:
commit 416c11d189a18a08c28135b8aa5e0f12cd51dcd6
Author: Caolán McNamara 
AuthorDate: Mon Sep 21 15:15:47 2020 +0100
Commit: Caolán McNamara 
CommitDate: Mon Sep 21 20:09:44 2020 +0200

set whether dates are needed in the ctor

so its known from the start which mode will be in use

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

diff --git a/sc/source/ui/cctrl/checklistmenu.cxx 
b/sc/source/ui/cctrl/checklistmenu.cxx
index 8707aff3f477..2edb5f50b1fe 100644
--- a/sc/source/ui/cctrl/checklistmenu.cxx
+++ b/sc/source/ui/cctrl/checklistmenu.cxx
@@ -167,7 +167,8 @@ ScCheckListMenuWindow* 
ScCheckListMenuControl::addSubMenuItem(const OUString& rT
 MenuItemData aItem;
 aItem.mbEnabled = bEnabled;
 vcl::Window *pContainer = mxFrame->GetWindow(GetWindowType::FirstChild);
-aItem.mxSubMenuWin.reset(VclPtr::Create(pContainer, 
mpDoc, false, -1, mxFrame.get()));
+aItem.mxSubMenuWin.reset(VclPtr::Create(pContainer, 
mpDoc, false,
+   false, -1, 
mxFrame.get()));
 maMenuItems.emplace_back(std::move(aItem));
 
 mxMenu->append_text(rText);
@@ -412,7 +413,8 @@ ScCheckListMember::ScCheckListMember()
 }
 
 ScCheckListMenuControl::ScCheckListMenuControl(ScCheckListMenuWindow* pParent, 
vcl::Window* pContainer,
-   ScDocument* pDoc, bool 
bCanHaveSubMenu, int nWidth)
+   ScDocument* pDoc, bool 
bCanHaveSubMenu,
+   bool bHasDates, int nWidth)
 : mxFrame(pParent)
 , mxBuilder(Application::CreateInterimBuilder(pContainer, 
"modules/scalc/ui/filterdropdown.ui", false))
 , mxContainer(mxBuilder->weld_container("FilterDropDown"))
@@ -422,7 +424,6 @@ 
ScCheckListMenuControl::ScCheckListMenuControl(ScCheckListMenuWindow* pParent, v
 , mxBox(mxBuilder->weld_widget("box"))
 , mxListChecks(mxBuilder->weld_tree_view("check_list_box"))
 , mxTreeChecks(mxBuilder->weld_tree_view("check_tree_box"))
-, mpChecks(mxTreeChecks.get())
 , mxChkToggleAll(mxBuilder->weld_check_button("toggle_all"))
 , mxBtnSelectSingle(mxBuilder->weld_button("select_current"))
 , mxBtnUnselectSingle(mxBuilder->weld_button("unselect_current"))
@@ -436,11 +437,27 @@ 
ScCheckListMenuControl::ScCheckListMenuControl(ScCheckListMenuWindow* pParent, v
 , mnSelectedMenu(MENU_NOT_SELECTED)
 , mpDoc(pDoc)
 , mnAsyncPostPopdownId(nullptr)
-, mbHasDates(false)
+, mbHasDates(bHasDates)
 , mbCanHaveSubMenu(bCanHaveSubMenu)
 , maOpenTimer(this)
 , maCloseTimer(this)
 {
+/*
+   tdf#136559 If we have no dates we don't need a tree
+   structure, just a list. GtkListStore can be then
+   used which is much faster than a GtkTreeStore, so
+   with no dates switch to the treeview which uses the
+   faster GtkListStore
+*/
+if (mbHasDates)
+mpChecks = mxTreeChecks.get();
+else
+{
+mxTreeChecks->hide();
+mxListChecks->show();
+mpChecks = mxListChecks.get();
+}
+
 bool bIsSubMenu = pParent->GetParentMenu();
 
 int nChecksHeight = mxTreeChecks->get_height_rows(9);
@@ -531,13 +548,13 @@ ScCheckListMenuControl::~ScCheckListMenuControl()
 }
 
 ScCheckListMenuWindow::ScCheckListMenuWindow(vcl::Window* pParent, ScDocument* 
pDoc, bool bCanHaveSubMenu,
- int nWidth, 
ScCheckListMenuWindow* pParentMenu)
+ bool bTreeMode, int nWidth, 
ScCheckListMenuWindow* pParentMenu)
 : DockingWindow(pParent, "InterimDockParent", 
"svx/ui/interimdockparent.ui")
 , mxParentMenu(pParentMenu)
 , mxBox(get("box"))
 {
 setDeferredProperties();
-mxControl.reset(new ScCheckListMenuControl(this, mxBox.get(), pDoc, 
bCanHaveSubMenu, nWidth));
+mxControl.reset(new ScCheckListMenuControl(this, mxBox.get(), pDoc, 
bCanHaveSubMenu, bTreeMode, nWidth));
 
SetBackground(Application::GetSettings().GetStyleSettings().GetMenuColor());
 set_id("check_list_menu");
 }
@@ -1150,24 +1167,6 @@ IMPL_LINK(ScCheckListMenuControl, KeyInputHdl, const 
KeyEvent&, rKEvt, bool)
 return false;
 }
 
-void ScCheckListMenuControl::setHasDates(bool bHasDates)
-{
-mbHasDates = bHasDates;
-
-/*
-   tdf#136559 If we have no dates we don't need a tree
-   structure, just a list. GtkListStore can be then
-   used which is much faster than a GtkTreeStore, so
-   with no dates switch to the tree

[Libreoffice-commits] core.git: Branch 'libreoffice-7-0' - writerfilter/source

2020-09-21 Thread Michael Stahl (via logerrit)
 writerfilter/source/rtftok/rtfdispatchdestination.cxx |   14 +-
 writerfilter/source/rtftok/rtfdocumentimpl.cxx|   10 +-
 2 files changed, 22 insertions(+), 2 deletions(-)

New commits:
commit fbc78668d4a95934fb0470ef2172aceedb806172
Author: Michael Stahl 
AuthorDate: Fri Sep 18 18:52:45 2020 +0200
Commit: Miklos Vajna 
CommitDate: Mon Sep 21 19:10:10 2020 +0200

tdf#136445 writerfilter: RTF import: buffer annotations inside tables

The problem is that one of the annotations is inside a table that
happens to start with a covered cell (vertically merged).

The table row is buffered, but the annotation is not, so it is inserted
before any of the text of the table cells is inserted, so it ends up in
the covered cell.

The strucuture of annotations is a bit icky; to fix this, buffer both the
\annotation destination and \atrfstart \atrfend start and end
destinations.

Change-Id: Ie955a75a2d254f8d7e965259698b688eece7cbd6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103016
Tested-by: Jenkins
Reviewed-by: Michael Stahl 
(cherry picked from commit 54bd2266d6e0c8926ecaf0fbb2dbb5ee9d1a802d)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103050
Reviewed-by: Miklos Vajna 
Tested-by: Miklos Vajna 

diff --git a/writerfilter/source/rtftok/rtfdispatchdestination.cxx 
b/writerfilter/source/rtftok/rtfdispatchdestination.cxx
index 0afb3c1f395c..68672bde9cd9 100644
--- a/writerfilter/source/rtftok/rtfdispatchdestination.cxx
+++ b/writerfilter/source/rtftok/rtfdispatchdestination.cxx
@@ -331,7 +331,19 @@ RTFError RTFDocumentImpl::dispatchDestination(RTFKeyword 
nKeyword)
 case RTF_ANNOTATION:
 if (!m_pSuperstream)
 {
-resolveSubstream(m_nGroupStartPos - 1, 
NS_ooxml::LN_annotation);
+if (!m_aStates.top().getCurrentBuffer())
+{
+resolveSubstream(m_nGroupStartPos - 1, 
NS_ooxml::LN_annotation);
+}
+else
+{
+RTFSprms aAttributes;
+aAttributes.set(Id(0), new RTFValue(m_nGroupStartPos - 
1));
+aAttributes.set(Id(1), new 
RTFValue(NS_ooxml::LN_annotation));
+aAttributes.set(Id(2), new RTFValue(OUString()));
+m_aStates.top().getCurrentBuffer()->push_back(
+Buf_t(BUFFER_RESOLVESUBSTREAM, new 
RTFValue(aAttributes), nullptr));
+}
 m_aStates.top().setDestination(Destination::SKIP);
 }
 else
diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx 
b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
index 1624b023ff34..97844308de0b 100644
--- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx
+++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
@@ -2725,7 +2725,15 @@ RTFError RTFDocumentImpl::beforePopState(RTFParserState& 
rState)
 
aAttributes.set(NS_ooxml::LN_EG_RangeMarkupElements_commentRangeEnd, pValue);
 writerfilter::Reference::Pointer_t pProperties
 = new RTFReferenceProperties(aAttributes);
-Mapper().props(pProperties);
+if (!m_aStates.top().getCurrentBuffer())
+{
+Mapper().props(pProperties);
+}
+else
+{
+auto const pValue2 = new RTFValue(aAttributes, RTFSprms());
+bufferProperties(*m_aStates.top().getCurrentBuffer(), pValue2, 
nullptr);
+}
 }
 break;
 case Destination::ANNOTATIONREFERENCE:
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Justin Luth (via logerrit)
 sw/qa/extras/ooxmlexport/ooxmlexport15.cxx |4 ++--
 sw/source/filter/ww8/wrtw8nds.cxx  |   14 --
 2 files changed, 14 insertions(+), 4 deletions(-)

New commits:
commit d08bbf4a1b1a62ef1f52665f52ed8880792c64ef
Author: Justin Luth 
AuthorDate: Wed Aug 26 18:22:51 2020 +0300
Commit: Justin Luth 
CommitDate: Mon Sep 21 18:41:37 2020 +0200

tdf#132149 ww8export: always check for break at end of paragraph

Make sure to check if the next node has a page-break
at the end of a split paragraph.

Change-Id: Ib103d7b2f653f9ae5772ff536c041afb445903b4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101344
Tested-by: Jenkins
Reviewed-by: Miklos Vajna 
Reviewed-by: Justin Luth 

diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx 
b/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx
index 6606befccaf1..09f847b64b2a 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx
@@ -525,8 +525,8 @@ DECLARE_OOXMLEXPORT_TEST(testTdf132149_pgBreak, 
"tdf132149_pgBreak.odt")
 assertXPath(pDump, "//page[2]/header", 0);
 
 //Page break is not lost. This SHOULD be on page 4, but sadly it is not.
-//assertXPathContent(pDump, "//page[5]/header", "First Page Style");
-//CPPUNIT_ASSERT(getXPathContent(pDump, 
"//page[5]/body/txt").startsWith("Lorem ipsum"));
+assertXPathContent(pDump, "//page[5]/header/txt", "First Page Style");
+CPPUNIT_ASSERT(getXPathContent(pDump, 
"//page[5]/body/txt").startsWith("Lorem ipsum"));
 }
 
 DECLARE_OOXMLEXPORT_TEST(testTdf135949_anchoredBeforeBreak, 
"tdf135949_anchoredBeforeBreak.docx")
diff --git a/sw/source/filter/ww8/wrtw8nds.cxx 
b/sw/source/filter/ww8/wrtw8nds.cxx
index 87ff1d82c701..3e9b52d40516 100644
--- a/sw/source/filter/ww8/wrtw8nds.cxx
+++ b/sw/source/filter/ww8/wrtw8nds.cxx
@@ -2723,10 +2723,20 @@ void MSWordExportBase::OutputTextNode( SwTextNode& 
rNode )
 assert(pNextPageDesc);
 PrepareNewPageDesc( rNode.GetpSwAttrSet(), rNode, nullptr , 
pNextPageDesc);
 }
-else if (!bNeedParaSplit)
+else
 {
 // else check if section break needed after the paragraph
-AttrOutput().SectionBreaks(rNode);
+bool bCheckSectionBreak = true;
+// only try to sectionBreak after a split para if the next node 
specifies a break
+if ( bNeedParaSplit )
+{
+SwNodeIndex aNextIndex( rNode, 1 );
+const SwTextNode* pNextNode = 
aNextIndex.GetNode().GetTextNode();
+bCheckSectionBreak = pNextNode && !NoPageBreakSection( 
pNextNode->GetpSwAttrSet() );
+}
+
+if ( bCheckSectionBreak )
+AttrOutput().SectionBreaks(rNode);
 }
 
 AttrOutput().StartParagraphProperties();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loleaflet/src

2020-09-21 Thread Pranam Lashkari (via logerrit)
 loleaflet/src/layer/marker/Annotation.js |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 31c931658d5f7ed453a05085c3286f70fe769e46
Author: Pranam Lashkari 
AuthorDate: Mon Sep 21 19:25:54 2020 +0530
Commit: Pranam Lashkari 
CommitDate: Mon Sep 21 18:15:21 2020 +0200

leaflet: show annotation marker only from the selected slide

Change-Id: I6a9950f8f5be0f6e7393faf4f8718b94ffb05ebc
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/103114
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Pranam Lashkari 

diff --git a/loleaflet/src/layer/marker/Annotation.js 
b/loleaflet/src/layer/marker/Annotation.js
index dc4f94633..6a8701dc7 100644
--- a/loleaflet/src/layer/marker/Annotation.js
+++ b/loleaflet/src/layer/marker/Annotation.js
@@ -485,7 +485,8 @@ L.Annotation = L.Layer.extend({
}),
draggable: true
});
-   this._map.addLayer(this._annotationMarker);
+   if 
(this._map._docLayer._partHashes[this._map._docLayer._selectedPart] == 
this._data.parthash)
+   this._map.addLayer(this._annotationMarker);
}
if (this._data.rectangle != null) {
var stringTwips = this._data.rectangle.match(/\d+/g);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-0' - include/svtools svtools/source

2020-09-21 Thread Tomofumi Yagi (via logerrit)
 include/svtools/filechangedchecker.hxx |2 +-
 svtools/source/misc/filechangedchecker.cxx |   21 -
 2 files changed, 13 insertions(+), 10 deletions(-)

New commits:
commit 1d28170d94893171e2a358274cda62cd73f7b834
Author: Tomofumi Yagi 
AuthorDate: Fri Sep 18 16:21:43 2020 +0900
Commit: Caolán McNamara 
CommitDate: Mon Sep 21 17:56:50 2020 +0200

tdf#134157 fix Edit with external tool causes a CPU hit

Switch Idle to 100ms Timer for fixing the bug

Change-Id: I85a9bdcb173edd28d952d8e91c1b93d748e69206
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102984
Tested-by: Jenkins
Reviewed-by: Noel Grandin 
(cherry picked from commit f110c037114f90d219ac8d149542bf96fe66a2f1)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103055
Reviewed-by: Caolán McNamara 

diff --git a/include/svtools/filechangedchecker.hxx 
b/include/svtools/filechangedchecker.hxx
index 3b7f817f3035..016fe9279800 100644
--- a/include/svtools/filechangedchecker.hxx
+++ b/include/svtools/filechangedchecker.hxx
@@ -29,7 +29,7 @@ class Timer;
 class UNLESS_MERGELIBS(SVT_DLLPUBLIC) FileChangedChecker
 {
 private:
-IdlemIdle;
+TimermTimer;
 OUString mFileName;
 TimeValuemLastModTime;
 ::std::function mpCallback;
diff --git a/svtools/source/misc/filechangedchecker.cxx 
b/svtools/source/misc/filechangedchecker.cxx
index 09e24c3fafb1..8536eb0bda57 100644
--- a/svtools/source/misc/filechangedchecker.cxx
+++ b/svtools/source/misc/filechangedchecker.cxx
@@ -16,7 +16,7 @@
 
 FileChangedChecker::FileChangedChecker(const OUString& rFilename,
 const ::std::function& rCallback)
-: mIdle("SVTools FileChangedChecker Idle")
+: mTimer("SVTools FileChangedChecker Timer")
 , mFileName(rFilename)
 , mLastModTime()
 , mpCallback(rCallback)
@@ -24,21 +24,24 @@ FileChangedChecker::FileChangedChecker(const OUString& 
rFilename,
 // Get the curren last file modified Status
 getCurrentModTime(mLastModTime);
 
-// associate the callback function for the Idle
-mIdle.SetInvokeHandler(LINK(this, FileChangedChecker, TimerHandler));
+// associate the callback function for the Timer
+mTimer.SetInvokeHandler(LINK(this, FileChangedChecker, TimerHandler));
 
-//start the timer
+// set timer interval
+mTimer.SetTimeout(100);
+
+// start the timer
 resetTimer();
 }
 
 void FileChangedChecker::resetTimer()
 {
-//Start the Idle if it's not active
-if(!mIdle.IsActive())
-mIdle.Start();
+// Start the Idle if it's not active
+if(!mTimer.IsActive())
+mTimer.Start();
 
 // Set lowest Priority
-mIdle.SetPriority(TaskPriority::LOWEST);
+mTimer.SetPriority(TaskPriority::LOWEST);
 }
 
 bool FileChangedChecker::getCurrentModTime(TimeValue& o_rValue) const
@@ -90,7 +93,7 @@ IMPL_LINK_NOARG(FileChangedChecker, TimerHandler, Timer *, 
void)
 mpCallback();
 }
 
-// Reset the Idle in any case
+// Reset the Timer in any case
 resetTimer();
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loleaflet/src

2020-09-21 Thread mert (via logerrit)
 loleaflet/src/map/handler/Map.TouchGesture.js |   15 +--
 1 file changed, 13 insertions(+), 2 deletions(-)

New commits:
commit c43aeb3e35a99c2f35bb817037d2451dc8731ae5
Author: mert 
AuthorDate: Wed Sep 16 17:31:46 2020 +0300
Commit: Andras Timar 
CommitDate: Mon Sep 21 17:20:06 2020 +0200

Fix pinch gesture causes hammer to stuck on Mobile

Change-Id: If0ae311346ae9c9935ebacde3bc5ea874833
Signed-off-by: mert 
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/102873
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Andras Timar 

diff --git a/loleaflet/src/map/handler/Map.TouchGesture.js 
b/loleaflet/src/map/handler/Map.TouchGesture.js
index 689e9104f..ce3ca184e 100644
--- a/loleaflet/src/map/handler/Map.TouchGesture.js
+++ b/loleaflet/src/map/handler/Map.TouchGesture.js
@@ -53,9 +53,20 @@ L.Map.TouchGesture = L.Handler.extend({
var tripleTap = new Hammer.Tap({event: 'tripletap', 
taps: 3, posThreshold: posThreshold });
this._hammer.add(tripleTap);
tripleTap.recognizeWith([doubleTap, singleTap]);
-
+   var hammer = this._hammer;
if (L.Browser.touch) {
-   L.DomEvent.on(this._map._mapPane, 'touchstart 
touchmove touchend touchcancel', L.DomEvent.preventDefault);
+   L.DomEvent.on(this._map._mapPane, 'touchstart 
touchmove touchcancel', L.DomEvent.preventDefault);
+   L.DomEvent.on(this._map._mapPane, 'touchend', 
function(e) {
+   // sometimes inputs get stuck in hammer 
and further events get mixed with the old ones
+   // this causes to a failure to use all 
the gestures properly.
+   // This is a workaround until it is 
fixed by hammer.js
+   if (hammer.input) {
+   if (hammer.input.store)  {
+   hammer.input.store = [];
+   }
+   }
+   L.DomEvent.preventDefault(e);
+   });
}
 
if (Hammer.prefixed(window, 'PointerEvent') !== 
undefined) {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Samuel Mehrbrodt (via logerrit)
 sw/source/core/crsr/crstrvl.cxx  |2 +-
 sw/source/core/txtnode/ndtxt.cxx |2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 4cb7e97ac32cde58a6c8de1301f05306ea326ea8
Author: Samuel Mehrbrodt 
AuthorDate: Thu Aug 20 15:33:49 2020 +0200
Commit: Thorsten Behrens 
CommitDate: Mon Sep 21 17:05:55 2020 +0200

Related tdf#100492 Detect click into empty field

Change-Id: Ic2937d619a8361b9d17b7dfa16698a5005f34ec6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101076
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt 
(cherry picked from commit 2c7bf3543ab798d1c117d9f3258467e4aef9a8db)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103107
Tested-by: Thorsten Behrens 
Reviewed-by: Thorsten Behrens 

diff --git a/sw/source/core/crsr/crstrvl.cxx b/sw/source/core/crsr/crstrvl.cxx
index 67c6fc7df511..749416c00636 100644
--- a/sw/source/core/crsr/crstrvl.cxx
+++ b/sw/source/core/crsr/crstrvl.cxx
@@ -898,7 +898,7 @@ bool SwCursorShell::CursorInsideInputField() const
 {
 for(SwPaM& rCursor : GetCursor()->GetRingContainer())
 {
-if (dynamic_cast(GetTextFieldAtCursor(&rCursor, false)))
+if (dynamic_cast(GetTextFieldAtCursor(&rCursor, true)))
 return true;
 }
 return false;
diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx
index c90e91bafaf1..5ca09ba95fd4 100755
--- a/sw/source/core/txtnode/ndtxt.cxx
+++ b/sw/source/core/txtnode/ndtxt.cxx
@@ -1798,7 +1798,7 @@ SwTextField* SwTextNode::GetFieldTextAttrAt(
 dynamic_cast( GetTextAttrAt(
 nIndex,
 RES_TXTATR_INPUTFIELD,
-bIncludeInputFieldAtStart ? DEFAULT : PARENT ));
+bIncludeInputFieldAtStart ? DEFAULT : EXPAND ));
 }
 
 return pTextField;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.4' - desktop/source sc/source

2020-09-21 Thread Gabriel Masei (via logerrit)
 desktop/source/lib/init.cxx|   15 ++-
 sc/source/ui/view/tabvwsha.cxx |   19 ---
 2 files changed, 22 insertions(+), 12 deletions(-)

New commits:
commit 2d4e43ef8c6f563087330c180b18ef83a1fad207
Author: Gabriel Masei 
AuthorDate: Wed Sep 2 19:22:23 2020 +0300
Commit: Jan Holesovsky 
CommitDate: Mon Sep 21 16:57:35 2020 +0200

lok: remove .uno:ModifiedStatus message from deduplication mechanism

This fixes the following issue in Online:

When a save is performed while a cell is still edited the save icon
does not reflect the correct state of the document: it shows that
the document is dirty although it is not. This is generated by two facts:

1. The status cache is avoided when sending the -dirty- status right
after the cell editing is finished. Because the cache has an old value
of -false- for ModifiedStatus, the notification that is sent after saving,
with -false- value, is ignored. We should not avoid the status cache.

2. Because there is a mechanism that keeps only the last notification
value for a status change in the queue that keeps messages that were not
sent yet (deduplication), the .uno:ModifiedStatus message with a value of 
-true-
that is enqueued right after the cell edit is finished is replaced by the 
same
message with a value of -false- that is enqueued after the save is finished.
This happens if the flush mechanism doesn't occur between them.

Change-Id: I3348bf230ba53a154c29e7d8ab064df7694adeae
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103053
Reviewed-by: Gabriel Masei 
Reviewed-by: Jan Holesovsky 
Tested-by: Jenkins CollaboraOffice 

diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index eaba422a3e4a..2dffed0204b5 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -1584,11 +1584,16 @@ void CallbackFlushHandler::queue(const int type, const 
char* data)
 if (pos != std::string::npos)
 {
 const std::string name = payload.substr(0, pos + 1);
-removeAll(
-[type, &name] (const queue_type::value_type& elem) {
-return (elem.Type == type) && 
(elem.PayloadString.compare(0, name.size(), name) == 0);
-}
-);
+// This is needed because otherwise it creates some 
problems when
+// a save occurs while a cell is still edited in Calc.
+if (name != ".uno:ModifiedStatus=")
+{
+removeAll(
+[type, &name] (const queue_type::value_type& elem) 
{
+return (elem.Type == type) && 
(elem.PayloadString.compare(0, name.size(), name) == 0);
+}
+);
+}
 }
 }
 break;
diff --git a/sc/source/ui/view/tabvwsha.cxx b/sc/source/ui/view/tabvwsha.cxx
index f527e539b62b..19ac69aec2d0 100644
--- a/sc/source/ui/view/tabvwsha.cxx
+++ b/sc/source/ui/view/tabvwsha.cxx
@@ -745,20 +745,25 @@ void ScTabViewShell::ExecuteSave( SfxRequest& rReq )
 // Finish entering unless 'DontTerminateEdit' is specified, even if a 
formula is being processed
 if (bCommitChanges)
 {
+SC_MOD()->InputEnterHandler();
+
 if (comphelper::LibreOfficeKit::isActive())
 {
 // Normally this isn't needed, but in Calc when editing a cell 
formula
 // and manually saving (without changing cells or hitting enter), 
while
 // InputEnterHandler will mark the doc as modified (when it is), 
because
 // we will save the doc immediately afterwards, the modified state 
event
-// is clobbered. To avoid that, we notify all views immediately of 
the
-// modified state, apply the modification, then save the document.
-ScInputHandler* pHdl = GetInputHandler();
-if (pHdl != nullptr && pHdl->GetModified())
-SfxLokHelper::notifyAllViews(LOK_CALLBACK_STATE_CHANGED, 
".uno:ModifiedStatus=true");
+// is clobbered. To avoid that, we need to update SID_DOC_MODIFIED 
so that
+// a possible state of "true" after "InputEnterHandler" will be 
sent
+// as a notification. It is important that the notification goes 
through
+// normal process (cache) rather than directly notifying the views.
+// Otherwise, because there is a previous state of "false" in 
cache, the
+// "false" state after saving will be ignored.
+// This will work only if .uno:ModifiedStatus message will be 
removed from
+// the mechanism that keeps in the message queue only last message 
of
+// a particular status even if the values are differe

[Libreoffice-commits] online.git: Branch 'distro/collabora/co-4-2' - loleaflet/src

2020-09-21 Thread Szymon Kłos (via logerrit)
 loleaflet/src/control/Control.JSDialogBuilder.js |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 94adc8682dc99afe8437fa95e82a2ba57694696e
Author: Szymon Kłos 
AuthorDate: Thu Sep 17 13:32:29 2020 +0200
Commit: Andras Timar 
CommitDate: Mon Sep 21 16:32:32 2020 +0200

jsdialog: send FillColor as number

Change-Id: Iab85bd2cc6ab082c368ec2a8669c9ce384305d24
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/102921
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Andras Timar 

diff --git a/loleaflet/src/control/Control.JSDialogBuilder.js 
b/loleaflet/src/control/Control.JSDialogBuilder.js
index e0b2f17be..7527d0fe5 100644
--- a/loleaflet/src/control/Control.JSDialogBuilder.js
+++ b/loleaflet/src/control/Control.JSDialogBuilder.js
@@ -1766,7 +1766,7 @@ L.Control.JSDialogBuilder = L.Control.extend({
gradientItem.endcolor = color;

builder.map.sendUnoCommand('.uno:FillPageGradient?FillPageGradientJSON:string=' 
+ JSON.stringify(gradientItem));
return;
-   } else if (data.id === 'Color' || data.id === 'CharBackColor') {
+   } else if (data.id === 'Color' || data.id === 'CharBackColor' 
|| data.id === 'FillColor') {
var params = {};
params[data.id] = {
type : 'long',
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Szymon Kłos (via logerrit)
 chart2/source/controller/inc/ChartController.hxx|1 
 chart2/source/controller/main/ChartController.cxx   |9 +++
 chart2/source/controller/main/ChartController_Tools.cxx |   20 
 3 files changed, 30 insertions(+)

New commits:
commit 5b7d841f062de8872457369da4d4e8e35be9bf60
Author: Szymon Kłos 
AuthorDate: Thu Sep 17 13:27:53 2020 +0200
Commit: Andras Timar 
CommitDate: Mon Sep 21 16:31:58 2020 +0200

lok: Add posibility to change chart fill color

Change-Id: I519a0fe15c4983803109aed7eef840d36a5e7b21
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102920
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Andras Timar 

diff --git a/chart2/source/controller/inc/ChartController.hxx 
b/chart2/source/controller/inc/ChartController.hxx
index 22469e396480..270f5743e0c7 100644
--- a/chart2/source/controller/inc/ChartController.hxx
+++ b/chart2/source/controller/inc/ChartController.hxx
@@ -501,6 +501,7 @@ private:
 
 void executeDispatch_LOKSetTextSelection(int nType, int nX, int nY);
 void executeDispatch_LOKPieSegmentDragging(int nOffset);
+void executeDispatch_FillColor(sal_uInt32 nColor);
 
 void sendPopupRequest(OUString const & rCID, tools::Rectangle aRectangle);
 
diff --git a/chart2/source/controller/main/ChartController.cxx 
b/chart2/source/controller/main/ChartController.cxx
index 27cb93cabdd7..5ee520362c0b 100644
--- a/chart2/source/controller/main/ChartController.cxx
+++ b/chart2/source/controller/main/ChartController.cxx
@@ -1113,6 +1113,15 @@ void SAL_CALL ChartController::dispatch(
 this->executeDispatch_PositionAndSize(&rArgs);
 }
 }
+else if(aCommand == "FillColor")
+{
+if (rArgs.getLength() > 0)
+{
+sal_uInt32 nColor = -1;
+rArgs[0].Value >>= nColor;
+this->executeDispatch_FillColor(nColor);
+}
+}
 else if(aCommand == "Paste")
 this->executeDispatch_Paste();
 else if(aCommand == "Copy" )
diff --git a/chart2/source/controller/main/ChartController_Tools.cxx 
b/chart2/source/controller/main/ChartController_Tools.cxx
index b1d26f3425ab..ff1c83ae7e7f 100644
--- a/chart2/source/controller/main/ChartController_Tools.cxx
+++ b/chart2/source/controller/main/ChartController_Tools.cxx
@@ -937,6 +937,26 @@ void ChartController::executeDispatch_ToggleGridVertical()
 }
 }
 
+void ChartController::executeDispatch_FillColor(sal_uInt32 nColor)
+{
+try
+{
+OUString aCID( m_aSelection.getSelectedCID() );
+const uno::Reference< frame::XModel >& xChartModel = getModel();
+if( xChartModel.is() )
+{
+Reference< beans::XPropertySet > xPointProperties(
+ObjectIdentifier::getObjectPropertySet( aCID, xChartModel ) );
+if( xPointProperties.is() )
+xPointProperties->setPropertyValue( "FillColor", uno::Any( 
nColor ) );
+}
+}
+catch( const uno::Exception & ex )
+{
+SAL_WARN( "chart2", "Exception caught. " << ex );
+}
+}
+
 void ChartController::executeDispatch_LOKSetTextSelection(int nType, int nX, 
int nY)
 {
 if (m_pDrawViewWrapper)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Andras Timar (via logerrit)
 configure.ac |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit e9e6d981e3727eec013e259fc9170eaf69f94614
Author: Andras Timar 
AuthorDate: Mon Sep 21 13:04:22 2020 +0200
Commit: Andras Timar 
CommitDate: Mon Sep 21 16:27:31 2020 +0200

nodejs >= 10.0.0 is required to build loleaflet

Change-Id: I4541044e090e85514004b941b6e57986479095cd
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/103095
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Andras Timar 

diff --git a/configure.ac b/configure.ac
index cdfd3aa65..6fe6e7967 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1044,8 +1044,8 @@ AS_IF([test `uname -s` = "Linux"],
AC_MSG_ERROR([node required to build loleaflet, but not installed])
else
NODE_VER=`node --version | sed 's/^v//' | awk -F. '{ print (($1 * 
100) + $2) * 100 + $3;}'`
-   if test "$NODE_VER" -lt 6; then
-   AC_MSG_ERROR([This node version is old, upgrade to >= 6.0.0])
+   if test "$NODE_VER" -lt 10; then
+   AC_MSG_ERROR([This node version is old, upgrade to >= 10.0.0])
fi
fi
if test "$enable_cypress" = "yes"; then
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: kit/Watermark.hpp loleaflet/src

2020-09-21 Thread Andras Timar (via logerrit)
 kit/Watermark.hpp   |2 +-
 loleaflet/src/control/Control.NotebookbarCalc.js|4 ++--
 loleaflet/src/control/Control.NotebookbarImpress.js |4 ++--
 loleaflet/src/control/Control.NotebookbarWriter.js  |4 ++--
 loleaflet/src/control/Control.TopToolbar.js |2 +-
 5 files changed, 8 insertions(+), 8 deletions(-)

New commits:
commit d6216e4335da0e2b6b06caabd5b378bd3798d922
Author: Andras Timar 
AuthorDate: Mon Sep 21 11:59:28 2020 +0200
Commit: Andras Timar 
CommitDate: Mon Sep 21 16:27:12 2020 +0200

default to Carlito in font selector

Change-Id: Ib568253adc48376cf57335934c3471b46d08fdbc
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/103092
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Andras Timar 

diff --git a/kit/Watermark.hpp b/kit/Watermark.hpp
index 303c194d6..deaca1549 100644
--- a/kit/Watermark.hpp
+++ b/kit/Watermark.hpp
@@ -26,7 +26,7 @@ public:
   const std::shared_ptr & session)
 : _loKitDoc(loKitDoc)
 , _text(session->getWatermarkText())
-, _font("Liberation Sans")
+, _font("Carlito")
 , _width(0)
 , _height(0)
 , _alphaLevel(session->getWatermarkOpacity())
diff --git a/loleaflet/src/control/Control.NotebookbarCalc.js 
b/loleaflet/src/control/Control.NotebookbarCalc.js
index 6fe096450..02a3c6907 100644
--- a/loleaflet/src/control/Control.NotebookbarCalc.js
+++ b/loleaflet/src/control/Control.NotebookbarCalc.js
@@ -554,7 +554,7 @@ L.Control.NotebookbarCalc = 
L.Control.NotebookbarWriter.extend({



{



'id': 'fontnamecombobox',



'type': 'combobox',
-   


'text': 'Liberation Sans',
+   


'text': 'Carlito',



'enabled': 'true',



'children': [



{
@@ -566,7 +566,7 @@ L.Control.NotebookbarCalc = 
L.Control.NotebookbarWriter.extend({



{



'id': '',



'type': 'edit',
-   


'text': 'Liberation Sans',
+  

[Libreoffice-commits] online.git: loleaflet/images

2020-09-21 Thread Pedro Pinto Silva (via logerrit)
 loleaflet/images/lc_rotation.svg |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 220b4498f19bc680bea84927afb4b2786898fef4
Author: Pedro Pinto Silva 
AuthorDate: Mon Sep 21 15:38:44 2020 +0200
Commit: Pedro Silva 
CommitDate: Mon Sep 21 16:24:53 2020 +0200

Mobile: add missing rotation icon

Change-Id: I380c2a21433ed1cb18fe059f70713028503cf966
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/103112
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Pedro Silva 

diff --git a/loleaflet/images/lc_rotation.svg b/loleaflet/images/lc_rotation.svg
new file mode 100644
index 0..6f57e10fe
--- /dev/null
+++ b/loleaflet/images/lc_rotation.svg
@@ -0,0 +1 @@
+http://www.w3.org/2000/svg";>
\ No newline at end of file
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-0' - vcl/skia

2020-09-21 Thread Luboš Luňák (via logerrit)
 vcl/skia/gdiimpl.cxx |   41 +
 1 file changed, 41 insertions(+)

New commits:
commit db650bc2f262424edd5b4f3edb24fb37bc2ce12c
Author: Luboš Luňák 
AuthorDate: Fri Sep 18 10:19:33 2020 +0200
Commit: Caolán McNamara 
CommitDate: Mon Sep 21 16:24:06 2020 +0200

do not try to merge polygons if they do not share a point (tdf#136222)

If two polygons do not share a point, then they do not share an edge,
so they cannot be adjacent polygons. As a side-effect this avoids
the problem with tdf#136222, as it turns out
basegfx::utils::mergeToSinglePolyPolygon() is broken with polygons
that are almost but not quite adjacent.

Change-Id: Ibf290cc886d7c337fd04c925b551b2e7773a6b70
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102985
Reviewed-by: Noel Grandin 
Reviewed-by: Luboš Luňák 
Tested-by: Jenkins
(cherry picked from commit 859596233146590f7ebac1f05bbb83ce5ea8aac4)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103052
Reviewed-by: Caolán McNamara 

diff --git a/vcl/skia/gdiimpl.cxx b/vcl/skia/gdiimpl.cxx
index 9fa79f498801..0555cb9549f6 100644
--- a/vcl/skia/gdiimpl.cxx
+++ b/vcl/skia/gdiimpl.cxx
@@ -40,6 +40,7 @@
 #include 
 #include 
 #include 
+#include 
 
 namespace
 {
@@ -830,6 +831,19 @@ void SkiaSalGraphicsImpl::performDrawPolyPolygon(const 
basegfx::B2DPolyPolygon&
 #endif
 }
 
+namespace
+{
+struct LessThan
+{
+bool operator()(const basegfx::B2DPoint& point1, const basegfx::B2DPoint& 
point2) const
+{
+if (basegfx::fTools::equal(point1.getX(), point2.getX()))
+return basegfx::fTools::less(point1.getY(), point2.getY());
+return basegfx::fTools::less(point1.getX(), point2.getX());
+}
+};
+} // namespace
+
 bool SkiaSalGraphicsImpl::delayDrawPolyPolygon(const basegfx::B2DPolyPolygon& 
aPolyPolygon,
double fTransparency)
 {
@@ -858,6 +872,9 @@ bool SkiaSalGraphicsImpl::delayDrawPolyPolygon(const 
basegfx::B2DPolyPolygon& aP
 // so they do not need joining.
 if (aPolyPolygon.count() != 1)
 return false;
+// If the polygon is not closed, it doesn't mark an area to be filled.
+if (!aPolyPolygon.isClosed())
+return false;
 // If a polygon does not contain a straight line, i.e. it's all curves, 
then do not merge.
 // First of all that's even more expensive, and second it's very unlikely 
that it's a polygon
 // split into more polygons.
@@ -870,6 +887,28 @@ bool SkiaSalGraphicsImpl::delayDrawPolyPolygon(const 
basegfx::B2DPolyPolygon& aP
 {
 checkPendingDrawing(); // Cannot be parts of the same larger polygon, 
draw the last and reset.
 }
+if (!mLastPolyPolygonInfo.polygons.empty())
+{
+assert(aPolyPolygon.count() == 1);
+assert(mLastPolyPolygonInfo.polygons.back().count() == 1);
+// Check if the new and the previous polygon share at least one point. 
If not, then they
+// cannot be adjacent polygons, so there's no point in trying to merge 
them.
+bool sharePoint = false;
+const basegfx::B2DPolygon& poly1 = aPolyPolygon.getB2DPolygon(0);
+const basegfx::B2DPolygon& poly2 = 
mLastPolyPolygonInfo.polygons.back().getB2DPolygon(0);
+o3tl::sorted_vector poly1Points; // for 
O(n log n)
+poly1Points.reserve(poly1.count());
+for (sal_uInt32 i = 0; i < poly1.count(); ++i)
+poly1Points.insert(poly1.getB2DPoint(i));
+for (sal_uInt32 i = 0; i < poly2.count(); ++i)
+if (poly1Points.find(poly2.getB2DPoint(i)) != poly1Points.end())
+{
+sharePoint = true;
+break;
+}
+if (!sharePoint)
+checkPendingDrawing(); // Draw the previous one and reset.
+}
 // Collect the polygons that can be possibly merged. Do the merging only 
once at the end,
 // because it's not a cheap operation.
 mLastPolyPolygonInfo.polygons.push_back(aPolyPolygon);
@@ -889,6 +928,8 @@ void SkiaSalGraphicsImpl::checkPendingDrawing()
 if (polygons.size() == 1)
 performDrawPolyPolygon(polygons.front(), transparency, true);
 else
+// TODO: tdf#136222 shows that 
basegfx::utils::mergeToSinglePolyPolygon() is unreliable
+// in corner cases, possibly either a bug or rounding errors 
somewhere.
 
performDrawPolyPolygon(basegfx::utils::mergeToSinglePolyPolygon(polygons), 
transparency,
true);
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: solenv/sanitizers

2020-09-21 Thread Caolán McNamara (via logerrit)
 solenv/sanitizers/ui/modules/BasicIDE.suppr |1 -
 1 file changed, 1 deletion(-)

New commits:
commit f08ddf3d3df0ef12fef36e96ffe6f5b9a7fda9e3
Author: Caolán McNamara 
AuthorDate: Mon Sep 21 14:00:40 2020 +0100
Commit: Caolán McNamara 
CommitDate: Mon Sep 21 16:17:16 2020 +0200

drop unused suppression

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

diff --git a/solenv/sanitizers/ui/modules/BasicIDE.suppr 
b/solenv/sanitizers/ui/modules/BasicIDE.suppr
index 00207b78a217..d504ecaaa2ff 100644
--- a/solenv/sanitizers/ui/modules/BasicIDE.suppr
+++ b/solenv/sanitizers/ui/modules/BasicIDE.suppr
@@ -5,4 +5,3 @@ 
basctl/uiconfig/basicide/ui/defaultlanguage.ui://GtkLabel[@id='added'] orphan-la
 basctl/uiconfig/basicide/ui/defaultlanguage.ui://GtkLabel[@id='alttitle'] 
orphan-label
 basctl/uiconfig/basicide/ui/dockingwatch.ui://GtkButton[@id='remove'] 
button-no-label
 basctl/uiconfig/basicide/ui/managelanguages.ui://GtkLabel[@id='label2'] 
orphan-label
-basctl/uiconfig/basicide/ui/managebreakpoints.ui://GtkEntry[@id='entries'] 
no-labelled-by
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Samuel Mehrbrodt (via logerrit)
 sw/source/core/text/frmcrsr.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 22a1f51add198f0b6378dd1cea63e586e652a02b
Author: Samuel Mehrbrodt 
AuthorDate: Mon Sep 21 14:41:18 2020 +0200
Commit: Samuel Mehrbrodt 
CommitDate: Mon Sep 21 16:12:53 2020 +0200

Fix typo

Change-Id: I2893137c047502a61924136191dee84d65dbfbeb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103104
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt 

diff --git a/sw/source/core/text/frmcrsr.cxx b/sw/source/core/text/frmcrsr.cxx
index 50f0034090be..6a823760a189 100644
--- a/sw/source/core/text/frmcrsr.cxx
+++ b/sw/source/core/text/frmcrsr.cxx
@@ -719,7 +719,7 @@ bool SwTextFrame::RightMargin(SwPaM *pPam, bool bAPI) const
 aLine.CharCursorToLine(MapModelToViewPos(*pPam->GetPoint()));
 nRightMargin = aLine.GetStart() + aLine.GetCurr()->GetLen();
 
-// We skip hard line brakes
+// We skip hard line breaks
 if( aLine.GetCurr()->GetLen() &&
 CH_BREAK == aInf.GetText()[sal_Int32(nRightMargin) - 1])
 --nRightMargin;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Luboš Luňák (via logerrit)
 vcl/skia/x11/textrender.cxx |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 94129b3ed8c158bf61fa0e17ee12a21fb9bf07e6
Author: Luboš Luňák 
AuthorDate: Mon Sep 21 13:28:53 2020 +0200
Commit: Luboš Luňák 
CommitDate: Mon Sep 21 15:34:27 2020 +0200

set properly font X-scale for Skia+X11 (tdf#136891)

Change-Id: I715453f6729363e6bf803f8493d91bb260fb808a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103097
Tested-by: Jenkins
Reviewed-by: Luboš Luňák 

diff --git a/vcl/skia/x11/textrender.cxx b/vcl/skia/x11/textrender.cxx
index 13eff3012721..e8596641c052 100644
--- a/vcl/skia/x11/textrender.cxx
+++ b/vcl/skia/x11/textrender.cxx
@@ -49,6 +49,7 @@ void SkiaTextRender::DrawTextLayout(const GenericSalLayout& 
rLayout, const SalGr
 sk_sp typeface
 = SkFontMgr_createTypefaceFromFcPattern(fontManager, 
rFont.GetFontOptions()->GetPattern());
 SkFont font(typeface, nHeight);
+font.setScaleX(1.0 * nWidth / nHeight);
 // TODO are these correct?
 if (rFont.NeedsArtificialItalic())
 font.setSkewX(-0x6000L / 0x1L);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.4' - emfio/source

2020-09-21 Thread Andras Timar (via logerrit)
 emfio/source/reader/emfreader.cxx |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 5d3eaa832a79695bcf122918997b32f4d3881500
Author: Andras Timar 
AuthorDate: Mon Jan 20 15:46:24 2020 +0100
Commit: Miklos Vajna 
CommitDate: Mon Sep 21 15:28:24 2020 +0200

fix constants according to [MS-EMF] 2.1.10

(cherry picked from commit 971c4135b3a11cd74a13ac0eb4e3aaae4e7dfefd)

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

diff --git a/emfio/source/reader/emfreader.cxx 
b/emfio/source/reader/emfreader.cxx
index e59b7eaa5adc..133b6ccf7f83 100644
--- a/emfio/source/reader/emfreader.cxx
+++ b/emfio/source/reader/emfreader.cxx
@@ -389,8 +389,8 @@ namespace emfio
 
 const sal_uInt32 EMR_COMMENT_BEGINGROUP = 0x0002;
 const sal_uInt32 EMR_COMMENT_ENDGROUP = 0x0003;
-const sal_uInt32 EMR_COMMENT_MULTIFORMATS = 0x0004;
-const sal_uInt32 EMR_COMMENT_WINDOWS_METAFILE = 0x0005;
+const sal_uInt32 EMR_COMMENT_MULTIFORMATS = 0x4004;
+const sal_uInt32 EMR_COMMENT_WINDOWS_METAFILE = 0x8001;
 
 void EmfReader::ReadGDIComment(sal_uInt32 nCommentId)
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: sal/cppunittester

2020-09-21 Thread Stephan Bergmann (via logerrit)
 sal/cppunittester/cppunittester.cxx |9 +++--
 1 file changed, 7 insertions(+), 2 deletions(-)

New commits:
commit 43d08f386117cb1de1fe2ba8248554c1aef1
Author: Stephan Bergmann 
AuthorDate: Mon Sep 21 14:03:14 2020 +0200
Commit: Stephan Bergmann 
CommitDate: Mon Sep 21 15:26:05 2020 +0200

cppunittester: Do not unload test libraries

At least on Windows, e6dfaf9f44f9939abc338c83b3024108431d0f69 "Turn
OUStringLiteral into a consteval'ed, static-refcound rtl_uString" caused
CppunitTest_sc_tablesheetsobj to fail at exit, when the

  static OUString aCacheName

in ScDocument::GetTable (sc/source/core/data/document.cxx) is destroyed but
references

  constexpr OUStringLiteral gaSrcSheetName(u"SheetToCopy")

from test/source/sheet/xspreadsheets2.cxx in Library_subsequenttest, 
referenced
(only) by the CppunitTest_sc_tablesheetsobj library, and both those 
libraries
had already been unloaded from memory.

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

diff --git a/sal/cppunittester/cppunittester.cxx 
b/sal/cppunittester/cppunittester.cxx
index a760ecf8ff41..0a833de5fba2 100644
--- a/sal/cppunittester/cppunittester.cxx
+++ b/sal/cppunittester/cppunittester.cxx
@@ -254,9 +254,14 @@ public:
 // call the initialize methods of the CppUnitTestPlugIns that
 // we statically link to the app executable.
 #else
-CppUnit::PlugInManager manager;
+// The PlugInManager instance is deliberately leaked, so that the 
dynamic libraries it loads
+// are never unloaded (which could make e.g. pointers from other 
libraries' static data
+// structures to const data in those libraries, like some static 
OUString cache pointing at
+// a const OUStringLiteral, become dangling by the time those static 
data structures are
+// destroyed during exit):
+auto manager = new CppUnit::PlugInManager;
 try {
-manager.load(testlib, args);
+manager->load(testlib, args);
 } catch (const CppUnit::DynamicLibraryManagerException &e) {
 std::cerr << "DynamicLibraryManagerException: \"" << e.what() << 
"\"\n";
 #ifdef _WIN32
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Andrea Gelmini (via logerrit)
 idlc/inc/idlctypes.hxx   |2 +-
 idlc/source/errorhandler.cxx |4 ++--
 idlc/source/parser.y |2 +-
 idlc/test/parser/attribute.tests |2 +-
 4 files changed, 5 insertions(+), 5 deletions(-)

New commits:
commit fec332602976676e1689a45ed846488f2484c89e
Author: Andrea Gelmini 
AuthorDate: Sat Aug 22 18:40:29 2020 +0200
Commit: Stephan Bergmann 
CommitDate: Mon Sep 21 15:24:43 2020 +0200

Fix typo in code

Change-Id: Ib026080d70fb7cf97f7f90079dbb4e1f6d77a05e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101197
Tested-by: Jenkins
Reviewed-by: Julien Nabet 
Reviewed-by: Stephan Bergmann 

diff --git a/idlc/inc/idlctypes.hxx b/idlc/inc/idlctypes.hxx
index 639360509968..c7247be6c86d 100644
--- a/idlc/inc/idlctypes.hxx
+++ b/idlc/inc/idlctypes.hxx
@@ -154,7 +154,7 @@ enum ParseState
 PS_BoundSeen,   // Seen BOUND  keyword
 PS_ConstrainedSeen, // Seen CONSTRAINED keyword
 PS_TransientSeen,   // Seen TRANSIENT keyword
-PS_MayBeAmbigiousSeen,  // Seen MAYBEAMBIGIOUS keyword
+PS_MayBeAmbiguousSeen,  // Seen MAYBEAMBIGUOUS keyword
 PS_MayBeDefaultSeen,// Seen MAYBEDEFAULT keyword
 PS_RemoveableSeen,  // Seen REMOVABLE keyword
 
diff --git a/idlc/source/errorhandler.cxx b/idlc/source/errorhandler.cxx
index 6d2d92ea35e5..1e09bb995302 100644
--- a/idlc/source/errorhandler.cxx
+++ b/idlc/source/errorhandler.cxx
@@ -293,8 +293,8 @@ static const char* parseStateToMessage(ParseState state)
 return "Illegal syntax after CONSTRAINED keyword";
 case PS_TransientSeen:
 return "Illegal syntax after TRANSIENT keyword";
-case PS_MayBeAmbigiousSeen:
-return "Illegal syntax after MAYBEAMBIGIOUS keyword";
+case PS_MayBeAmbiguousSeen:
+return "Illegal syntax after MAYBEAMBIGUOUS keyword";
 case PS_MayBeDefaultSeen:
 return "Illegal syntax after MAYBEDEFAULT keyword";
 case PS_RemoveableSeen:
diff --git a/idlc/source/parser.y b/idlc/source/parser.y
index 1d81492562d5..5238f3b5c879 100644
--- a/idlc/source/parser.y
+++ b/idlc/source/parser.y
@@ -805,7 +805,7 @@ opt_attrflag :
 }
 | IDL_MAYBEAMBIGUOUS
 {
-idlc()->setParseState(PS_MayBeAmbigiousSeen);
+idlc()->setParseState(PS_MayBeAmbiguousSeen);
 $$ = AF_MAYBEAMBIGUOUS;
 }
 | IDL_MAYBEDEFAULT
diff --git a/idlc/test/parser/attribute.tests b/idlc/test/parser/attribute.tests
index 73b9d348501a..dd0b85bde9c5 100644
--- a/idlc/test/parser/attribute.tests
+++ b/idlc/test/parser/attribute.tests
@@ -182,7 +182,7 @@ interface I1 {
 
 EXPECT FAILURE "attribute.tests 21":
 interface I1 {
-[attribute, maybeambigious] long a;
+[attribute, maybeambiguous] long a;
 };
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.4' - emfio/inc emfio/source

2020-09-21 Thread Miklos Vajna (via logerrit)
 emfio/inc/emfreader.hxx   |4 +
 emfio/source/reader/emfreader.cxx |   82 +++---
 2 files changed, 80 insertions(+), 6 deletions(-)

New commits:
commit ee2911ad64eb7a84c96e4a0e3e4a1352282129ef
Author: Miklos Vajna 
AuthorDate: Mon Sep 21 08:43:48 2020 +0200
Commit: Miklos Vajna 
CommitDate: Mon Sep 21 15:21:49 2020 +0200

tdf#136836 emfio: speed up import of EMF import when the orig PDF is 
available

The PPTX bugdoc has a 17MB EMF file, which has enough instructions to
keep Impress busy for minutes during import.

Take advantage of the detail that this EMF has a
EMR_COMMENT_MULTIFORMATS record that contains the original PDF, which
can be rendered much faster:

- old cost: 122.153 seconds
- new cost: 1.952 seconds (1.6% of baseline)

(cherry picked from commit d75c5b38911557173c54a78f42ff220ab3918573)

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

diff --git a/emfio/inc/emfreader.hxx b/emfio/inc/emfreader.hxx
index 90d8969ae70c..75a77211ea61 100644
--- a/emfio/inc/emfreader.hxx
+++ b/emfio/inc/emfreader.hxx
@@ -32,6 +32,8 @@ namespace emfio
 boolmbRecordPath : 1;
 boolmbEMFPlus : 1;
 boolmbEMFPlusDualMode : 1;
+/// An other format is read already, can ignore actual EMF data.
+bool mbReadOtherGraphicFormat = false;
 
 boolReadHeader();
 // reads and converts the rectangle
@@ -43,6 +45,8 @@ namespace emfio
 
 bool ReadEnhWMF();
 void ReadGDIComment(sal_uInt32 nCommentId);
+/// Parses EMR_COMMENT_MULTIFORMATS.
+void ReadMultiformatsComment();
 
 private:
 template  void ReadAndDrawPolyPolygon(sal_uInt32 nNextPos);
diff --git a/emfio/source/reader/emfreader.cxx 
b/emfio/source/reader/emfreader.cxx
index 300a4337992f..e59b7eaa5adc 100644
--- a/emfio/source/reader/emfreader.cxx
+++ b/emfio/source/reader/emfreader.cxx
@@ -26,6 +26,8 @@
 #include 
 #include 
 #include 
+#include 
+#include 
 
 #ifdef DBG_UTIL
 #include 
@@ -165,6 +167,8 @@ using namespace std;
 #define EMR_SETLINKEDUFIS  119
 #define EMR_SETTEXTJUSTIFICATION   120
 
+#define PDF_SIGNATURE 0x50444620 // "PDF "
+
 namespace
 {
 
@@ -383,7 +387,6 @@ namespace emfio
 {
 }
 
-#if OSL_DEBUG_LEVEL > 0
 const sal_uInt32 EMR_COMMENT_BEGINGROUP = 0x0002;
 const sal_uInt32 EMR_COMMENT_ENDGROUP = 0x0003;
 const sal_uInt32 EMR_COMMENT_MULTIFORMATS = 0x0004;
@@ -433,7 +436,7 @@ namespace emfio
 break;
 
 case EMR_COMMENT_MULTIFORMATS:
-SAL_WARN("emfio", "\t\tEMR_COMMENT_MULTIFORMATS not 
implemented");
+ReadMultiformatsComment();
 break;
 
 case EMR_COMMENT_WINDOWS_METAFILE:
@@ -445,11 +448,78 @@ namespace emfio
 break;
 }
 }
-#else
-void EmfReader::ReadGDIComment(sal_uInt32)
+
+void EmfReader::ReadMultiformatsComment()
 {
+tools::Rectangle aOutputRect = EmfReader::ReadRectangle();
+
+sal_uInt32 nCountFormats;
+mpInputStream->ReadUInt32(nCountFormats);
+if (nCountFormats < 1)
+{
+return;
+}
+
+// Read the first EmrFormat.
+sal_uInt32 nSignature;
+mpInputStream->ReadUInt32(nSignature);
+if (nSignature != PDF_SIGNATURE)
+{
+return;
+}
+
+sal_uInt32 nVersion;
+mpInputStream->ReadUInt32(nVersion);
+if (nVersion != 1)
+{
+return;
+}
+
+sal_uInt32 nSizeData;
+mpInputStream->ReadUInt32(nSizeData);
+if (!nSizeData || nSizeData > mpInputStream->remainingSize())
+{
+return;
+}
+
+sal_uInt32 nOffData;
+mpInputStream->ReadUInt32(nOffData);
+if (!nOffData)
+{
+return;
+}
+
+std::vector aPdfData(nSizeData);
+mpInputStream->ReadBytes(aPdfData.data(), aPdfData.size());
+if (!mpInputStream->good())
+{
+return;
+}
+
+SvMemoryStream aPdfStream;
+aPdfStream.WriteBytes(aPdfData.data(), aPdfData.size());
+aPdfStream.Seek(0);
+Graphic aGraphic;
+if (!vcl::ImportPDF(aPdfStream, aGraphic))
+{
+return;
+}
+
+maBmpSaveList.emplace_back(new BSaveStruct(aGraphic.GetBitmapEx(), 
aOutputRect, SRCCOPY));
+const std::shared_ptr pVectorGraphicData
+= aGraphic.getVectorGraphicData();
+if (!pVectorGraphicData)
+{
+return;
+}
+
+if (pVectorGraphicData->getVectorGraphicDataType() != 
VectorGraphicDataType::Pdf)
+{
+return;
+}
+
+mbReadOtherGraphicForm

[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.4' - emfio/inc emfio/source

2020-09-21 Thread Chris Sherlock (via logerrit)
 emfio/inc/emfreader.hxx   |1 
 emfio/source/reader/emfreader.cxx |  267 +-
 emfio/source/reader/mtftools.cxx  |6 
 3 files changed, 211 insertions(+), 63 deletions(-)

New commits:
commit 6fe626727e35b837511851f2e4ea79f61e90586d
Author: Chris Sherlock 
AuthorDate: Wed Nov 20 15:16:07 2019 +1100
Commit: Miklos Vajna 
CommitDate: Mon Sep 21 15:05:58 2020 +0200

emfio: extra logging

For emfio I believe we need more logging, so I am gradually adding this.
I decided to log the EMR_COMMENT_PUBLIC record subtypes
EMR_COMMENT_BEGINGROUP and EMR_COMMENT_ENDGROUP.

I honestly don't know what these actually do, but they are specified in
[MS-EMF] 2.3.3.4.1 and 2.3.3.4.2. Later on, we will need to look into
handling EMR_COMMENT_MULTIFORMATS so we can display things with EPS
data. We should also probably look into handling
EMR_COMMENT_WINDOWS_METAFILE later on also.

(cherry picked from commit debb38c7be8015b4de4aace6f8ac78e4ee2fbfa6)

Conflicts:
emfio/source/reader/emfreader.cxx

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

diff --git a/emfio/inc/emfreader.hxx b/emfio/inc/emfreader.hxx
index a54eee1a9c70..90d8969ae70c 100644
--- a/emfio/inc/emfreader.hxx
+++ b/emfio/inc/emfreader.hxx
@@ -42,6 +42,7 @@ namespace emfio
 ~EmfReader();
 
 bool ReadEnhWMF();
+void ReadGDIComment(sal_uInt32 nCommentId);
 
 private:
 template  void ReadAndDrawPolyPolygon(sal_uInt32 nNextPos);
diff --git a/emfio/source/reader/emfreader.cxx 
b/emfio/source/reader/emfreader.cxx
index 6a974085d887..300a4337992f 100644
--- a/emfio/source/reader/emfreader.cxx
+++ b/emfio/source/reader/emfreader.cxx
@@ -375,7 +375,7 @@ namespace emfio
 , mnRecordCount(0)
 , mbRecordPath(false)
 , mbEMFPlus(false)
-,mbEMFPlusDualMode(false)
+, mbEMFPlusDualMode(false)
 {
 }
 
@@ -383,6 +383,74 @@ namespace emfio
 {
 }
 
+#if OSL_DEBUG_LEVEL > 0
+const sal_uInt32 EMR_COMMENT_BEGINGROUP = 0x0002;
+const sal_uInt32 EMR_COMMENT_ENDGROUP = 0x0003;
+const sal_uInt32 EMR_COMMENT_MULTIFORMATS = 0x0004;
+const sal_uInt32 EMR_COMMENT_WINDOWS_METAFILE = 0x0005;
+
+void EmfReader::ReadGDIComment(sal_uInt32 nCommentId)
+{
+sal_uInt32 nPublicCommentIdentifier;
+mpInputStream->ReadUInt32(nPublicCommentIdentifier);
+
+SAL_INFO("emfio", "\t\tEMR_COMMENT_PUBLIC, id: 0x" << std::hex << 
nCommentId << std::dec);
+switch (nPublicCommentIdentifier)
+{
+case EMR_COMMENT_BEGINGROUP:
+{
+SAL_INFO("emfio", "\t\t\tEMR_COMMENT_BEGINGROUP");
+sal_uInt32 left, top, right, bottom;
+
mpInputStream->ReadUInt32(left).ReadUInt32(top).ReadUInt32(right).ReadUInt32(bottom);
+
+SAL_INFO("emfio", "\t\t\t\tBounding rect");
+SAL_INFO("emfio", "\t\t\t\t\tLeft: " << left);
+SAL_INFO("emfio", "\t\t\t\t\tTop: " << top);
+SAL_INFO("emfio", "\t\t\t\t\tRight: " << right);
+SAL_INFO("emfio", "\t\t\t\t\tBottom: " << bottom);
+
+sal_uInt32 nDescChars;
+mpInputStream->ReadUInt32(nDescChars);
+
+OUString aDesc;
+for (sal_uInt32 i=0; i < nDescChars; i++)
+{
+sal_uInt16 cChar(0);
+mpInputStream->ReadUInt16(cChar);
+if (cChar == '\0')
+break;
+
+sal_Unicode cUniChar = static_cast(cChar);
+aDesc = aDesc.concat(OUString(cUniChar));
+}
+
+SAL_INFO("emfio", "\t\tDescription: " << aDesc);
+}
+break;
+
+case EMR_COMMENT_ENDGROUP:
+SAL_INFO("emfio", "\t\t\tEMR_COMMENT_ENDGROUP");
+break;
+
+case EMR_COMMENT_MULTIFORMATS:
+SAL_WARN("emfio", "\t\tEMR_COMMENT_MULTIFORMATS not 
implemented");
+break;
+
+case EMR_COMMENT_WINDOWS_METAFILE:
+SAL_WARN("emfio", "\t\tEMR_COMMENT_WINDOWS_METAFILE not 
implemented");
+break;
+
+default:
+SAL_WARN("emfio", "\t\tEMR_COMMENT_PUBLIC not implemented, id: 
0x" << std::hex << nCommentId << std::dec);
+break;
+}
+}
+#else
+void EmfReader::ReadGDIComment(sal_uInt32)
+{
+}
+#endif
+
 void EmfReader::ReadEMFPlusComment(sal_uInt32 length, bool& bHaveDC)
 {
 if (!mbEMFPlus)
@@ -425,14 +493,14 @@ namespace emfio
 mpInputStream->ReadUInt16( type ).ReadUInt16( flags ).ReadUInt32( 
size ).ReadUInt32( dataSize );
 nRemai

[Libreoffice-commits] core.git: Branch 'libreoffice-7-0' - oox/qa oox/source sd/qa

2020-09-21 Thread Miklos Vajna (via logerrit)
 oox/qa/unit/data/shape-text-alignment.pptx |binary
 oox/qa/unit/drawingml.cxx  |   20 +++
 oox/source/drawingml/shape.cxx |3 
 oox/source/drawingml/textbodypropertiescontext.cxx |5 
 sd/qa/unit/data/xml/n762695_0.xml  |6 -
 sd/qa/unit/data/xml/n762695_1.xml  |   10 -
 sd/qa/unit/data/xml/n819614_0.xml  |  114 ++---
 sd/qa/unit/data/xml/n820786_0.xml  |  102 +-
 sd/qa/unit/data/xml/tdf109317_0.xml|   12 +-
 sd/qa/unit/import-tests.cxx|7 -
 10 files changed, 153 insertions(+), 126 deletions(-)

New commits:
commit 876f1ddab04fc6d655638274fb90dd601bd3039f
Author: Miklos Vajna 
AuthorDate: Fri Sep 18 17:53:33 2020 +0200
Commit: Caolán McNamara 
CommitDate: Mon Sep 21 14:56:57 2020 +0200

tdf#129685 PPTX import: fix unexpected centering of shape text

Regression from commit 89f0af144c18efafe2573801641689a1432c0cae (tdf#113198 
set
default shape paragraph alignment.., 2019-11-19), the old bugdoc had this
markup:

 (centered)

The new bugdoc has 2 shapes with text:

 (aligned to left)
 (should be centered)

"anchor" is about vertical, "anchorCtr" is about horizontal centering of 
text.

Checking what the binary filter does, it maps horizontal centering to
TextHorizontalAdjust, so fix the original bug differently, by leaving
ParaAdjust alone, and tweaking TextHorizontalAdjust intead: this keeps the 
old
bugdoc working but fixes the new one.

This caused a number of "change detector" XML-based tests to fail: all of 
them
are unchanged visually, so the XML files are adapted to the new state.

The tdf#113198 fix itself was fixing a regression from tdf#104722, and that
commit had no testcase, I tested that we don't regress there, manually.

(cherry picked from commit 10bb02efd8afd42e633e370480104e2575546d8e)

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

diff --git a/oox/qa/unit/data/shape-text-alignment.pptx 
b/oox/qa/unit/data/shape-text-alignment.pptx
new file mode 100644
index ..ff4ff06f2fdf
Binary files /dev/null and b/oox/qa/unit/data/shape-text-alignment.pptx differ
diff --git a/oox/qa/unit/drawingml.cxx b/oox/qa/unit/drawingml.cxx
index d88f91797304..43609435c468 100644
--- a/oox/qa/unit/drawingml.cxx
+++ b/oox/qa/unit/drawingml.cxx
@@ -24,6 +24,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -226,6 +227,25 @@ CPPUNIT_TEST_FIXTURE(OoxDrawingmlTest, 
testGradientMultiStepTransparency)
 CPPUNIT_ASSERT_EQUAL(static_cast(0xff), 
aTransparence.EndColor);
 }
 
+CPPUNIT_TEST_FIXTURE(OoxDrawingmlTest, testShapeTextAlignment)
+{
+OUString aURL = m_directories.getURLFromSrc(DATA_DIRECTORY) + 
"shape-text-alignment.pptx";
+load(aURL);
+
+uno::Reference 
xDrawPagesSupplier(getComponent(), uno::UNO_QUERY);
+uno::Reference 
xDrawPage(xDrawPagesSupplier->getDrawPages()->getByIndex(0),
+ uno::UNO_QUERY);
+uno::Reference xShape(xDrawPage->getByIndex(0), 
uno::UNO_QUERY);
+sal_Int16 nParaAdjust = -1;
+CPPUNIT_ASSERT(xShape->getPropertyValue("ParaAdjust") >>= nParaAdjust);
+// Without the accompanying fix in place, this test would have failed with:
+// - Expected: 0
+// - Actual  : 3
+// i.e. text which is meant to be left-aligned was centered at a paragraph 
level.
+CPPUNIT_ASSERT_EQUAL(style::ParagraphAdjust_LEFT,
+ static_cast(nParaAdjust));
+}
+
 CPPUNIT_PLUGIN_IMPLEMENT();
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/oox/source/drawingml/shape.cxx b/oox/source/drawingml/shape.cxx
index ec162e0ade7c..0973a0790e33 100644
--- a/oox/source/drawingml/shape.cxx
+++ b/oox/source/drawingml/shape.cxx
@@ -209,7 +209,8 @@ void Shape::setDefaults(bool bHeight)
 if (bHeight)
 maDefaultShapeProperties.setProperty(PROP_CharHeight, static_cast< 
float >( 18.0 ));
 maDefaultShapeProperties.setProperty(PROP_TextVerticalAdjust, 
TextVerticalAdjust_TOP);
-maDefaultShapeProperties.setProperty(PROP_ParaAdjust, static_cast< 
sal_Int16 >( ParagraphAdjust_CENTER ));
+maDefaultShapeProperties.setProperty(PROP_ParaAdjust,
+ 
static_cast(ParagraphAdjust_LEFT));
 }
 
 ::oox::vml::OleObjectInfo& Shape::setOleObjectType()
diff --git a/oox/source/drawingml/textbodypropertiescontext.cxx 
b/oox/source/drawingml/textbodypropertiescontext.cxx
index c70b50273b2f..b72fa194401a 100644
--- a/oox/source/drawingml/textbodypropertiescontext.cxx
+++ b/oox/source/drawingml/textbodypropertiescontext.cxx
@@ -116,6 +116,11 @@ TextBodyPropertiesContext::TextBodyPropertiesC

[Libreoffice-commits] online.git: common/MessageQueue.cpp

2020-09-21 Thread Gabriel Masei (via logerrit)
 common/MessageQueue.cpp |5 +
 1 file changed, 5 insertions(+)

New commits:
commit 95c9c58f5b3f8116aef348f48ce4583df59718a2
Author: Gabriel Masei 
AuthorDate: Mon Sep 21 09:46:38 2020 +0300
Commit: Jan Holesovsky 
CommitDate: Mon Sep 21 14:51:10 2020 +0200

remove .uno:ModifiedStatus message from deduplication mechanism

This fixes the following issue in Online:

When a save is performed while a cell is still edited the save icon
does not reflect the correct state of the document: it shows that
the document is dirty although it is not.

This works only in conjunction with the following commit from core:
-lok: remove .uno:ModifiedStatus message from deduplication mechanism-

Change-Id: Ie671097ef2b206c8801a5bdfc2b908ee260951fb
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/103084
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Jan Holesovsky 

diff --git a/common/MessageQueue.cpp b/common/MessageQueue.cpp
index f239a2e9c..632c696b3 100644
--- a/common/MessageQueue.cpp
+++ b/common/MessageQueue.cpp
@@ -324,6 +324,11 @@ std::string TileQueue::removeCallbackDuplicate(const 
std::string& callbackMsg)
 if (unoCommand.empty())
 return std::string();
 
+// This is needed because otherwise it creates some problems when
+// a save occurs while a cell is still edited in Calc.
+if (unoCommand == ".uno:ModifiedStatus")
+return std::string();
+
 // remove obsolete states of the same .uno: command
 for (std::size_t i = 0; i < getQueue().size(); ++i)
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: cypress_test/plugins

2020-09-21 Thread Tamás Zolnai (via logerrit)
 cypress_test/plugins/blacklists.js |   60 +
 1 file changed, 60 insertions(+)

New commits:
commit 1d26d6513ba8fe733effb0c573d0d6c756907d6d
Author: Tamás Zolnai 
AuthorDate: Mon Sep 21 14:00:57 2020 +0200
Commit: Tamás Zolnai 
CommitDate: Mon Sep 21 14:49:21 2020 +0200

cypress: disable multi-user tests for NC / php-proxy.

Change-Id: I3393a1fb0b998bd82295d6d566594ed05af50634
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/103102
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Tamás Zolnai 

diff --git a/cypress_test/plugins/blacklists.js 
b/cypress_test/plugins/blacklists.js
index 4101d9172..cf2edb893 100644
--- a/cypress_test/plugins/blacklists.js
+++ b/cypress_test/plugins/blacklists.js
@@ -77,6 +77,36 @@ var nextcloudBlackList = [
'Print'
]
],
+   ['multiuser/calc/sheet_operations_user1_spec.js',
+   []
+   ],
+   ['multiuser/calc/sheet_operations_user2_spec.js',
+   []
+   ],
+   ['multiuser/impress/slide_operations_user1_spec.js',
+   []
+   ],
+   ['multiuser/impress/slide_operations_user2_spec.js',
+   []
+   ],
+   ['multiuser/writer/paragraph_prop_user1_spec.js',
+   []
+   ],
+   ['multiuser/writer/paragraph_prop_user2_spec.js',
+   []
+   ],
+   ['multiuser/writer/sidebar_visibility_user1_spec.js',
+   []
+   ],
+   ['multiuser/writer/sidebar_visibility_user2_spec.js',
+   []
+   ],
+   ['multiuser/writer/simultaneous_typing_user1_spec.js',
+   []
+   ],
+   ['multiuser/writer/simultaneous_typing_user2_spec.js',
+   []
+   ],
 ];
 
 var phpProxyBlackList = [
@@ -101,6 +131,36 @@ var phpProxyBlackList = [
['desktop/calc/focus_spec.js',
[]
],
+   ['multiuser/calc/sheet_operations_user1_spec.js',
+   []
+   ],
+   ['multiuser/calc/sheet_operations_user2_spec.js',
+   []
+   ],
+   ['multiuser/impress/slide_operations_user1_spec.js',
+   []
+   ],
+   ['multiuser/impress/slide_operations_user2_spec.js',
+   []
+   ],
+   ['multiuser/writer/paragraph_prop_user1_spec.js',
+   []
+   ],
+   ['multiuser/writer/paragraph_prop_user2_spec.js',
+   []
+   ],
+   ['multiuser/writer/sidebar_visibility_user1_spec.js',
+   []
+   ],
+   ['multiuser/writer/sidebar_visibility_user2_spec.js',
+   []
+   ],
+   ['multiuser/writer/simultaneous_typing_user1_spec.js',
+   []
+   ],
+   ['multiuser/writer/simultaneous_typing_user2_spec.js',
+   []
+   ],
 ];
 
 module.exports.coreBlackLists = coreBlackLists;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Gabriel Masei (via logerrit)
 desktop/source/lib/init.cxx|   15 ++-
 sc/source/ui/view/tabvwsha.cxx |   19 ---
 2 files changed, 22 insertions(+), 12 deletions(-)

New commits:
commit 137440e161f0f8631e7e67ba0609680d6686fa94
Author: Gabriel Masei 
AuthorDate: Wed Sep 2 19:22:23 2020 +0300
Commit: Jan Holesovsky 
CommitDate: Mon Sep 21 14:39:17 2020 +0200

lok: remove .uno:ModifiedStatus message from deduplication mechanism

This fixes the following issue in Online:

When a save is performed while a cell is still edited the save icon
does not reflect the correct state of the document: it shows that
the document is dirty although it is not. This is generated by two facts:

1. The status cache is avoided when sending the -dirty- status right
after the cell editing is finished. Because the cache has an old value
of -false- for ModifiedStatus, the notification that is sent after saving,
with -false- value, is ignored. We should not avoid the status cache.

2. Because there is a mechanism that keeps only the last notification
value for a status change in the queue that keeps messages that were not
sent yet (deduplication), the .uno:ModifiedStatus message with a value of 
-true-
that is enqueued right after the cell edit is finished is replaced by the 
same
message with a value of -false- that is enqueued after the save is finished.
This happens if the flush mechanism doesn't occur between them.

Change-Id: I3348bf230ba53a154c29e7d8ab064df7694adeae
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101948
Tested-by: Jenkins
Reviewed-by: Jan Holesovsky 

diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index a5c2b7c4ea8b..ecef209842a8 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -1571,11 +1571,16 @@ void CallbackFlushHandler::queue(const int type, const 
char* data)
 if (pos != std::string::npos)
 {
 const std::string name = payload.substr(0, pos + 1);
-removeAll(
-[type, &name] (const queue_type::value_type& elem) {
-return (elem.Type == type) && 
(elem.PayloadString.compare(0, name.size(), name) == 0);
-}
-);
+// This is needed because otherwise it creates some 
problems when
+// a save occurs while a cell is still edited in Calc.
+if (name != ".uno:ModifiedStatus=")
+{
+removeAll(
+[type, &name] (const queue_type::value_type& elem) 
{
+return (elem.Type == type) && 
(elem.PayloadString.compare(0, name.size(), name) == 0);
+}
+);
+}
 }
 }
 break;
diff --git a/sc/source/ui/view/tabvwsha.cxx b/sc/source/ui/view/tabvwsha.cxx
index 210500e651d9..211a047c9bb1 100644
--- a/sc/source/ui/view/tabvwsha.cxx
+++ b/sc/source/ui/view/tabvwsha.cxx
@@ -742,20 +742,25 @@ void ScTabViewShell::ExecuteSave( SfxRequest& rReq )
 // Finish entering unless 'DontTerminateEdit' is specified, even if a 
formula is being processed
 if (bCommitChanges)
 {
+SC_MOD()->InputEnterHandler();
+
 if (comphelper::LibreOfficeKit::isActive())
 {
 // Normally this isn't needed, but in Calc when editing a cell 
formula
 // and manually saving (without changing cells or hitting enter), 
while
 // InputEnterHandler will mark the doc as modified (when it is), 
because
 // we will save the doc immediately afterwards, the modified state 
event
-// is clobbered. To avoid that, we notify all views immediately of 
the
-// modified state, apply the modification, then save the document.
-ScInputHandler* pHdl = GetInputHandler();
-if (pHdl != nullptr && pHdl->GetModified())
-SfxLokHelper::notifyAllViews(LOK_CALLBACK_STATE_CHANGED, 
".uno:ModifiedStatus=true");
+// is clobbered. To avoid that, we need to update SID_DOC_MODIFIED 
so that
+// a possible state of "true" after "InputEnterHandler" will be 
sent
+// as a notification. It is important that the notification goes 
through
+// normal process (cache) rather than directly notifying the views.
+// Otherwise, because there is a previous state of "false" in 
cache, the
+// "false" state after saving will be ignored.
+// This will work only if .uno:ModifiedStatus message will be 
removed from
+// the mechanism that keeps in the message queue only last message 
of
+// a particular status even if the values are different.
+
GetViewData().GetDocShell()->Ge

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

2020-09-21 Thread Luboš Luňák (via logerrit)
 vcl/skia/gdiimpl.cxx |   41 +
 1 file changed, 41 insertions(+)

New commits:
commit 859596233146590f7ebac1f05bbb83ce5ea8aac4
Author: Luboš Luňák 
AuthorDate: Fri Sep 18 10:19:33 2020 +0200
Commit: Luboš Luňák 
CommitDate: Mon Sep 21 14:33:11 2020 +0200

do not try to merge polygons if they do not share a point (tdf#136222)

If two polygons do not share a point, then they do not share an edge,
so they cannot be adjacent polygons. As a side-effect this avoids
the problem with tdf#136222, as it turns out
basegfx::utils::mergeToSinglePolyPolygon() is broken with polygons
that are almost but not quite adjacent.

Change-Id: Ibf290cc886d7c337fd04c925b551b2e7773a6b70
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102985
Reviewed-by: Noel Grandin 
Reviewed-by: Luboš Luňák 
Tested-by: Jenkins

diff --git a/vcl/skia/gdiimpl.cxx b/vcl/skia/gdiimpl.cxx
index f6abc2ffb6fb..a5a8b00b9b0c 100644
--- a/vcl/skia/gdiimpl.cxx
+++ b/vcl/skia/gdiimpl.cxx
@@ -40,6 +40,7 @@
 #include 
 #include 
 #include 
+#include 
 
 namespace
 {
@@ -849,6 +850,19 @@ void SkiaSalGraphicsImpl::performDrawPolyPolygon(const 
basegfx::B2DPolyPolygon&
 #endif
 }
 
+namespace
+{
+struct LessThan
+{
+bool operator()(const basegfx::B2DPoint& point1, const basegfx::B2DPoint& 
point2) const
+{
+if (basegfx::fTools::equal(point1.getX(), point2.getX()))
+return basegfx::fTools::less(point1.getY(), point2.getY());
+return basegfx::fTools::less(point1.getX(), point2.getX());
+}
+};
+} // namespace
+
 bool SkiaSalGraphicsImpl::delayDrawPolyPolygon(const basegfx::B2DPolyPolygon& 
aPolyPolygon,
double fTransparency)
 {
@@ -877,6 +891,9 @@ bool SkiaSalGraphicsImpl::delayDrawPolyPolygon(const 
basegfx::B2DPolyPolygon& aP
 // so they do not need joining.
 if (aPolyPolygon.count() != 1)
 return false;
+// If the polygon is not closed, it doesn't mark an area to be filled.
+if (!aPolyPolygon.isClosed())
+return false;
 // If a polygon does not contain a straight line, i.e. it's all curves, 
then do not merge.
 // First of all that's even more expensive, and second it's very unlikely 
that it's a polygon
 // split into more polygons.
@@ -889,6 +906,28 @@ bool SkiaSalGraphicsImpl::delayDrawPolyPolygon(const 
basegfx::B2DPolyPolygon& aP
 {
 checkPendingDrawing(); // Cannot be parts of the same larger polygon, 
draw the last and reset.
 }
+if (!mLastPolyPolygonInfo.polygons.empty())
+{
+assert(aPolyPolygon.count() == 1);
+assert(mLastPolyPolygonInfo.polygons.back().count() == 1);
+// Check if the new and the previous polygon share at least one point. 
If not, then they
+// cannot be adjacent polygons, so there's no point in trying to merge 
them.
+bool sharePoint = false;
+const basegfx::B2DPolygon& poly1 = aPolyPolygon.getB2DPolygon(0);
+const basegfx::B2DPolygon& poly2 = 
mLastPolyPolygonInfo.polygons.back().getB2DPolygon(0);
+o3tl::sorted_vector poly1Points; // for 
O(n log n)
+poly1Points.reserve(poly1.count());
+for (sal_uInt32 i = 0; i < poly1.count(); ++i)
+poly1Points.insert(poly1.getB2DPoint(i));
+for (sal_uInt32 i = 0; i < poly2.count(); ++i)
+if (poly1Points.find(poly2.getB2DPoint(i)) != poly1Points.end())
+{
+sharePoint = true;
+break;
+}
+if (!sharePoint)
+checkPendingDrawing(); // Draw the previous one and reset.
+}
 // Collect the polygons that can be possibly merged. Do the merging only 
once at the end,
 // because it's not a cheap operation.
 mLastPolyPolygonInfo.polygons.push_back(aPolyPolygon);
@@ -908,6 +947,8 @@ void SkiaSalGraphicsImpl::checkPendingDrawing()
 if (polygons.size() == 1)
 performDrawPolyPolygon(polygons.front(), transparency, true);
 else
+// TODO: tdf#136222 shows that 
basegfx::utils::mergeToSinglePolyPolygon() is unreliable
+// in corner cases, possibly either a bug or rounding errors 
somewhere.
 
performDrawPolyPolygon(basegfx::utils::mergeToSinglePolyPolygon(polygons), 
transparency,
true);
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: emfio/CppunitTest_emfio_emf.mk emfio/CppunitTest_emfio_emf_test.mk emfio/CppunitTest_emfio_wmf.mk emfio/CppunitTest_emfio_wmf_test.mk emfio/Module_emfio.mk

2020-09-21 Thread Miklos Vajna (via logerrit)
 emfio/Module_emfio.mk |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit b637a607eadaae19e5f6d1004127019dde410798
Author: Miklos Vajna 
AuthorDate: Mon Sep 21 13:24:35 2020 +0200
Commit: Miklos Vajna 
CommitDate: Mon Sep 21 14:30:27 2020 +0200

emfio: fix emf/wmf test cppunit name vs makefile name

The convention is that CppunitTest_foo is defined in CppunitTest_foo.mk,
but we got an extra "_test" suffix here, fix that.

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

diff --git a/emfio/CppunitTest_emfio_emf_test.mk 
b/emfio/CppunitTest_emfio_emf.mk
similarity index 100%
rename from emfio/CppunitTest_emfio_emf_test.mk
rename to emfio/CppunitTest_emfio_emf.mk
diff --git a/emfio/CppunitTest_emfio_wmf_test.mk 
b/emfio/CppunitTest_emfio_wmf.mk
similarity index 100%
rename from emfio/CppunitTest_emfio_wmf_test.mk
rename to emfio/CppunitTest_emfio_wmf.mk
diff --git a/emfio/Module_emfio.mk b/emfio/Module_emfio.mk
index c4d5ec70be9c..96b69d1cbe86 100644
--- a/emfio/Module_emfio.mk
+++ b/emfio/Module_emfio.mk
@@ -23,8 +23,8 @@ $(eval $(call gb_Module_add_targets,emfio,\
 ))
 
 $(eval $(call gb_Module_add_check_targets,emfio,\
-CppunitTest_emfio_emf_test \
-   $(if $(MERGELIBS),,CppunitTest_emfio_wmf_test) \
+CppunitTest_emfio_emf \
+   $(if $(MERGELIBS),,CppunitTest_emfio_wmf) \
 ))
 
 # vim: set noet ts=4 sw=4:
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'feature/cib_contract3753' - filter/source include/oox oox/source sc/source sw/source

2020-09-21 Thread Michael Stahl (via logerrit)
 filter/source/msfilter/escherex.cxx  |   20 -
 include/oox/export/vmlexport.hxx |7 +-
 oox/source/export/vmlexport.cxx  |   22 +-
 sc/source/filter/xcl97/xcl97rec.cxx  |2 
 sw/source/filter/ww8/docxattributeoutput.cxx |   91 +--
 sw/source/filter/ww8/docxattributeoutput.hxx |6 +
 sw/source/filter/ww8/docxsdrexport.cxx   |6 +
 7 files changed, 94 insertions(+), 60 deletions(-)

New commits:
commit d879c7bea3fe819933ecb5d83b46e52b1f929105
Author: Michael Stahl 
AuthorDate: Fri Sep 18 11:47:56 2020 +0200
Commit: Michael Stahl 
CommitDate: Mon Sep 21 14:29:04 2020 +0200

tdf#136620 tdf#136708 filter,oox,sw: fix export of 2 different wraps

This reverts commit 2cb90a5c87fe46737c8d840967d8836284f92ffd.

Revert the change to EscherPropertyContainer, which was completely
bogus, based on pre-existing bogus code in VMLExport::Commit().

The problem is that ESCHER_Wrap values are for wrapping text *inside* a
text box, which is "mso-wrap-style" in VML, whereas VML's w10:wrap
element defines how text wraps *around* a shape, doesn't exist as an
ESCHER property and is specific to Word formats.

Instead, export the w10:wrap element in VMLExport::EndShape().

This has 2 callers, WriteActiveXControl() and writeVMLDrawing().

Furthermore the value "none" wasn't written for WrapTextMode_THROUGH,
which caused the wrap element to be omitted in that case.

Change-Id: Id4a01fcb2ea73fa9bef4ee8769b5e0680e059f15
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103009
Tested-by: Jenkins
Reviewed-by: Michael Stahl 
(cherry picked from commit fdc8590032b292dcb8152b328401e591fea642a4)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103090
Reviewed-by: Caolán McNamara 
(cherry picked from commit c54d697e2ac379d4b1a3ff5acb6f06bff30cadd6)

diff --git a/filter/source/msfilter/escherex.cxx 
b/filter/source/msfilter/escherex.cxx
index a2071237deb7..f04043e9156a 100644
--- a/filter/source/msfilter/escherex.cxx
+++ b/filter/source/msfilter/escherex.cxx
@@ -66,7 +66,6 @@
 #include 
 #include 
 #include 
-#include 
 #include 
 #include 
 #include 
@@ -700,10 +699,6 @@ void EscherPropertyContainer::CreateTextProperties(
 bool bWordWrap  ( false );
 bool bAutoGrowSize  ( false );
 
-uno::Any aTextWrap;
-
-EscherPropertyValueHelper::GetPropertyValue(aTextWrap, rXPropSet, 
"TextWrap", true);
-
 if ( EscherPropertyValueHelper::GetPropertyValue( aAny, rXPropSet, 
"TextWritingMode", true ) )
 aAny >>= eWM;
 if ( EscherPropertyValueHelper::GetPropertyValue( aAny, rXPropSet, 
"TextVerticalAdjust", true ) )
@@ -842,21 +837,6 @@ void EscherPropertyContainer::CreateTextProperties(
 nTextAttr |= 0x20002;
 }
 }
-
-if (aTextWrap.hasValue())
-{   // explicit text wrap overrides whatever was inferred previously
-switch (aTextWrap.get())
-{
-case text::WrapTextMode_THROUGH:
-eWrapMode = ESCHER_WrapNone;
-break;
-// in theory there are 3 more Escher_Wrap, but [MS-ODRAW] says 
they are useless
-default:
-eWrapMode = ESCHER_WrapSquare;
-break;
-}
-}
-
 AddOpt( ESCHER_Prop_dxTextLeft, nLeft * 360 );
 AddOpt( ESCHER_Prop_dxTextRight, nRight * 360 );
 AddOpt( ESCHER_Prop_dyTextTop, nTop * 360 );
diff --git a/include/oox/export/vmlexport.hxx b/include/oox/export/vmlexport.hxx
index 7c2d3a62da6f..3736420756a6 100644
--- a/include/oox/export/vmlexport.hxx
+++ b/include/oox/export/vmlexport.hxx
@@ -80,8 +80,9 @@ class OOX_DLLPUBLIC VMLExport : public EscherEx
 /// Parent exporter, used for text callback.
 VMLTextExport* m_pTextExport;
 
-/// Anchoring.
+/// Anchoring - Writer specific properties
 sal_Int16 m_eHOri, m_eVOri, m_eHRel, m_eVRel;
+std::unique_ptr m_pWrapAttrList;
 bool m_bInline; // css::text::TextContentAnchorType_AS_CHARACTER
 
 /// The object we're exporting.
@@ -139,7 +140,9 @@ public:
 /// Call this when you need to export the object as VML.
 OString const & AddSdrObject( const SdrObject& rObj, sal_Int16 eHOri = -1,
 sal_Int16 eVOri = -1, sal_Int16 eHRel = -1,
-sal_Int16 eVRel = -1, const bool bOOxmlExport = false );
+sal_Int16 eVRel = -1,
+std::unique_ptr m_pWrapAttrList 
= nullptr,
+const bool bOOxmlExport = false );
 OString const & AddInlineSdrObject( const SdrObject& rObj, const bool 
bOOxmlExport );
 virtual void  AddSdrObjectVMLObject( const SdrObject& rObj) override;
 static bool IsWaterMarkShape(const OUString& rStr);
diff --git a/oox/source/export/vmlexport.cxx b/oox/source/export/vmlexport.cxx
index ee93cf32bd27..2009d9ccf055 100644
--- a/oox/source/export/vmlexport.cxx
+++ b/oox/source/export/vmlexport.cxx

[Libreoffice-commits] core.git: Branch 'libreoffice-7-0' - emfio/CppunitTest_emfio_emf_test.mk emfio/inc emfio/qa emfio/source include/vcl offapi/com svx/source vcl/source

2020-09-21 Thread Miklos Vajna (via logerrit)
 emfio/CppunitTest_emfio_emf_test.mk |   15 --
 emfio/inc/emfreader.hxx |2 
 emfio/qa/cppunit/emf/EmfImportTest.cxx  |   57 +++-
 emfio/qa/cppunit/emf/data/pdf-in-emf.pptx   |binary
 emfio/source/emfuno/xemfparser.cxx  |   15 +-
 emfio/source/reader/emfreader.cxx   |4 +
 include/vcl/pdfread.hxx |3 -
 include/vcl/vectorgraphicdata.hxx   |   10 
 offapi/com/sun/star/graphic/XEmfParser.idl  |8 +++
 svx/source/sdr/properties/defaultproperties.cxx |   16 ++
 vcl/source/filter/ipdf/pdfread.cxx  |   21 +++-
 vcl/source/gdi/vectorgraphicdata.cxx|   12 -
 12 files changed, 141 insertions(+), 22 deletions(-)

New commits:
commit 69842afcab0c5043c3c554493dd92d58c2bb02af
Author: Miklos Vajna 
AuthorDate: Fri Sep 18 17:52:41 2020 +0200
Commit: Miklos Vajna 
CommitDate: Mon Sep 21 14:00:40 2020 +0200

[API CHANGE] tdf#136836 emfio: set size hint on inner PDF if used as shape 
fill

The bugdoc has a shape, its bitmap fill is an EMF, which is actually a
PDF. The PDF is has a height of 5cm, but the shape has a height of 14
cm.

Inform vcl::RenderPDFBitmaps() about the size of the shape, so the
result won't be blurry. This approach makes sure that we don't
unconditionally render at higher resolution, i.e. the "load a PDF of 100
pages into Online" use-case won't use more memory than before.

API CHANGE, because the EMF reader is only available via UNO, though
it's likely that no actual external code would ever invoke it directly.

(cherry picked from commit 01024ee24c6e89044c68051f6fd5f1264905e90c)

Conflicts:
include/vcl/vectorgraphicdata.hxx
vcl/source/gdi/vectorgraphicdata.cxx

Change-Id: If1d8def0136d408a31a0cc54777a7f26430a0ff3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103087
Tested-by: Jenkins
Reviewed-by: Gülşah Köse 

diff --git a/emfio/CppunitTest_emfio_emf_test.mk 
b/emfio/CppunitTest_emfio_emf_test.mk
index 123e4b3549bd..5b32187b7ea8 100644
--- a/emfio/CppunitTest_emfio_emf_test.mk
+++ b/emfio/CppunitTest_emfio_emf_test.mk
@@ -38,20 +38,7 @@ $(eval $(call gb_CppunitTest_use_libraries,emfio_emf,\
 $(eval $(call gb_CppunitTest_use_ure,emfio_emf))
 $(eval $(call gb_CppunitTest_use_vcl,emfio_emf))
 
-$(eval $(call gb_CppunitTest_use_components,emfio_emf,\
-configmgr/source/configmgr \
-dtrans/util/mcnttype \
-emfio/emfio \
-framework/util/fwk \
-i18npool/util/i18npool \
-package/source/xstor/xstor \
-package/util/package2 \
-toolkit/util/tk \
-sfx2/util/sfx \
-ucb/source/core/ucb1 \
-ucb/source/ucp/file/ucpfile1 \
-unotools/util/utl \
-))
+$(eval $(call gb_CppunitTest_use_rdb,emfio_emf,services))
 
 $(eval $(call gb_CppunitTest_use_configuration,emfio_emf))
 
diff --git a/emfio/inc/emfreader.hxx b/emfio/inc/emfreader.hxx
index 75a77211ea61..c6caa0fb9f26 100644
--- a/emfio/inc/emfreader.hxx
+++ b/emfio/inc/emfreader.hxx
@@ -34,6 +34,7 @@ namespace emfio
 boolmbEMFPlusDualMode : 1;
 /// An other format is read already, can ignore actual EMF data.
 bool mbReadOtherGraphicFormat = false;
+basegfx::B2DTuple maSizeHint;
 
 boolReadHeader();
 // reads and converts the rectangle
@@ -47,6 +48,7 @@ namespace emfio
 void ReadGDIComment(sal_uInt32 nCommentId);
 /// Parses EMR_COMMENT_MULTIFORMATS.
 void ReadMultiformatsComment();
+void SetSizeHint(const basegfx::B2DTuple& rSizeHint) { maSizeHint = 
rSizeHint; }
 
 private:
 template  void ReadAndDrawPolyPolygon(sal_uInt32 nNextPos);
diff --git a/emfio/qa/cppunit/emf/EmfImportTest.cxx 
b/emfio/qa/cppunit/emf/EmfImportTest.cxx
index ac435905d570..5ee4ad9e224a 100644
--- a/emfio/qa/cppunit/emf/EmfImportTest.cxx
+++ b/emfio/qa/cppunit/emf/EmfImportTest.cxx
@@ -12,6 +12,12 @@
 
 #include 
 #include 
+#include 
+
+#include 
+#include 
+#include 
+#include 
 
 #include 
 #include 
@@ -26,14 +32,17 @@
 namespace
 {
 
+using namespace css;
 using namespace css::uno;
 using namespace css::io;
 using namespace css::graphic;
 using drawinglayer::primitive2d::Primitive2DSequence;
 using drawinglayer::primitive2d::Primitive2DContainer;
 
-class Test : public test::BootstrapFixture, public XmlTestTools
+class Test : public test::BootstrapFixture, public XmlTestTools, public 
unotest::MacrosTest
 {
+uno::Reference mxComponent;
+
 void checkRectPrimitive(Primitive2DSequence const & rPrimitive);
 
 void testWorking();
@@ -41,19 +50,40 @@ class Test : public test::BootstrapFixture, public 
XmlTestTools
 void TestDrawStringTransparent();
 void TestDrawLine();
 void TestLinearGradient();
+void TestPdfInEmf();
 
 Primitive2DSequence parseEmf(const OUString& aSource);
 
 public:
+void setUp() 

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

2020-09-21 Thread Miklos Vajna (via logerrit)
 emfio/inc/emfreader.hxx   |4 +
 emfio/source/reader/emfreader.cxx |   82 +++---
 2 files changed, 80 insertions(+), 6 deletions(-)

New commits:
commit f1494915d40f4bdb3e25bd35427ba7b773b91838
Author: Miklos Vajna 
AuthorDate: Mon Sep 21 08:43:48 2020 +0200
Commit: Miklos Vajna 
CommitDate: Mon Sep 21 13:59:23 2020 +0200

tdf#136836 emfio: speed up import of EMF import when the orig PDF is 
available

The PPTX bugdoc has a 17MB EMF file, which has enough instructions to
keep Impress busy for minutes during import.

Take advantage of the detail that this EMF has a
EMR_COMMENT_MULTIFORMATS record that contains the original PDF, which
can be rendered much faster:

- old cost: 122.153 seconds
- new cost: 1.952 seconds (1.6% of baseline)

(cherry picked from commit d75c5b38911557173c54a78f42ff220ab3918573)

Change-Id: I38efc1c24e21a7622377b9e1c1938ebee826bae9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103086
Tested-by: Jenkins
Reviewed-by: Gülşah Köse 

diff --git a/emfio/inc/emfreader.hxx b/emfio/inc/emfreader.hxx
index 90d8969ae70c..75a77211ea61 100644
--- a/emfio/inc/emfreader.hxx
+++ b/emfio/inc/emfreader.hxx
@@ -32,6 +32,8 @@ namespace emfio
 boolmbRecordPath : 1;
 boolmbEMFPlus : 1;
 boolmbEMFPlusDualMode : 1;
+/// An other format is read already, can ignore actual EMF data.
+bool mbReadOtherGraphicFormat = false;
 
 boolReadHeader();
 // reads and converts the rectangle
@@ -43,6 +45,8 @@ namespace emfio
 
 bool ReadEnhWMF();
 void ReadGDIComment(sal_uInt32 nCommentId);
+/// Parses EMR_COMMENT_MULTIFORMATS.
+void ReadMultiformatsComment();
 
 private:
 template  void ReadAndDrawPolyPolygon(sal_uInt32 nNextPos);
diff --git a/emfio/source/reader/emfreader.cxx 
b/emfio/source/reader/emfreader.cxx
index 5d2749d16356..7bb4d408203a 100644
--- a/emfio/source/reader/emfreader.cxx
+++ b/emfio/source/reader/emfreader.cxx
@@ -24,6 +24,8 @@
 #include 
 #include 
 #include 
+#include 
+#include 
 
 #ifdef DBG_UTIL
 #include 
@@ -163,6 +165,8 @@ using namespace std;
 #define EMR_SETLINKEDUFIS  119
 #define EMR_SETTEXTJUSTIFICATION   120
 
+#define PDF_SIGNATURE 0x50444620 // "PDF "
+
 namespace
 {
 
@@ -381,7 +385,6 @@ namespace emfio
 {
 }
 
-#if OSL_DEBUG_LEVEL > 0
 const sal_uInt32 EMR_COMMENT_BEGINGROUP = 0x0002;
 const sal_uInt32 EMR_COMMENT_ENDGROUP = 0x0003;
 const sal_uInt32 EMR_COMMENT_MULTIFORMATS = 0x4004;
@@ -431,7 +434,7 @@ namespace emfio
 break;
 
 case EMR_COMMENT_MULTIFORMATS:
-SAL_WARN("emfio", "\t\tEMR_COMMENT_MULTIFORMATS not 
implemented");
+ReadMultiformatsComment();
 break;
 
 case EMR_COMMENT_WINDOWS_METAFILE:
@@ -443,11 +446,78 @@ namespace emfio
 break;
 }
 }
-#else
-void EmfReader::ReadGDIComment(sal_uInt32)
+
+void EmfReader::ReadMultiformatsComment()
 {
+tools::Rectangle aOutputRect = EmfReader::ReadRectangle();
+
+sal_uInt32 nCountFormats;
+mpInputStream->ReadUInt32(nCountFormats);
+if (nCountFormats < 1)
+{
+return;
+}
+
+// Read the first EmrFormat.
+sal_uInt32 nSignature;
+mpInputStream->ReadUInt32(nSignature);
+if (nSignature != PDF_SIGNATURE)
+{
+return;
+}
+
+sal_uInt32 nVersion;
+mpInputStream->ReadUInt32(nVersion);
+if (nVersion != 1)
+{
+return;
+}
+
+sal_uInt32 nSizeData;
+mpInputStream->ReadUInt32(nSizeData);
+if (!nSizeData || nSizeData > mpInputStream->remainingSize())
+{
+return;
+}
+
+sal_uInt32 nOffData;
+mpInputStream->ReadUInt32(nOffData);
+if (!nOffData)
+{
+return;
+}
+
+std::vector aPdfData(nSizeData);
+mpInputStream->ReadBytes(aPdfData.data(), aPdfData.size());
+if (!mpInputStream->good())
+{
+return;
+}
+
+SvMemoryStream aPdfStream;
+aPdfStream.WriteBytes(aPdfData.data(), aPdfData.size());
+aPdfStream.Seek(0);
+Graphic aGraphic;
+if (!vcl::ImportPDF(aPdfStream, aGraphic))
+{
+return;
+}
+
+maBmpSaveList.emplace_back(new BSaveStruct(aGraphic.GetBitmapEx(), 
aOutputRect, SRCCOPY));
+const std::shared_ptr pVectorGraphicData
+= aGraphic.getVectorGraphicData();
+if (!pVectorGraphicData)
+{
+return;
+}
+
+if (pVectorGraphicData->getVectorGraphicDataType() != 
VectorGraphicDataType::Pdf)
+{
+return;
+}
+
+mbReadOtherGraphicFormat = true;
 }

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

2020-09-21 Thread Stephan Bergmann (via logerrit)
 xmloff/source/text/txtparae.cxx |  110 
 1 file changed, 55 insertions(+), 55 deletions(-)

New commits:
commit 121771e37f7e2de41cd5643475861062bf25627b
Author: Stephan Bergmann 
AuthorDate: Mon Sep 21 09:17:54 2020 +0200
Commit: Stephan Bergmann 
CommitDate: Mon Sep 21 13:28:27 2020 +0200

Make some OUStringLiteral vars constexpr

...to see if that helps silence cid#1467018 PARSE_ERROR.  (Plus, it is 
arguably
the better choice to have OUStringLiteral vars be constexpr than just 
const, so
they themselves can take part in larger constant expressions.  I just 
thought it
wouldn't make much difference in practice for now, so I didn't do that 
wholesale
in e6dfaf9f44f9939abc338c83b3024108431d0f69 "Turn OUStringLiteral into a
consteval'ed, static-refcound rtl_uString" to not make that change bigger 
than
it already was.  Similarly for 4b9e440c51be3e40326bc90c33ae69885bfb51e4 
"Turn
OStringLiteral into a consteval'ed, static-refcound rtl_String".)

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

diff --git a/xmloff/source/text/txtparae.cxx b/xmloff/source/text/txtparae.cxx
index 09e923957221..c33eec54ddf9 100644
--- a/xmloff/source/text/txtparae.cxx
+++ b/xmloff/source/text/txtparae.cxx
@@ -126,61 +126,61 @@ using namespace ::xmloff;
 using namespace ::xmloff::token;
 
 // Implement Title/Description Elements UI (#i73249#)
-const OUStringLiteral gsTitle(u"Title");
-const OUStringLiteral gsDescription(u"Description");
-const OUStringLiteral gsAnchorPageNo(u"AnchorPageNo");
-const OUStringLiteral gsAnchorType(u"AnchorType");
-const OUStringLiteral gsBookmark(u"Bookmark");
-const OUStringLiteral gsChainNextName(u"ChainNextName");
-const OUStringLiteral gsContourPolyPolygon(u"ContourPolyPolygon");
-const OUStringLiteral gsDocumentIndexMark(u"DocumentIndexMark");
-const OUStringLiteral gsFrame(u"Frame");
-const OUStringLiteral gsGraphicFilter(u"GraphicFilter");
-const OUStringLiteral gsGraphicRotation(u"GraphicRotation");
-const OUStringLiteral gsHeight(u"Height");
-const OUStringLiteral gsHoriOrient(u"HoriOrient");
-const OUStringLiteral gsHoriOrientPosition(u"HoriOrientPosition");
-const OUStringLiteral gsHyperLinkName(u"HyperLinkName");
-const OUStringLiteral gsHyperLinkTarget(u"HyperLinkTarget");
-const OUStringLiteral gsHyperLinkURL(u"HyperLinkURL");
-const OUStringLiteral gsIsAutomaticContour(u"IsAutomaticContour");
-const OUStringLiteral gsIsCollapsed(u"IsCollapsed");
-const OUStringLiteral gsIsPixelContour(u"IsPixelContour");
-const OUStringLiteral gsIsStart(u"IsStart");
-const OUStringLiteral gsIsSyncHeightToWidth(u"IsSyncHeightToWidth");
-const OUStringLiteral gsIsSyncWidthToHeight(u"IsSyncWidthToHeight");
-const OUStringLiteral gsNumberingRules(u"NumberingRules");
-const OUStringLiteral gsParaConditionalStyleName(u"ParaConditionalStyleName");
-const OUStringLiteral gsParagraphService(u"com.sun.star.text.Paragraph");
-const OUStringLiteral gsRedline(u"Redline");
-const OUStringLiteral gsReferenceMark(u"ReferenceMark");
-const OUStringLiteral gsRelativeHeight(u"RelativeHeight");
-const OUStringLiteral gsRelativeWidth(u"RelativeWidth");
-const OUStringLiteral gsRuby(u"Ruby");
-const OUStringLiteral gsRubyCharStyleName(u"RubyCharStyleName");
-const OUStringLiteral gsRubyText(u"RubyText");
-const OUStringLiteral gsServerMap(u"ServerMap");
-const OUStringLiteral gsShapeService(u"com.sun.star.drawing.Shape");
-const OUStringLiteral gsSizeType(u"SizeType");
-const OUStringLiteral gsSoftPageBreak( u"SoftPageBreak"  );
-const OUStringLiteral gsTableService(u"com.sun.star.text.TextTable");
-const OUStringLiteral gsText(u"Text");
-const OUStringLiteral gsTextContentService(u"com.sun.star.text.TextContent");
-const OUStringLiteral 
gsTextEmbeddedService(u"com.sun.star.text.TextEmbeddedObject");
-const OUStringLiteral gsTextField(u"TextField");
-const OUStringLiteral gsTextFieldService(u"com.sun.star.text.TextField");
-const OUStringLiteral gsTextFrameService(u"com.sun.star.text.TextFrame");
-const OUStringLiteral 
gsTextGraphicService(u"com.sun.star.text.TextGraphicObject");
-const OUStringLiteral gsTextPortionType(u"TextPortionType");
-const OUStringLiteral gsUnvisitedCharStyleName(u"UnvisitedCharStyleName");
-const OUStringLiteral gsVertOrient(u"VertOrient");
-const OUStringLiteral gsVertOrientPosition(u"VertOrientPosition");
-const OUStringLiteral gsVisitedCharStyleName(u"VisitedCharStyleName");
-const OUStringLiteral gsWidth(u"Width");
-const OUStringLiteral gsWidthType( u"WidthType"  );
-const OUStringLiteral gsTextFieldStart( u"TextFieldStart"  );
-const OUStringLiteral gsTextFieldEnd( u"TextFieldEnd"  );
-const OUStringLiteral gsTextFieldStartEnd( u"TextFieldStartEnd"  );
+constexpr OUStringLiteral gsTitle(u"Title");
+constexpr OUStringLiteral gsDescription(u"Description");
+constexpr OUSt

[Libreoffice-commits] core.git: include/o3tl

2020-09-21 Thread Caolán McNamara (via logerrit)
 include/o3tl/deleter.hxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 649a625cb585af244a3d5e57911670784fa87c40
Author: Caolán McNamara 
AuthorDate: Mon Sep 21 11:37:44 2020 +0100
Commit: Caolán McNamara 
CommitDate: Mon Sep 21 13:20:53 2020 +0200

missing identifier

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

diff --git a/include/o3tl/deleter.hxx b/include/o3tl/deleter.hxx
index 72d13d086de1..a886acb03d3c 100644
--- a/include/o3tl/deleter.hxx
+++ b/include/o3tl/deleter.hxx
@@ -32,7 +32,7 @@ template struct default_delete
 {
 delete p;
 }
-catch (const css::uno::Exception&)
+catch (const css::uno::Exception& ex)
 {
 SAL_WARN("vcl.app", "Fatal exception: " << exceptionToString(ex));
 std::terminate();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-0' - filter/source include/oox oox/source sc/source sw/source

2020-09-21 Thread Michael Stahl (via logerrit)
 filter/source/msfilter/escherex.cxx  |   20 -
 include/oox/export/vmlexport.hxx |7 +-
 oox/source/export/vmlexport.cxx  |   22 +-
 sc/source/filter/xcl97/xcl97rec.cxx  |2 
 sw/source/filter/ww8/docxattributeoutput.cxx |   91 +--
 sw/source/filter/ww8/docxattributeoutput.hxx |6 +
 sw/source/filter/ww8/docxsdrexport.cxx   |6 +
 7 files changed, 94 insertions(+), 60 deletions(-)

New commits:
commit c54d697e2ac379d4b1a3ff5acb6f06bff30cadd6
Author: Michael Stahl 
AuthorDate: Fri Sep 18 11:47:56 2020 +0200
Commit: Caolán McNamara 
CommitDate: Mon Sep 21 13:15:04 2020 +0200

tdf#136620 tdf#136708 filter,oox,sw: fix export of 2 different wraps

This reverts commit 2cb90a5c87fe46737c8d840967d8836284f92ffd.

Revert the change to EscherPropertyContainer, which was completely
bogus, based on pre-existing bogus code in VMLExport::Commit().

The problem is that ESCHER_Wrap values are for wrapping text *inside* a
text box, which is "mso-wrap-style" in VML, whereas VML's w10:wrap
element defines how text wraps *around* a shape, doesn't exist as an
ESCHER property and is specific to Word formats.

Instead, export the w10:wrap element in VMLExport::EndShape().

This has 2 callers, WriteActiveXControl() and writeVMLDrawing().

Furthermore the value "none" wasn't written for WrapTextMode_THROUGH,
which caused the wrap element to be omitted in that case.

Change-Id: Id4a01fcb2ea73fa9bef4ee8769b5e0680e059f15
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103009
Tested-by: Jenkins
Reviewed-by: Michael Stahl 
(cherry picked from commit fdc8590032b292dcb8152b328401e591fea642a4)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103090
Reviewed-by: Caolán McNamara 

diff --git a/filter/source/msfilter/escherex.cxx 
b/filter/source/msfilter/escherex.cxx
index 8bf8c779af64..443d533ecadb 100644
--- a/filter/source/msfilter/escherex.cxx
+++ b/filter/source/msfilter/escherex.cxx
@@ -61,7 +61,6 @@
 #include 
 #include 
 #include 
-#include 
 #include 
 #include 
 #include 
@@ -693,10 +692,6 @@ void EscherPropertyContainer::CreateTextProperties(
 bool bWordWrap  ( false );
 bool bAutoGrowSize  ( false );
 
-uno::Any aTextWrap;
-
-EscherPropertyValueHelper::GetPropertyValue(aTextWrap, rXPropSet, 
"TextWrap", true);
-
 if ( EscherPropertyValueHelper::GetPropertyValue( aAny, rXPropSet, 
"TextWritingMode", true ) )
 aAny >>= eWM;
 if ( EscherPropertyValueHelper::GetPropertyValue( aAny, rXPropSet, 
"TextVerticalAdjust", true ) )
@@ -835,21 +830,6 @@ void EscherPropertyContainer::CreateTextProperties(
 nTextAttr |= 0x20002;
 }
 }
-
-if (aTextWrap.hasValue())
-{   // explicit text wrap overrides whatever was inferred previously
-switch (aTextWrap.get())
-{
-case text::WrapTextMode_THROUGH:
-eWrapMode = ESCHER_WrapNone;
-break;
-// in theory there are 3 more Escher_Wrap, but [MS-ODRAW] says 
they are useless
-default:
-eWrapMode = ESCHER_WrapSquare;
-break;
-}
-}
-
 AddOpt( ESCHER_Prop_dxTextLeft, nLeft * 360 );
 AddOpt( ESCHER_Prop_dxTextRight, nRight * 360 );
 AddOpt( ESCHER_Prop_dyTextTop, nTop * 360 );
diff --git a/include/oox/export/vmlexport.hxx b/include/oox/export/vmlexport.hxx
index 71d3441fdaaa..07a07c8c5b3b 100644
--- a/include/oox/export/vmlexport.hxx
+++ b/include/oox/export/vmlexport.hxx
@@ -80,8 +80,9 @@ class OOX_DLLPUBLIC VMLExport : public EscherEx
 /// Parent exporter, used for text callback.
 VMLTextExport* m_pTextExport;
 
-/// Anchoring.
+/// Anchoring - Writer specific properties
 sal_Int16 m_eHOri, m_eVOri, m_eHRel, m_eVRel;
+std::unique_ptr m_pWrapAttrList;
 bool m_bInline; // css::text::TextContentAnchorType_AS_CHARACTER
 
 /// The object we're exporting.
@@ -139,7 +140,9 @@ public:
 /// Call this when you need to export the object as VML.
 OString const & AddSdrObject( const SdrObject& rObj, sal_Int16 eHOri = -1,
 sal_Int16 eVOri = -1, sal_Int16 eHRel = -1,
-sal_Int16 eVRel = -1, const bool bOOxmlExport = false );
+sal_Int16 eVRel = -1,
+std::unique_ptr m_pWrapAttrList 
= nullptr,
+const bool bOOxmlExport = false );
 OString const & AddInlineSdrObject( const SdrObject& rObj, const bool 
bOOxmlExport );
 virtual void  AddSdrObjectVMLObject( const SdrObject& rObj) override;
 static bool IsWaterMarkShape(const OUString& rStr);
diff --git a/oox/source/export/vmlexport.cxx b/oox/source/export/vmlexport.cxx
index 79733db5ced0..54eba8b7ee1e 100644
--- a/oox/source/export/vmlexport.cxx
+++ b/oox/source/export/vmlexport.cxx
@@ -421,11 +421,15 @@ void VMLExport::Commit( EscherPropertyContainer&

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

2020-09-21 Thread Michael Stahl (via logerrit)
 sw/source/ui/misc/bookmark.cxx |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 88084ceca708a343fc79249f91eb9de34d26b3e9
Author: Michael Stahl 
AuthorDate: Fri Sep 18 17:12:38 2020 +0200
Commit: Caolán McNamara 
CommitDate: Mon Sep 21 13:11:45 2020 +0200

tdf#135879 sw: fix bookmark dialog's Delete button

(regression from cb5d18871b46ef4f7bc47eb4d71df5374d712575)

Change-Id: Ic8c66504a760ef26fbf95a5a1a13b37346982024
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103015
Tested-by: Jenkins
Reviewed-by: Michael Stahl 
(cherry picked from commit fefcad1186232b26180d095bbafdf8e8bdda8209)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103049
Reviewed-by: Caolán McNamara 

diff --git a/sw/source/ui/misc/bookmark.cxx b/sw/source/ui/misc/bookmark.cxx
index be22962fcf8d..731fe0651cf7 100644
--- a/sw/source/ui/misc/bookmark.cxx
+++ b/sw/source/ui/misc/bookmark.cxx
@@ -164,6 +164,7 @@ IMPL_LINK_NOARG(SwInsertBookmarkDlg, SelectionChangedHdl, 
weld::TreeView&, void)
 m_xInsertBtn->set_sensitive(false);
 m_xGotoBtn->set_sensitive(nSelectedRows == 1);
 m_xRenameBtn->set_sensitive(nSelectedRows == 1 && !m_bAreProtected);
+m_xDeleteBtn->set_sensitive(!m_bAreProtected);
 m_xEditBox->set_text(sEditBoxText.makeStringAndClear());
 }
 else
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Jan-Marek Glogowski (via logerrit)
 vcl/source/font/fontcharmap.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 229aca48befa4bdb52041ce6d0dca16a87b778e4
Author: Jan-Marek Glogowski 
AuthorDate: Sat Sep 19 11:53:27 2020 +0200
Commit: Caolán McNamara 
CommitDate: Mon Sep 21 12:59:45 2020 +0200

Fix crash from broken font CMAP subtable

ParseCMAP crashes on a broken CMAP subtable of a font used by the
bugdoc of tdf#119074, which returns a negative offset (technically
it's large positive offset turning into a wrong negative integer,
which is still out of bounds of the CMAP overall size - you get
the point). This simply ignores that broken subtable, checking for
other existing ones.

Regressed-by: c7482bc2904401e7d975b5721ec861b8589253f9
Change-Id: I95820fe3bb6bd2fe2e0cf9d4c3536abce31fd497
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103033
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit 9bf4c5ac49b73cc2a8c89a87ff87238c061a579d)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103046
Reviewed-by: Jan-Marek Glogowski 

diff --git a/vcl/source/font/fontcharmap.cxx b/vcl/source/font/fontcharmap.cxx
index 5e83e19cefb1..027df3ce6df1 100644
--- a/vcl/source/font/fontcharmap.cxx
+++ b/vcl/source/font/fontcharmap.cxx
@@ -151,7 +151,7 @@ bool ParseCMAP( const unsigned char* pCmap, int nLength, 
CmapResult& rResult )
 
 int nTmpOffset = GetUInt( p+4 );
 
-if (nTmpOffset + 2 > nLength)
+if (nTmpOffset + 2 > nLength || nTmpOffset < 0)
 continue;
 
 int nTmpFormat = GetUShort( pCmap + nTmpOffset );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Caolán McNamara (via logerrit)
 vcl/unx/gtk3/gtk3gtkinst.cxx |   32 ++--
 1 file changed, 26 insertions(+), 6 deletions(-)

New commits:
commit 64387d6e0546719f7853facade35d1d3fa2abc2a
Author: Caolán McNamara 
AuthorDate: Sun Sep 20 19:07:44 2020 +0100
Commit: Caolán McNamara 
CommitDate: Mon Sep 21 12:57:35 2020 +0200

add some more thaw/freeze uses

to try and squeeze out a little more performance.

Its plausible that disconnecting the model from treeview with
gtk_tree_view_set_model(..., nullptr) no longer improves times.  If we 
didn't
do that, then we could thaw/freeze without losing what nodes are expanded 
and
the current scroll pos.

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

diff --git a/vcl/unx/gtk3/gtk3gtkinst.cxx b/vcl/unx/gtk3/gtk3gtkinst.cxx
index 94574376acf2..f707a0e473f1 100644
--- a/vcl/unx/gtk3/gtk3gtkinst.cxx
+++ b/vcl/unx/gtk3/gtk3gtkinst.cxx
@@ -2887,10 +2887,12 @@ public:
 virtual void freeze() override
 {
 gtk_widget_freeze_child_notify(m_pWidget);
+g_object_freeze_notify(G_OBJECT(m_pWidget));
 }
 
 virtual void thaw() override
 {
+g_object_thaw_notify(G_OBJECT(m_pWidget));
 gtk_widget_thaw_child_notify(m_pWidget);
 }
 
@@ -10694,6 +10696,8 @@ public:
 
 virtual void all_foreach(const std::function& func) 
override
 {
+g_object_freeze_notify(G_OBJECT(m_pTreeModel));
+
 GtkInstanceTreeIter aGtkIter(nullptr);
 if (get_iter_first(aGtkIter))
 {
@@ -10703,10 +10707,14 @@ public:
 break;
 } while (iter_next(aGtkIter));
 }
+
+g_object_thaw_notify(G_OBJECT(m_pTreeModel));
 }
 
 virtual void selected_foreach(const std::function& 
func) override
 {
+g_object_freeze_notify(G_OBJECT(m_pTreeModel));
+
 GtkInstanceTreeIter aGtkIter(nullptr);
 
 GtkTreeModel* pModel;
@@ -10719,10 +10727,14 @@ public:
 break;
 }
 g_list_free_full(pList, 
reinterpret_cast(gtk_tree_path_free));
+
+g_object_thaw_notify(G_OBJECT(m_pTreeModel));
 }
 
 virtual void visible_foreach(const std::function& 
func) override
 {
+g_object_freeze_notify(G_OBJECT(m_pTreeModel));
+
 GtkTreePath* start_path;
 GtkTreePath* end_path;
 
@@ -10747,6 +10759,8 @@ public:
 
 gtk_tree_path_free(start_path);
 gtk_tree_path_free(end_path);
+
+g_object_thaw_notify(G_OBJECT(m_pTreeModel));
 }
 
 virtual void connect_visible_range_changed(const Link& rLink) override
@@ -11430,9 +11444,10 @@ public:
 virtual void freeze() override
 {
 disable_notify_events();
-g_object_ref(m_pTreeModel);
 GtkInstanceContainer::freeze();
+g_object_ref(m_pTreeModel);
 gtk_tree_view_set_model(m_pTreeView, nullptr);
+g_object_freeze_notify(G_OBJECT(m_pTreeModel));
 if (m_xSorter)
 {
 int nSortColumn;
@@ -11457,9 +11472,10 @@ public:
 m_aSavedSortTypes.pop_back();
 m_aSavedSortColumns.pop_back();
 }
+g_object_thaw_notify(G_OBJECT(m_pTreeModel));
 gtk_tree_view_set_model(m_pTreeView, GTK_TREE_MODEL(m_pTreeModel));
-GtkInstanceContainer::thaw();
 g_object_unref(m_pTreeModel);
+GtkInstanceContainer::thaw();
 enable_notify_events();
 }
 
@@ -12036,18 +12052,20 @@ public:
 virtual void freeze() override
 {
 disable_notify_events();
-g_object_ref(m_pTreeStore);
 GtkInstanceContainer::freeze();
+g_object_ref(m_pTreeStore);
 gtk_icon_view_set_model(m_pIconView, nullptr);
+g_object_freeze_notify(G_OBJECT(m_pTreeStore));
 enable_notify_events();
 }
 
 virtual void thaw() override
 {
 disable_notify_events();
+g_object_thaw_notify(G_OBJECT(m_pTreeStore));
 gtk_icon_view_set_model(m_pIconView, GTK_TREE_MODEL(m_pTreeStore));
-GtkInstanceContainer::thaw();
 g_object_unref(m_pTreeStore);
+GtkInstanceContainer::thaw();
 enable_notify_events();
 }
 
@@ -14926,9 +14944,10 @@ public:
 virtual void freeze() override
 {
 disable_notify_events();
-g_object_ref(m_pTreeModel);
 GtkInstanceContainer::freeze();
+g_object_ref(m_pTreeModel);
 gtk_tree_view_set_model(m_pTreeView, nullptr);
+g_object_freeze_notify(G_OBJECT(m_pTreeModel));
 if (m_xSorter)
 {
 GtkTreeSortable* pSortable = GTK_TREE_SORTABLE(m_pTreeModel);
@@ -14945,10 +14964,11 @@ public:
 GtkTreeSortable* pSortable = GTK_TREE_SORTABLE(m_pTreeModel);
 gtk_tree_sortable_set_sort_column_id(pSortable, m_nTextCol, 
GTK_SORT_ASCENDING);
 }
+g_object_thaw_notify(G_

[Libreoffice-commits] online.git: loleaflet/src

2020-09-21 Thread Tamás Zolnai (via logerrit)
 loleaflet/src/core/Socket.js |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 4f41ac60968d478fbbb27be0632b6defafe17744
Author: Tamás Zolnai 
AuthorDate: Fri Sep 18 16:29:01 2020 +0200
Commit: Tamás Zolnai 
CommitDate: Mon Sep 21 12:54:56 2020 +0200

Fix missing InputBar and sidebar in Calc.

_isReady() can be true even if the _docLayer is not
created yet and in this case we dropped the window
messages which should have triggered the input bar
and the sidebar creation.

cypress tests were failing because of this issue sometimes.

Change-Id: Ifda1d66c952c65c420db06bfd61918411426ae93
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/103010
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Tamás Zolnai 

diff --git a/loleaflet/src/core/Socket.js b/loleaflet/src/core/Socket.js
index 750e98bd6..0cfe7003f 100644
--- a/loleaflet/src/core/Socket.js
+++ b/loleaflet/src/core/Socket.js
@@ -892,7 +892,7 @@ L.Socket = L.Class.extend({
}
 
var msgDelayed = false;
-   if (!this._isReady() || this._delayedMessages.length || 
this._handlingDelayedMessages) {
+   if (!this._isReady() || !this._map._docLayer || 
this._delayedMessages.length || this._handlingDelayedMessages) {
msgDelayed = this._tryToDelayMessage(textMsg);
}
 
@@ -919,7 +919,7 @@ L.Socket = L.Class.extend({
},
 
_handleDelayedMessages: function() {
-   if (!this._isReady() || this._handlingDelayedMessages) {
+   if (!this._isReady() || !this._map._docLayer || 
this._handlingDelayedMessages) {
var that = this;
// Retry in a bit.
this._delayedMsgHandlerTimeoutId = 
setTimeout(function() {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Jean-Pierre Ledure (via logerrit)
 wizards/source/access2base/access2base.py |2 --
 1 file changed, 2 deletions(-)

New commits:
commit 13512bf5ef004e7388ad15b3c3c91377c90c3623
Author: Jean-Pierre Ledure 
AuthorDate: Mon Sep 21 12:31:03 2020 +0200
Commit: Jean-Pierre Ledure 
CommitDate: Mon Sep 21 12:31:03 2020 +0200

Access2Base - access2base.py, remove compatibility import

Change-Id: I0f390758e17c09c3cec8a86c22cdfc3a8d39cc17

diff --git a/wizards/source/access2base/access2base.py 
b/wizards/source/access2base/access2base.py
index 77878e0053bc..87734ebbb17f 100644
--- a/wizards/source/access2base/access2base.py
+++ b/wizards/source/access2base/access2base.py
@@ -36,8 +36,6 @@ Specific documentation about Access2Base and Python:
 
http://www.access2base.com/access2base.html#%5B%5BAccess2Base%20and%20Python%5D%5D
 """
 
-from __future__ import unicode_literals
-
 import uno
 XSCRIPTCONTEXT = uno
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Stephan Bergmann (via logerrit)
 vcl/source/font/fontcharmap.cxx |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 8cc52b0573c64cf5eb62ebe3098cd964c437
Author: Stephan Bergmann 
AuthorDate: Mon Sep 21 10:59:39 2020 +0200
Commit: Stephan Bergmann 
CommitDate: Mon Sep 21 12:16:35 2020 +0200

Missing include

(for std::max, since f8474367449a1b6b54918d2753e3a36798761839 "ofz#25774 
keep
ParseCMAP within legal area")

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

diff --git a/vcl/source/font/fontcharmap.cxx b/vcl/source/font/fontcharmap.cxx
index f7db9fd65ead..d672c76c5f42 100644
--- a/vcl/source/font/fontcharmap.cxx
+++ b/vcl/source/font/fontcharmap.cxx
@@ -21,6 +21,7 @@
 #include 
 #include 
 
+#include 
 #include 
 #include 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Caolán McNamara (via logerrit)
 vcl/source/font/fontcharmap.cxx |   17 ++---
 1 file changed, 14 insertions(+), 3 deletions(-)

New commits:
commit fb733dea0c172c8a692cf66f66c5457591be314a
Author: Caolán McNamara 
AuthorDate: Fri Sep 18 19:33:15 2020 +0100
Commit: Michael Stahl 
CommitDate: Mon Sep 21 12:12:28 2020 +0200

ofz#25774 keep ParseCMAP within legal area

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

diff --git a/vcl/source/font/fontcharmap.cxx b/vcl/source/font/fontcharmap.cxx
index 9ba392935c60..5e83e19cefb1 100644
--- a/vcl/source/font/fontcharmap.cxx
+++ b/vcl/source/font/fontcharmap.cxx
@@ -189,12 +189,23 @@ bool ParseCMAP( const unsigned char* pCmap, int nLength, 
CmapResult& rResult )
 nRangeCount = 0;
 }
 
-pCodePairs = new sal_UCS4[ nRangeCount * 2 ];
-pStartGlyphs = new int[ nRangeCount ];
 const unsigned char* pLimitBase = pCmap + nOffset + 14;
 const unsigned char* pBeginBase = pLimitBase + nSegCountX2 + 2;
 const unsigned char* pDeltaBase = pBeginBase + nSegCountX2;
 const unsigned char* pOffsetBase = pDeltaBase + nSegCountX2;
+
+const int nOffsetBaseStart = pOffsetBase - pCmap;
+const int nRemainingLen = nLength - nOffsetBaseStart;
+const int nMaxPossibleRangeOffsets = nRemainingLen / 2;
+if (nRangeCount > nMaxPossibleRangeOffsets)
+{
+SAL_WARN("vcl.gdi", "more range offsets requested then space 
available");
+nRangeCount = std::max(0, nMaxPossibleRangeOffsets);
+}
+
+pCodePairs = new sal_UCS4[ nRangeCount * 2 ];
+pStartGlyphs = new int[ nRangeCount ];
+
 sal_UCS4* pCP = pCodePairs;
 for( int i = 0; i < nRangeCount; ++i )
 {
@@ -254,7 +265,7 @@ bool ParseCMAP( const unsigned char* pCmap, int nLength, 
CmapResult& rResult )
 if (nRangeCount > nMaxPossiblePairs)
 {
 SAL_WARN("vcl.gdi", "more code pairs requested then space 
available");
-nRangeCount = nMaxPossiblePairs;
+nRangeCount = std::max(0, nMaxPossiblePairs);
 }
 
 pCodePairs = new sal_UCS4[ nRangeCount * 2 ];
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: Branch 'distro/collabora/co-4-2' - ios/Mobile

2020-09-21 Thread Tor Lillqvist (via logerrit)
 ios/Mobile/Info.plist.in |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 30c61255347c12f79567b3e02d42eb67af1f3023
Author: Tor Lillqvist 
AuthorDate: Mon Sep 21 12:44:50 2020 +0300
Commit: Tor Lillqvist 
CommitDate: Mon Sep 21 12:44:50 2020 +0300

Bump CFBundleShortVersionString to 4.2.10

Change-Id: I7b413757266c8bf3f56b1794f7578949d4e2b340

diff --git a/ios/Mobile/Info.plist.in b/ios/Mobile/Info.plist.in
index fb33a9fc1..a5f2205bb 100644
--- a/ios/Mobile/Info.plist.in
+++ b/ios/Mobile/Info.plist.in
@@ -214,7 +214,7 @@
CFBundlePackageType
APPL
CFBundleShortVersionString
-   4.2.9
+   4.2.10
CFBundleVersion
@IOSAPP_BUNDLE_VERSION@
LSRequiresIPhoneOS
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loleaflet/src

2020-09-21 Thread Henry Castro (via logerrit)
 loleaflet/src/map/handler/Map.TouchGesture.js |8 +++-
 1 file changed, 7 insertions(+), 1 deletion(-)

New commits:
commit 283e3951ce69d638a7cae870aecf362280b4acc2
Author: Henry Castro 
AuthorDate: Fri Aug 14 09:43:08 2020 -0400
Commit: Andras Timar 
CommitDate: Mon Sep 21 11:21:50 2020 +0200

mobile: pre-condition if they are numbers

The hammer library sometimes or random when
consecutively pinch events, the center and scale
has infinity values

Change-Id: Ide6605bcbc0c7b4818fd27b7b44706fb8122d80a
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/100744
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Andras Timar 
(cherry picked from commit 091eca0ae421ca436ba95ea1e478909f2a18d0a7)
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/103047

diff --git a/loleaflet/src/map/handler/Map.TouchGesture.js 
b/loleaflet/src/map/handler/Map.TouchGesture.js
index 895977228..689e9104f 100644
--- a/loleaflet/src/map/handler/Map.TouchGesture.js
+++ b/loleaflet/src/map/handler/Map.TouchGesture.js
@@ -515,6 +515,9 @@ L.Map.TouchGesture = L.Handler.extend({
},
 
_onPinchStart: function (e) {
+   if (isNaN(e.center.x) || isNaN(e.center.y))
+   return;
+
this._pinchStartCenter = {x: e.center.x, y: e.center.y};
if (this._map._docLayer.isCursorVisible()) {
this._map._docLayer._cursorMarker.setOpacity(0);
@@ -537,7 +540,7 @@ L.Map.TouchGesture = L.Handler.extend({
},
 
_onPinch: function (e) {
-   if (!this._pinchStartCenter)
+   if (!this._pinchStartCenter || isNaN(e.center.x) || 
isNaN(e.center.y))
return;
 
// we need to invert the offset or the map is moved in the 
opposite direction
@@ -554,6 +557,9 @@ L.Map.TouchGesture = L.Handler.extend({
},
 
_onPinchEnd: function () {
+   if (!this._pinchStartCenter)
+   return;
+
var oldZoom = this._map.getZoom(),
zoomDelta = this._zoom - oldZoom,
finalZoom = this._map._limitZoom(zoomDelta > 0 ? 
Math.ceil(this._zoom) : Math.floor(this._zoom));
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Mike Kaganski (via logerrit)
 sc/source/core/data/table4.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit d5ebe7c3089ab9f4d3fe0707169fc1ce024cdb70
Author: Mike Kaganski 
AuthorDate: Mon Sep 21 10:21:24 2020 +0200
Commit: Mike Kaganski 
CommitDate: Mon Sep 21 11:12:07 2020 +0200

tdf#129606: Round the mean of the two subtractions

This improves handling of cases when the two subtraction methods give
these values:

c = -0.10053
d = -0.10006

Rounding c would give -0.10100, while rounding the mean
gives -0.10001.

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

diff --git a/sc/source/core/data/table4.cxx b/sc/source/core/data/table4.cxx
index 9403d1b913a7..09a17546c002 100644
--- a/sc/source/core/data/table4.cxx
+++ b/sc/source/core/data/table4.cxx
@@ -208,7 +208,8 @@ double approxDiff( double a, double b )
 // tdf#129606: Limit precision to the 16th significant digit of the least 
precise argument.
 // Cf. mnMaxGeneralPrecision in sc/source/core/data/column3.cxx.
 const int nExpArg = static_cast(floor(log10(std::max(aa, ab - 15;
-return rtl::math::round(c, -std::max(nExp, nExpArg));
+// Round the mean of the two subtractions
+return rtl::math::round((c + d) / 2, -std::max(nExp, nExpArg));
 }
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: filter/source include/oox oox/source sc/source sw/source

2020-09-21 Thread Michael Stahl (via logerrit)
 filter/source/msfilter/escherex.cxx  |   20 -
 include/oox/export/vmlexport.hxx |7 +-
 oox/source/export/vmlexport.cxx  |   22 +-
 sc/source/filter/xcl97/xcl97rec.cxx  |2 
 sw/source/filter/ww8/docxattributeoutput.cxx |   91 +--
 sw/source/filter/ww8/docxattributeoutput.hxx |6 +
 sw/source/filter/ww8/docxsdrexport.cxx   |6 +
 7 files changed, 94 insertions(+), 60 deletions(-)

New commits:
commit fdc8590032b292dcb8152b328401e591fea642a4
Author: Michael Stahl 
AuthorDate: Fri Sep 18 11:47:56 2020 +0200
Commit: Michael Stahl 
CommitDate: Mon Sep 21 11:02:20 2020 +0200

tdf#136620 tdf#136708 filter,oox,sw: fix export of 2 different wraps

This reverts commit 2cb90a5c87fe46737c8d840967d8836284f92ffd.

Revert the change to EscherPropertyContainer, which was completely
bogus, based on pre-existing bogus code in VMLExport::Commit().

The problem is that ESCHER_Wrap values are for wrapping text *inside* a
text box, which is "mso-wrap-style" in VML, whereas VML's w10:wrap
element defines how text wraps *around* a shape, doesn't exist as an
ESCHER property and is specific to Word formats.

Instead, export the w10:wrap element in VMLExport::EndShape().

This has 2 callers, WriteActiveXControl() and writeVMLDrawing().

Furthermore the value "none" wasn't written for WrapTextMode_THROUGH,
which caused the wrap element to be omitted in that case.

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

diff --git a/filter/source/msfilter/escherex.cxx 
b/filter/source/msfilter/escherex.cxx
index b05e013f8082..24dcabe0277e 100644
--- a/filter/source/msfilter/escherex.cxx
+++ b/filter/source/msfilter/escherex.cxx
@@ -61,7 +61,6 @@
 #include 
 #include 
 #include 
-#include 
 #include 
 #include 
 #include 
@@ -692,10 +691,6 @@ void EscherPropertyContainer::CreateTextProperties(
 bool bWordWrap  ( false );
 bool bAutoGrowSize  ( false );
 
-uno::Any aTextWrap;
-
-(void)EscherPropertyValueHelper::GetPropertyValue(aTextWrap, rXPropSet, 
"TextWrap", true);
-
 if ( EscherPropertyValueHelper::GetPropertyValue( aAny, rXPropSet, 
"TextWritingMode", true ) )
 aAny >>= eWM;
 if ( EscherPropertyValueHelper::GetPropertyValue( aAny, rXPropSet, 
"TextVerticalAdjust", true ) )
@@ -834,21 +829,6 @@ void EscherPropertyContainer::CreateTextProperties(
 nTextAttr |= 0x20002;
 }
 }
-
-if (aTextWrap.hasValue())
-{   // explicit text wrap overrides whatever was inferred previously
-switch (aTextWrap.get())
-{
-case text::WrapTextMode_THROUGH:
-eWrapMode = ESCHER_WrapNone;
-break;
-// in theory there are 3 more Escher_Wrap, but [MS-ODRAW] says 
they are useless
-default:
-eWrapMode = ESCHER_WrapSquare;
-break;
-}
-}
-
 AddOpt( ESCHER_Prop_dxTextLeft, nLeft * 360 );
 AddOpt( ESCHER_Prop_dxTextRight, nRight * 360 );
 AddOpt( ESCHER_Prop_dyTextTop, nTop * 360 );
diff --git a/include/oox/export/vmlexport.hxx b/include/oox/export/vmlexport.hxx
index 94aeb8601f1a..67c5fc88f113 100644
--- a/include/oox/export/vmlexport.hxx
+++ b/include/oox/export/vmlexport.hxx
@@ -77,8 +77,9 @@ class OOX_DLLPUBLIC VMLExport : public EscherEx
 /// Parent exporter, used for text callback.
 VMLTextExport* m_pTextExport;
 
-/// Anchoring.
+/// Anchoring - Writer specific properties
 sal_Int16 m_eHOri, m_eVOri, m_eHRel, m_eVRel;
+std::unique_ptr m_pWrapAttrList;
 bool m_bInline; // css::text::TextContentAnchorType_AS_CHARACTER
 
 /// The object we're exporting.
@@ -136,7 +137,9 @@ public:
 /// Call this when you need to export the object as VML.
 OString const & AddSdrObject( const SdrObject& rObj, sal_Int16 eHOri = -1,
 sal_Int16 eVOri = -1, sal_Int16 eHRel = -1,
-sal_Int16 eVRel = -1, const bool bOOxmlExport = false );
+sal_Int16 eVRel = -1,
+std::unique_ptr m_pWrapAttrList 
= nullptr,
+const bool bOOxmlExport = false );
 OString const & AddInlineSdrObject( const SdrObject& rObj, const bool 
bOOxmlExport );
 virtual void  AddSdrObjectVMLObject( const SdrObject& rObj) override;
 static bool IsWaterMarkShape(const OUString& rStr);
diff --git a/oox/source/export/vmlexport.cxx b/oox/source/export/vmlexport.cxx
index dea03c552cee..b5cc2152acda 100644
--- a/oox/source/export/vmlexport.cxx
+++ b/oox/source/export/vmlexport.cxx
@@ -421,11 +421,15 @@ void VMLExport::Commit( EscherPropertyContainer& rProps, 
const tools::Rectangle&
 case ESCHER_WrapSquare:
 case ESCHER_WrapByPoints:  pWrapType = "square"; 
break; //

[Libreoffice-commits] online.git: loolkitconfig.xcu

2020-09-21 Thread Andras Timar (via logerrit)
 loolkitconfig.xcu |   10 +-
 1 file changed, 5 insertions(+), 5 deletions(-)

New commits:
commit 40ade379183307b650566d933d36bf710d87951e
Author: Andras Timar 
AuthorDate: Mon Sep 21 10:55:26 2020 +0200
Commit: Andras Timar 
CommitDate: Mon Sep 21 10:55:26 2020 +0200

Prefer Calibra/Carlito font for new documents

Change-Id: I132df2ceac2a20ace380fb09afe0d097207e3bdb

diff --git a/loolkitconfig.xcu b/loolkitconfig.xcu
index 27a7f61f0..d9a5b671a 100644
--- a/loolkitconfig.xcu
+++ b/loolkitconfig.xcu
@@ -31,10 +31,10 @@
 
 NeverMatchAnyUrlSuffix
 
-
-Noto 
Sans;Liberation Sans;Albany AMT;Albany;Arial;Arimo;Nimbus Sans L;DejaVu 
Sans;Helvetica;Lucida;Geneva;Helmet;Arial Unicode MS;Lucida Sans 
Unicode;Tahoma;SansSerif
-Noto 
Sans;Liberation Sans;Albany AMT;Albany;Arial;Arimo;Nimbus Sans L;DejaVu 
Sans;Helvetica;Lucida;Geneva;Helmet;Arial Unicode MS;Lucida Sans 
Unicode;Tahoma;SansSerif
-Noto 
Sans;Liberation Sans;Albany AMT;Albany;Arial;Arimo;Nimbus Sans L;DejaVu 
Sans;Helvetica;Lucida;Geneva;Helmet;Arial Unicode MS;Lucida Sans 
Unicode;Tahoma;SansSerif
-Noto 
Sans;Liberation Sans;Albany AMT;Albany;Arial;Arimo;Nimbus Sans L;DejaVu 
Sans;Helvetica;Lucida;Geneva;Helmet;Arial Unicode MS;Lucida Sans 
Unicode;Tahoma;SansSerif
+
+Calibri;Carlito;Noto Sans;Liberation Sans;Albany 
AMT;Albany;Arial;Arimo;Nimbus Sans L;DejaVu 
Sans;Helvetica;Lucida;Geneva;Helmet;Arial Unicode MS;Lucida Sans 
Unicode;Tahoma;SansSerif
+Calibri;Carlito;Noto Sans;Liberation Sans;Albany 
AMT;Albany;Arial;Arimo;Nimbus Sans L;DejaVu 
Sans;Helvetica;Lucida;Geneva;Helmet;Arial Unicode MS;Lucida Sans 
Unicode;Tahoma;SansSerif
+Calibri;Carlito;Noto Sans;Liberation Sans;Albany 
AMT;Albany;Arial;Arimo;Nimbus Sans L;DejaVu 
Sans;Helvetica;Lucida;Geneva;Helmet;Arial Unicode MS;Lucida Sans 
Unicode;Tahoma;SansSerif
+Calibri;Carlito;Noto Sans;Liberation Sans;Albany 
AMT;Albany;Arial;Arimo;Nimbus Sans L;DejaVu 
Sans;Helvetica;Lucida;Geneva;Helmet;Arial Unicode MS;Lucida Sans 
Unicode;Tahoma;SansSerif
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Michael Stahl (via logerrit)
 writerfilter/source/rtftok/rtfdispatchdestination.cxx |   14 +-
 writerfilter/source/rtftok/rtfdocumentimpl.cxx|   10 +-
 2 files changed, 22 insertions(+), 2 deletions(-)

New commits:
commit 54bd2266d6e0c8926ecaf0fbb2dbb5ee9d1a802d
Author: Michael Stahl 
AuthorDate: Fri Sep 18 18:52:45 2020 +0200
Commit: Michael Stahl 
CommitDate: Mon Sep 21 10:47:42 2020 +0200

tdf#136855 writerfilter: RTF import: buffer annotations inside tables

The problem is that one of the annotations is inside a table that
happens to start with a covered cell (vertically merged).

The table row is buffered, but the annotation is not, so it is inserted
before any of the text of the table cells is inserted, so it ends up in
the covered cell.

The strucuture of annotations is a bit icky; to fix this, buffer both the
\annotation destination and \atrfstart \atrfend start and end
destinations.

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

diff --git a/writerfilter/source/rtftok/rtfdispatchdestination.cxx 
b/writerfilter/source/rtftok/rtfdispatchdestination.cxx
index 9574224e0fa0..f545d861a0c8 100644
--- a/writerfilter/source/rtftok/rtfdispatchdestination.cxx
+++ b/writerfilter/source/rtftok/rtfdispatchdestination.cxx
@@ -335,7 +335,19 @@ RTFError RTFDocumentImpl::dispatchDestination(RTFKeyword 
nKeyword)
 case RTF_ANNOTATION:
 if (!m_pSuperstream)
 {
-resolveSubstream(m_nGroupStartPos - 1, 
NS_ooxml::LN_annotation);
+if (!m_aStates.top().getCurrentBuffer())
+{
+resolveSubstream(m_nGroupStartPos - 1, 
NS_ooxml::LN_annotation);
+}
+else
+{
+RTFSprms aAttributes;
+aAttributes.set(Id(0), new RTFValue(m_nGroupStartPos - 
1));
+aAttributes.set(Id(1), new 
RTFValue(NS_ooxml::LN_annotation));
+aAttributes.set(Id(2), new RTFValue(OUString()));
+m_aStates.top().getCurrentBuffer()->push_back(
+Buf_t(BUFFER_RESOLVESUBSTREAM, new 
RTFValue(aAttributes), nullptr));
+}
 m_aStates.top().setDestination(Destination::SKIP);
 }
 else
diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx 
b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
index 7edeccdcb4e7..bbcec8792bc1 100644
--- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx
+++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
@@ -2725,7 +2725,15 @@ RTFError RTFDocumentImpl::beforePopState(RTFParserState& 
rState)
 
aAttributes.set(NS_ooxml::LN_EG_RangeMarkupElements_commentRangeEnd, pValue);
 writerfilter::Reference::Pointer_t pProperties
 = new RTFReferenceProperties(aAttributes);
-Mapper().props(pProperties);
+if (!m_aStates.top().getCurrentBuffer())
+{
+Mapper().props(pProperties);
+}
+else
+{
+auto const pValue2 = new RTFValue(aAttributes, RTFSprms());
+bufferProperties(*m_aStates.top().getCurrentBuffer(), pValue2, 
nullptr);
+}
 }
 break;
 case Destination::ANNOTATIONREFERENCE:
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Michael Stahl (via logerrit)
 sw/source/ui/misc/bookmark.cxx |1 +
 1 file changed, 1 insertion(+)

New commits:
commit fefcad1186232b26180d095bbafdf8e8bdda8209
Author: Michael Stahl 
AuthorDate: Fri Sep 18 17:12:38 2020 +0200
Commit: Michael Stahl 
CommitDate: Mon Sep 21 10:47:00 2020 +0200

tdf#135879 sw: fix bookmark dialog's Delete button

(regression from cb5d18871b46ef4f7bc47eb4d71df5374d712575)

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

diff --git a/sw/source/ui/misc/bookmark.cxx b/sw/source/ui/misc/bookmark.cxx
index b69cce75b47b..33cdbee276fa 100644
--- a/sw/source/ui/misc/bookmark.cxx
+++ b/sw/source/ui/misc/bookmark.cxx
@@ -163,6 +163,7 @@ IMPL_LINK_NOARG(SwInsertBookmarkDlg, SelectionChangedHdl, 
weld::TreeView&, void)
 m_xInsertBtn->set_sensitive(false);
 m_xGotoBtn->set_sensitive(nSelectedRows == 1);
 m_xRenameBtn->set_sensitive(nSelectedRows == 1 && !m_bAreProtected);
+m_xDeleteBtn->set_sensitive(!m_bAreProtected);
 m_xEditBox->set_text(sEditBoxText.makeStringAndClear());
 }
 else
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: svx/IwyuFilter_svx.yaml

2020-09-21 Thread Gabor Kelemen (via logerrit)
 svx/IwyuFilter_svx.yaml |3 +++
 1 file changed, 3 insertions(+)

New commits:
commit a6a1cfe0bf1c176d3f0cd385d494b7c0e8133815
Author: Gabor Kelemen 
AuthorDate: Sun Aug 9 23:24:12 2020 +0200
Commit: Miklos Vajna 
CommitDate: Mon Sep 21 10:30:24 2020 +0200

Add IWYU rules for svx

After commit 456d61ec526e250fd1af894e109d5914ac9c9e6e

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

diff --git a/svx/IwyuFilter_svx.yaml b/svx/IwyuFilter_svx.yaml
index be9c2e28b254..48e1b7b56cb2 100644
--- a/svx/IwyuFilter_svx.yaml
+++ b/svx/IwyuFilter_svx.yaml
@@ -119,3 +119,6 @@ excludelist:
 svx/qa/unit/xoutdev.cxx:
 # Needed for system-cppunit
 - unotest/bootstrapfixturebase.hxx
+svx/qa/unit/XTableImportExportTest.cxx:
+# Needed for --with-system-cppunit
+- unotest/bootstrapfixturebase.hxx
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: loleaflet/src

2020-09-21 Thread Michael Meeks (via logerrit)
 loleaflet/src/layer/tile/CanvasTileLayer.js |   37 ++--
 1 file changed, 24 insertions(+), 13 deletions(-)

New commits:
commit 224526c9678be37b4ac4258b1f01c7df473c50bc
Author: Michael Meeks 
AuthorDate: Sat Sep 19 21:47:34 2020 +0100
Commit: Michael Meeks 
CommitDate: Mon Sep 21 09:57:16 2020 +0200

calc grid: render during canvas 'clear' if we can.

Also re-render as soon as we have grid positions.

Change-Id: I57095683e662991badcb3a58832c81ebb3bc460d
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/103043
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Michael Meeks 

diff --git a/loleaflet/src/layer/tile/CanvasTileLayer.js 
b/loleaflet/src/layer/tile/CanvasTileLayer.js
index 15d813939..285fa11c3 100644
--- a/loleaflet/src/layer/tile/CanvasTileLayer.js
+++ b/loleaflet/src/layer/tile/CanvasTileLayer.js
@@ -130,12 +130,22 @@ L.CanvasTilePainter = L.Class.extend({
}
},
 
-   clear: function () {
-   if (this._layer._debug)
-   this._canvasCtx.fillStyle = 'rgba(255, 0, 0, 0.5)';
+   clear: function (ctx) {
+   // First render the background / sheet grid if we can
+   if (this.renderBackground)
+   {
+   if (!ctx)
+   ctx = this._paintContext();
+   this.renderBackground(this._canvasCtx, ctx);
+   }
else
-   this._canvasCtx.fillStyle = 'white';
-   this._canvasCtx.fillRect(0, 0, this._pixWidth, this._pixHeight);
+   {
+   if (this._layer._debug)
+   this._canvasCtx.fillStyle = 'rgba(255, 0, 0, 
0.5)';
+   else
+   this._canvasCtx.fillStyle = 'white';
+   this._canvasCtx.fillRect(0, 0, this._pixWidth, 
this._pixHeight);
+   }
},
 
// Details of tile areas to render
@@ -265,11 +275,13 @@ L.CanvasTilePainter = L.Class.extend({
if (skipUpdate)
return;
 
+   var ctx;
if (resizeCanvas || scaleChanged) {
this._setCanvasSize(newSize.x, newSize.y);
}
else if (mapSizeChanged && topLeftChanged) {
-   this.clear();
+   ctx = this._paintContext();
+   this.clear(ctx);
}
 
if (mapSizeChanged)
@@ -282,24 +294,22 @@ L.CanvasTilePainter = L.Class.extend({
this._lastPart = part;
 
this._topLeft = newTopLeft;
-   this._paintWholeCanvas();
+   this._paintWholeCanvas(ctx);
 
if (this._layer._debug)
this._drawSplits();
},
 
-   _paintWholeCanvas: function () {
+   _paintWholeCanvas: function(ctx) {
 
var zoom = this._lastZoom || Math.round(this._map.getZoom());
var part = this._lastPart || this._layer._selectedPart;
 
// Calculate all this here intead of doing it per tile.
-   var ctx = this._paintContext();
-
-   // First render the background / sheet grid if we can
-   if (this.renderBackground)
-   this.renderBackground(this._canvasCtx, ctx);
+   if (!ctx)
+   ctx = this._paintContext();
 
+   this.clear(ctx);
var tileRanges = 
ctx.paneBoundsList.map(this._layer._pxBoundsToTileRange, this._layer);
 
for (var rangeIdx = 0; rangeIdx < tileRanges.length; 
++rangeIdx) {
@@ -451,6 +461,7 @@ L.CanvasTileLayer = L.TileLayer.extend({
}
canvas.closePath();
};
+   this._painter.clear();
},
 
hasSplitPanesSupport: function () {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Szymon Kłos (via logerrit)
 svx/source/table/tablecontroller.cxx |   58 ++-
 1 file changed, 31 insertions(+), 27 deletions(-)

New commits:
commit 368146c29d0280964399fc86fa0117965d510130
Author: Szymon Kłos 
AuthorDate: Wed Jul 22 16:17:37 2020 +0200
Commit: Szymon Kłos 
CommitDate: Mon Sep 21 09:49:48 2020 +0200

Make Table Properties dialog async

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

diff --git a/svx/source/table/tablecontroller.cxx 
b/svx/source/table/tablecontroller.cxx
index 317135b6c260..1b52f835180c 100644
--- a/svx/source/table/tablecontroller.cxx
+++ b/svx/source/table/tablecontroller.cxx
@@ -925,46 +925,50 @@ void SvxTableController::onFormatTable(const SfxRequest& 
rReq)
 aNewAttr.Put( aBoxInfoItem );
 
 SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
-ScopedVclPtr xDlg( pFact->CreateSvxFormatCellsDialog(
+VclPtr xDlg( pFact->CreateSvxFormatCellsDialog(
 rReq.GetFrameWeld(),
 &aNewAttr,
 rModel) );
 
 // Even Cancel Button is returning positive(101) value,
-if (xDlg->Execute() != RET_OK)
-return;
+xDlg->StartExecuteAsync([xDlg, this, aBoxItem, aBoxInfoItem](int nResult){
+if (nResult == RET_OK)
+{
+SfxItemSet aNewSet(*(xDlg->GetOutputItemSet()));
 
-SfxItemSet aNewSet(*(xDlg->GetOutputItemSet()));
+//Only properties that were unchanged by the dialog appear in this
+//itemset.  We had constructed these two properties from other
+//ones, so if they were not changed, then forcible set them back to
+//their originals in the new result set so we can decompose that
+//unchanged state back to their input properties
+if (aNewSet.GetItemState(SDRATTR_TABLE_BORDER, false) != 
SfxItemState::SET)
+{
+aNewSet.Put(aBoxItem);
+}
+if (aNewSet.GetItemState(SDRATTR_TABLE_BORDER_INNER, false) != 
SfxItemState::SET)
+{
+aNewSet.Put(aBoxInfoItem);
+}
 
-//Only properties that were unchanged by the dialog appear in this
-//itemset.  We had constructed these two properties from other
-//ones, so if they were not changed, then forcible set them back to
-//their originals in the new result set so we can decompose that
-//unchanged state back to their input properties
-if (aNewSet.GetItemState(SDRATTR_TABLE_BORDER, false) != SfxItemState::SET)
-{
-aNewSet.Put(aBoxItem);
-}
-if (aNewSet.GetItemState(SDRATTR_TABLE_BORDER_INNER, false) != 
SfxItemState::SET)
-{
-aNewSet.Put(aBoxInfoItem);
-}
+SvxBoxItem aNewBoxItem( aNewSet.Get( SDRATTR_TABLE_BORDER ) );
 
-SvxBoxItem aNewBoxItem( aNewSet.Get( SDRATTR_TABLE_BORDER ) );
+if( aNewBoxItem.GetDistance( SvxBoxItemLine::LEFT ) != 
aBoxItem.GetDistance( SvxBoxItemLine::LEFT ) )
+aNewSet.Put(makeSdrTextLeftDistItem( aNewBoxItem.GetDistance( 
SvxBoxItemLine::LEFT ) ) );
 
-if( aNewBoxItem.GetDistance( SvxBoxItemLine::LEFT ) != 
aBoxItem.GetDistance( SvxBoxItemLine::LEFT ) )
-aNewSet.Put(makeSdrTextLeftDistItem( aNewBoxItem.GetDistance( 
SvxBoxItemLine::LEFT ) ) );
+if( aNewBoxItem.GetDistance( SvxBoxItemLine::RIGHT ) != 
aBoxItem.GetDistance( SvxBoxItemLine::RIGHT ) )
+aNewSet.Put(makeSdrTextRightDistItem( aNewBoxItem.GetDistance( 
SvxBoxItemLine::RIGHT ) ) );
 
-if( aNewBoxItem.GetDistance( SvxBoxItemLine::RIGHT ) != 
aBoxItem.GetDistance( SvxBoxItemLine::RIGHT ) )
-aNewSet.Put(makeSdrTextRightDistItem( aNewBoxItem.GetDistance( 
SvxBoxItemLine::RIGHT ) ) );
+if( aNewBoxItem.GetDistance( SvxBoxItemLine::TOP ) != 
aBoxItem.GetDistance( SvxBoxItemLine::TOP ) )
+aNewSet.Put(makeSdrTextUpperDistItem( aNewBoxItem.GetDistance( 
SvxBoxItemLine::TOP ) ) );
 
-if( aNewBoxItem.GetDistance( SvxBoxItemLine::TOP ) != 
aBoxItem.GetDistance( SvxBoxItemLine::TOP ) )
-aNewSet.Put(makeSdrTextUpperDistItem( aNewBoxItem.GetDistance( 
SvxBoxItemLine::TOP ) ) );
+if( aNewBoxItem.GetDistance( SvxBoxItemLine::BOTTOM ) != 
aBoxItem.GetDistance( SvxBoxItemLine::BOTTOM ) )
+aNewSet.Put(makeSdrTextLowerDistItem( aNewBoxItem.GetDistance( 
SvxBoxItemLine::BOTTOM ) ) );
 
-if( aNewBoxItem.GetDistance( SvxBoxItemLine::BOTTOM ) != 
aBoxItem.GetDistance( SvxBoxItemLine::BOTTOM ) )
-aNewSet.Put(makeSdrTextLowerDistItem( aNewBoxItem.GetDistance( 
SvxBoxItemLine::BOTTOM ) ) );
+this->SetAttrToSelectedCells(aNewSet, false);
+}
 
-SetAttrToSelectedCells(aNewSet, false);
+xDlg->disposeOnce();
+});
 }
 
 void SvxTableControl

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

2020-09-21 Thread Miklos Vajna (via logerrit)
 sw/inc/docufld.hxx|2 -
 sw/inc/edglbldc.hxx   |   14 +++
 sw/source/core/edit/edglbldc.cxx  |   18 -
 sw/source/core/fields/ddefld.cxx  |   41 ++---
 sw/source/core/fields/docufld.cxx |4 +-
 sw/source/core/fields/textapi.cxx |   74 +++---
 sw/source/core/inc/textapi.hxx|2 -
 7 files changed, 78 insertions(+), 77 deletions(-)

New commits:
commit df86ec5d465875a5c59017c24578ca9153440d0b
Author: Miklos Vajna 
AuthorDate: Mon Sep 21 08:04:00 2020 +0200
Commit: Miklos Vajna 
CommitDate: Mon Sep 21 09:46:12 2020 +0200

sw: prefix members of SwGlblDocContent, SwIntrnlRefLink, SwPostItField ...

... and SwTextAPIEditSource

See tdf#94879 for motivation.

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

diff --git a/sw/inc/docufld.hxx b/sw/inc/docufld.hxx
index 5c8187dafa13..bc7ef9219093 100644
--- a/sw/inc/docufld.hxx
+++ b/sw/inc/docufld.hxx
@@ -451,7 +451,7 @@ class SW_DLLPUBLIC SwPostItField final : public SwField
 sal_uInt32 m_nPostItId;
 
 public:
-static sal_uInt32 m_nLastPostItId;
+static sal_uInt32 s_nLastPostItId;
 
 SwPostItField( SwPostItFieldType*,
const OUString& rAuthor,
diff --git a/sw/inc/edglbldc.hxx b/sw/inc/edglbldc.hxx
index 6cac147f56e5..9ab0bf4e4b6b 100644
--- a/sw/inc/edglbldc.hxx
+++ b/sw/inc/edglbldc.hxx
@@ -34,12 +34,12 @@ enum GlobalDocContentType {
 
 class SwGlblDocContent
 {
-GlobalDocContentType eType;
-sal_uLong nDocPos;
+GlobalDocContentType m_eType;
+sal_uLong m_nDocPos;
 union {
 const SwTOXBase* pTOX;
 const SwSection* pSect;
-} PTR;
+} m_PTR;
 
 public:
 SwGlblDocContent( sal_uLong nPos );
@@ -47,12 +47,12 @@ public:
 SwGlblDocContent( const SwSection* pSect );
 
 /// Query contents.
-GlobalDocContentType GetType() const { return eType; }
+GlobalDocContentType GetType() const { return m_eType; }
 const SwSection* GetSection() const
-{ return GLBLDOC_SECTION == eType ? PTR.pSect : 
nullptr; }
+{ return GLBLDOC_SECTION == m_eType ? m_PTR.pSect 
: nullptr; }
 const SwTOXBase* GetTOX() const
-{ return GLBLDOC_TOXBASE == eType ? PTR.pTOX : 
nullptr; }
-sal_uLong GetDocPos() const { return nDocPos; }
+{ return GLBLDOC_TOXBASE == m_eType ? m_PTR.pTOX : 
nullptr; }
+sal_uLong GetDocPos() const { return m_nDocPos; }
 
 /// For sorting.
 bool operator==( const SwGlblDocContent& rCmp ) const
diff --git a/sw/source/core/edit/edglbldc.cxx b/sw/source/core/edit/edglbldc.cxx
index 1849f6990c92..7c30b156db0c 100644
--- a/sw/source/core/edit/edglbldc.cxx
+++ b/sw/source/core/edit/edglbldc.cxx
@@ -358,27 +358,27 @@ void SwEditShell::GotoGlobalDocContent( const 
SwGlblDocContent& rPos )
 
 SwGlblDocContent::SwGlblDocContent( sal_uLong nPos )
 {
-eType = GLBLDOC_UNKNOWN;
-PTR.pTOX = nullptr;
-nDocPos = nPos;
+m_eType = GLBLDOC_UNKNOWN;
+m_PTR.pTOX = nullptr;
+m_nDocPos = nPos;
 }
 
 SwGlblDocContent::SwGlblDocContent( const SwTOXBaseSection* pTOX )
 {
-eType = GLBLDOC_TOXBASE;
-PTR.pTOX = pTOX;
+m_eType = GLBLDOC_TOXBASE;
+m_PTR.pTOX = pTOX;
 
 const SwSectionNode* pSectNd = pTOX->GetFormat()->GetSectionNode();
-nDocPos = pSectNd ? pSectNd->GetIndex() : 0;
+m_nDocPos = pSectNd ? pSectNd->GetIndex() : 0;
 }
 
 SwGlblDocContent::SwGlblDocContent( const SwSection* pSect )
 {
-eType = GLBLDOC_SECTION;
-PTR.pSect = pSect;
+m_eType = GLBLDOC_SECTION;
+m_PTR.pSect = pSect;
 
 const SwSectionNode* pSectNd = pSect->GetFormat()->GetSectionNode();
-nDocPos = pSectNd ? pSectNd->GetIndex() : 0;
+m_nDocPos = pSectNd ? pSectNd->GetIndex() : 0;
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/core/fields/ddefld.cxx b/sw/source/core/fields/ddefld.cxx
index 0b80f7feb2ae..9c4ba9c762cb 100644
--- a/sw/source/core/fields/ddefld.cxx
+++ b/sw/source/core/fields/ddefld.cxx
@@ -45,11 +45,12 @@ namespace {
 
 class SwIntrnlRefLink : public SwBaseLink
 {
-SwDDEFieldType& rFieldType;
+SwDDEFieldType& m_rFieldType;
+
 public:
-SwIntrnlRefLink( SwDDEFieldType& rType, SfxLinkUpdateMode nUpdateType )
-: SwBaseLink( nUpdateType, SotClipboardFormatId::STRING ),
-rFieldType( rType )
+SwIntrnlRefLink(SwDDEFieldType& rType, SfxLinkUpdateMode nUpdateType)
+: SwBaseLink(nUpdateType, SotClipboardFormatId::STRING)
+, m_rFieldType(rType)
 {}
 
 virtual void Closed() override;
@@ -87,9 +88,9 @@ public:
 if( bDel )
 sStr = sStr.copy( 0, n );
 
-rFieldType.SetExpansion( sStr );
+m_rFieldType.SetExpansion(sStr);
 // set Exp

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

2020-09-21 Thread Gülşah Köse (via logerrit)
 include/oox/export/chartexport.hxx |2 +-
 oox/source/export/chartexport.cxx  |4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

New commits:
commit de59062d95605e5c91d687e3441399ffb05ff2dc
Author: Gülşah Köse 
AuthorDate: Fri Sep 18 15:45:17 2020 +0300
Commit: Gülşah Köse 
CommitDate: Mon Sep 21 09:33:19 2020 +0200

tdf#136247 Change element order of data labels

Reference OOXML (Appendix B.5.1, line 248)

Change-Id: Idf5c2546b4ad65c8e78ca03e18ecfa575ef17fe8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103005
Tested-by: Jenkins
Reviewed-by: Gülşah Köse 

diff --git a/include/oox/export/chartexport.hxx 
b/include/oox/export/chartexport.hxx
index 5faaf42cb1d1..b900c68b51a2 100644
--- a/include/oox/export/chartexport.hxx
+++ b/include/oox/export/chartexport.hxx
@@ -179,7 +179,6 @@ private:
 void exportSeriesValues(
 const css::uno::Reference< css::chart2::data::XDataSequence >& 
xValueSeq, sal_Int32 nValueType = XML_val );
 void exportShapeProps( const css::uno::Reference< css::beans::XPropertySet 
>& xPropSet );
-void exportTextProps(const css::uno::Reference< css::beans::XPropertySet 
>& xPropSet);
 void exportDataPoints(
 const css::uno::Reference< css::beans::XPropertySet >& 
xSeriesProperties,
 sal_Int32 nSeriesLength, sal_Int32 eChartType );
@@ -224,6 +223,7 @@ public:
 const css::uno::Reference< css::frame::XModel >& getModel() const { return 
mxChartModel; }
 
 void WriteChartObj( const css::uno::Reference< css::drawing::XShape >& 
xShape, sal_Int32 nID, sal_Int32 nChartCount );
+void exportTextProps(const css::uno::Reference< css::beans::XPropertySet 
>& xPropSet);
 
 void ExportContent();
 void InitRangeSegmentationProperties(
diff --git a/oox/source/export/chartexport.cxx 
b/oox/source/export/chartexport.cxx
index 4d830f37c6ba..fd33d9a38bc8 100644
--- a/oox/source/export/chartexport.cxx
+++ b/oox/source/export/chartexport.cxx
@@ -3450,6 +3450,8 @@ void writeLabelProperties( const FSHelperPtr& pFS, 
ChartExport* pChartExport,
 pFS->endElement(FSNS(XML_c, XML_spPr));
 }
 
+pChartExport->exportTextProps(xPropSet);
+
 if (aCustomLabelFields.hasElements())
 writeCustomLabel(pFS, pChartExport, aCustomLabelFields);
 
@@ -3616,12 +3618,10 @@ void ChartExport::exportDataLabels(
 }
 
 // Individual label property that overwrites the baseline.
-exportTextProps( xLabelPropSet );
 writeLabelProperties(pFS, this, xLabelPropSet, aParam);
 pFS->endElement(FSNS(XML_c, XML_dLbl));
 }
 
-exportTextProps( xPropSet );
 // Baseline label properties for all labels.
 writeLabelProperties(pFS, this, xPropSet, aParam);
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: New Defects reported by Coverity Scan for LibreOffice

2020-09-21 Thread Stephan Bergmann

On 20/09/2020 13:32, Caolán McNamara wrote:

On Tue, 2020-09-08 at 15:45 +0200, Stephan Bergmann wrote:

On 08/09/2020 11:13, scan-ad...@coverity.com wrote:

  CID 1466649:  Parse warnings  (PARSE_ERROR)
  class template name must be a placeholder for the
complete type being initialized (not for a component of that
type)

25 const OStringLiteral sGlobal("::");



I have contacted Coverity about the above PARSE_ERROR problem.


I notice that while global "const OStringLiteral" and "const
OUStringLiteral" give PARSE_ERROR that non-const global
"OStringLiteral" and "OUStringLiteral" do not


Lets see whether  "Make 
some OUStringLiteral vars constexpr" would similarly get rid of those 
unhelpful error messages.


(By the way,


Some recent change in the LibreOffice source code caused Scan to fail with


Unrecoverable parse warning (PARSE_ERROR)
1. modified_class_template_placeholder: class template name must be a 
placeholder for the complete type being initialized (not for a component of 
that type)


in four places:

* 

* 

* 

* 


That OStringLiteral is a class template, see 
,
 and these four global variable definitions rely on class template argument deduction.  
There are similar definitions of static variables in function bodies, see 
,
 for which Scan did not report errors.

Any chance to get this fixed in Scan, or some workaround/annotation that can be applied to the code?  Many more instances of this pattern are scheduled to hit the LibreOffice code base soon, and I would like to get this issue sorted out first. 


is what I had sent to , but without any 
response.  And then I completely forgot about this issue when submitting 
 
"Turn OUStringLiteral into a consteval'ed, static-refcound rtl_uString", 
which caused many more of those errors now.)


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: Branch 'feature/cib_contract3753' - .gitreview

2020-09-21 Thread Samuel Mehrbrodt (via logerrit)
 .gitreview |3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit 6f7215c2581395ddb0d43b31b209b3af1f85a080
Author: Samuel Mehrbrodt 
AuthorDate: Thu Sep 10 09:45:08 2020 +0200
Commit: Samuel Mehrbrodt 
CommitDate: Mon Sep 21 09:17:21 2020 +0200

.gitreview: Update default branch

Change-Id: Ifcbcd3427508b468a9f1872b563c93760854becf
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102364
Tested-by: Samuel Mehrbrodt 
Reviewed-by: Samuel Mehrbrodt 

diff --git a/.gitreview b/.gitreview
index 4cd7d22d9a83..2bbb2f4856f3 100644
--- a/.gitreview
+++ b/.gitreview
@@ -3,5 +3,4 @@ host=gerrit.libreoffice.org
 port=29418
 project=core
 defaultremote=logerrit
-defaultbranch=libreoffice-6-4
-
+defaultbranch=feature/cib_contract3753
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-09-21 Thread Gabor Kelemen (via logerrit)
 sc/uiconfig/scalc/menubar/menubar.xml |   13 -
 1 file changed, 13 deletions(-)

New commits:
commit ce9e965b3fc3744b99afee07f6d56860852af5e4
Author: Gabor Kelemen 
AuthorDate: Mon Sep 21 00:30:49 2020 +0200
Commit: Heiko Tietze 
CommitDate: Mon Sep 21 09:16:09 2020 +0200

tdf#136071 Drop mostly useless Format - Spacing menu from Calc

Change-Id: I175e6c6f5f6b3edf338763af4d195414dcb54fbc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103078
Tested-by: Jenkins
Reviewed-by: Heiko Tietze 

diff --git a/sc/uiconfig/scalc/menubar/menubar.xml 
b/sc/uiconfig/scalc/menubar/menubar.xml
index 3f688bd29553..2312fbf26128 100644
--- a/sc/uiconfig/scalc/menubar/menubar.xml
+++ b/sc/uiconfig/scalc/menubar/menubar.xml
@@ -347,19 +347,6 @@
 
 
   
-  
-
-
-
-
-
-
-
-
-
-
-
-  
   
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: offapi/com

2020-09-21 Thread Miklos Vajna (via logerrit)
 offapi/com/sun/star/graphic/XEmfParser.idl |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 622cf1dcbe6f2daa43ce4584fe3e68e3e1bd087f
Author: Miklos Vajna 
AuthorDate: Mon Sep 21 08:16:31 2020 +0200
Commit: Miklos Vajna 
CommitDate: Mon Sep 21 09:04:23 2020 +0200

offapi: add missing @since tag for setSizeHint()

See


for motivation.

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

diff --git a/offapi/com/sun/star/graphic/XEmfParser.idl 
b/offapi/com/sun/star/graphic/XEmfParser.idl
index 234d70bc1937..a3f6492e205a 100644
--- a/offapi/com/sun/star/graphic/XEmfParser.idl
+++ b/offapi/com/sun/star/graphic/XEmfParser.idl
@@ -57,6 +57,8 @@ interface XEmfParser : ::com::sun::star::uno::XInterface
 
 @param Size
 the size in 100/th mm
+
+@since LibreOffice 7.1
  */
 void setSizeHint([in] com::sun::star::geometry::RealPoint2D Size);
 };
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits