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

2020-12-18 Thread Miklos Vajna (via logerrit)
 include/vcl/filter/PDFiumLibrary.hxx   |2 ++
 vcl/qa/cppunit/pdfexport/pdfexport.cxx |   22 +-
 vcl/source/pdf/PDFiumLibrary.cxx   |9 +
 3 files changed, 16 insertions(+), 17 deletions(-)

New commits:
commit e987a050260ad4c8f6c3487e57bec1c8b680c65e
Author: Miklos Vajna 
AuthorDate: Thu Dec 17 21:07:41 2020 +0100
Commit: Miklos Vajna 
CommitDate: Fri Dec 18 09:08:19 2020 +0100

pdfium: add PDFiumPage::hasLinks() wrapper

Reduces the amount of raw pdfium includes in CppunitTest_vcl_pdfexport.

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

diff --git a/include/vcl/filter/PDFiumLibrary.hxx 
b/include/vcl/filter/PDFiumLibrary.hxx
index cc6d65c15362..5dc8ea46fede 100644
--- a/include/vcl/filter/PDFiumLibrary.hxx
+++ b/include/vcl/filter/PDFiumLibrary.hxx
@@ -220,6 +220,8 @@ public:
 double getHeight();
 
 bool hasTransparency();
+
+bool hasLinks();
 };
 
 /// Represents one digital signature, as exposed by PDFium.
diff --git a/vcl/qa/cppunit/pdfexport/pdfexport.cxx 
b/vcl/qa/cppunit/pdfexport/pdfexport.cxx
index 69b7d17711a2..61debc5ed5ec 100644
--- a/vcl/qa/cppunit/pdfexport/pdfexport.cxx
+++ b/vcl/qa/cppunit/pdfexport/pdfexport.cxx
@@ -35,9 +35,6 @@
 #include 
 #include 
 #include 
-#include 
-#include 
-#include 
 #include 
 #include 
 #include 
@@ -1803,11 +1800,9 @@ CPPUNIT_TEST_FIXTURE(PdfExportTest, testTocLink)
 CPPUNIT_ASSERT(pPdfPage);
 
 // Ensure there is a link on the first page (in the ToC).
-int nStartPos = 0;
-FPDF_LINK pLinkAnnot = nullptr;
-// Without the accompanying fix in place, this test would have failed, as 
FPDFLink_Enumerate()
-// returned false, as the page contained no links.
-CPPUNIT_ASSERT(FPDFLink_Enumerate(pPdfPage->getPointer(), &nStartPos, 
&pLinkAnnot));
+// Without the accompanying fix in place, this test would have failed, as 
the page contained no
+// links.
+CPPUNIT_ASSERT(pPdfPage->hasLinks());
 }
 
 CPPUNIT_TEST_FIXTURE(PdfExportTest, testReduceSmallImage)
@@ -1904,13 +1899,6 @@ CPPUNIT_TEST_FIXTURE(PdfExportTest, testReduceImage)
 CPPUNIT_ASSERT_EQUAL(160, nHeight);
 }
 
-bool HasLinksOnPage(std::unique_ptr& pPdfPage)
-{
-int nStartPos = 0;
-FPDF_LINK pLinkAnnot = nullptr;
-return FPDFLink_Enumerate(pPdfPage->getPointer(), &nStartPos, &pLinkAnnot);
-}
-
 CPPUNIT_TEST_FIXTURE(PdfExportTest, testLinkWrongPage)
 {
 // Import the bugdoc and export as PDF.
@@ -1928,12 +1916,12 @@ CPPUNIT_TEST_FIXTURE(PdfExportTest, testLinkWrongPage)
 
 // Without the accompanying fix in place, this test would have failed, as 
the link of the first
 // page went to the second page due to the hidden first slide.
-CPPUNIT_ASSERT(HasLinksOnPage(pPdfPage));
+CPPUNIT_ASSERT(pPdfPage->hasLinks());
 
 // Second page should have no links (3rd slide).
 std::unique_ptr pPdfPage2 = 
pPdfDocument->openPage(/*nIndex=*/1);
 CPPUNIT_ASSERT(pPdfPage2);
-CPPUNIT_ASSERT(!HasLinksOnPage(pPdfPage2));
+CPPUNIT_ASSERT(!pPdfPage2->hasLinks());
 }
 
 CPPUNIT_TEST_FIXTURE(PdfExportTest, testLargePage)
diff --git a/vcl/source/pdf/PDFiumLibrary.cxx b/vcl/source/pdf/PDFiumLibrary.cxx
index 01b1acf1bd1a..78abdc433fa6 100644
--- a/vcl/source/pdf/PDFiumLibrary.cxx
+++ b/vcl/source/pdf/PDFiumLibrary.cxx
@@ -458,6 +458,15 @@ std::unique_ptr PDFiumPage::getTextPage()
 return pPDFiumTextPage;
 }
 
+bool PDFiumPage::hasLinks()
+{
+// This could be a full iterator, but at the moment we just determine if 
the list is empty or
+// not.
+int nStartPos = 0;
+FPDF_LINK pLinkAnnot = nullptr;
+return FPDFLink_Enumerate(mpPage, &nStartPos, &pLinkAnnot);
+}
+
 PDFiumPageObject::PDFiumPageObject(FPDF_PAGEOBJECT pPageObject)
 : mpPageObject(pPageObject)
 {
___
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-7-0+backports' - 62 commits - bridges/source chart2/source configure.ac connectivity/source drawinglayer/source emfio/qa emfio/source ext

2020-12-18 Thread Michael Weghorn (via logerrit)
 Makefile.in   |2 
 bridges/source/cpp_uno/shared/vtablefactory.cxx   |   18 
 chart2/source/view/main/VLegend.cxx   |   17 
 configure.ac  |6 
 connectivity/source/commontools/TTableHelper.cxx  |5 
 connectivity/source/drivers/firebird/DatabaseMetaData.cxx |2 
 drawinglayer/source/processor2d/vclpixelprocessor2d.cxx   |   48 
 emfio/qa/cppunit/emf/EmfImportTest.cxx|   36 
 emfio/qa/cppunit/emf/data/test_mm_hienglish_ref.emf   |binary
 emfio/qa/cppunit/emf/data/test_mm_himetric_ref.emf|binary
 emfio/source/reader/mtftools.cxx  |   58 
 extensions/source/macosx/spotlight/OOoContentDataParser.h |2 
 extensions/source/macosx/spotlight/OOoContentDataParser.m |7 
 extensions/source/macosx/spotlight/OOoMetaDataParser.h|2 
 extensions/source/macosx/spotlight/OOoMetaDataParser.m|6 
 extensions/source/propctrlr/standardcontrol.cxx   |5 
 external/mariadb-connector-c/StaticLibrary_mariadb-connector-c.mk |3 
 external/mariadb-connector-c/UnpackedTarball_mariadb-connector-c.mk   |   10 
 external/nss/nss_macosx.patch |   21 
 external/python3/ExternalProject_python3.mk   |   20 
 filter/source/msfilter/eschesdo.cxx   |   37 
 formula/source/ui/dlg/funcutl.cxx |8 
 fpicker/source/aqua/AquaFilePickerDelegate.hxx|2 
 fpicker/source/aqua/SalAquaFilePicker.mm  |8 
 hardened_runtime.xcent.in |2 
 helpcontent2  |2 
 i18npool/CustomTarget_breakiterator.mk|1 
 i18npool/source/breakiterator/data/char.txt   |  119 
 icon-themes/colibre/cmd/32/mergecells.png |binary
 icon-themes/colibre/cmd/32/selecttable.png|binary
 icon-themes/colibre/cmd/32/splitcell.png  |binary
 icon-themes/colibre/cmd/32/togglemergecells.png   |binary
 icon-themes/colibre/cmd/lc_mergecells.png |binary
 icon-themes/colibre/cmd/lc_selecttable.png|binary
 icon-themes/colibre/cmd/lc_splitcell.png  |binary
 icon-themes/colibre/cmd/lc_togglemergecells.png   |binary
 icon-themes/colibre/cmd/sc_mergecells.png |binary
 icon-themes/colibre/cmd/sc_selecttable.png|binary
 icon-themes/colibre/cmd/sc_splitcell.png  |binary
 icon-themes/colibre/cmd/sc_togglemergecells.png   |binary
 icon-themes/colibre_svg/cmd/32/mergecells.svg |2 
 icon-themes/colibre_svg/cmd/32/selecttable.svg|2 
 icon-themes/colibre_svg/cmd/32/splitcell.svg  |2 
 icon-themes/colibre_svg/cmd/32/togglemergecells.svg   |2 
 icon-themes/colibre_svg/cmd/lc_mergecells.svg |2 
 icon-themes/colibre_svg/cmd/lc_selecttable.svg|2 
 icon-themes/colibre_svg/cmd/lc_splitcell.svg  |2 
 icon-themes/colibre_svg/cmd/lc_togglemergecells.svg   |2 
 icon-themes/colibre_svg/cmd/sc_mergecells.svg |4 
 icon-themes/colibre_svg/cmd/sc_selecttable.svg|3 
 icon-themes/colibre_svg/cmd/sc_splitcell.svg  |4 
 icon-themes/colibre_svg/cmd/sc_togglemergecells.svg   |5 
 include/formula/funcutl.hxx   |5 
 include/o3tl/lru_map.hxx  |1 
 include/svx/linectrl.hxx  |5 
 include/svx/sdrpagewindow.hxx |4 
 include/svx/sidebar/LinePropertyPanelBase.hxx |4 
 odk/CustomTarget_unowinreg.mk |2 
 readlicense_oo/license/CREDITS.fodt   | 4572 
+-
 sal/rtl/math.cxx  |   99 
 sc/source/core/data/postit.cxx|   11 
 sc/source/filter/xml/xmlexprt.cxx |5 
 sc/source/ui/namedlg/namedlg.cxx  |   16 
 sd/Library

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

2020-12-18 Thread Stephan Bergmann (via logerrit)
 connectivity/source/drivers/postgresql/pq_connection.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 976ceae533becc3978e7c3741eadc69af4484437
Author: Stephan Bergmann 
AuthorDate: Fri Dec 18 09:06:27 2020 +0100
Commit: Stephan Bergmann 
CommitDate: Fri Dec 18 09:19:46 2020 +0100

fix build

...after 177792660697f85763b39f455d7ebff0f83084fd "pgsql-sdbc: use libpq's
custom free()..."

Change-Id: I44f86470707eea850742130caf7ec243d850ad51
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107933
Tested-by: Stephan Bergmann 
Reviewed-by: Stephan Bergmann 

diff --git a/connectivity/source/drivers/postgresql/pq_connection.cxx 
b/connectivity/source/drivers/postgresql/pq_connection.cxx
index e4716fe8855d..2bc1e4a42af8 100644
--- a/connectivity/source/drivers/postgresql/pq_connection.cxx
+++ b/connectivity/source/drivers/postgresql/pq_connection.cxx
@@ -444,7 +444,7 @@ void Connection::initialize( const Sequence< Any >& 
aArguments )
 nColon = url.indexOf( ':' , 1+ nColon );
 if( nColon != -1 )
 {
- o = OUStringToOString( url.subView(nColon+1), 
ConnectionSettings::encoding );
+ o = rtl::OUStringToOString( url.subView(nColon+1), 
ConnectionSettings::encoding );
 }
 }
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Noel (via logerrit)
 include/xmloff/families.hxx  |   10 
 include/xmloff/xmlstyle.hxx  |2 -
 include/xmloff/xmltoken.hxx  |2 -
 include/xmloff/xmluconv.hxx  |2 -
 sc/source/filter/xml/XMLConverter.cxx|   12 -
 sc/source/filter/xml/XMLConverter.hxx|   12 -
 sc/source/filter/xml/xmlfilti.cxx|   28 +++
 sc/source/filter/xml/xmlfilti.hxx|4 +--
 sc/source/filter/xml/xmlsorti.cxx|2 -
 sc/source/filter/xml/xmlsorti.hxx|2 -
 xmloff/inc/XMLNumberStylesImport.hxx |2 -
 xmloff/source/chart/SchXMLTools.cxx  |2 -
 xmloff/source/chart/SchXMLTools.hxx  |2 -
 xmloff/source/chart/XMLSymbolTypePropertyHdl.cxx |2 -
 xmloff/source/core/xmltoken.cxx  |9 ---
 xmloff/source/core/xmluconv.cxx  |2 -
 xmloff/source/draw/XMLNumberStyles.cxx   |2 -
 xmloff/source/style/PageMasterPropHdl.cxx|2 -
 xmloff/source/style/xmlstyle.cxx |2 -
 xmloff/source/transform/FrameOASISTContext.cxx   |2 -
 xmloff/source/transform/FrameOASISTContext.hxx   |2 -
 xmloff/source/transform/StyleOASISTContext.cxx   |4 +--
 22 files changed, 56 insertions(+), 53 deletions(-)

New commits:
commit 8e6ec5ebcc523a189238a90fd9237872d67085f9
Author: Noel 
AuthorDate: Fri Dec 18 08:57:20 2020 +0200
Commit: Noel Grandin 
CommitDate: Fri Dec 18 09:29:49 2020 +0100

use more string_view in IsXMLToken

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

diff --git a/include/xmloff/families.hxx b/include/xmloff/families.hxx
index 253472220168..58143393bc9d 100644
--- a/include/xmloff/families.hxx
+++ b/include/xmloff/families.hxx
@@ -33,14 +33,14 @@
 #define XML_STYLE_FAMILY_TABLE_ROW_STYLES_PREFIX"ro"
 #define XML_STYLE_FAMILY_TABLE_CELL_STYLES_NAME "table-cell"
 #define XML_STYLE_FAMILY_TABLE_CELL_STYLES_PREFIX   "ce"
-#define XML_STYLE_FAMILY_SD_GRAPHICS_NAME   "graphic"
+#define XML_STYLE_FAMILY_SD_GRAPHICS_NAME   u"graphic"
 #define XML_STYLE_FAMILY_SD_GRAPHICS_PREFIX "gr"
-#define XML_STYLE_FAMILY_SD_PRESENTATION_NAME   "presentation"
+#define XML_STYLE_FAMILY_SD_PRESENTATION_NAME   u"presentation"
 #define XML_STYLE_FAMILY_SD_PRESENTATION_PREFIX "pr"
-#define XML_STYLE_FAMILY_SD_POOL_NAME   "default"
-#define XML_STYLE_FAMILY_SD_DRAWINGPAGE_NAME"drawing-page"
+#define XML_STYLE_FAMILY_SD_POOL_NAME   u"default"
+#define XML_STYLE_FAMILY_SD_DRAWINGPAGE_NAMEu"drawing-page"
 #define XML_STYLE_FAMILY_SD_DRAWINGPAGE_PREFIX  "dp"
-#define XML_STYLE_FAMILY_SCH_CHART_NAME "chart"
+#define XML_STYLE_FAMILY_SCH_CHART_NAME u"chart"
 #define XML_STYLE_FAMILY_SCH_CHART_PREFIX   "ch"
 #define XML_STYLE_FAMILY_CONTROL_PREFIX "ctrl"
 
diff --git a/include/xmloff/xmlstyle.hxx b/include/xmloff/xmlstyle.hxx
index d0b820258ba4..184fd19eb379 100644
--- a/include/xmloff/xmlstyle.hxx
+++ b/include/xmloff/xmlstyle.hxx
@@ -178,7 +178,7 @@ public:
   XmlStyleFamily nFamily,
   const OUString& rName,
   bool bCreateIndex = false ) const;
-static XmlStyleFamily GetFamily( const OUString& rFamily );
+static XmlStyleFamily GetFamily( std::u16string_view rFamily );
 virtual rtl::Reference < SvXMLImportPropertyMapper > 
GetImportPropertyMapper(
 XmlStyleFamily nFamily ) const;
 
diff --git a/include/xmloff/xmltoken.hxx b/include/xmloff/xmltoken.hxx
index 0a8a12381240..19978788ec5f 100644
--- a/include/xmloff/xmltoken.hxx
+++ b/include/xmloff/xmltoken.hxx
@@ -3407,7 +3407,7 @@ namespace xmloff::token {
 
 /// compare eToken to the string
 XMLOFF_DLLPUBLIC bool IsXMLToken(
-const OUString& rString,
+std::u16string_view rString,
 enum XMLTokenEnum eToken );
 
 /// compare eToken to the string
diff --git a/include/xmloff/xmluconv.hxx b/include/xmloff/xmluconv.hxx
index daca3b617f7f..6c391d74fe7f 100644
--- a/include/xmloff/xmluconv.hxx
+++ b/include/xmloff/xmluconv.hxx
@@ -265,7 +265,7 @@ public:
 /** convert num-format and num-letter-sync values to NumberingType */
 bool convertNumFormat( sal_Int16& rType,
const OUString& rNumFormat,
-   const OUString& rNumLetterSync,
+   std::u16string_view rNumLetterSync,
bool bNumberNone = false ) const;
 
 /** convert NumberingType to num-format and num-letter-sync values */
diff --git a/sc/source/filter/xml/XMLConverter.cxx 
b/sc/source/filter/xml/XMLConverter.cxx
index 004479c7a2c6..02d4eca32f24 100644
-

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

2020-12-18 Thread Michael Stahl (via logerrit)
 sw/inc/ndtxt.hxx|2 -
 sw/qa/extras/uiwriter/data3/tdf100018-1.odt |binary
 sw/qa/extras/uiwriter/uiwriter3.cxx |   15 +
 sw/source/core/doc/DocumentContentOperationsManager.cxx |6 +++--
 sw/source/core/docnode/ndcopy.cxx   |   18 ++--
 5 files changed, 36 insertions(+), 5 deletions(-)

New commits:
commit 6c1e6b188eeb5868cafe3f1605f4213d627a452c
Author: Michael Stahl 
AuthorDate: Thu Dec 17 19:48:22 2020 +0100
Commit: Michael Stahl 
CommitDate: Fri Dec 18 09:39:28 2020 +0100

tdf#138897 sw: avoid creating SwUndoResetAttr in CopyImplImpl()

The problem is that SwTextNode::CopyCollFormat() both creates the
SwTextFormatColl with undo and applies it with undo.

The first is desirable, the second causes a problem because it
necessarily happens after SplitNode() and currently happens before
copying the non-start/end nodes, so the node-index may not match in
Undo, regardless if it runs before or after SwUndoCpyDoc.

But SwUndoInserts restores the SwTextFormatColl on the node itself,
so it can just be suppressed, which looks easier than refactoring this
to call SplitNode() with Undo enabled.

(regression from b4365b985178e1866c74afd757a104aad1d405a9)

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

diff --git a/sw/inc/ndtxt.hxx b/sw/inc/ndtxt.hxx
index 5733a5f2c3d6..7692dc5b6470 100644
--- a/sw/inc/ndtxt.hxx
+++ b/sw/inc/ndtxt.hxx
@@ -413,7 +413,7 @@ public:
 /** Copy collection with all auto formats to dest-node.
 The latter might be in another document!
(Method in ndcopy.cxx!!). */
-void CopyCollFormat( SwTextNode& rDestNd );
+void CopyCollFormat(SwTextNode& rDestNd, bool bUndoForChgFormatColl = 
true);
 
 // BEGIN OF BULLET/NUMBERING/OUTLINE STUFF:
 
diff --git a/sw/qa/extras/uiwriter/data3/tdf100018-1.odt 
b/sw/qa/extras/uiwriter/data3/tdf100018-1.odt
new file mode 100644
index ..5cd36efcee77
Binary files /dev/null and b/sw/qa/extras/uiwriter/data3/tdf100018-1.odt differ
diff --git a/sw/qa/extras/uiwriter/uiwriter3.cxx 
b/sw/qa/extras/uiwriter/uiwriter3.cxx
index 3f89bba3d171..7da4e05b03f9 100644
--- a/sw/qa/extras/uiwriter/uiwriter3.cxx
+++ b/sw/qa/extras/uiwriter/uiwriter3.cxx
@@ -2118,4 +2118,19 @@ CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testTdf137964)
 CPPUNIT_ASSERT_EQUAL(sal_Int32(3090), xShape->getPosition().Y);
 }
 
+CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testTdf138897)
+{
+load(DATA_DIRECTORY, "tdf100018-1.odt");
+
+dispatchCommand(mxComponent, ".uno:SelectAll", {});
+dispatchCommand(mxComponent, ".uno:Cut", {});
+dispatchCommand(mxComponent, ".uno:Paste", {});
+// this was crashing
+dispatchCommand(mxComponent, ".uno:Undo", {});
+dispatchCommand(mxComponent, ".uno:Redo", {});
+dispatchCommand(mxComponent, ".uno:Undo", {});
+dispatchCommand(mxComponent, ".uno:Redo", {});
+Scheduler::ProcessEventsToIdle();
+}
+
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/core/doc/DocumentContentOperationsManager.cxx 
b/sw/source/core/doc/DocumentContentOperationsManager.cxx
index ea18f8717509..19701083ba38 100644
--- a/sw/source/core/doc/DocumentContentOperationsManager.cxx
+++ b/sw/source/core/doc/DocumentContentOperationsManager.cxx
@@ -4888,7 +4888,8 @@ bool 
DocumentContentOperationsManager::CopyImplImpl(SwPaM& rPam, SwPosition& rPo
 {
 if (bCopyCollFormat)
 {
-pSttTextNd->CopyCollFormat( *pDestTextNd );
+// tdf#138897 no Undo for applying style, 
SwUndoInserts does it
+pSttTextNd->CopyCollFormat(*pDestTextNd, false);
 POP_NUMRULE_STATE
 }
 
@@ -4987,7 +4988,8 @@ bool 
DocumentContentOperationsManager::CopyImplImpl(SwPaM& rPam, SwPosition& rPo
 // Also copy all format templates
 if( bCopyCollFormat && ( bOneNode || bEmptyDestNd ))
 {
-pEndTextNd->CopyCollFormat( *pDestTextNd );
+// tdf#138897 no Undo for applying style, SwUndoInserts does it
+pEndTextNd->CopyCollFormat(*pDestTextNd, false);
 if ( bOneNode )
 {
 POP_NUMRULE_STATE
diff --git a/sw/source/core/docnode/ndcopy.cxx 
b/sw/source/core/docnode/ndcopy.cxx
index 6ccc17003f53..5b3c9edbd9db 100644
--- a/sw/source/core/docnode/ndcopy.cxx
+++ b/sw/source/core/docnode/ndcopy.cxx
@@ -18,6 +18,7 @@
  */
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -330,7 +331,7 @@ SwTableNode* SwTableNode::MakeCopy( SwDoc& rDoc, const 
SwNodeIndex& rIdx ) const
 return pTableNd;
 }
 
-void SwTextNode::CopyCollFormat( Sw

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

2020-12-18 Thread Xisco Fauli (via logerrit)
 filter/qa/cppunit/data/tiff/tdf115863.tif |binary
 filter/qa/cppunit/filters-tiff-test.cxx   |   31 +-
 2 files changed, 30 insertions(+), 1 deletion(-)

New commits:
commit e57665ea6f812aff9fc87073ce947f40a8b26e9d
Author: Xisco Fauli 
AuthorDate: Thu Dec 17 21:48:07 2020 +0100
Commit: Xisco Fauli 
CommitDate: Fri Dec 18 09:46:58 2020 +0100

tdf#115863: libtest_filter_tiff: Add unittest

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

diff --git a/filter/qa/cppunit/data/tiff/tdf115863.tif 
b/filter/qa/cppunit/data/tiff/tdf115863.tif
new file mode 100644
index ..b5e2dd9e4bcd
Binary files /dev/null and b/filter/qa/cppunit/data/tiff/tdf115863.tif differ
diff --git a/filter/qa/cppunit/filters-tiff-test.cxx 
b/filter/qa/cppunit/filters-tiff-test.cxx
index 8d8fba03caf1..0dd5e4f82354 100644
--- a/filter/qa/cppunit/filters-tiff-test.cxx
+++ b/filter/qa/cppunit/filters-tiff-test.cxx
@@ -12,6 +12,7 @@
 #include 
 #include 
 #include 
+#include 
 
 extern "C"
 {
@@ -35,13 +36,20 @@ public:
 const OUString &rURL, const OUString &,
 SfxFilterFlags, SotClipboardFormatId, unsigned int) override;
 
+OUString getUrl()
+{
+return m_directories.getURLFromSrc("/filter/qa/cppunit/data/tiff/");
+}
+
 /**
  * Ensure CVEs remain unbroken
  */
 void testCVEs();
+void testTdf115863();
 
 CPPUNIT_TEST_SUITE(TiffFilterTest);
 CPPUNIT_TEST(testCVEs);
+CPPUNIT_TEST(testTdf115863);
 CPPUNIT_TEST_SUITE_END();
 };
 
@@ -57,7 +65,28 @@ bool TiffFilterTest::load(const OUString &,
 void TiffFilterTest::testCVEs()
 {
 testDir(OUString(),
-m_directories.getURLFromSrc("/filter/qa/cppunit/data/tiff/"));
+getUrl());
+}
+
+void TiffFilterTest::testTdf115863()
+{
+OUString aURL = getUrl() + "tdf115863.tif";
+SvFileStream aFileStream(aURL, StreamMode::READ);
+Graphic aGraphic;
+GraphicFilter& rFilter = GraphicFilter::GetGraphicFilter();
+
+ErrCode bResult = rFilter.ImportGraphic(aGraphic, aURL, aFileStream);
+
+// Without the fix in place, this test would have failed with
+// - Expected: 0x0(Error Area:Io Class:NONE Code:0)
+// - Actual  : 0x8203(Error Area:Vcl Class:General Code:3)
+CPPUNIT_ASSERT_EQUAL(ERRCODE_NONE, bResult);
+
+Bitmap aBitmap = aGraphic.GetBitmapEx().GetBitmap();
+Size aSize = aBitmap.GetSizePixel();
+CPPUNIT_ASSERT_EQUAL(tools::Long(528), aSize.Width());
+CPPUNIT_ASSERT_EQUAL(tools::Long(618), aSize.Height());
+
 }
 
 CPPUNIT_TEST_SUITE_REGISTRATION(TiffFilterTest);
___
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.0' - vcl/CppunitTest_vcl_filter_ipdf.mk vcl/Module_vcl.mk vcl/qa vcl/source

2020-12-18 Thread Miklos Vajna (via logerrit)
 vcl/CppunitTest_vcl_filter_ipdf.mk  |   49 
 vcl/Module_vcl.mk   |1 
 vcl/qa/cppunit/filter/ipdf/data/dict-array-dict.pdf |   55 +
 vcl/qa/cppunit/filter/ipdf/ipdf.cxx |  112 
 vcl/source/filter/ipdf/pdfdocument.cxx  |   13 +-
 5 files changed, 228 insertions(+), 2 deletions(-)

New commits:
commit e163144267f366184c3c458bd1ff0cae4e628857
Author: Miklos Vajna 
AuthorDate: Fri Oct 16 18:15:21 2020 +0200
Commit: Miklos Vajna 
CommitDate: Fri Dec 18 10:17:07 2020 +0100

vcl pdf tokenizer: fix handling of dict -> array -> dict tokens

Needed to be able to parse the /Reference key of signatures.

(cherry picked from commit 056c1284d6a68525002c54bef10834cc135385db)

Conflicts:
vcl/qa/cppunit/filter/ipdf/ipdf.cxx

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

diff --git a/vcl/CppunitTest_vcl_filter_ipdf.mk 
b/vcl/CppunitTest_vcl_filter_ipdf.mk
new file mode 100644
index ..403836ac781a
--- /dev/null
+++ b/vcl/CppunitTest_vcl_filter_ipdf.mk
@@ -0,0 +1,49 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#*
+#
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+#*
+
+$(eval $(call gb_CppunitTest_CppunitTest,vcl_filter_ipdf))
+
+$(eval $(call gb_CppunitTest_use_externals,vcl_filter_ipdf,\
+   boost_headers \
+   pdfium \
+))
+
+$(eval $(call gb_CppunitTest_add_exception_objects,vcl_filter_ipdf, \
+vcl/qa/cppunit/filter/ipdf/ipdf \
+))
+
+$(eval $(call gb_CppunitTest_use_libraries,vcl_filter_ipdf, \
+comphelper \
+cppu \
+sal \
+sfx \
+svx \
+test \
+tl \
+unotest \
+utl \
+vcl \
+))
+
+$(eval $(call gb_CppunitTest_use_sdk_api,vcl_filter_ipdf))
+
+$(eval $(call gb_CppunitTest_use_ure,vcl_filter_ipdf))
+$(eval $(call gb_CppunitTest_use_vcl,vcl_filter_ipdf))
+
+$(eval $(call gb_CppunitTest_use_rdb,vcl_filter_ipdf,services))
+
+$(eval $(call gb_CppunitTest_use_custom_headers,vcl_filter_ipdf,\
+   officecfg/registry \
+))
+
+$(eval $(call gb_CppunitTest_use_configuration,vcl_filter_ipdf))
+
+# vim: set noet sw=4 ts=4:
diff --git a/vcl/Module_vcl.mk b/vcl/Module_vcl.mk
index a6a674bff685..0dd4eee01f69 100644
--- a/vcl/Module_vcl.mk
+++ b/vcl/Module_vcl.mk
@@ -181,6 +181,7 @@ $(eval $(call gb_Module_add_check_targets,vcl,\
 ifneq (,$(filter PDFIUM,$(BUILD_TYPE)))
 $(eval $(call gb_Module_add_check_targets,vcl,\
CppunitTest_vcl_pdfexport \
+   CppunitTest_vcl_filter_ipdf \
 ))
 endif
 
diff --git a/vcl/qa/cppunit/filter/ipdf/data/dict-array-dict.pdf 
b/vcl/qa/cppunit/filter/ipdf/data/dict-array-dict.pdf
new file mode 100644
index ..73de3117b9a6
--- /dev/null
+++ b/vcl/qa/cppunit/filter/ipdf/data/dict-array-dict.pdf
@@ -0,0 +1,55 @@
+%PDF-1.7
+%���
+1 0 obj <<
+  /Type /Catalog
+  /Pages 2 0 R
+>>
+endobj
+2 0 obj <<
+  /Type /Pages
+  /MediaBox [0 0 200 300]
+  /Count 1
+  /Kids [3 0 R]
+>>
+endobj
+3 0 obj <<
+  /Type /Page
+  /Parent 2 0 R
+  /Contents 4 0 R
+  /Key[<>]
+>>
+endobj
+4 0 obj <<
+  /Length 188
+>>
+stream
+q
+0 0 0 rg
+0 290 10 10 re B*
+10 150 50 30 re B*
+0 0 1 rg
+190 290 10 10 re B*
+70 232 50 30 re B*
+0 1 0 rg
+190 0 10 10 re B*
+130 150 50 30 re B*
+1 0 0 rg
+0 0 10 10 re B*
+70 67 50 30 re B*
+Q
+endstream
+endobj
+xref
+0 5
+00 65535 f 
+15 0 n 
+68 0 n 
+000157 0 n 
+000251 0 n 
+trailer <<
+  /Root 1 0 R
+  /Size 5
+>>
+startxref
+491
+%%EOF
diff --git a/vcl/qa/cppunit/filter/ipdf/ipdf.cxx 
b/vcl/qa/cppunit/filter/ipdf/ipdf.cxx
new file mode 100644
index ..a66adcf923e0
--- /dev/null
+++ b/vcl/qa/cppunit/filter/ipdf/ipdf.cxx
@@ -0,0 +1,112 @@
+/* -*- 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 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+using namespace ::com::sun::star;
+
+namespace
+{
+char const DATA_DIRECTORY[] = "/vcl/qa/cppunit/filter/ipdf/data/";
+}
+
+/// Covers vcl/source/filter/ipdf/ fixes.
+class VclFi

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

2020-12-18 Thread Justin Luth (via logerrit)
 sd/source/ui/func/fupage.cxx |   10 ++
 1 file changed, 10 insertions(+)

New commits:
commit 6b161f615712f6daa11f66d0dfe45eef0877c860
Author: Justin Luth 
AuthorDate: Sat Dec 5 19:48:36 2020 +0300
Commit: Xisco Fauli 
CommitDate: Fri Dec 18 10:30:30 2020 +0100

tdf#137729 sd UI: unique hatch names in slide/page area dlg

A custom hatch on a page background was not getting a name,
so it was exported referring to an empty string, which was
implemented as using the first available hatch.

Ensuring that a name exists causes the hatch to be exported
in the styles, and thus can be referred to in content.xml

All praise goes to Katarina since this just copies her
similar fix for grandients in tdf#125449.
Too bad it took me a whole day to find that.

Unfortunately, Katarina didn't provide any unit tests
for me to copycat as well.

Change-Id: If2be0830b521946fb1b88b247319a7e6c2c61c3c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107258
Tested-by: Jenkins
Reviewed-by: Xisco Fauli 
Reviewed-by: Justin Luth 
(cherry picked from commit 0c37e164dbbff89ecac843e1b182fdbce70cda34)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107898

diff --git a/sd/source/ui/func/fupage.cxx b/sd/source/ui/func/fupage.cxx
index 3779feec3f82..6d44b70d5a9d 100644
--- a/sd/source/ui/func/fupage.cxx
+++ b/sd/source/ui/func/fupage.cxx
@@ -37,6 +37,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -394,6 +395,15 @@ const SfxItemSet* FuPage::ExecuteDialog(weld::Window* 
pParent, const SfxRequest&
 SdrModel::MigrateItemSet( &aMigrateSet, pTempSet.get(), mpDoc);
 }
 
+const XFillHatchItem* pTempHatchItem = 
pTempSet->GetItem(XATTR_FILLHATCH);
+if (pTempHatchItem && pTempHatchItem->GetName().isEmpty())
+{
+// MigrateItemSet guarantees unique hatch names
+SfxItemSet aMigrateSet( mpDoc->GetPool(), 
svl::Items{} );
+aMigrateSet.Put( XFillHatchItem("hatch", 
pTempHatchItem->GetHatchValue()) );
+SdrModel::MigrateItemSet( &aMigrateSet, pTempSet.get(), mpDoc);
+}
+
 if( !mbMasterPage && bChanges && mbPageBckgrdDeleted )
 {
  mpBackgroundObjUndoAction.reset( new 
SdBackgroundObjUndoAction(
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-1' - include/sal sal/rtl

2020-12-18 Thread Eike Rathke (via logerrit)
 include/sal/mathconf.h |   14 +
 sal/rtl/math.cxx   |  135 +
 2 files changed, 85 insertions(+), 64 deletions(-)

New commits:
commit ead1cdd23f5379f5cd8f69d5e73f410a67896db2
Author: Eike Rathke 
AuthorDate: Thu Dec 17 20:44:43 2020 +0100
Commit: Eike Rathke 
CommitDate: Fri Dec 18 11:00:57 2020 +0100

Check intermediate for not to be rounded value, tdf#138360 follow-up

 This is a combination of 3 commits.

Add sal_uInt64 fields to sal_math_Double

We may need them later, and at least don't have a confusing
inf_parts or nan_parts struct name but just parts as well.

Ife0cf279c47d2815aa2a1483223397b147e9d776
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107924
Reviewed-by: Eike Rathke 
Tested-by: Jenkins

Replace log2() call with parts.exponent-1023, tdf#138360 follow-up

... to save some cycles as we anyway need only the integer value
of the exponent and even exactly this value for the number of
possible decimals.

I8d462f53cadde6a95d57d1342d8487fbfa001ae9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107928
Tested-by: Jenkins
Reviewed-by: Eike Rathke 

Check intermediate for not to be rounded value, tdf#138360 follow-up

I98cc25267e7a10c34179bab50d19f49436e1c48c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107929
Tested-by: Jenkins
Reviewed-by: Eike Rathke 

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

diff --git a/include/sal/mathconf.h b/include/sal/mathconf.h
index 687f6e3da133..11bd32c35de0 100644
--- a/include/sal/mathconf.h
+++ b/include/sal/mathconf.h
@@ -104,6 +104,13 @@ union sal_math_Double
 unsigned msw  :32;
 unsigned lsw  :32;
 } w32_parts;
+struct
+{
+sal_uInt64 sign   : 1;
+sal_uInt64 exponent   :11;
+sal_uInt64 fraction   :52;
+} parts;
+sal_uInt64 intrep;
 double value;
 };
 
@@ -130,6 +137,13 @@ union sal_math_Double
 unsigned lsw  :32;
 unsigned msw  :32;
 } w32_parts;
+struct
+{
+sal_uInt64 fraction   :52;
+sal_uInt64 exponent   :11;
+sal_uInt64 sign   : 1;
+} parts;
+sal_uInt64 intrep;
 double value;
 };
 
diff --git a/sal/rtl/math.cxx b/sal/rtl/math.cxx
index 46a3e925b95b..a85c8ac6e959 100644
--- a/sal/rtl/math.cxx
+++ b/sal/rtl/math.cxx
@@ -1167,9 +1167,10 @@ double SAL_CALL rtl_math_round(double fValue, int 
nDecPlaces,
 // Determine how many decimals are representable in the precision.
 // Anything greater 2^52 and 0.0 was already ruled out above.
 // Theoretically 0.5, 0.25, 0.125, 0.0625, 0.03125, ...
-const double fDec = 52 - log2(fValue) + 1;
-if (fDec < nDecPlaces)
-nDecPlaces = static_cast(fDec);
+const sal_math_Double* pd = reinterpret_cast(&fValue);
+const sal_Int32 nDec = 52 - (pd->parts.exponent - 1023);
+if (nDec < nDecPlaces)
+nDecPlaces = nDec;
 }
 
 /* TODO: this was without the inverse factor and determining max
@@ -1190,75 +1191,81 @@ double SAL_CALL rtl_math_round(double fValue, int 
nDecPlaces,
 fValue *= fFac;
 }
 
-switch ( eMode )
+// Round only if not already in distance precision gaps of integers, where
+// for [2^52,2^53) adding 0.5 would even yield the next representable
+// integer.
+if (fValue < (static_cast(1) << 52))
 {
-case rtl_math_RoundingMode_Corrected :
-fValue = rtl::math::approxFloor(fValue + 0.5);
-break;
-case rtl_math_RoundingMode_Down:
-fValue = rtl::math::approxFloor(fValue);
-break;
-case rtl_math_RoundingMode_Up:
-fValue = rtl::math::approxCeil(fValue);
-break;
-case rtl_math_RoundingMode_Floor:
-fValue = bSign ? rtl::math::approxCeil(fValue)
-: rtl::math::approxFloor( fValue );
-break;
-case rtl_math_RoundingMode_Ceiling:
-fValue = bSign ? rtl::math::approxFloor(fValue)
-: rtl::math::approxCeil(fValue);
-break;
-case rtl_math_RoundingMode_HalfDown :
-{
-double f = floor(fValue);
-fValue = ((fValue - f) <= 0.5) ? f : ceil(fValue);
-}
-break;
-case rtl_math_RoundingMode_HalfUp:
+switch ( eMode )
 {
-double f = floor(fValue);
-fValue = ((fValue - f) < 0.5) ? f : ceil(fValue);
-}
-break;
-case rtl_math_RoundingMode_HalfEven:
+case rtl_math_RoundingMode_Corrected :
+fValue = rtl::math::approxFloor(fValue + 0.5);
+break;
+  

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

2020-12-18 Thread Miklos Vajna (via logerrit)
 sw/source/core/layout/newfrm.cxx |4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit 73dc3bdf58d80bf22477cdf95bf46d6acbc20f80
Author: Miklos Vajna 
AuthorDate: Fri Dec 18 10:18:49 2020 +0100
Commit: Miklos Vajna 
CommitDate: Fri Dec 18 11:26:28 2020 +0100

sw: document how the first page frame is created

I can't remember if the boolean order is left/right and then
first/nonfirst or the other way around.

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

diff --git a/sw/source/core/layout/newfrm.cxx b/sw/source/core/layout/newfrm.cxx
index 36d80df0e3c9..4b40f4d6ded6 100644
--- a/sw/source/core/layout/newfrm.cxx
+++ b/sw/source/core/layout/newfrm.cxx
@@ -491,7 +491,9 @@ void SwRootFrame::Init( SwFrameFormat* pFormat )
 
 // Create a page and put it in the layout
 // The first page is always a right-page and always a first-page
-SwPageFrame *pPage = ::InsertNewPage(*pDesc, this, true, true, false, 
false, nullptr, true);
+SwPageFrame* pPage = ::InsertNewPage(
+*pDesc, /*pUpper=*/this, /*isRightPage=*/true, /*bFirst=*/true, 
/*bInsertEmpty=*/false,
+/*bFootnote=*/false, /*pSibling=*/nullptr, /*bVeryFirstPage=*/true);
 
 // Find the first page in the Bodytext section.
 SwLayoutFrame *pLay = pPage->FindBodyCont();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Have to set up IDE for Java again, any hints?

2020-12-18 Thread gerrit

Hello
I've been trying to fix a bug in the Libreoffice Base reportbuilder, and 
to push the bugfix I deleted some stuff from my libreoffice folder that 
had nothing to do with my changes. now I found bugs in my bugfix and my 
carefully hacked together eclipse fails to read the sources again wich 
it barely did before. I was unable to find the Instructions I need 
online. There was only c++ setups, no java, and if there was java, it 
was to create my own plugin wich i'm also not doing. Can someone please 
show me instructions on how to easily and correctly setup any opensource 
IDE on Linux to debug the reportbuilder?

Greetings,
Gerrit Großkopf
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2020-12-18 Thread Chris Sherlock (via logerrit)
 vcl/source/gdi/bitmap3.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 3f28fd9a4093de421ea92ddcf7e8cda65f65a3f0
Author: Chris Sherlock 
AuthorDate: Thu Dec 17 05:34:37 2020 +1100
Commit: Mike Kaganski 
CommitDate: Fri Dec 18 11:48:13 2020 +0100

vcl: move nShift closer into scope where it is used

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

diff --git a/vcl/source/gdi/bitmap3.cxx b/vcl/source/gdi/bitmap3.cxx
index a2c50583a2b4..e037c0c38c99 100644
--- a/vcl/source/gdi/bitmap3.cxx
+++ b/vcl/source/gdi/bitmap3.cxx
@@ -343,7 +343,6 @@ bool Bitmap::ImplMakeGreyscales( sal_uInt16 nGreys )
 if( pReadAcc )
 {
 const BitmapPalette& rPal = GetGreyPalette( nGreys );
-sal_uLong nShift = ( ( nGreys == 16 ) ? 4UL : 0UL );
 bool bPalDiffers = !pReadAcc->HasPalette() || ( rPal.GetEntryCount() 
!= pReadAcc->GetPaletteEntryCount() );
 
 if( !bPalDiffers )
@@ -359,6 +358,8 @@ bool Bitmap::ImplMakeGreyscales( sal_uInt16 nGreys )
 const tools::Long nWidth = pWriteAcc->Width();
 const tools::Long nHeight = pWriteAcc->Height();
 
+sal_uLong nShift = ((nGreys == 16) ? 4UL : 0UL);
+
 if( pReadAcc->HasPalette() )
 {
 for( tools::Long nY = 0; nY < nHeight; nY++ )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Noel (via logerrit)
 include/rtl/strbuf.hxx |   10 ++
 1 file changed, 10 insertions(+)

New commits:
commit ccb3fed37d849a88c74594c44f2aec68c808a33f
Author: Noel 
AuthorDate: Fri Dec 18 11:20:01 2020 +0200
Commit: Noel Grandin 
CommitDate: Fri Dec 18 11:50:55 2020 +0100

add OStringBuffer::append(std::string_view)

so we don't need to construct an OString when appending from a view

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

diff --git a/include/rtl/strbuf.hxx b/include/rtl/strbuf.hxx
index 074d1278ea86..2f2df8624f25 100644
--- a/include/rtl/strbuf.hxx
+++ b/include/rtl/strbuf.hxx
@@ -30,6 +30,7 @@
 
 #ifdef LIBO_INTERNAL_ONLY // "RTL_FAST_STRING"
 #include "rtl/stringconcat.hxx"
+#include 
 #endif
 
 #ifdef RTL_STRING_UNITTEST
@@ -585,6 +586,15 @@ public:
 return append( c.buf, c.length );
 }
 
+/**
+ @overload
+ @internal
+ */
+OStringBuffer& append( std::string_view s )
+{
+return append( s.data(), s.size() );
+}
+
 #endif
 
 /**
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Using Java on macOS ARM64

2020-12-18 Thread Stephan Bergmann

To document my findings so far:

* Running a x86-64 LO with an x86-64 JDK works fine on ARM64.

* Running an ARM64 LO with an x86-64 JDK, LO can find the JDK but cannot 
instantiate an in-process JVM:



warn:sal.osl:86417:2142204:sal/osl/unx/module.cxx:162: 
dlopen(/Library/Java/JavaVirtualMachines/adoptopenjdk-15.jdk/Contents/Home/lib/server/libjvm.dylib,
 9): 
dlopen(/Library/Java/JavaVirtualMachines/adoptopenjdk-15.jdk/Contents/Home/lib/server/libjvm.dylib,
 9): no suitable image found.  Did find:

/Library/Java/JavaVirtualMachines/adoptopenjdk-15.jdk/Contents/Home/lib/server/libjvm.dylib:
 mach-o, but wrong architecture

/Library/Java/JavaVirtualMachines/adoptopenjdk-15.jdk/Contents/Home/lib/server/libjvm.dylib:
 mach-o, but wrong architecture
warn:jfw:86417:2142204:jvmfwk/plugins/sunmajor/pluginlib/sunjavaplugin.cxx:662: [Java framework]sunjavaplugin.dylib could not load Java runtime library: 
file:///Library/Java/JavaVirtualMachines/adoptopenjdk-15.jdk/Contents/Home/lib/server/libjvm.dylib


and LO's "...The selected JRE is defective..." error box.

* A macOS ARM64 JDK is work in progress 
( "JEP 391: macOS/AArch64 Port"), and 
e.g. a MacPorts build of openjdk15 would still only cross-build an 
x86-64 one.  But Azul appears to be progressing that JEP 
(), 
and already offers e.g. JDK13 
() 
and a JDK16EA 
(; 
curiously, there's no JDK15, though):


* The Azul JDK13 works, but after starting an in-process JVM in LO it 
crashes with a SIGBUS at



Process 86470 stopped
* thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGBUS
frame #0: 0x00016bdf41d8
->  0x16bdf41d8: movx9, #0x0
0x16bdf41dc: movk   x9, #0x0, lsl #16
0x16bdf41e0: movx10, #0x0
0x16bdf41e4: movk   x10, #0x0, lsl #16
Target 0: (soffice) stopped.
(lldb) bt
* thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGBUS
  * frame #0: 0x00016bdf41d8
frame #1: 0x000284fb7500 
libjavaloaderlo.dylib`com::sun::star::uno::BaseReference::iquery_throw(pInterface=0x000287ea59d8,
 rType=0x000287ea20a0) at Reference.hxx:76:29
frame #2: 0x000284fb8ba4 
libjavaloaderlo.dylib`com::sun::star::uno::Reference::iquery_throw(pInterface=0x000287ea59d8)
 at Reference.hxx:88:12
frame #3: 0x000284fb8b60 
libjavaloaderlo.dylib`com::sun::star::uno::Reference::Reference(this=0x00016fdfa6c0,
 rRef=0x000282591550, (null)=UNO_QUERY_THROW) at Reference.hxx:191:19
frame #4: 0x000284fb7108 
libjavaloaderlo.dylib`com::sun::star::uno::Reference::Reference(this=0x00016fdfa6c0,
 rRef=0x000282591550, (null)=UNO_QUERY_THROW) at Reference.hxx:190:1
frame #5: 0x000284fb5ffc 
libjavaloaderlo.dylib`stoc_javaloader::(anonymous 
namespace)::JavaComponentLoader::getJavaLoader(this=0x000282591510) at 
javaloader.cxx:248:46
frame #6: 0x000284fb09a0 
libjavaloaderlo.dylib`stoc_javaloader::(anonymous 
namespace)::JavaComponentLoader::activate(this=0x000282591510, 
rImplName=0x0001157129e8, blabla=0x00016fdfad78, 
rLibName=0x00016fdfae08, xKey=0x00016fdfad70) at javaloader.cxx:317:65
frame #7: 0x00010124a5d8 
libuno_cppuhelpergcc3.dylib.3`cppuhelper::ServiceManager::loadImplementation(this=0x00011572a170,
 context=0x00011572a210, 
implementation=std::__1::shared_ptr::element_type
 @ 0x0001157129e8 strong=3 weak=1) at servicemanager.cxx:849:22
frame #8: 0x00010124e0cc 
libuno_cppuhelpergcc3.dylib.3`cppuhelper::ServiceManager::findServiceImplementation(this=0x00011572a170,
 context=0x00011572a210, specifier=0x00016fdfbc58) at 
servicemanager.cxx:1793:9
frame #9: 0x00010124daa0 
libuno_cppuhelpergcc3.dylib.3`cppuhelper::ServiceManager::createInstanceWithContext(this=0x00011572a170,
 aServiceSpecifier=0x00016fdfbc58, Context=0x00011572a210) at 
servicemanager.cxx:1000:9
frame #10: 0x00010124d5b4 
libuno_cppuhelpergcc3.dylib.3`cppuhelper::ServiceManager::createInstance(this=0x00011572a170,
 aServiceSpecifier=0x00016fdfbc58) at servicemanager.cxx:966:12
frame #11: 0x0001021b5ca0 
libfwklo.dylib`framework::DispatchProvider::implts_searchProtocolHandler(this=0x0001777655e0,
 aURL=0x00016fdfc6d0) at dispatchprovider.cxx:447:25
frame #12: 0x0001021b4ca4 
libfwklo.dylib`framework::DispatchProvider::implts_queryFrameDispatch(this=0x0001777655e0,
 xFrame=0x00016fdfc180, aURL=0x00016fdfc6d0, 
sTargetFrameName=0x000287d5c3b8, nSearchFlags=0) at 
dispatchprovider.cxx:355:27
frame #13: 0x0001021b39fc 
libfwklo.dylib`framework::DispatchProvider::queryDispatch(this=0x0001777655e0,
 aURL=0x00016fdfc6d0, sTargetFrameName=0x000287d5c3b8, nSe

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

2020-12-18 Thread Aron Budea (via logerrit)
 sfx2/source/sidebar/SidebarController.cxx |   11 +++
 1 file changed, 7 insertions(+), 4 deletions(-)

New commits:
commit 49b7d99af0edc46793c9955061eaee78e7f7822f
Author: Aron Budea 
AuthorDate: Wed Dec 9 18:39:54 2020 +0100
Commit: Andras Timar 
CommitDate: Fri Dec 18 12:04:22 2020 +0100

tdf#138762: crash when trying to open sidebar w chart in Writer

In Writer when in chart edit mode, and the chart is deselected,
the object selection remains. Opening Properties sidebar at
this point crashed. Calc and Impress were unaffected.

Regression from b5fdb148fe87a90f3e586efcea7aa6ef865fa42a

Change-Id: I356c3a42c41dd38e4739df27c72c6d67722b1dbc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107500
Tested-by: Jenkins
Reviewed-by: Aron Budea 
(cherry picked from commit 7e5991dc695d1e590483615c2907811ce4117834)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107544
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Andras Timar 

diff --git a/sfx2/source/sidebar/SidebarController.cxx 
b/sfx2/source/sidebar/SidebarController.cxx
index ba61d0c23a11..d6c1103850e2 100644
--- a/sfx2/source/sidebar/SidebarController.cxx
+++ b/sfx2/source/sidebar/SidebarController.cxx
@@ -622,10 +622,13 @@ void SidebarController::OpenThenToggleDeck (
 SwitchToDeck(rsDeckId);
 
 // Make sure the sidebar is wide enough to fit the requested content
-sal_Int32 nRequestedWidth = (mpCurrentDeck->GetMinimalWidth() + 
TabBar::GetDefaultWidth())
-* mpTabBar->GetDPIScaleFactor();
-if (mnSavedSidebarWidth < nRequestedWidth)
-SetChildWindowWidth(nRequestedWidth);
+if (mpCurrentDeck && mpTabBar)
+{
+sal_Int32 nRequestedWidth = (mpCurrentDeck->GetMinimalWidth() + 
TabBar::GetDefaultWidth())
+* mpTabBar->GetDPIScaleFactor();
+if (mnSavedSidebarWidth < nRequestedWidth)
+SetChildWindowWidth(nRequestedWidth);
+}
 
 collectUIInformation(rsDeckId);
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Xisco Fauli (via logerrit)
 filter/qa/cppunit/data/tiff/tdf126460.tif |binary
 filter/qa/cppunit/filters-tiff-test.cxx   |   18 ++
 2 files changed, 18 insertions(+)

New commits:
commit 8cfad2357f309c8f8aaf11c89722307b5bd704c7
Author: Xisco Fauli 
AuthorDate: Fri Dec 18 11:02:53 2020 +0100
Commit: Xisco Fauli 
CommitDate: Fri Dec 18 12:29:37 2020 +0100

tdf#126460: libtest_filter_tiff: Add unittest

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

diff --git a/filter/qa/cppunit/data/tiff/tdf126460.tif 
b/filter/qa/cppunit/data/tiff/tdf126460.tif
new file mode 100644
index ..ffdf6a1d56b8
Binary files /dev/null and b/filter/qa/cppunit/data/tiff/tdf126460.tif differ
diff --git a/filter/qa/cppunit/filters-tiff-test.cxx 
b/filter/qa/cppunit/filters-tiff-test.cxx
index 0dd5e4f82354..4a5647ca7867 100644
--- a/filter/qa/cppunit/filters-tiff-test.cxx
+++ b/filter/qa/cppunit/filters-tiff-test.cxx
@@ -45,10 +45,12 @@ public:
  * Ensure CVEs remain unbroken
  */
 void testCVEs();
+void testTdf126460();
 void testTdf115863();
 
 CPPUNIT_TEST_SUITE(TiffFilterTest);
 CPPUNIT_TEST(testCVEs);
+CPPUNIT_TEST(testTdf126460);
 CPPUNIT_TEST(testTdf115863);
 CPPUNIT_TEST_SUITE_END();
 };
@@ -68,6 +70,22 @@ void TiffFilterTest::testCVEs()
 getUrl());
 }
 
+void TiffFilterTest::testTdf126460()
+{
+OUString aURL = getUrl() + "tdf126460.tif";
+SvFileStream aFileStream(aURL, StreamMode::READ);
+Graphic aGraphic;
+GraphicFilter& rFilter = GraphicFilter::GetGraphicFilter();
+
+ErrCode bResult = rFilter.ImportGraphic(aGraphic, aURL, aFileStream);
+
+CPPUNIT_ASSERT_EQUAL(ERRCODE_NONE, bResult);
+
+// Without the fix in place, the following asserts would have failed
+CPPUNIT_ASSERT(aGraphic.IsAlpha());
+CPPUNIT_ASSERT(aGraphic.IsTransparent());
+}
+
 void TiffFilterTest::testTdf115863()
 {
 OUString aURL = getUrl() + "tdf115863.tif";
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Seth Chaiklin (via logerrit)
 sfx2/uiconfig/ui/newstyle.ui |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit c19c7d0cd5cea757d854f5e7ddc6a0e1d9b709d5
Author: Seth Chaiklin 
AuthorDate: Fri Dec 18 01:51:33 2020 +0100
Commit: Heiko Tietze 
CommitDate: Fri Dec 18 12:32:22 2020 +0100

Partially resolves: tdf#139017 update labels in Create Style dialog

  Changes name of dialog to correspond to command name.
  Changes label of entry box to Action verb and colon
because it has a buddy control.

Change-Id: Ib34b859ad2e25fbb70a46af7459c910e9bbe0ec1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107903
Tested-by: Jenkins
Reviewed-by: Seth Chaiklin 
Reviewed-by: Heiko Tietze 

diff --git a/sfx2/uiconfig/ui/newstyle.ui b/sfx2/uiconfig/ui/newstyle.ui
index 84c5580153bc..6ec3668e3302 100644
--- a/sfx2/uiconfig/ui/newstyle.ui
+++ b/sfx2/uiconfig/ui/newstyle.ui
@@ -13,7 +13,7 @@
   
 False
 6
-Create Style
+New Style from Selection
 True
 0
 0
@@ -174,7 +174,7 @@
   
 True
 False
-Style Name
+Enter New Style Name:
 
   
 
___
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' - vcl/source

2020-12-18 Thread Szymon Kłos (via logerrit)
 vcl/source/app/salvtables.cxx |3 ++-
 vcl/source/control/button.cxx |2 +-
 vcl/source/window/dialog.cxx  |2 +-
 3 files changed, 4 insertions(+), 3 deletions(-)

New commits:
commit 70f2fc7a10f41204e353bd3487377983a1018b53
Author: Szymon Kłos 
AuthorDate: Thu Dec 17 14:44:51 2020 +0100
Commit: Szymon Kłos 
CommitDate: Fri Dec 18 13:00:47 2020 +0100

lok: don't use focus window to request help

Use clicked button instead - what leads to the correct window.
If only focused window was taken into account sometimes
it caused incorrect help link to be used.

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

diff --git a/vcl/source/app/salvtables.cxx b/vcl/source/app/salvtables.cxx
index af2f66ca9b0e..4285b037c880 100644
--- a/vcl/source/app/salvtables.cxx
+++ b/vcl/source/app/salvtables.cxx
@@ -70,6 +70,7 @@
 #include 
 #include 
 #include 
+#include 
 
 SalFrame::SalFrame()
 : m_pWindow(nullptr)
@@ -6218,7 +6219,7 @@ void SalInstanceWindow::help()
 {
 //show help for widget with keyboard focus
 vcl::Window* pWidget = ImplGetSVData()->mpWinData->mpFocusWin;
-if (!pWidget)
+if (!pWidget || comphelper::LibreOfficeKit::isActive())
 pWidget = m_xWindow;
 OString sHelpId = pWidget->GetHelpId();
 while (sHelpId.isEmpty())
diff --git a/vcl/source/control/button.cxx b/vcl/source/control/button.cxx
index a4ae36cffe15..fecb052628b7 100644
--- a/vcl/source/control/button.cxx
+++ b/vcl/source/control/button.cxx
@@ -1774,7 +1774,7 @@ void HelpButton::Click()
 if ( !GetClickHdl() )
 {
 vcl::Window* pFocusWin = Application::GetFocusWindow();
-if ( !pFocusWin )
+if ( !pFocusWin || comphelper::LibreOfficeKit::isActive() )
 pFocusWin = this;
 
 HelpEvent aEvt( pFocusWin->GetPointerPosPixel(), 
HelpEventMode::CONTEXT );
diff --git a/vcl/source/window/dialog.cxx b/vcl/source/window/dialog.cxx
index df9135f43058..536228b97ec8 100644
--- a/vcl/source/window/dialog.cxx
+++ b/vcl/source/window/dialog.cxx
@@ -1374,7 +1374,7 @@ IMPL_LINK(Dialog, ResponseHdl, Button*, pButton, void)
 if (nResponse == RET_HELP)
 {
 vcl::Window* pFocusWin = Application::GetFocusWindow();
-if (!pFocusWin)
+if (!pFocusWin || comphelper::LibreOfficeKit::isActive())
 pFocusWin = pButton;
 HelpEvent aEvt(pFocusWin->GetPointerPosPixel(), 
HelpEventMode::CONTEXT);
 pFocusWin->RequestHelp(aEvt);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] translations.git: Branch 'distro/collabora/cp-6.4' - source/ar source/as source/ast source/bg source/bn-IN source/br source/ca source/ca-valencia source/cs source/cy source/da so

2020-12-18 Thread Andras Timar (via logerrit)
 source/ar/cui/messages.po  |  433 ++---
 source/as/cui/messages.po  |  433 ++---
 source/ast/cui/messages.po |  433 ++---
 source/bg/cui/messages.po  |  433 ++---
 source/bn-IN/cui/messages.po   |  433 ++---
 source/br/cui/messages.po  |  433 ++---
 source/ca-valencia/cui/messages.po |  433 ++---
 source/ca/cui/messages.po  |  433 ++---
 source/cs/cui/messages.po  |  433 ++---
 source/cy/cui/messages.po  |  433 ++---
 source/da/cui/messages.po  |  433 ++---
 source/de/cui/messages.po  |  433 ++---
 source/el/cui/messages.po  |  433 ++---
 source/en-GB/cui/messages.po   |  433 ++---
 source/es/cui/messages.po  |  172 +-
 source/et/cui/messages.po  |  433 ++---
 source/eu/cui/messages.po  |  433 ++---
 source/fi/cui/messages.po  |  433 ++---
 source/fr/cui/messages.po  |  433 ++---
 source/ga/cui/messages.po  |  433 ++---
 source/gd/cui/messages.po  |  433 ++---
 source/gl/cui/messages.po  |  433 ++---
 source/gu/cui/messages.po  |  433 ++---
 source/he/cui/messages.po  |  433 ++---
 source/hi/cui/messages.po  |  433 ++---
 source/hr/cui/messages.po  |  433 ++---
 source/hu/cui/messages.po  |  433 ++---
 source/id/cui/messages.po  |  433 ++---
 source/is/cui/messages.po  |  433 ++---
 source/it/cui/messages.po  |  433 ++---
 source/ja/cui/messages.po  |  433 ++---
 source/km/cui/messages.po  |  433 ++---
 source/kn/cui/messages.po  |  433 ++---
 source/ko/cui/messages.po  |  433 ++---
 source/lt/cui/messages.po  |  433 ++---
 source/lv/cui/messages.po  |  433 ++---
 source/ml/cui/messages.po  |  433 ++---
 source/mr/cui/messages.po  |  433 ++---
 source/nb/cui/messages.po  |  433 ++---
 source/nl/cui/messages.po  |  433 ++---
 source/nn/cui/messages.po  |  433 ++---
 source/oc/cui/messages.po  |  433 ++---
 source/or/cui/messages.po  |  433 ++---
 source/pa-IN/cui/messages.po   |  433 ++---
 source/pl/cui/messages.po  |  433 ++---
 source/pt-BR/cui/messages.po   |  433 ++---
 source/pt/cui/messages.po  |  433 ++---
 source/ro/cui/messages.po  |  435 ++---
 source/ru/cui/messages.po  |  433 ++---
 source/sk/cui/messages.po  |  433 ++---
 source/sl/cui/messages.po  | 3037 ++---
 source/sr-Latn/cui/messages.po |  439 ++---
 source/sr/cui/messages.po  |  439 ++---
 source/sv/cui/messages.po  |  433 ++---
 source/ta/cui/messages.po  |  437 ++---
 source/te/cui/messages.po  |  437 ++---
 source/tr/cui/messages.po  |  433 ++---
 source/uk/cui/messages.po  |  433 ++---
 source/vi/cui/messages.po  |  433 ++---
 source/zh-CN/cui/messages.po   |  433 ++---
 source/zh-TW/cui/messages.po   |  433 ++---
 61 files changed, 17046 insertions(+), 11732 deletions(-)

New commits:
commit 4418735900f7b96584fb9f2cd247e1ca858266f3
Author: Andras Timar 
AuthorDate: Fri Dec 18 13:33:03 2020 +0100
Commit: Andras Timar 
CommitDate: Fri Dec 18 13:33:03 2020 +0100

Translation update for 'Impress Table Shadow' feature

Change-Id: I21b277d71ea1cf4d7036683faf40e10c47f97ee0

diff --git a/source/ar/cui/messages.po b/source/ar/cui/messages.po
index 641f3e6d7bc..84455e1c1a9 100644
--- a/source/ar/cui/messages.po
+++ b/source/ar/cui/messages.po
@@ -3,7 +3,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
 "Report-Msgid-Bugs-To: 
https://bugs.libreoffice.org/enter_bug.cgi?product=LibreOffice&bug_status=UNCONFIRMED&component=UI\n";
-"POT-Creation-Date: 2020-02-27 12:57+0100\n"
+"POT-Creation-Date: 2020-12-18 12:51+0100\n"
 "PO-Revision-Date: 2020-08-05 13:35+\n"
 "Last-Translator: صفا الفليج \n"
 "Language-Team: Arabic 
\n"
@@ -4263,163 +4263,163 @@ msgid "Parameters"
 msgstr "المعاملات"
 
 #. nxZTH
-#: cui/uiconfig/ui/applyautofmtpage.ui:47
+#: cui/uiconfig/ui/applyautofmtpage.ui:53
 msgctxt "applyautofmtpage|edit"
 msgid "_Edit..."
 msgstr "_حرر..."
 
 #. sYxng
-#: cui/uiconfig/ui/applyautofmtpage.ui:65
+#: cui/uiconfig/ui/applyautofmtpage.ui:71
 msgctxt "applyautofmtpage|label1"
 msgid "[M]: Replace while modifying existing text"
 msgstr "[ت]: تنسيق تلقائي أثناء تعديل النص الموجود"
 
 #. FtXg9
-#: cui/uiconfig/ui/applyautofmtpage.ui:77
+#: cui/uiconfig/ui/applyautofmtpage.ui:83
 msgctxt "applyautofmtpage|label2"
 msgid "[T]: AutoCorrect while typing"
 msgstr "[ك]: تصحيح تلقائي أثناء الكتابة"
 
 #. NujUD
-#: cui/uiconfig/ui/applyautofmtpage.ui:122
+#: cui/uiconfig/ui/applyautofmtpage.ui:128
 msgctxt "applyautofmtpage|m"
 msgid "[M]"
 msgstr "[ت]"
 
 #. qanx6
-#: cui/uiconfig/ui/applyautofmtpage.ui:137
+#: cui/uiconfig/ui/applyautofmtpage.ui:150
 msgctxt

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

2020-12-18 Thread Andras Timar (via logerrit)
 translations |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 0c402356100bf4c0db342d31fcfca53d41eba962
Author: Andras Timar 
AuthorDate: Fri Dec 18 13:33:37 2020 +0100
Commit: Gerrit Code Review 
CommitDate: Fri Dec 18 13:33:37 2020 +0100

Update git submodules

* Update translations from branch 'distro/collabora/cp-6.4'
  to 4418735900f7b96584fb9f2cd247e1ca858266f3
  - Translation update for 'Impress Table Shadow' feature

Change-Id: I21b277d71ea1cf4d7036683faf40e10c47f97ee0

diff --git a/translations b/translations
index c68bab7cc30d..4418735900f7 16
--- a/translations
+++ b/translations
@@ -1 +1 @@
-Subproject commit c68bab7cc30dfa80ac049eff819fdc1ea022f779
+Subproject commit 4418735900f7b96584fb9f2cd247e1ca858266f3
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Jan-Marek Glogowski (via logerrit)
 cui/source/options/fontsubs.cxx |1 -
 1 file changed, 1 deletion(-)

New commits:
commit 4cabfc30bf2db873930cef4f7f1b0243ae2fde28
Author: Jan-Marek Glogowski 
AuthorDate: Thu Dec 17 19:30:26 2020 +0100
Commit: Jan-Marek Glogowski 
CommitDate: Fri Dec 18 13:47:56 2020 +0100

tdf#138865 don't set ColumnToggleType::Check

We don't want any hidden, magic checkbox for this table, as the
user explicitly has to toggle the desired replacement modes,
which isn't in any way related to a row selection.

Change-Id: I3f9a73d41cc8727aa6380172221ea07068ef74c3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107920
Reviewed-by: Attila Szűcs 
Reviewed-by: László Németh 
Reviewed-by: Jan-Marek Glogowski 
Tested-by: Jenkins
Tested-by: László Németh 

diff --git a/cui/source/options/fontsubs.cxx b/cui/source/options/fontsubs.cxx
index fa05481d0663..07c4f7e9f51e 100644
--- a/cui/source/options/fontsubs.cxx
+++ b/cui/source/options/fontsubs.cxx
@@ -54,7 +54,6 @@ SvxFontSubstTabPage::SvxFontSubstTabPage(weld::Container* 
pPage, weld::DialogCon
 
 m_xCheckLB->set_size_request(m_xCheckLB->get_approximate_digit_width() * 
60,
  m_xCheckLB->get_height_rows(8));
-m_xCheckLB->enable_toggle_buttons(weld::ColumnToggleType::Check);
 m_xCheckLB->set_help_id(HID_OFA_FONT_SUBST_CLB);
 m_xCheckLB->set_selection_mode(SelectionMode::Multiple);
 
___
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.0' - include/vcl svx/source vcl/Library_vcl.mk vcl/qa vcl/source

2020-12-18 Thread Tomaž Vajngerl (via logerrit)
 include/vcl/filter/PDFiumLibrary.hxx   |   46 +
 svx/source/svdraw/svdpdf.cxx   |   14 +-
 svx/source/svdraw/svdpdf.hxx   |4 ++
 vcl/Library_vcl.mk |1 
 vcl/qa/cppunit/pdfexport/pdfexport.cxx |   11 ++-
 vcl/source/filter/ipdf/pdfread.cxx |   26 +++---
 vcl/source/pdf/PDFiumLibrary.cxx   |   39 +++
 7 files changed, 101 insertions(+), 40 deletions(-)

New commits:
commit 7acba39a9b3c17b83e3365e3e4ff2b4f2a3cc778
Author: Tomaž Vajngerl 
AuthorDate: Sun May 31 11:50:20 2020 +0200
Commit: Miklos Vajna 
CommitDate: Fri Dec 18 13:54:06 2020 +0100

pdfium: only init pdfium library one and destroy on LO exit

With more and more usage of PDFium, it is hard to keep track of
the life-time of the PDFium library, so it can happen that a
FPDF_DestroyLibrary happens when we still have another instance
where PDFium is still use. The result of this is a crash. To
prevent this, just initialize the library once and delete, when
on LO exit.

This can be improved in the future to only keep the library
active when in actual use.

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95391
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl 
(cherry picked from commit 067a8a954c8e1d8d6465a4ab5fb61e93f16c26c2)

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95933
Tested-by: Tomaž Vajngerl 
Reviewed-by: Tomaž Vajngerl 
(cherry picked from commit 3538b83c8d83e66f63c745bd769d118117704026)

Conflicts:
vcl/qa/cppunit/pdfexport/pdfexport.cxx
vcl/source/filter/ipdf/pdfread.cxx
vcl/source/graphic/VectorGraphicSearch.cxx

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

diff --git a/include/vcl/filter/PDFiumLibrary.hxx 
b/include/vcl/filter/PDFiumLibrary.hxx
new file mode 100644
index ..1f6d97045088
--- /dev/null
+++ b/include/vcl/filter/PDFiumLibrary.hxx
@@ -0,0 +1,46 @@
+/* -*- 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/.
+ *
+ */
+
+#pragma once
+
+#include 
+
+#if HAVE_FEATURE_PDFIUM
+
+#include 
+#include 
+#include 
+
+namespace vcl
+{
+namespace pdf
+{
+class VCL_DLLPUBLIC PDFium final
+{
+private:
+PDFium(const PDFium&) = delete;
+PDFium& operator=(const PDFium&) = delete;
+
+public:
+PDFium();
+~PDFium();
+};
+
+struct PDFiumLibrary : public rtl::StaticWithInit, 
PDFiumLibrary>
+{
+std::shared_ptr operator()() { return std::make_shared(); }
+};
+
+} // namespace pdf
+} // namespace pdf
+
+#endif // HAVE_FEATURE_PDFIUM
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/svdraw/svdpdf.cxx b/svx/source/svdraw/svdpdf.cxx
index 9e49a3d1e90a..78437f247123 100644
--- a/svx/source/svdraw/svdpdf.cxx
+++ b/svx/source/svdraw/svdpdf.cxx
@@ -147,6 +147,7 @@ ImpSdrPdfImport::ImpSdrPdfImport(SdrModel& rModel, 
SdrLayerID nLay, const tools:
 , mnPageCount(0)
 , mdPageWidthPts(0)
 , mdPageHeightPts(0)
+, mpPDFium(vcl::pdf::PDFiumLibrary::get())
 {
 mpVD->EnableOutput(false);
 mpVD->SetLineColor();
@@ -160,13 +161,6 @@ ImpSdrPdfImport::ImpSdrPdfImport(SdrModel& rModel, 
SdrLayerID nLay, const tools:
svl::Items{});
 checkClip();
 
-FPDF_LIBRARY_CONFIG aConfig;
-aConfig.version = 2;
-aConfig.m_pUserFontPaths = nullptr;
-aConfig.m_pIsolate = nullptr;
-aConfig.m_v8EmbedderSlot = 0;
-FPDF_InitLibraryWithConfig(&aConfig);
-
 // Load the buffer using pdfium.
 mpPdfDocument = FPDF_LoadMemDocument(mpPdfData->data(), mpPdfData->size(),
  /*password=*/nullptr);
@@ -199,11 +193,7 @@ ImpSdrPdfImport::ImpSdrPdfImport(SdrModel& rModel, 
SdrLayerID nLay, const tools:
 mnPageCount = FPDF_GetPageCount(mpPdfDocument);
 }
 
-ImpSdrPdfImport::~ImpSdrPdfImport()
-{
-FPDF_CloseDocument(mpPdfDocument);
-FPDF_DestroyLibrary();
-}
+ImpSdrPdfImport::~ImpSdrPdfImport() { FPDF_CloseDocument(mpPdfDocument); }
 
 void ImpSdrPdfImport::DoObjects(SvdProgressInfo* pProgrInfo, sal_uInt32* 
pActionsToReport,
 int nPageIndex)
diff --git a/svx/source/svdraw/svdpdf.hxx b/svx/source/svdraw/svdpdf.hxx
index fd97768dc233..0b293e894709 100644
--- a/svx/source/svdraw/svdpdf.hxx
+++ b/svx/source/svdraw/svdpdf.hxx
@@ -41,6 +41,8 @@
 #include 
 #include 
 
+#include 
+
 // Forward Declarations
 
 class SfxItemSet;
@@ -207,6 +209,8 @@ class ImpSdrPdfImpo

[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.0' - include/vcl vcl/source xmlsecurity/Library_xmlsecurity.mk xmlsecurity/qa xmlsecurity/source xmlsecurity/workben

2020-12-18 Thread Miklos Vajna (via logerrit)
 include/vcl/filter/PDFiumLibrary.hxx   |   
30 
 vcl/source/pdf/PDFiumLibrary.cxx   |   
31 
 xmlsecurity/Library_xmlsecurity.mk |   
 5 
 xmlsecurity/qa/unit/signing/data/hide-and-replace-shadow-file-signed-2.pdf 
|binary
 xmlsecurity/qa/unit/signing/signing.cxx|   
18 ++
 xmlsecurity/source/pdfio/pdfdocument.cxx   |   
70 ++
 xmlsecurity/workben/pdfverify.cxx  |   
 5 
 7 files changed, 156 insertions(+), 3 deletions(-)

New commits:
commit 3bd3fbe77ba0fb86e82f157b15f9626d586e96fa
Author: Miklos Vajna 
AuthorDate: Fri Sep 4 17:17:48 2020 +0200
Commit: Miklos Vajna 
CommitDate: Fri Dec 18 13:54:19 2020 +0100

xmlsecurity: pdf incremental updates that are non-commenting are invalid

I.e. it's OK to add incremental updates for annotation/commenting
purposes and that doesn't invalite existing signatures. Everything else
does.

(cherry picked from commit 61834cd574568613f0b0a2ee099a60fa5a8d9804)

Conflicts:
include/vcl/filter/PDFiumLibrary.hxx
vcl/source/pdf/PDFiumLibrary.cxx
xmlsecurity/qa/unit/signing/signing.cxx
xmlsecurity/source/pdfio/pdfdocument.cxx
xmlsecurity/workben/pdfverify.cxx

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

diff --git a/include/vcl/filter/PDFiumLibrary.hxx 
b/include/vcl/filter/PDFiumLibrary.hxx
index 1f6d97045088..60ece6b7cbc9 100644
--- a/include/vcl/filter/PDFiumLibrary.hxx
+++ b/include/vcl/filter/PDFiumLibrary.hxx
@@ -17,6 +17,9 @@
 #include 
 #include 
 #include 
+#include 
+
+#include 
 
 namespace vcl
 {
@@ -33,6 +36,33 @@ public:
 ~PDFium();
 };
 
+class VCL_DLLPUBLIC PDFiumPage final
+{
+private:
+FPDF_PAGE mpPage;
+
+private:
+PDFiumPage(const PDFiumPage&) = delete;
+PDFiumPage& operator=(const PDFiumPage&) = delete;
+
+public:
+PDFiumPage(FPDF_PAGE pPage)
+: mpPage(pPage)
+{
+}
+
+~PDFiumPage()
+{
+if (mpPage)
+FPDF_ClosePage(mpPage);
+}
+
+FPDF_PAGE getPointer() { return mpPage; }
+
+/// Get bitmap checksum of the page, without annotations/commenting.
+BitmapChecksum getChecksum();
+};
+
 struct PDFiumLibrary : public rtl::StaticWithInit, 
PDFiumLibrary>
 {
 std::shared_ptr operator()() { return std::make_shared(); }
diff --git a/vcl/source/pdf/PDFiumLibrary.cxx b/vcl/source/pdf/PDFiumLibrary.cxx
index 9d822c34642c..a8774b15bb4e 100644
--- a/vcl/source/pdf/PDFiumLibrary.cxx
+++ b/vcl/source/pdf/PDFiumLibrary.cxx
@@ -15,6 +15,9 @@
 #include 
 #include 
 
+#include 
+#include 
+
 namespace vcl
 {
 namespace pdf
@@ -31,6 +34,34 @@ PDFium::PDFium()
 
 PDFium::~PDFium() { FPDF_DestroyLibrary(); }
 
+BitmapChecksum PDFiumPage::getChecksum()
+{
+size_t nPageWidth = FPDF_GetPageWidth(mpPage);
+size_t nPageHeight = FPDF_GetPageHeight(mpPage);
+FPDF_BITMAP pPdfBitmap = FPDFBitmap_Create(nPageWidth, nPageHeight, 
/*alpha=*/1);
+if (!pPdfBitmap)
+{
+return 0;
+}
+
+// Intentionally not using FPDF_ANNOT here, annotations/commenting is OK 
to not affect the
+// checksum, signature verification wants this.
+FPDF_RenderPageBitmap(pPdfBitmap, mpPage, /*start_x=*/0, /*start_y=*/0, 
nPageWidth, nPageHeight,
+  /*rotate=*/0, /*flags=*/0);
+Bitmap aBitmap(Size(nPageWidth, nPageHeight), 24);
+{
+Bitmap::ScopedWriteAccess pWriteAccess(aBitmap);
+const auto pPdfBuffer = static_cast(FPDFBitmap_GetBuffer(pPdfBitmap));
+const int nStride = FPDFBitmap_GetStride(pPdfBitmap);
+for (size_t nRow = 0; nRow < nPageHeight; ++nRow)
+{
+const sal_uInt8* pPdfLine = pPdfBuffer + (nStride * nRow);
+pWriteAccess->CopyScanline(nRow, pPdfLine, 
ScanlineFormat::N32BitTcBgra, nStride);
+}
+}
+return aBitmap.GetChecksum();
+}
+
 } // end pdf
 } // end vcl
 
diff --git a/xmlsecurity/Library_xmlsecurity.mk 
b/xmlsecurity/Library_xmlsecurity.mk
index 22d27c717155..26d1549089c2 100644
--- a/xmlsecurity/Library_xmlsecurity.mk
+++ b/xmlsecurity/Library_xmlsecurity.mk
@@ -20,7 +20,10 @@ $(eval $(call gb_Library_add_defs,xmlsecurity,\
 -DXMLSECURITY_DLLIMPLEMENTATION \
 ))
 
-$(eval $(call gb_Library_use_externals,xmlsecurity,boost_headers))
+$(eval $(call gb_Library_use_externals,xmlsecurity,\
+   boost_headers \
+   $(if $(filter PDFIUM,$(BUILD_TYPE)),pdfium) \
+))
 
 $(eval $(call 
gb_Library_set_precompiled_header,xmlsecurity,$(SRCDIR)/xmlsecurity/inc/pch/precompiled_xmlsecurity))
 
diff --git 
a/xmlsecurity/qa/unit/signing/data/hide-and-replace-shadow-file-signed-2.pdf 
b/xmlsecurity

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

2020-12-18 Thread Christian Lohmaier (via logerrit)
 configure.ac |4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit d691b46e52d173cf945130df01bd35b5c4c0f539
Author: Christian Lohmaier 
AuthorDate: Fri Dec 18 15:40:37 2020 +0100
Commit: Christian Lohmaier 
CommitDate: Fri Dec 18 15:40:37 2020 +0100

cross-compilation targets really do need all AC_CONFIG_FILES

Build doesn't fail after just a make clean, but do fail with a
completely fresh checkout
regression from https://gerrit.libreoffice.org/c/core/+/107655

Change-Id: Id05f747548729449fbda6306fc27e35377b80569

diff --git a/configure.ac b/configure.ac
index 1458c394c9fc..89c44b74e4f9 100644
--- a/configure.ac
+++ b/configure.ac
@@ -5156,7 +5156,9 @@ if test "$cross_compiling" = "yes"; then
 hardened_runtime.xcent.in \
 instsetoo_native/util/openoffice.lst.in \
 config_host/*.in \
-sysui/desktop/macosx/Info.plist.in) \
+sysui/desktop/macosx/Info.plist.in \
+.vscode/vs-code-template.code-workspace.in \
+) \
 | (cd CONF-FOR-BUILD && tar xf -)
 cp configure CONF-FOR-BUILD
 test -d config_build && cp -p config_build/*.h CONF-FOR-BUILD/config_host 
2>/dev/null
___
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.0' - include/vcl vcl/source xmlsecurity/inc xmlsecurity/qa xmlsecurity/source xmlsecurity/workben

2020-12-18 Thread Miklos Vajna (via logerrit)
 include/vcl/filter/PDFiumLibrary.hxx|2 
 include/vcl/filter/pdfdocument.hxx  |6 +
 vcl/source/filter/ipdf/pdfdocument.cxx  |   82 ++--
 vcl/source/pdf/PDFiumLibrary.cxx|   12 +-
 xmlsecurity/inc/pdfio/pdfdocument.hxx   |2 
 xmlsecurity/qa/unit/pdfsigning/data/bad-cert-p1.pdf |binary
 xmlsecurity/qa/unit/pdfsigning/pdfsigning.cxx   |   25 +-
 xmlsecurity/source/helper/pdfsignaturehelper.cxx|5 -
 xmlsecurity/source/pdfio/pdfdocument.cxx|   17 ++--
 xmlsecurity/workben/pdfverify.cxx   |3 
 10 files changed, 130 insertions(+), 24 deletions(-)

New commits:
commit 255ff5f6f9f11f72fca48b337c8dc6f2d08e8d6b
Author: Miklos Vajna 
AuthorDate: Mon Oct 19 16:50:07 2020 +0200
Commit: Miklos Vajna 
CommitDate: Fri Dec 18 16:02:08 2020 +0100

xmlsecurity: handle MDP permission during PDF verify

(cherry picked from commit 586f6abee92af3cdabdce034b607b9a046ed3946)

Conflicts:
include/vcl/filter/PDFiumLibrary.hxx
vcl/source/filter/ipdf/pdfdocument.cxx
vcl/source/pdf/PDFiumLibrary.cxx
xmlsecurity/inc/pdfio/pdfdocument.hxx
xmlsecurity/qa/unit/pdfsigning/pdfsigning.cxx
xmlsecurity/source/helper/pdfsignaturehelper.cxx

(cherry picked from commit 00479937dc071246cc27f33fd6397668448a7ed9)

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

diff --git a/include/vcl/filter/PDFiumLibrary.hxx 
b/include/vcl/filter/PDFiumLibrary.hxx
index 60ece6b7cbc9..34b28787eb37 100644
--- a/include/vcl/filter/PDFiumLibrary.hxx
+++ b/include/vcl/filter/PDFiumLibrary.hxx
@@ -60,7 +60,7 @@ public:
 FPDF_PAGE getPointer() { return mpPage; }
 
 /// Get bitmap checksum of the page, without annotations/commenting.
-BitmapChecksum getChecksum();
+BitmapChecksum getChecksum(int nMDPPerm);
 };
 
 struct PDFiumLibrary : public rtl::StaticWithInit, 
PDFiumLibrary>
diff --git a/include/vcl/filter/pdfdocument.hxx 
b/include/vcl/filter/pdfdocument.hxx
index 65f72f301c8f..a814a7da3c15 100644
--- a/include/vcl/filter/pdfdocument.hxx
+++ b/include/vcl/filter/pdfdocument.hxx
@@ -359,6 +359,7 @@ public:
 size_t GetObjectOffset(size_t nIndex) const;
 const std::vector< std::unique_ptr >& GetElements();
 std::vector GetPages();
+PDFObjectElement* GetCatalog();
 /// Remember the end location of an EOF token.
 void PushBackEOF(size_t nOffset);
 /// Look up object based on object number, possibly by parsing object 
streams.
@@ -381,6 +382,11 @@ public:
 bool Write(SvStream& rStream);
 /// Get a list of signatures embedded into this document.
 std::vector GetSignatureWidgets();
+/**
+ * Get the value of the "modification detection and prevention" permission:
+ * Valid values are 1, 2 and 3: only 3 allows annotations after signing.
+ */
+int GetMDPPerm();
 /// Remove the nth signature from read document in the edit buffer.
 bool RemoveSignature(size_t nPosition);
 /// Get byte offsets of the end of incremental updates.
diff --git a/vcl/source/filter/ipdf/pdfdocument.cxx 
b/vcl/source/filter/ipdf/pdfdocument.cxx
index 6851bef19b91..b17ffb25999f 100644
--- a/vcl/source/filter/ipdf/pdfdocument.cxx
+++ b/vcl/source/filter/ipdf/pdfdocument.cxx
@@ -1793,10 +1793,8 @@ static void visitPages(PDFObjectElement* pPages, 
std::vector&
 pPages->setVisiting(false);
 }
 
-std::vector PDFDocument::GetPages()
+PDFObjectElement* PDFDocument::GetCatalog()
 {
-std::vector aRet;
-
 PDFReferenceElement* pRoot = nullptr;
 
 
@@ -1817,11 +1815,18 @@ std::vector PDFDocument::GetPages()
 
 if (!pRoot)
 {
-SAL_WARN("vcl.filter", "PDFDocument::GetPages: trailer has no Root 
key");
-return aRet;
+SAL_WARN("vcl.filter", "PDFDocument::GetCatalog: trailer has no Root 
key");
+return nullptr;
 }
 
-PDFObjectElement* pCatalog = pRoot->LookupObject();
+return pRoot->LookupObject();
+}
+
+std::vector PDFDocument::GetPages()
+{
+std::vector aRet;
+
+PDFObjectElement* pCatalog = GetCatalog();
 if (!pCatalog)
 {
 SAL_WARN("vcl.filter", "PDFDocument::GetPages: trailer has no 
catalog");
@@ -1896,6 +1901,71 @@ std::vector 
PDFDocument::GetSignatureWidgets()
 return aRet;
 }
 
+int PDFDocument::GetMDPPerm()
+{
+int nRet = 3;
+
+std::vector aSignatures = GetSignatureWidgets();
+if (aSignatures.empty())
+{
+return nRet;
+}
+
+for (const auto& pSignature : aSignatures)
+{
+vcl::filter::PDFObjectElement* pSig = pSignature->LookupObject("V");
+if (!pSig)
+{
+SAL_WARN("vcl.filter", "PDFDocument::GetMDPPerm: can't find 
signature object");
+continue;
+}
+

[Libreoffice-commits] translations.git: Branch 'distro/collabora/cp-6.4' - source/ar source/as source/ast source/bg source/bn-IN source/br source/ca source/ca-valencia source/cs source/cy source/da so

2020-12-18 Thread Andras Timar (via logerrit)
 source/ar/sc/messages.po  |  632 ++--
 source/as/sc/messages.po  |  631 ++--
 source/ast/sc/messages.po |  627 ++--
 source/bg/sc/messages.po  |  627 ++--
 source/bn-IN/sc/messages.po   |  630 ++--
 source/br/sc/messages.po  |  631 ++--
 source/ca-valencia/sc/messages.po |  627 ++--
 source/ca/sc/messages.po  |  627 ++--
 source/cs/sc/messages.po  |  627 ++--
 source/cy/sc/messages.po  |  627 ++--
 source/da/sc/messages.po  |  627 ++--
 source/de/sc/messages.po  |  627 ++--
 source/el/sc/messages.po  |  627 ++--
 source/en-GB/sc/messages.po   |  627 ++--
 source/es/sc/messages.po  |  610 ++--
 source/et/sc/messages.po  |  627 ++--
 source/eu/sc/messages.po  |  627 ++--
 source/fi/sc/messages.po  |  627 ++--
 source/fr/sc/messages.po  |  627 ++--
 source/ga/sc/messages.po  |  627 ++--
 source/gd/sc/messages.po  |  627 ++--
 source/gl/sc/messages.po  |  627 ++--
 source/gu/sc/messages.po  |  629 ++--
 source/he/sc/messages.po  |  633 ++--
 source/hi/sc/messages.po  |  632 ++--
 source/hr/sc/messages.po  |  627 ++--
 source/hu/sc/messages.po  |  627 ++--
 source/id/sc/messages.po  |  627 ++--
 source/is/sc/messages.po  |  627 ++--
 source/it/sc/messages.po  |  627 ++--
 source/ja/sc/messages.po  |  627 ++--
 source/km/sc/messages.po  |  629 ++--
 source/kn/sc/messages.po  |  630 ++--
 source/ko/sc/messages.po  |  627 ++--
 source/lt/sc/messages.po  |  627 ++--
 source/lv/sc/messages.po  |  627 ++--
 source/ml/sc/messages.po  |  631 ++--
 source/mr/sc/messages.po  |  629 ++--
 source/nb/sc/messages.po  |  627 ++--
 source/nl/sc/messages.po  |  627 ++--
 source/nn/sc/messages.po  |  627 ++--
 source/oc/sc/messages.po  |  627 ++--
 source/or/sc/messages.po  |  631 ++--
 source/pa-IN/sc/messages.po   |  627 ++--
 source/pl/sc/messages.po  |  627 ++--
 source/pt-BR/sc/messages.po   |  627 ++--
 source/pt/sc/messages.po  |  627 ++--
 source/ro/sc/messages.po  |  631 ++--
 source/ru/sc/messages.po  |  627 ++--
 source/sk/sc/messages.po  |  627 ++--
 source/sl/sc/messages.po  | 5454 --
 source/sr-Latn/sc/messages.po |  628 ++--
 source/sr/sc/messages.po  |  628 ++--
 source/sv/sc/messages.po  |  627 ++--
 source/ta/sc/messages.po  |  631 ++--
 source/te/sc/messages.po  |  629 ++--
 source/tr/sc/messages.po  |  627 ++--
 source/uk/sc/messages.po  |  627 ++--
 source/vi/sc/messages.po  |  627 ++--
 source/zh-CN/sc/messages.po   |  627 ++--
 source/zh-TW/sc/messages.po   |  627 ++--
 61 files changed, 26131 insertions(+), 16982 deletions(-)

New commits:
commit 2ba607b3f87ba2e877520034f516499fc12a111d
Author: Andras Timar 
AuthorDate: Fri Dec 18 16:20:46 2020 +0100
Commit: Andras Timar 
CommitDate: Fri Dec 18 16:20:46 2020 +0100

Updated translations of AutoFilter, Validation, etc. in Calc

Change-Id: I09bc54be9be157ac86f0ddb2516ef8406cb2e710

diff --git a/source/ar/sc/messages.po b/source/ar/sc/messages.po
index 134e66a304d..6e920cc7a24 100644
--- a/source/ar/sc/messages.po
+++ b/source/ar/sc/messages.po
@@ -3,7 +3,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
 "Report-Msgid-Bugs-To: 
https://bugs.libreoffice.org/enter_bug.cgi?product=LibreOffice&bug_status=UNCONFIRMED&component=UI\n";
-"POT-Creation-Date: 2020-04-29 13:12+0200\n"
+"POT-Creation-Date: 2020-12-18 12:51+0100\n"
 "PO-Revision-Date: 2018-11-12 11:34+\n"
 "Last-Translator: Anonymous Pootle User\n"
 "Language-Team: LANGUAGE \n"
@@ -17467,242 +17467,215 @@ msgctxt "STR_MENU_SORT_CUSTOM"
 msgid "Custom Sort"
 msgstr "فرز مخصص"
 
-#. YeT6Y
-#: sc/inc/strings.hrc:169
-msgctxt "STR_BTN_TOGGLE_ALL"
-msgid "All"
-msgstr "الكل"
-
-#. RqBMw
-#: sc/inc/strings.hrc:170
-#, fuzzy
-msgctxt "STR_BTN_SELECT_CURRENT"
-msgid "Show only the current item."
-msgstr "إظهار العنصر الحالي فقط."
-
-#. VnRK2
-#: sc/inc/strings.hrc:171
-#, fuzzy
-msgctxt "STR_BTN_UNSELECT_CURRENT"
-msgid "Hide only the current item."
-msgstr "إخفاء العنصر الحالي فقط."
-
-#. eWCA7
-#: sc/inc/strings.hrc:172
-#, fuzzy
-msgctxt "STR_EDIT_SEARCH_ITEMS"
-msgid "Search items..."
-msgstr "ابحث عن عناصر..."
-
 #. bpBbA
-#: sc/inc/strings.hrc:174
+#: sc/inc/strings.hrc:170
 msgctxt "SCSTR_QHELP_POSWND"
 msgid "Name Box"
 msgstr "مربع الاسم"
 
 #. GeNTF
-#: sc/inc/strings.hrc:175
+#: sc/inc/strings.hrc:171
 msgctxt "SCSTR_QHELP_INPUTWND"
 msgid "Input line"
 msgstr "سطر اﻹدخال"
 
 #. E6mnF
-#: sc/inc/strings.hrc:176
+#: sc/inc/strings.hrc:172
 msgctxt "SCSTR_QHELP_BTNCALC"
 msgid "Function Wizard"
 msgstr "مرشد الدوال"
 
 #. rU6xA
-#: sc/inc/strings.hrc:177
+#: sc/inc/strings.hrc:173
 ms

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

2020-12-18 Thread Andras Timar (via logerrit)
 translations |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit e2952df6e186e69cf782597e8b1eeb92ba5a70f0
Author: Andras Timar 
AuthorDate: Fri Dec 18 16:21:03 2020 +0100
Commit: Gerrit Code Review 
CommitDate: Fri Dec 18 16:21:03 2020 +0100

Update git submodules

* Update translations from branch 'distro/collabora/cp-6.4'
  to 2ba607b3f87ba2e877520034f516499fc12a111d
  - Updated translations of AutoFilter, Validation, etc. in Calc

Change-Id: I09bc54be9be157ac86f0ddb2516ef8406cb2e710

diff --git a/translations b/translations
index 4418735900f7..2ba607b3f87b 16
--- a/translations
+++ b/translations
@@ -1 +1 @@
-Subproject commit 4418735900f7b96584fb9f2cd247e1ca858266f3
+Subproject commit 2ba607b3f87ba2e877520034f516499fc12a111d
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Henry Castro (via logerrit)
 desktop/source/lib/init.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 51ba81931518e17fe7c00481d7c230621415b728
Author: Henry Castro 
AuthorDate: Thu Oct 15 16:10:31 2020 -0400
Commit: Henry Castro 
CommitDate: Fri Dec 18 16:21:10 2020 +0100

lok: initialize to dispatch ".uno:RunMacro" command

The ".uno:RunMacro" command it is needed for
client side to show the Macro Selector Dialog.

Change-Id: I8f01b9f5cc985119c9215734a6484ed7a0e30080
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107886
Tested-by: Jenkins
Reviewed-by: Henry Castro 

diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index cc2cee9913c0..945f3a2adf7c 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -2821,7 +2821,8 @@ static void doc_iniUnoCommands ()
 OUString(".uno:FreezePanesColumn"),
 OUString(".uno:FreezePanesRow"),
 OUString(".uno:Sidebar"),
-OUString(".uno:SheetRightToLeft")
+OUString(".uno:SheetRightToLeft"),
+OUString(".uno:RunMacro")
 };
 
 util::URL aCommandURL;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Henry Castro (via logerrit)
 include/vcl/toolkit/dialog.hxx |1 +
 vcl/source/window/dialog.cxx   |8 
 2 files changed, 9 insertions(+)

New commits:
commit c266dae3fbea14cdd29e590d9ec8f519813143b3
Author: Henry Castro 
AuthorDate: Fri Dec 4 15:38:35 2020 -0400
Commit: Henry Castro 
CommitDate: Fri Dec 18 16:27:46 2020 +0100

lok: jsbuilder: fix disable dialog tunneling

When a client side issue command to show the Macro Selector Dialog
to the server side, it is not necessary the dialog sends window
invalidate.

I guess the dialog tunneling progressively will be deprecated in
favor of JSDialog, that it will send JSON data to client side,
then it will be constructed to html element using a javascript
dialog builder. (I am wondering why sending JSON?, the server side
can just send the HTML string, and no need for javascript dialog builder).

Change-Id: Ia88f431ed9a860bb9bb30caaaf0f7f889d765115
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107240
Tested-by: Jenkins
Reviewed-by: Henry Castro 

diff --git a/include/vcl/toolkit/dialog.hxx b/include/vcl/toolkit/dialog.hxx
index 922bb8e46164..cbda9ee4b6fc 100644
--- a/include/vcl/toolkit/dialog.hxx
+++ b/include/vcl/toolkit/dialog.hxx
@@ -109,6 +109,7 @@ public:
 virtual voidStateChanged( StateChangedType nStateChange ) override;
 virtual voidDataChanged( const DataChangedEvent& rDCEvt ) override;
 virtual voidCommand( const CommandEvent& rCEvt ) override;
+virtual voidPixelInvalidate(const tools::Rectangle* pRectangle) 
override;
 
 virtual void queue_resize(StateChangedType eReason = 
StateChangedType::Layout) override;
 virtual bool set_property(const OString &rKey, const OUString &rValue) 
override;
diff --git a/vcl/source/window/dialog.cxx b/vcl/source/window/dialog.cxx
index cf240167d588..c3899483b0a4 100644
--- a/vcl/source/window/dialog.cxx
+++ b/vcl/source/window/dialog.cxx
@@ -396,6 +396,14 @@ void Dialog::ImplInitDialogData()
 mpDialogImpl.reset(new DialogImpl);
 }
 
+void Dialog::PixelInvalidate(const tools::Rectangle* pRectangle)
+{
+if (!mpDialogImpl->m_bLOKTunneling)
+return;
+
+Window::PixelInvalidate(pRectangle);
+}
+
 vcl::Window* Dialog::GetDefaultParent(WinBits nStyle)
 {
 vcl::Window* pParent = Application::GetDefDialogParent();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Caolán McNamara (via logerrit)
 editeng/source/editeng/editview.cxx |5 +
 include/editeng/editview.hxx|1 +
 2 files changed, 6 insertions(+)

New commits:
commit 69f1f7f61506131ca203e43b799e7422e98b82a5
Author: Caolán McNamara 
AuthorDate: Fri Dec 18 09:34:48 2020 +
Commit: Caolán McNamara 
CommitDate: Fri Dec 18 16:47:23 2020 +0100

add GetOutputDevice to EditView

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

diff --git a/editeng/source/editeng/editview.cxx 
b/editeng/source/editeng/editview.cxx
index 877c59f1c520..99e3f67730d5 100644
--- a/editeng/source/editeng/editview.cxx
+++ b/editeng/source/editeng/editview.cxx
@@ -348,6 +348,11 @@ vcl::Window* EditView::GetWindow() const
 return pImpEditView->pOutWin;
 }
 
+OutputDevice& EditView::GetOutputDevice() const
+{
+return pImpEditView->GetOutputDevice();
+}
+
 bool EditView::HasOtherViewWindow( vcl::Window* pWin )
 {
 OutWindowSet& rOutWindowSet = pImpEditView->aOutWindowSet;
diff --git a/include/editeng/editview.hxx b/include/editeng/editview.hxx
index 5552e05b1313..7189f40d63ff 100644
--- a/include/editeng/editview.hxx
+++ b/include/editeng/editview.hxx
@@ -166,6 +166,7 @@ public:
 
 voidSetWindow( vcl::Window* pWin );
 vcl::Window*GetWindow() const;
+OutputDevice&   GetOutputDevice() const;
 
 boolHasOtherViewWindow( vcl::Window* pWin );
 boolAddOtherViewWindow( vcl::Window* pWin );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Caolán McNamara (via logerrit)
 sfx2/source/doc/templatedlg.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit cba301460f1aaa1834e72796935cc1e88d74c19b
Author: Caolán McNamara 
AuthorDate: Fri Dec 18 13:16:18 2020 +
Commit: Caolán McNamara 
CommitDate: Fri Dec 18 16:48:46 2020 +0100

Delete Category dialog includes '~' text in the titlebar

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

diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index 313bf591862a..26787f0d2ac9 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -36,6 +36,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 
@@ -1110,7 +,7 @@ void SfxTemplateManagerDlg::OnCategoryDelete()
 SfxTemplateCategoryDialog aDlg(m_xDialog.get());
 aDlg.SetCategoryLBEntries(mxLocalView->getFolderNames());
 aDlg.HideNewCategoryOption();
-aDlg.set_title(SfxResId(STR_CATEGORY_DELETE));
+
aDlg.set_title(MnemonicGenerator::EraseAllMnemonicChars(SfxResId(STR_CATEGORY_DELETE)));
 aDlg.SetSelectLabelText(SfxResId(STR_CATEGORY_SELECT));
 
 if (aDlg.run() == RET_OK)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-1' - cui/source

2020-12-18 Thread Jan-Marek Glogowski (via logerrit)
 cui/source/options/fontsubs.cxx |1 -
 1 file changed, 1 deletion(-)

New commits:
commit ee601c71908dc05fb0f3bd6c4916041d889e96e2
Author: Jan-Marek Glogowski 
AuthorDate: Thu Dec 17 19:30:26 2020 +0100
Commit: Caolán McNamara 
CommitDate: Fri Dec 18 16:49:09 2020 +0100

tdf#138865 don't set ColumnToggleType::Check

We don't want any hidden, magic checkbox for this table, as the
user explicitly has to toggle the desired replacement modes,
which isn't in any way related to a row selection.

Change-Id: I3f9a73d41cc8727aa6380172221ea07068ef74c3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107920
Reviewed-by: Attila Szűcs 
Reviewed-by: László Németh 
Reviewed-by: Jan-Marek Glogowski 
Tested-by: Jenkins
Tested-by: László Németh 
(cherry picked from commit 4cabfc30bf2db873930cef4f7f1b0243ae2fde28)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107908
Reviewed-by: Caolán McNamara 

diff --git a/cui/source/options/fontsubs.cxx b/cui/source/options/fontsubs.cxx
index d94112822f65..4f46e3aa8e53 100644
--- a/cui/source/options/fontsubs.cxx
+++ b/cui/source/options/fontsubs.cxx
@@ -54,7 +54,6 @@ SvxFontSubstTabPage::SvxFontSubstTabPage(weld::Container* 
pPage, weld::DialogCon
 
 m_xCheckLB->set_size_request(m_xCheckLB->get_approximate_digit_width() * 
60,
  m_xCheckLB->get_height_rows(8));
-m_xCheckLB->enable_toggle_buttons(weld::ColumnToggleType::Check);
 m_xCheckLB->set_help_id(HID_OFA_FONT_SUBST_CLB);
 m_xCheckLB->set_selection_mode(SelectionMode::Multiple);
 
___
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.0' - xmlsecurity/qa xmlsecurity/source

2020-12-18 Thread Miklos Vajna (via logerrit)
 xmlsecurity/qa/unit/pdfsigning/data/bad-cert-p3-stamp.pdf |binary
 xmlsecurity/qa/unit/pdfsigning/pdfsigning.cxx |   18 
 xmlsecurity/source/pdfio/pdfdocument.cxx  |   63 --
 3 files changed, 76 insertions(+), 5 deletions(-)

New commits:
commit 4c04745a2deee6590970d5139be958817b8b3591
Author: Miklos Vajna 
AuthorDate: Wed Nov 4 21:39:04 2020 +0100
Commit: Miklos Vajna 
CommitDate: Fri Dec 18 16:52:07 2020 +0100

xmlsecurity: reject a few dangerous annotation types during pdf sig verify

(cherry picked from commit f231dacde9df1c4aa5f4e0970535c4f4093364a7)

Conflicts:
include/vcl/filter/PDFiumLibrary.hxx
xmlsecurity/qa/unit/pdfsigning/pdfsigning.cxx
xmlsecurity/source/helper/pdfsignaturehelper.cxx
xmlsecurity/source/pdfio/pdfdocument.cxx

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

diff --git a/xmlsecurity/qa/unit/pdfsigning/data/bad-cert-p3-stamp.pdf 
b/xmlsecurity/qa/unit/pdfsigning/data/bad-cert-p3-stamp.pdf
new file mode 100644
index ..b30f5b03867c
Binary files /dev/null and 
b/xmlsecurity/qa/unit/pdfsigning/data/bad-cert-p3-stamp.pdf differ
diff --git a/xmlsecurity/qa/unit/pdfsigning/pdfsigning.cxx 
b/xmlsecurity/qa/unit/pdfsigning/pdfsigning.cxx
index 899a7567c4a3..91e565cf2813 100644
--- a/xmlsecurity/qa/unit/pdfsigning/pdfsigning.cxx
+++ b/xmlsecurity/qa/unit/pdfsigning/pdfsigning.cxx
@@ -73,6 +73,7 @@ public:
 void testPartial();
 void testPartialInBetween();
 void testBadCertP1();
+void testBadCertP3Stamp();
 /// Test writing a PAdES signature.
 void testSigningCertificateAttribute();
 /// Test that we accept files which are supposed to be good.
@@ -96,6 +97,7 @@ public:
 CPPUNIT_TEST(testPartial);
 CPPUNIT_TEST(testPartialInBetween);
 CPPUNIT_TEST(testBadCertP1);
+CPPUNIT_TEST(testBadCertP3Stamp);
 CPPUNIT_TEST(testSigningCertificateAttribute);
 CPPUNIT_TEST(testGood);
 CPPUNIT_TEST(testTokenize);
@@ -419,6 +421,22 @@ void PDFSigningTest::testBadCertP1()
  rInformation.nStatus);
 }
 
+void PDFSigningTest::testBadCertP3Stamp()
+{
+std::vector aInfos
+= verify(m_directories.getURLFromSrc(DATA_DIRECTORY) + 
"bad-cert-p3-stamp.pdf", 1,
+ /*rExpectedSubFilter=*/OString());
+CPPUNIT_ASSERT(!aInfos.empty());
+SignatureInformation& rInformation = aInfos[0];
+
+// Without the accompanying fix in place, this test would have failed with:
+// - Expected: 0 (SecurityOperationStatus_UNKNOWN)
+// - Actual  : 1 (SecurityOperationStatus_OPERATION_SUCCEEDED)
+// i.e. adding a stamp annotation was not considered as a bad modification.
+
CPPUNIT_ASSERT_EQUAL(xml::crypto::SecurityOperationStatus::SecurityOperationStatus_UNKNOWN,
+ rInformation.nStatus);
+}
+
 void PDFSigningTest::testSigningCertificateAttribute()
 {
 // Create a new signature.
diff --git a/xmlsecurity/source/pdfio/pdfdocument.cxx 
b/xmlsecurity/source/pdfio/pdfdocument.cxx
index 7b697d6d86eb..160bbee6bcde 100644
--- a/xmlsecurity/source/pdfio/pdfdocument.cxx
+++ b/xmlsecurity/source/pdfio/pdfdocument.cxx
@@ -38,6 +38,11 @@
 #include 
 #include 
 #include 
+#include 
+
+#if HAVE_FEATURE_PDFIUM
+#include 
+#endif
 
 #ifdef XMLSEC_CRYPTO_NSS
 #include 
@@ -167,8 +172,29 @@ bool IsCompleteSignature(SvStream& rStream, 
vcl::filter::PDFDocument& rDocument,
 return std::find(rAllEOFs.begin(), rAllEOFs.end(), nFileEnd) != 
rAllEOFs.end();
 }
 
+/**
+ * Contains checksums of a PDF page, which is rendered without annotations. It 
also contains
+ * the geometry of a few dangerous annotation types.
+ */
+struct PageChecksum
+{
+BitmapChecksum m_nPageContent;
+std::vector m_aAnnotations;
+bool operator==(const PageChecksum& rChecksum) const;
+};
+
+bool PageChecksum::operator==(const PageChecksum& rChecksum) const
+{
+if (m_nPageContent != rChecksum.m_nPageContent)
+{
+return false;
+}
+
+return m_aAnnotations == rChecksum.m_aAnnotations;
+}
+
 /// Collects the checksum of each page of one version of the PDF.
-void AnalyizeSignatureStream(SvMemoryStream& rStream, 
std::vector& rPageChecksums,
+void AnalyizeSignatureStream(SvMemoryStream& rStream, 
std::vector& rPageChecksums,
  int nMDPPerm)
 {
 #if HAVE_FEATURE_PDFIUM
@@ -185,8 +211,35 @@ void AnalyizeSignatureStream(SvMemoryStream& rStream, 
std::vectorgetChecksum(nMDPPerm);
-rPageChecksums.push_back(nPageChecksum);
+PageChecksum aPageChecksum;
+aPageChecksum.m_nPageContent = pPdfPage->getChecksum(nMDPPerm);
+for (int i = 0; i < FPDFPage_GetAnnotCount(pPdfPage->getPointer()); 
++i)
+{
+FPDF_ANNOTATION pAnnotation = 
FPDFPage_GetAnnot(pPdfPage->getPoint

[Libreoffice-commits] core.git: Branch 'feature/wasm' - 117 commits - accessibility/Library_acc.mk accessibility/source autogen.sh avmedia/source basctl/inc basctl/source bridges/Module_bridges.mk bri

2020-12-18 Thread Jan-Marek Glogowski (via logerrit)
Rebased ref, commits from common ancestor:
commit 49a8faf3fd7980b2b6f12e05bc44a69514918db4
Author: Jan-Marek Glogowski 
AuthorDate: Fri Dec 18 16:44:29 2020 +0100
Commit: Jan-Marek Glogowski 
CommitDate: Fri Dec 18 16:51:03 2020 +0100

Next catchall

Before my rebase, this used to link a ui-previewer "executable".
I have this major problem with the static linkage of the binary,
which now has to list ~150 dependencies.

While it linked withhout any more symbol errors, it (obviously)
won't run, because the LO mainloop can't drive the browser
mainloop.

It currently fails in cairo with pthread detection, which did
somehow work before. Also exception handling isn't yet correctly
supported in the build - I think of providing an emscripten
settings.js instead of adding the info to all external builds.

Change-Id: I757634bb2f819022e537f3f4dd55ddabdc742454

diff --git a/README.wasm b/README.wasm
index 401ad6a345ef..d6180cab09da 100644
--- a/README.wasm
+++ b/README.wasm
@@ -1,3 +1,11 @@
+= Status =
+
+$ make cross-toolset
+$ make vcl.all
+
+> instdir/program/ui-previewer.html
+
+
 = Setup for the LO WASM build (with Qt) =
 
 We're using Qt 5.15 with the officially supported emscripten v1.39.8.
@@ -20,6 +28,50 @@ 
EMSDK_ENV=$HOME/Development/libreoffice/git_emsdk/emsdk_env.sh
 [ -f "$EMSDK_ENV" ] && \. "$EMSDK_ENV" 1>/dev/null 2>&1
 
 
+== Setup Qt ==
+
+https://doc.qt.io/qt-5/wasm.html
+
+I originally build the Qt 5.15 branch, but probably better to build a tag like 
v5.15.2.
+
+./configure -xplatform wasm-emscripten -feature-thread -compile-examples 
-prefix $PWD/qtbase
+make -j module-qtbase module-qtdeclarative
+
+Building with examples will break with some of them, but at that point Qt 
already works.
+
+If you get a configure failure for Qt:
+
+Checking for target architecture... Project ERROR: target architecture 
detection binary not found.
+
+Edit git_emsdk/upstream/emscripten/emcc.py:
+@@ -760,8 +760,8 @@
+ only_object = '-c' in cmd
+ for i in reversed(range(len(cmd) - 1)): # Last -o directive should take 
precedence, if multiple are specified
+   if cmd[i] == '-o':
+-if not only_object:
+-  cmd[i + 1] += '.js'
++#if not only_object:
++#  cmd[i + 1] += '.js'
+ target = cmd[i + 1]
+ break
+ if not target:
+
+The previous suggestion, which was to edit 
qtbase/config.tests/arch/write_info.pri
+- ext = .wasm
++ ext = .js.wasm
+
+produces errors when loading the generated html, because it can't find the 
wasm now.
+
+Current Qt fails to start the demo webserver: 
https://bugreports.qt.io/browse/QTCREATORBUG-24072
+Use: emrun --serve_after_close to run Qt WASM demos
+
+Enabling multi-thread support in Firefox is a bit of work with older versions:
+- https://bugzilla.mozilla.org/show_bug.cgi?id=1477743#c7
+- https://wiki.qt.io/Qt_for_WebAssembly#Multithreading_Support
+- 
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/SharedArrayBuffer
+
+
+
 == Setup LO ==
 
 Currently autogen.sh is patched to use emconfigure. That basically sets 
various environment vars,
@@ -42,6 +94,7 @@ QT5DIR=/dir/of/git_qt5/qtbase
 --disable-gio
 --disable-gstreamer-1-0
 --disable-gtk3
+--disable-ldap
 --disable-lpsolve
 --disable-mariadb-sdbc
 --disable-nss
@@ -66,29 +119,6 @@ QT5DIR=/dir/of/git_qt5/qtbase
 Will also be encoded in configure.ac at some point, some already is.
 
 
-== Setup Qt ==
-
-https://doc.qt.io/qt-5/wasm.html
-
-I originally build the Qt 5.15 branch, but probably better to build a tag like 
v5.15.2.
-
-./configure -xplatform wasm-emscripten -feature-thread -compile-examples 
-prefix $PWD/qtbase
-make -j module-qtbase module-qtdeclarative
-
-Building with examples will break with some of them, but at that point Qt 
already works.
-
-If you get a configure failure for Qt:
-
-Checking for target architecture... Project ERROR: target architecture 
detection binary not found.
-
-Edit qtbase/config.tests/arch/write_info.pri
-- ext = .wasm
-+ ext = .js.wasm
-
-Current Qt fails to start the demo webserver: 
https://bugreports.qt.io/browse/QTCREATORBUG-24072
-Use: emrun --serve_after_close to run Qt WASM demos
-
-
 = Mixed information, links, problems, TODO =
 
 More info on Qt WASM emscripten pthreads: 
https://wiki.qt.io/Qt_for_WebAssembly#Multithreading_Support
@@ -141,6 +171,10 @@ This will be interesting: 
https://emscripten.org/docs/getting_started/FAQ.html#h
 
 This didn't help much yet: https://github.com/emscripten-ports
 
+Emscripten supports standalone WASI binaries: 
https://github.com/emscripten-core/emscripten/wiki/WebAssembly-Standalone
+WASM dynamic dispatch: 
https://fitzgeraldnick.com/2018/04/26/how-does-dynamic-dispatch-work-in-wasm.html
+WASM dlload: 
https://iandouglasscott.com/2019/07/18/experimenting-with-webassembly-dynamic-linking-with-clang/
+
 https://www.qt.io/qt-examples-for-webassembly
 http://qtandeverything.blog

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

2020-12-18 Thread Seth Chaiklin (via logerrit)
 source/text/swriter/main0115.xhp |   18 +-
 1 file changed, 9 insertions(+), 9 deletions(-)

New commits:
commit 0e196f08f250f652ff087de7ab9ca6e0caafcdd7
Author: Seth Chaiklin 
AuthorDate: Fri Dec 18 14:36:48 2020 +0100
Commit: Ilmari Lauhakangas 
CommitDate: Fri Dec 18 18:13:24 2020 +0100

tdf#137084   update and link some command names in Styles menu

  * update command labels
  "Update Style" --> "Update Selected Style"
  "New Style" --> "New Style from Selection"
  + add  to "Load Styles"
  * update to ,,

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

diff --git a/source/text/swriter/main0115.xhp b/source/text/swriter/main0115.xhp
index e10269b54..82a064a18 100644
--- a/source/text/swriter/main0115.xhp
+++ b/source/text/swriter/main0115.xhp
@@ -20,28 +20,28 @@
 
 
 
-Styles
+Styles (menu)
 /text/swriter/main0115.xhp
   
 
 
  
   
-  Styles
+  Styles
   Contains commands to apply, create, edit, update, load, and manage 
styles in a text 
document.
  
- Text styles entries
+ Text styles entries
  The 
entries includes most common paragraph, character and list styles. Click on the 
style to apply.
- You can 
customize the list of styles entries using menu Tools - 
Customize. Because custom styles belongs to the actual document, 
remember to store the customized menu in the document scope.
- Edit Style
+ You can customize the list 
of styles entries using menu Tools - Customize. Because custom 
styles belongs to the actual document, remember to store the customized menu in 
the document scope.
+ Edit Style
  Opens 
the Paragraph Style dialog box of the current paragraph.
- Update Style
+ Update Selected Style
  Update the paragraph style with the direct 
formatting applied to the current paragraph.
- New style
+ New Style from Selection
  Adds 
a paragraph style with the settings of the current selection. You will be 
prompted to enter the style name.
- Load Styles
+ Load Styles
  Import 
styles from another document or template into the current 
document.
-  Manage Styles
+  Manage Styles
   Opens the Styles deck in the sidebar.
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: helpcontent2

2020-12-18 Thread Seth Chaiklin (via logerrit)
 helpcontent2 |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 12357c8f4f592524e2f7db39784e4a5613f733ab
Author: Seth Chaiklin 
AuthorDate: Fri Dec 18 18:13:24 2020 +0100
Commit: Gerrit Code Review 
CommitDate: Fri Dec 18 18:13:24 2020 +0100

Update git submodules

* Update helpcontent2 from branch 'master'
  to 0e196f08f250f652ff087de7ab9ca6e0caafcdd7
  - tdf#137084   update and link some command names in Styles menu

  * update command labels
  "Update Style" --> "Update Selected Style"
  "New Style" --> "New Style from Selection"
  + add  to "Load Styles"
  * update to ,,

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

diff --git a/helpcontent2 b/helpcontent2
index f5ff6097a410..0e196f08f250 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit f5ff6097a41055bb91d73a9c9fa847f03212431c
+Subproject commit 0e196f08f250f652ff087de7ab9ca6e0caafcdd7
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Commits with missing ODF implementer notes

2020-12-18 Thread Christian Lohmaier
Hi *,

bin/check-implementer-notes.py finds the following seven commits that
touch the core/schema/* files, but are not listed in either
https://wiki.documentfoundation.org/Development/ODF_Implementer_Notes/List_of_LibreOffice_ODF_Extensions
or
https://wiki.documentfoundation.org/Development/ODF_Implementer_Notes/List_of_LibreOffice_OpenFormula_Extensions

commit bc9049851fd7e914fd695bcfb3c9a94a19634ce0
Author: Szabolcs Toth 
Date:   Thu Oct 15 16:13:08 2020 +0200

tdf#137627 sw top page border orientation: add ODF

Map between RelOrientation::PAGE_PRINT_AREA_TOP and
loext:vertical-rel="page-content-top".

Follow-up of commit 1c593e1916c9164c7db71da2017cfc26972f8e9f
(tdf#133045 sw: add shape alignment to the top page border).
See also commit 65b7873aab5deec7157328047e869a6385e0a74a
(sw from-bottom relative orientation: add ODF filter).

Change-Id: I9bff7a9507152262dda7d126fa3e7e1bee6a8276
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104554
Tested-by: Jenkins
Tested-by: László Németh 
Reviewed-by: László Németh 
commit a41cf57c1eb4cabe5afc1a45d6fe535dbb935217
Author: Balazs Varga 
Date:   Fri Oct 9 10:20:49 2020 +0200

tdf#134987 convert DOCX to ODT: fix lost charts

Embedded charts of DOCX documents were lost or replaced
by images during conversion to native ODT format,
resulted by bad handling of XEmbedPersist objects in
EmbeddedObjectContainer.

Note: Add missing loext:external-data to ODF 1.3 schema
definition to fix ODF validation error in gerrit.

See commit 2054af83fefb955e20de2b40178a11726525057e
(fdo#72520 : Added property to store external data path in chart)
and commit a49a9dab3168c03a539adc131f2ade03236edb69
(fix one more ODF validation error).

Change-Id: I9edff9af3a79370ea447ffc6078da3520d0c6f63
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104104
Tested-by: László Németh 
Reviewed-by: László Németh 
commit e2f4e65a7b8024c00b049eebf0d87637efda7f24
Author: Balazs Varga 
Date:   Thu Aug 27 11:21:48 2020 +0200

tdf#134571 chart2, xmloff: add loext:custom-leader-lines

new ODF chart series style attribute for saving not default
(switched off) state of data labels in custom positions.

Note: import of the embedded chart of the DOCX unit test
document uses also ODF format in the background, testing
also this loext attribute, i.e. the chart of the unit test
document doesn't contain custom leader lines.

Change-Id: Ia6b76e8d7fe5b6b6204761f3bbc2309f1b631008
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101442
Tested-by: László Németh 
Reviewed-by: László Németh 
commit 8750cbc7f609c5de77796b179425469dbdcfdcb5
Author: Andrea Gelmini 
Date:   Sat Aug 22 23:04:45 2020 +0200

Fix typo in code

Change-Id: I22e37a583f673d0bd02c74a6b05c0a0e25ed3722
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101215
Tested-by: Jenkins
Reviewed-by: Noel Grandin 
commit ee9cb297c583cb5a2e6ed388af31fffc79f282ca
Author: Michael Stahl 
Date:   Wed Aug 5 17:15:52 2020 +0200

schema: add fieldmarks to LO schema

Change-Id: I4ff445a9cf70a3a918d9a47f9bf615167f85958b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100180
Tested-by: Jenkins
Reviewed-by: Xisco Fauli 
Reviewed-by: Michael Stahl 
commit 1c080b887c1ef28cb2e98173d0121bcae3167075
Author: Jim Raykowski 
Date:   Mon Jul 27 21:34:57 2020 -0800

tdf#38093 Writer outline folding - persistence

Patch 6/6 that breaks down https://gerrit.libreoffice.org/c/core/+/96672

Adds persistence attribute loext:outline-content-visible

Change-Id: Ide30f127a05def4d4f493bb4b469e0877b00
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99657
Tested-by: Jenkins
Reviewed-by: Mike Kaganski 
commit 2803b09ec024cb0b8cf25ec6fe08412649f40d5e
Author: A_GAN 
Date:   Mon Jun 22 23:39:16 2020 +0200

OOXML/ODF Support for Shadow blur radius

Adding export support for OOXML. Adding import/export support for ODF
Changing some values in test cases as convertEMUtoHmm round the fraction.
Add two test functions for OOXML and ODF export.

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

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


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

2020-12-18 Thread Henry Castro (via logerrit)
 vcl/source/window/builder.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 9a4266fa95af71903e1e1db6874af82958315d6d
Author: Henry Castro 
AuthorDate: Fri Dec 4 16:32:30 2020 -0400
Commit: Henry Castro 
CommitDate: Fri Dec 18 18:19:34 2020 +0100

lok: use JSDialog Builder to create a Macro Selector Dialog

The Macro Selector Dialog should be created for desktop too.
The JS Builder has an implementation to send "jsdialog: "
data to the client side.

Change-Id: If29660467e494323ac26605e704ee9bf15725fd5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107243
Tested-by: Jenkins
Reviewed-by: Henry Castro 

diff --git a/vcl/source/window/builder.cxx b/vcl/source/window/builder.cxx
index 2e46a942cd4b..03a79f0eca8b 100644
--- a/vcl/source/window/builder.cxx
+++ b/vcl/source/window/builder.cxx
@@ -190,7 +190,8 @@ weld::Builder* Application::CreateBuilder(weld::Widget* 
pParent, const OUString
 if (rUIFile == "modules/scalc/ui/pivottablelayoutdialog.ui"
 || rUIFile == "modules/scalc/ui/selectsource.ui"
 || rUIFile == "modules/scalc/ui/managenamesdialog.ui"
-|| rUIFile == "modules/scalc/ui/definename.ui")
+|| rUIFile == "modules/scalc/ui/definename.ui"
+|| rUIFile == "cui/ui/macroselectordialog.ui")
 {
 bUseJSBuilder = true;
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Henry Castro (via logerrit)
 vcl/jsdialog/jsdialogbuilder.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 40588ede2070e5b01ad4d2c71894bd19d6ec9738
Author: Henry Castro 
AuthorDate: Fri Dec 4 16:49:31 2020 -0400
Commit: Henry Castro 
CommitDate: Fri Dec 18 18:20:18 2020 +0100

lok: jsbuilder: avoid sending early id to client side

In the case of Macro Selector Dialog it is not required
to send the id too early when the dialog is created and
it is not initialized yet.

Change-Id: I22fb05bd9ecff49b3e9eda19737750379a61dd69
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107244
Tested-by: Jenkins
Reviewed-by: Henry Castro 

diff --git a/vcl/jsdialog/jsdialogbuilder.cxx b/vcl/jsdialog/jsdialogbuilder.cxx
index 08e66eedb6f5..e4dd0f4a8b96 100644
--- a/vcl/jsdialog/jsdialogbuilder.cxx
+++ b/vcl/jsdialog/jsdialogbuilder.cxx
@@ -404,7 +404,7 @@ std::unique_ptr 
JSInstanceBuilder::weld_dialog(const OString& id)
 RememberWidget("__DIALOG__", pRet.get());
 
 const vcl::ILibreOfficeKitNotifier* pNotifier = pDialog->GetLOKNotifier();
-if (pNotifier)
+if (pNotifier && id != "MacroSelectorDialog")
 {
 tools::JsonWriter aJsonWriter;
 m_aOwnedToplevel->DumpAsPropertyTree(aJsonWriter);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Henry Castro (via logerrit)
 vcl/jsdialog/jsdialogbuilder.cxx |   34 ++
 1 file changed, 18 insertions(+), 16 deletions(-)

New commits:
commit ca839b341883c1238f27ba42236f08ebb49d53a4
Author: Henry Castro 
AuthorDate: Fri Dec 4 17:00:51 2020 -0400
Commit: Henry Castro 
CommitDate: Fri Dec 18 18:20:56 2020 +0100

lok: jsdialog: fix possible nullptr dereference

p = nullptr;

if (p)
{
}

p->Somenthing();

Change-Id: I2a46d6a8e7eae96928210c8941ec71eed88bf631
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107245
Tested-by: Jenkins
Reviewed-by: Henry Castro 

diff --git a/vcl/jsdialog/jsdialogbuilder.cxx b/vcl/jsdialog/jsdialogbuilder.cxx
index e4dd0f4a8b96..795acc644274 100644
--- a/vcl/jsdialog/jsdialogbuilder.cxx
+++ b/vcl/jsdialog/jsdialogbuilder.cxx
@@ -383,33 +383,35 @@ VclPtr& 
JSInstanceBuilder::GetNotifierWindow()
 
 std::unique_ptr JSInstanceBuilder::weld_dialog(const OString& id)
 {
+std::unique_ptr pRet;
 ::Dialog* pDialog = m_xBuilder->get<::Dialog>(id);
-m_nWindowId = pDialog->GetLOKWindowId();
-pDialog->SetLOKTunnelingState(false);
-
-InsertWindowToMap(m_nWindowId);
 
 if (pDialog)
 {
+m_nWindowId = pDialog->GetLOKWindowId();
+pDialog->SetLOKTunnelingState(false);
+
+InsertWindowToMap(m_nWindowId);
+
 assert(!m_aOwnedToplevel && "only one toplevel per .ui allowed");
 m_aOwnedToplevel.set(pDialog);
 m_xBuilder->drop_ownership(pDialog);
 m_bHasTopLevelDialog = true;
-}
 
-std::unique_ptr pRet(pDialog ? new 
JSDialog(m_aOwnedToplevel, m_aOwnedToplevel,
-  pDialog, this, 
false, m_sTypeOfJSON)
-   : nullptr);
+pRet.reset(pDialog ? new JSDialog(m_aOwnedToplevel, m_aOwnedToplevel, 
pDialog, this, false,
+  m_sTypeOfJSON)
+   : nullptr);
 
-RememberWidget("__DIALOG__", pRet.get());
+RememberWidget("__DIALOG__", pRet.get());
 
-const vcl::ILibreOfficeKitNotifier* pNotifier = pDialog->GetLOKNotifier();
-if (pNotifier && id != "MacroSelectorDialog")
-{
-tools::JsonWriter aJsonWriter;
-m_aOwnedToplevel->DumpAsPropertyTree(aJsonWriter);
-aJsonWriter.put("id", m_aOwnedToplevel->GetLOKWindowId());
-pNotifier->libreOfficeKitViewCallback(LOK_CALLBACK_JSDIALOG, 
aJsonWriter.extractData());
+const vcl::ILibreOfficeKitNotifier* pNotifier = 
pDialog->GetLOKNotifier();
+if (pNotifier && id != "MacroSelectorDialog")
+{
+tools::JsonWriter aJsonWriter;
+m_aOwnedToplevel->DumpAsPropertyTree(aJsonWriter);
+aJsonWriter.put("id", m_aOwnedToplevel->GetLOKWindowId());
+pNotifier->libreOfficeKitViewCallback(LOK_CALLBACK_JSDIALOG, 
aJsonWriter.extractData());
+}
 }
 
 return pRet;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Henry Castro (via logerrit)
 cui/source/customize/cfgutil.cxx |1 +
 cui/source/factory/dlgfact.cxx   |7 ++-
 cui/source/factory/dlgfact.hxx   |5 +++--
 sfx2/source/appl/appserv.cxx |   39 ++-
 4 files changed, 32 insertions(+), 20 deletions(-)

New commits:
commit 4ea3ec3d3aaa304b9769c2d5c7556529cc4df9ff
Author: Henry Castro 
AuthorDate: Fri Dec 4 17:34:48 2020 -0400
Commit: Henry Castro 
CommitDate: Fri Dec 18 18:21:37 2020 +0100

lok: run async the Macro Selector Dialog

Required to be called by the client side

Change-Id: I9c9d22dd249839009bdc6a701553f3b9d776347a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107246
Tested-by: Jenkins
Reviewed-by: Henry Castro 

diff --git a/cui/source/customize/cfgutil.cxx b/cui/source/customize/cfgutil.cxx
index 778e2940ba1d..f694f26fd6bc 100644
--- a/cui/source/customize/cfgutil.cxx
+++ b/cui/source/customize/cfgutil.cxx
@@ -42,6 +42,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
diff --git a/cui/source/factory/dlgfact.cxx b/cui/source/factory/dlgfact.cxx
index e43b027602c4..d10914440db5 100644
--- a/cui/source/factory/dlgfact.cxx
+++ b/cui/source/factory/dlgfact.cxx
@@ -145,6 +145,11 @@ short AbstractTitleDialog_Impl::Execute()
 return m_xDlg->run();
 }
 
+bool AbstractScriptSelectorDialog_Impl::StartExecuteAsync(AsyncContext &rCtx)
+{
+return SfxDialogController::runAsync(m_xDlg, rCtx.maEndDialogFn);
+}
+
 short AbstractScriptSelectorDialog_Impl::Execute()
 {
 return m_xDlg->run();
@@ -1113,7 +1118,7 @@ void 
AbstractDialogFactory_Impl::ShowAsyncScriptErrorDialog(weld::Window* pParen
 VclPtr 
AbstractDialogFactory_Impl::CreateScriptSelectorDialog(weld::Window* pParent,
 const Reference& rxFrame)
 {
-return 
VclPtr::Create(std::make_unique(pParent,
 rxFrame));
+return 
VclPtr::Create(std::make_shared(pParent,
 rxFrame));
 }
 
 OUString AbstractScriptSelectorDialog_Impl::GetScriptURL() const
diff --git a/cui/source/factory/dlgfact.hxx b/cui/source/factory/dlgfact.hxx
index a9d521708f5d..87ad9730b307 100644
--- a/cui/source/factory/dlgfact.hxx
+++ b/cui/source/factory/dlgfact.hxx
@@ -283,13 +283,14 @@ public:
 class SvxScriptSelectorDialog;
 class AbstractScriptSelectorDialog_Impl : public AbstractScriptSelectorDialog
 {
-std::unique_ptr m_xDlg;
+std::shared_ptr m_xDlg;
 public:
-explicit 
AbstractScriptSelectorDialog_Impl(std::unique_ptr p)
+explicit 
AbstractScriptSelectorDialog_Impl(std::shared_ptr p)
 : m_xDlg(std::move(p))
 {
 }
 virtual short Execute() override;
+virtual bool StartExecuteAsync(AsyncContext &rCtx) override;
 virtual OUString GetScriptURL() const override;
 virtual void SetRunLabel() override;
 };
diff --git a/sfx2/source/appl/appserv.cxx b/sfx2/source/appl/appserv.cxx
index ab441f70b7f5..7452faff296a 100644
--- a/sfx2/source/appl/appserv.cxx
+++ b/sfx2/source/appl/appserv.cxx
@@ -1453,32 +1453,37 @@ void SfxApplication::OfaExec_Impl( SfxRequest& rReq )
 
 do  // artificial loop for flow control
 {
-ScopedVclPtr 
pDlg(pFact->CreateScriptSelectorDialog(lcl_getDialogParent(xFrame), xFrame));
+VclPtr 
pDlg(pFact->CreateScriptSelectorDialog(lcl_getDialogParent(xFrame), xFrame));
 OSL_ENSURE( pDlg, "SfxApplication::OfaExec_Impl( SID_RUNMACRO 
): no dialog!" );
 if ( !pDlg )
 break;
 pDlg->SetRunLabel();
 
-short nDialogResult = pDlg->Execute();
-if ( !nDialogResult )
-break;
+pDlg->StartExecuteAsync([pDlg, xFrame](sal_Int32 
nDialogResult) {
+if ( !nDialogResult )
+{
+pDlg->disposeOnce();
+return;
+}
 
-Sequence< Any > args;
-Sequence< sal_Int16 > outIndex;
-Sequence< Any > outArgs;
-Any ret;
+Sequence< Any > args;
+Sequence< sal_Int16 > outIndex;
+Sequence< Any > outArgs;
+Any ret;
 
-Reference< XInterface > xScriptContext;
+Reference< XInterface > xScriptContext;
 
-Reference< XController > xController;
-if ( xFrame.is() )
-xController = xFrame->getController();
-if ( xController.is() )
-xScriptContext = xController->getModel();
-if ( !xScriptContext.is() )
-xScriptContext = xController;
+Reference< XController > xController;
+if ( xFrame.is() )
+xController = xFrame->getController();
+if ( xController.is() )
+xScriptContext = xController->getModel();
+  

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

2020-12-18 Thread Henry Castro (via logerrit)
 vcl/source/treelist/svtabbx.cxx |   13 +
 1 file changed, 13 insertions(+)

New commits:
commit 00f587ecfe06274bf71356c913145a2e7847e763
Author: Henry Castro 
AuthorDate: Thu Dec 10 13:42:25 2020 -0400
Commit: Henry Castro 
CommitDate: Fri Dec 18 18:22:40 2020 +0100

lok: add "ondemand" property to dump the TreeView property

The "SalInstanceTreeView" instance does not use the flag
"CHILDREN_ON_DEMAND", but instead it creates a "" child.

However the client side requires "on demand" information to
request and trigger the "On Expanding" event.

Change-Id: I4d8667fc83dae2c5f1d477fefa9c9917a5e6c90d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107576
Tested-by: Jenkins
Reviewed-by: Henry Castro 

diff --git a/vcl/source/treelist/svtabbx.cxx b/vcl/source/treelist/svtabbx.cxx
index 816acb66a46c..613d1831bf2b 100644
--- a/vcl/source/treelist/svtabbx.cxx
+++ b/vcl/source/treelist/svtabbx.cxx
@@ -73,6 +73,19 @@ static void lcl_DumpEntryAndSiblings(tools::JsonWriter& 
rJsonWriter,
 }
 }
 
+// SalInstanceTreeView does not use the flag CHILDREN_ON_DEMAND
+// and it creates a dummy child
+const SvTreeListEntries& rChildren = pEntry->GetChildEntries();
+if (rChildren.size() == 1)
+{
+auto& rChild = rChildren[0];
+if (const SvLBoxItem* pChild = 
rChild->GetFirstItem(SvLBoxItemType::String))
+{
+if (static_cast(pChild)->GetText() == 
"")
+rJsonWriter.put("ondemand", "true");
+}
+}
+
 if (bCheckButtons)
 {
 SvButtonState eCheckState = 
pTabListBox->GetCheckButtonState(pEntry);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Henry Castro (via logerrit)
 desktop/source/lib/init.cxx |5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

New commits:
commit fb45e5c52836cdf045da1e66c168a2dfd55b9e90
Author: Henry Castro 
AuthorDate: Thu Dec 17 10:16:52 2020 -0400
Commit: Henry Castro 
CommitDate: Fri Dec 18 18:23:13 2020 +0100

lok: add parameter "MacroExecMode"

It is required to execute VBA scripts.

Change-Id: Ibaafc62ecedcefcd0596c701728039783b5a0de7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107891
Tested-by: Jenkins
Reviewed-by: Henry Castro 

diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index 945f3a2adf7c..2b87faecc677 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -62,6 +62,7 @@
 #include 
 #include 
 
+#include 
 #include 
 #include 
 #include 
@@ -2232,7 +2233,7 @@ static LibreOfficeKitDocument* 
lo_documentLoadWithOptions(LibreOfficeKit* pThis,
 const OUString aDeviceFormFactor = extractParameter(aOptions, 
"DeviceFormFactor");
 SfxLokHelper::setDeviceFormFactor(aDeviceFormFactor);
 
-uno::Sequence aFilterOptions(2);
+uno::Sequence aFilterOptions(3);
 aFilterOptions[0] = css::beans::PropertyValue( "FilterOptions",
0,
uno::makeAny(aOptions),
@@ -2251,11 +2252,11 @@ static LibreOfficeKitDocument* 
lo_documentLoadWithOptions(LibreOfficeKit* pThis,
 aFilterOptions[1].Name = "InteractionHandler";
 aFilterOptions[1].Value <<= xInteraction;
 
-/* TODO
 sal_Int16 nMacroExecMode = document::MacroExecMode::USE_CONFIG;
 aFilterOptions[2].Name = "MacroExecutionMode";
 aFilterOptions[2].Value <<= nMacroExecMode;
 
+/* TODO
 sal_Int16 nUpdateDoc = document::UpdateDocMode::ACCORDING_TO_CONFIG;
 aFilterOptions[3].Name = "UpdateDocMode";
 aFilterOptions[3].Value <<= nUpdateDoc;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Henry Castro (via logerrit)
 include/vcl/toolkit/treelist.hxx|6 ++
 vcl/source/treelist/treelist.cxx|8 
 vcl/source/treelist/treelistbox.cxx |1 +
 3 files changed, 15 insertions(+)

New commits:
commit bf253b234e37f69c030cc531343f26d416224297
Author: Henry Castro 
AuthorDate: Thu Dec 17 10:33:19 2020 -0400
Commit: Henry Castro 
CommitDate: Fri Dec 18 18:23:54 2020 +0100

lok: check if the tree list box model has changed

It is necessary to know when the tree list model
has changed to notify client side changes.

Change-Id: I188a97223e06520d0b34cd9272eff6449a14d60e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107892
Tested-by: Jenkins
Reviewed-by: Henry Castro 

diff --git a/include/vcl/toolkit/treelist.hxx b/include/vcl/toolkit/treelist.hxx
index 09ed5da01df2..dbab485fde61 100644
--- a/include/vcl/toolkit/treelist.hxx
+++ b/include/vcl/toolkit/treelist.hxx
@@ -209,6 +209,7 @@ class VCL_DLLPUBLIC SvListView
 std::unique_ptr m_pImpl;
 
 protected:
+boolm_bDirtyModel;
 std::unique_ptr pModel;
 
 voidExpandListEntry( SvTreeListEntry* pParent );
@@ -227,6 +228,11 @@ public:
 sal_uLong nPos
 );
 
+boolIsDirtyModel() const
+{ return m_bDirtyModel; }
+voidSetDirtyModel(bool bValue)
+{ m_bDirtyModel = bValue; }
+
 sal_uLong   GetVisibleCount() const
 { return pModel->GetVisibleCount( const_cast(this) ); }
 
diff --git a/vcl/source/treelist/treelist.cxx b/vcl/source/treelist/treelist.cxx
index e314329c10b8..1e4759ee6c85 100644
--- a/vcl/source/treelist/treelist.cxx
+++ b/vcl/source/treelist/treelist.cxx
@@ -1032,6 +1032,7 @@ SvListView::SvListView()
 {
 pModel.reset(new SvTreeList(*this));
 m_pImpl->InitTable();
+m_bDirtyModel = false;
 }
 
 void SvListView::dispose()
@@ -1248,15 +1249,18 @@ void SvListView::Impl::ActionClear()
 void SvListView::ModelNotification( SvListAction nActionId, SvTreeListEntry* 
pEntry1,
 SvTreeListEntry* /*pEntry2*/, sal_uLong /*nPos*/ )
 {
+
 switch( nActionId )
 {
 case SvListAction::INSERTED:
 m_pImpl->ActionInserted( pEntry1 );
 ModelHasInserted( pEntry1 );
+m_bDirtyModel = true;
 break;
 case SvListAction::INSERTED_TREE:
 m_pImpl->ActionInsertedTree( pEntry1 );
 ModelHasInsertedTree( pEntry1 );
+m_bDirtyModel = true;
 break;
 case SvListAction::REMOVING:
 ModelIsRemoving( pEntry1 );
@@ -1264,6 +1268,7 @@ void SvListView::ModelNotification( SvListAction 
nActionId, SvTreeListEntry* pEn
 break;
 case SvListAction::REMOVED:
 ModelHasRemoved( pEntry1 );
+m_bDirtyModel = true;
 break;
 case SvListAction::MOVING:
 ModelIsMoving( pEntry1 );
@@ -1272,12 +1277,14 @@ void SvListView::ModelNotification( SvListAction 
nActionId, SvTreeListEntry* pEn
 case SvListAction::MOVED:
 m_pImpl->ActionMoved();
 ModelHasMoved( pEntry1 );
+m_bDirtyModel = true;
 break;
 case SvListAction::CLEARING:
 m_pImpl->ActionClear();
 ModelHasCleared(); // sic! for compatibility reasons!
 break;
 case SvListAction::CLEARED:
+m_bDirtyModel = true;
 break;
 case SvListAction::INVALIDATE_ENTRY:
 // no action for the base class
@@ -1285,6 +1292,7 @@ void SvListView::ModelNotification( SvListAction 
nActionId, SvTreeListEntry* pEn
 break;
 case SvListAction::RESORTED:
 m_pImpl->m_bVisPositionsValid = false;
+m_bDirtyModel = true;
 break;
 case SvListAction::RESORTING:
 break;
diff --git a/vcl/source/treelist/treelistbox.cxx 
b/vcl/source/treelist/treelistbox.cxx
index bbafb2a4ba95..6a305b8d98ef 100644
--- a/vcl/source/treelist/treelistbox.cxx
+++ b/vcl/source/treelist/treelistbox.cxx
@@ -417,6 +417,7 @@ SvTreeListBox::SvTreeListBox(vcl::Window* pParent, WinBits 
nWinStyle) :
 pImpl->SetModel( pModel.get() );
 
 SetSublistOpenWithLeftRight();
+m_bDirtyModel = false;
 }
 
 void SvTreeListBox::Clear()
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Tor Lillqvist (via logerrit)
 vcl/inc/quartz/salgdi.h |1 -
 1 file changed, 1 deletion(-)

New commits:
commit 94e8de1652370ec7d3a09a76b082ba7c77f1b278
Author: Tor Lillqvist 
AuthorDate: Fri Dec 18 13:39:56 2020 +0200
Commit: Tor Lillqvist 
CommitDate: Fri Dec 18 18:51:04 2020 +0100

Bin unnecessary forward declaration

Change-Id: I351635064b73145975b421879450f3e8ee64e983
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107963
Tested-by: Jenkins
Reviewed-by: Tor Lillqvist 

diff --git a/vcl/inc/quartz/salgdi.h b/vcl/inc/quartz/salgdi.h
index d718cf788dcc..db47dac517a1 100644
--- a/vcl/inc/quartz/salgdi.h
+++ b/vcl/inc/quartz/salgdi.h
@@ -53,7 +53,6 @@
 
 class AquaSalFrame;
 class FontAttributes;
-class CoreTextStyle;
 class XorEmulation;
 
 // CoreText-specific physically available font face
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-7-1' - connectivity/source

2020-12-18 Thread Lionel Elie Mamane (via logerrit)
 connectivity/source/drivers/postgresql/pq_baseresultset.cxx   |2 +-
 connectivity/source/drivers/postgresql/pq_connection.cxx  |3 ++-
 connectivity/source/drivers/postgresql/pq_preparedstatement.cxx   |2 +-
 connectivity/source/drivers/postgresql/pq_tools.hxx   |8 

 connectivity/source/drivers/postgresql/pq_updateableresultset.cxx |2 +-
 5 files changed, 13 insertions(+), 4 deletions(-)

New commits:
commit 1ab014ddf72dd09b2ef30320b8b2936a26923b3a
Author: Lionel Elie Mamane 
AuthorDate: Tue Nov 17 02:14:15 2020 +0100
Commit: Michael Stahl 
CommitDate: Fri Dec 18 18:56:32 2020 +0100

pgsql-sdbc: use libpq's custom free()...

... for stuff allocated by libpq

Their documentation says this is important on Microsoft Windows:

 It is particularly important that this function, rather than free(),
 be used on Microsoft Windows. This is because allocating memory in a
 DLL and releasing it in the application works only if
 multithreaded/single-threaded, release/debug, and static/dynamic
 flags are the same for the DLL and the application.

Also use const unique_ptr since we don't need the value to survive the
scope in any way.

Change-Id: If4637ea0cd1c05125d63e2f3d37dbeaf716973f9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105967
Tested-by: Lionel Mamane 
Reviewed-by: Lionel Mamane 
(cherry picked from commit 177792660697f85763b39f455d7ebff0f83084fd)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107906
Tested-by: Jenkins
Reviewed-by: Michael Stahl 

diff --git a/connectivity/source/drivers/postgresql/pq_baseresultset.cxx 
b/connectivity/source/drivers/postgresql/pq_baseresultset.cxx
index 8fc7140e4817..9ff5e01e098a 100644
--- a/connectivity/source/drivers/postgresql/pq_baseresultset.cxx
+++ b/connectivity/source/drivers/postgresql/pq_baseresultset.cxx
@@ -456,7 +456,7 @@ Sequence< sal_Int8 > BaseResultSet::getBytes( sal_Int32 
columnIndex )
 char * res = reinterpret_cast(PQunescapeBytea( 
reinterpret_cast(val.getStr()), &length));
 ret = Sequence< sal_Int8 > ( reinterpret_cast(res), length 
);
 if( res )
-free( res );
+PQfreemem( res );
 }
 return ret;
 }
diff --git a/connectivity/source/drivers/postgresql/pq_connection.cxx 
b/connectivity/source/drivers/postgresql/pq_connection.cxx
index d9889dea8091..ed3ed85e9c6c 100644
--- a/connectivity/source/drivers/postgresql/pq_connection.cxx
+++ b/connectivity/source/drivers/postgresql/pq_connection.cxx
@@ -41,6 +41,7 @@
 
 #include "pq_connection.hxx"
 #include "pq_statement.hxx"
+#include "pq_tools.hxx"
 #include "pq_preparedstatement.hxx"
 #include "pq_databasemetadata.hxx"
 #include "pq_xtables.hxx"
@@ -460,7 +461,7 @@ void Connection::initialize( const Sequence< Any >& 
aArguments )
 if ( err != nullptr)
 {
 errorMessage = OUString( err, strlen(err), 
ConnectionSettings::encoding );
-free(err);
+PQfreemem(err);
 }
 else
 errorMessage = "#no error message#";
diff --git a/connectivity/source/drivers/postgresql/pq_preparedstatement.cxx 
b/connectivity/source/drivers/postgresql/pq_preparedstatement.cxx
index c1d9a4f66731..344c27175850 100644
--- a/connectivity/source/drivers/postgresql/pq_preparedstatement.cxx
+++ b/connectivity/source/drivers/postgresql/pq_preparedstatement.cxx
@@ -481,7 +481,7 @@ void PreparedStatement::setBytes(
 checkClosed();
 checkColumnIndex( parameterIndex );
 size_t len;
-std::unique_ptr escapedString(
+const std::unique_ptr> 
escapedString(
 PQescapeBytea( reinterpret_cast(x.getConstArray()), x.getLength(), &len));
 if( ! escapedString )
 {
diff --git a/connectivity/source/drivers/postgresql/pq_tools.hxx 
b/connectivity/source/drivers/postgresql/pq_tools.hxx
index af751f8e633b..7fbdb260d30b 100644
--- a/connectivity/source/drivers/postgresql/pq_tools.hxx
+++ b/connectivity/source/drivers/postgresql/pq_tools.hxx
@@ -49,6 +49,14 @@
 #include "pq_connection.hxx"
 #include 
 
+namespace
+{
+// helper to create one-time deleters
+template 
+using deleter_from_fn = std::integral_constant;
+
+}
+
 namespace pq_sdbc_driver
 {
 bool isWhitespace( sal_Unicode c );
diff --git a/connectivity/source/drivers/postgresql/pq_updateableresultset.cxx 
b/connectivity/source/drivers/postgresql/pq_updateableresultset.cxx
index 880adc647c7e..d8780e76c563 100644
--- a/connectivity/source/drivers/postgresql/pq_updateableresultset.cxx
+++ b/connectivity/source/drivers/postgresql/pq_updateableresultset.cxx
@@ -481,7 +481,7 @@ void UpdateableResultSet::updateBytes( sal_Int32 
columnIndex, const css::uno::Se
 
 m_updateableField[columnIndex-1].value <<=
 OUString( reinterpret_cast(escapedString), len, 
RTL_TEXTENCODING_ASCII_US );
-free( escapedString );
+

[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.0-29' - .gitreview

2020-12-18 Thread Miklos Vajna (via logerrit)
 .gitreview |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 4243fd4db9babb6e6a51e34bb6166981345a0aea
Author: Miklos Vajna 
AuthorDate: Fri Dec 18 17:30:13 2020 +0100
Commit: Miklos Vajna 
CommitDate: Fri Dec 18 19:09:58 2020 +0100

Update gitreview for this branch

Change-Id: Ic024316bc377c392260b04aae65c2ce5cbb86612
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107972
Tested-by: Miklos Vajna 
Reviewed-by: Miklos Vajna 

diff --git a/.gitreview b/.gitreview
index 46c9ae9716d3..6eaab8cf0459 100644
--- a/.gitreview
+++ b/.gitreview
@@ -3,5 +3,5 @@ host=logerrit
 port=29418
 project=core
 defaultremote=logerrit
-defaultbranch=distro/collabora/cp-6.0
+defaultbranch=distro/collabora/cp-6.0-29
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Initial work on a LibreOffice WASM port (and more)

2020-12-18 Thread Jan-Marek Glogowski

Hi everyone,

since a few days the core repo has a new branch named feature/wasm. That 
project was announced during the LibreOffice conference, but at that 
point everything was still in some setup stage. There is a recording of 
that talk available at 
https://events.opensuse.org/conferences/oSLO/program/proposals/3232 / 
https://www.youtube.com/watch?v=EycRK5gMpeU


This is a project done by Thorsten Behrens, Armin Le Grand and myself, 
sponsored by NLnet (see https://nlnet.nl/project/LibreOfficeP2P/).


I remember there was some fat client collaboration discussion a few days 
back on this list, so that is the general plan. But while it'll be a fat 
client, the primary work is probably to get LO to run in your browser 
(or WASI runtime eventually). Sponsorship is limited and every dev knows 
enough of our codebase, so you can imagine the amount of work involved.


WASM is already a few years "old", but … let's say the platform has it's 
problems and is in very active development, especially looking into 
threading, atomics and exception handling w.r.t. SharedBuffer and 
Security (remember Spectre?).


The main info of the branch is README.wasm. The idea is to initially 
have something VCL based running in the browser using Qt5, eventually 
developing something "VCL-native". Two days ago I was able to link the 
ui-previewer without missing symbols, which basically is "make vcl.all", 
but after a rebase and make clean there are new build failures, probably 
because I fixed other stuff in the meantime :-) I'm still learning new 
stuff (and bugs) daily.


I'm currently working on this on my own, laying the foundations. So no 
bugzilla bug reports yet please ;-) But I'm happy about everyone trying 
to get the build running based on the README.wasm. Thorsten plans to 
setup some LO CI in the next days, so we can actually get stuff easier 
tested in the long run.


And the current target is "just" Writer. We hope to replace some of the 
graphics stack with some "native" HTML5 canvas code in mid term. If 
stuff works out as expected, we might have something VCL based really 
working for FOSDEM 2021 (not full collaboration, but VCL and browser and 
eventually more).


Thanks for reading. Any questions?

Jan-Marek (for the WASM port team ;-)

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


Update for Occitan dictionary

2020-12-18 Thread Quentin PAGÈS

Hello, 
I'm writing this mail to ask for a review of my Pull Request located here: 
https://github.com/LibreOffice/dictionaries/pull/30 
It includes an update of the Occitan dictionary. 
I have got these files from Bruno Gallart, known to contribute at LibreOffice. 

Best regards 


Quentin PAGÈS 
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: Branch 'libreoffice-7-1' - solenv/gbuild

2020-12-18 Thread Mike Kaganski (via logerrit)
 solenv/gbuild/platform/filter-showIncludes.awk |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 384ec11a85ea57579a772e9dffd3c3b721a78ecd
Author: Mike Kaganski 
AuthorDate: Thu Dec 17 15:17:01 2020 +0300
Commit: Michael Stahl 
CommitDate: Fri Dec 18 20:19:54 2020 +0100

include everything from BUILDDIR, e.g. config_host/*

... otherwise any change in config that modifies those does not trigger
related units to be rebuilt

Change-Id: I680fc1e004208f7ccc752186d5e765560dffebf9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107875
Tested-by: Jenkins
Reviewed-by: Mike Kaganski 
(cherry picked from commit 6a1555d2011032100dc0f37bb2298f3c555d3b45)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107912
Reviewed-by: Michael Stahl 

diff --git a/solenv/gbuild/platform/filter-showIncludes.awk 
b/solenv/gbuild/platform/filter-showIncludes.awk
index 7803e376c9ed..9f5cabd1085b 100755
--- a/solenv/gbuild/platform/filter-showIncludes.awk
+++ b/solenv/gbuild/platform/filter-showIncludes.awk
@@ -35,7 +35,7 @@ BEGIN {
 # to match especially drive letters in allowlist case insensitive
 IGNORECASE = 1
 allowlist = \
-"^(" ENVIRON["SRCDIR"] "|" ENVIRON["WORKDIR"] ")"
+"^(" ENVIRON["SRCDIR"] "|" ENVIRON["BUILDDIR"] ")"
 firstline = 1
 }
 
___
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' - solenv/gbuild

2020-12-18 Thread Mike Kaganski (via logerrit)
 solenv/gbuild/platform/filter-showIncludes.awk |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit e29387a749edb1bf39ca2b558099964da42b3a4b
Author: Mike Kaganski 
AuthorDate: Thu Dec 17 15:17:01 2020 +0300
Commit: Michael Stahl 
CommitDate: Fri Dec 18 20:28:58 2020 +0100

include everything from BUILDDIR, e.g. config_host/*

... otherwise any change in config that modifies those does not trigger
related units to be rebuilt

Change-Id: I680fc1e004208f7ccc752186d5e765560dffebf9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107875
Tested-by: Jenkins
Reviewed-by: Mike Kaganski 
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107976
Reviewed-by: Michael Stahl 

diff --git a/solenv/gbuild/platform/filter-showIncludes.awk 
b/solenv/gbuild/platform/filter-showIncludes.awk
index b8a1db052701..6a7cf0296940 100755
--- a/solenv/gbuild/platform/filter-showIncludes.awk
+++ b/solenv/gbuild/platform/filter-showIncludes.awk
@@ -35,7 +35,7 @@ BEGIN {
 # to match especially drive letters in whitelist case insensitive
 IGNORECASE = 1
 whitelist = \
-"^(" ENVIRON["SRCDIR"] "|" ENVIRON["WORKDIR"] ")"
+"^(" ENVIRON["SRCDIR"] "|" ENVIRON["BUILDDIR"] ")"
 firstline = 1
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Update for Occitan dictionary

2020-12-18 Thread Jan-Marek Glogowski

Hi Quentin,

Am 18.12.20 um 20:15 schrieb Quentin PAGÈS:
I'm writing this mail to ask for a review of my Pull Request located 
here: https://github.com/LibreOffice/dictionaries/pull/30

It includes an update of the Occitan dictionary.


LibreOffice uses Gerrit (https://gerrit.libreoffice.org) for development 
and patches. I guess you can follow 
https://wiki.documentfoundation.org/Development/GetInvolved, just skip 
the whole LO build stuff and git clone 
"https://git.libreoffice.org/dictionaries"; instead of core and submit 
your patches to Gerrit.


HTH

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


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

2020-12-18 Thread Luboš Luňák (via logerrit)
 vcl/inc/salbmp.hxx   |3 ++-
 vcl/source/bitmap/salbmp.cxx |5 +++--
 2 files changed, 5 insertions(+), 3 deletions(-)

New commits:
commit 29c5b99832d731071dd201e88d6631c805efe91a
Author: Luboš Luňák 
AuthorDate: Fri Dec 18 11:59:25 2020 +0100
Commit: Noel Grandin 
CommitDate: Fri Dec 18 21:20:03 2020 +0100

fix incorrect array access after a removed enum (tdf#138973)

c521e614359d236405754134a54e8a05bdb1c44c removed some enum values
but didn't remove them from the conversion array.

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

diff --git a/vcl/inc/salbmp.hxx b/vcl/inc/salbmp.hxx
index 943f9d6b2986..adbf70e5c17f 100644
--- a/vcl/inc/salbmp.hxx
+++ b/vcl/inc/salbmp.hxx
@@ -121,7 +121,8 @@ protected:
 {
 A8,
 RGBA,
-BGRA
+BGRA,
+LAST = BGRA
 };
 static std::unique_ptr< sal_uInt8[] > convertDataBitCount( const 
sal_uInt8* src,
 int width, int height, int bitCount, int bytesPerRow, const 
BitmapPalette& palette,
diff --git a/vcl/source/bitmap/salbmp.cxx b/vcl/source/bitmap/salbmp.cxx
index 880be0bb437b..7159ac3d5a6b 100644
--- a/vcl/source/bitmap/salbmp.cxx
+++ b/vcl/source/bitmap/salbmp.cxx
@@ -18,6 +18,7 @@
  */
 
 #include 
+#include 
 
 static BitmapChecksum scanlineChecksum(BitmapChecksum nCrc, const sal_uInt8* 
bits, int lineBitsCount, sal_uInt8 extraBitsMask)
 {
@@ -264,8 +265,8 @@ std::unique_ptr< sal_uInt8[] > 
SalBitmap::convertDataBitCount( const sal_uInt8*
 int width, int height, int bitCount, int bytesPerRow, const BitmapPalette& 
palette, BitConvert type )
 {
 assert( bitCount == 1 || bitCount == 4 || bitCount == 8 );
-static const int bpp[] = { 1, 3, 3, 4, 4 };
-std::unique_ptr< sal_uInt8[] > data( new sal_uInt8[width * height * bpp[ 
static_cast(type) ]] );
+static const o3tl::enumarray bpp = { 1, 4, 4 };
+std::unique_ptr< sal_uInt8[] > data( new sal_uInt8[width * height * bpp[ 
type ]] );
 
 if(type == BitConvert::A8 && bitCount == 8 && palette.IsGreyPalette8Bit())
 { // no actual data conversion
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Caolán McNamara (via logerrit)
 sfx2/source/doc/templatedlg.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 9ba11eb2a4c6c18fc265ad51813d9aea57671c1a
Author: Caolán McNamara 
AuthorDate: Fri Dec 18 13:16:18 2020 +
Commit: Caolán McNamara 
CommitDate: Fri Dec 18 21:31:51 2020 +0100

Delete Category dialog includes '~' text in the titlebar

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

diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index fcf651bafb05..f7d6a1d72210 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -34,6 +34,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 
@@ -1200,7 +1201,7 @@ void SfxTemplateManagerDlg::OnCategoryDelete()
 SfxTemplateCategoryDialog aDlg(m_xDialog.get());
 aDlg.SetCategoryLBEntries(mxLocalView->getFolderNames());
 aDlg.HideNewCategoryOption();
-aDlg.set_title(SfxResId(STR_CATEGORY_DELETE));
+
aDlg.set_title(MnemonicGenerator::EraseAllMnemonicChars(SfxResId(STR_CATEGORY_DELETE)));
 aDlg.SetSelectLabelText(SfxResId(STR_CATEGORY_SELECT));
 
 if (aDlg.run() == RET_OK)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Caolán McNamara (via logerrit)
 editeng/source/editeng/editview.cxx |5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

New commits:
commit 0d6063a61c15688998c1a7f865b090fd9b1f8fff
Author: Caolán McNamara 
AuthorDate: Fri Dec 18 10:26:28 2020 +
Commit: Caolán McNamara 
CommitDate: Fri Dec 18 21:38:46 2020 +0100

use the OutputDevice view

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

diff --git a/editeng/source/editeng/editview.cxx 
b/editeng/source/editeng/editview.cxx
index 99e3f67730d5..7b70f98b6ef7 100644
--- a/editeng/source/editeng/editview.cxx
+++ b/editeng/source/editeng/editview.cxx
@@ -951,7 +951,8 @@ static void LOKSendSpellPopupMenu(const weld::Menu& rMenu, 
LanguageType nGuessLa
 
 void EditView::ExecuteSpellPopup( const Point& rPosPixel, 
Link const * pCallBack )
 {
-Point aPos(pImpEditView->GetOutputDevice().PixelToLogic(rPosPixel));
+OutputDevice& rDevice = pImpEditView->GetOutputDevice();
+Point aPos(rDevice.PixelToLogic(rPosPixel));
 aPos = pImpEditView->GetDocPos( aPos );
 EditPaM aPaM = pImpEditView->pEditEngine->GetPaM(aPos, false);
 Reference< linguistic2::XSpellChecker1 >  xSpeller( 
pImpEditView->pEditEngine->pImpEditEngine->GetSpeller() );
@@ -964,7 +965,7 @@ void EditView::ExecuteSpellPopup( const Point& rPosPixel, 
LinkGetWindowPos(aTempRect);
 // Convert to pixels
-aTempRect = pImpEditView->GetWindow()->LogicToPixel(aTempRect);
+aTempRect = rDevice.LogicToPixel(aTempRect);
 
 weld::Widget* pPopupParent = pImpEditView->GetPopupParent(aTempRect);
 std::unique_ptr 
xBuilder(Application::CreateBuilder(pPopupParent, "editeng/ui/spellmenu.ui"));
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Caolán McNamara (via logerrit)
 editeng/source/editeng/editview.cxx |4 ++--
 editeng/source/editeng/impedit.cxx  |4 ++--
 editeng/source/editeng/impedit.hxx  |4 ++--
 editeng/source/editeng/impedit2.cxx |8 ++--
 editeng/source/outliner/outlvw.cxx  |6 ++
 include/editeng/editview.hxx|2 +-
 include/editeng/outliner.hxx|2 +-
 include/vcl/seleng.hxx  |2 +-
 svx/source/dialog/weldeditview.cxx  |3 +--
 vcl/source/window/seleng.cxx|7 ---
 10 files changed, 22 insertions(+), 20 deletions(-)

New commits:
commit 2a91637ed9a312471afe7a2201371eb9ae7f33c7
Author: Caolán McNamara 
AuthorDate: Fri Dec 18 10:46:03 2020 +
Commit: Caolán McNamara 
CommitDate: Fri Dec 18 21:39:05 2020 +0100

add a return to EditView::Command to indicate if the command was consumed

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

diff --git a/editeng/source/editeng/editview.cxx 
b/editeng/source/editeng/editview.cxx
index 7b70f98b6ef7..a17f76d6d492 100644
--- a/editeng/source/editeng/editview.cxx
+++ b/editeng/source/editeng/editview.cxx
@@ -471,9 +471,9 @@ bool EditView::MouseMove( const MouseEvent& rMouseEvent )
 return pImpEditView->MouseMove( rMouseEvent );
 }
 
-void EditView::Command( const CommandEvent& rCEvt )
+bool EditView::Command(const CommandEvent& rCEvt)
 {
-pImpEditView->Command( rCEvt );
+return pImpEditView->Command(rCEvt);
 }
 
 void EditView::SetBroadcastLOKViewCursor(bool bSet)
diff --git a/editeng/source/editeng/impedit.cxx 
b/editeng/source/editeng/impedit.cxx
index 20dce95424a9..bd2f0bf24218 100644
--- a/editeng/source/editeng/impedit.cxx
+++ b/editeng/source/editeng/impedit.cxx
@@ -1705,10 +1705,10 @@ bool ImpEditView::MouseMove( const MouseEvent& 
rMouseEvent )
 return pEditEngine->pImpEditEngine->MouseMove( rMouseEvent, 
GetEditViewPtr() );
 }
 
-void ImpEditView::Command( const CommandEvent& rCEvt )
+bool ImpEditView::Command(const CommandEvent& rCEvt)
 {
 pEditEngine->CheckIdleFormatter();  // If fast typing and mouse button down
-pEditEngine->pImpEditEngine->Command( rCEvt, GetEditViewPtr() );
+return pEditEngine->pImpEditEngine->Command(rCEvt, GetEditViewPtr());
 }
 
 
diff --git a/editeng/source/editeng/impedit.hxx 
b/editeng/source/editeng/impedit.hxx
index 45088dc9bedf..a874a51699e3 100644
--- a/editeng/source/editeng/impedit.hxx
+++ b/editeng/source/editeng/impedit.hxx
@@ -368,7 +368,7 @@ public:
 boolMouseButtonDown( const MouseEvent& rMouseEvent );
 voidReleaseMouse();
 boolMouseMove( const MouseEvent& rMouseEvent );
-voidCommand( const CommandEvent& rCEvt );
+boolCommand(const CommandEvent& rCEvt);
 
 voidCutCopy( css::uno::Reference< 
css::datatransfer::clipboard::XClipboard > const & rxClipboard, bool bCut );
 voidPaste( css::uno::Reference< 
css::datatransfer::clipboard::XClipboard > const & rxClipboard, bool 
bUseSpecial = false );
@@ -841,7 +841,7 @@ public:
 boolMouseButtonDown( const MouseEvent& rMouseEvent, 
EditView* pView );
 voidReleaseMouse();
 boolMouseMove( const MouseEvent& rMouseEvent, EditView* 
pView );
-voidCommand( const CommandEvent& rCEvt, EditView* 
pView );
+boolCommand(const CommandEvent& rCEvt, EditView* 
pView);
 
 EditSelectionEngine&GetSelEngine() { return aSelEngine; }
 OUStringGetSelected( const EditSelection& rSel ) const;
diff --git a/editeng/source/editeng/impedit2.cxx 
b/editeng/source/editeng/impedit2.cxx
index 2c83c1165856..d2596ebd9065 100644
--- a/editeng/source/editeng/impedit2.cxx
+++ b/editeng/source/editeng/impedit2.cxx
@@ -331,8 +331,10 @@ bool ImpEditEngine::MouseButtonDown( const MouseEvent& 
rMEvt, EditView* pView )
 return true;
 }
 
-void ImpEditEngine::Command( const CommandEvent& rCEvt, EditView* pView )
+bool ImpEditEngine::Command( const CommandEvent& rCEvt, EditView* pView )
 {
+bool bConsumed = true;
+
 GetSelEngine().SetCurView( pView );
 SetActiveView( pView );
 if ( rCEvt.GetCommand() == CommandEventId::StartExtTextInput )
@@ -555,8 +557,10 @@ void ImpEditEngine::Command( const CommandEvent& rCEvt, 
EditView* pView )
 }
 }
 }
+else
+bConsumed = false;
 
-GetSelEngine().Command( rCEvt );
+return GetSelEngine().Command(rCEvt) || bConsumed;
 }
 
 bool ImpEditEngine::MouseButtonUp( const MouseEvent& rMEvt, EditView* pView )
diff --git a/editeng/source/outliner/outlvw.cxx 
b/editeng/source/outliner/outlvw.cxx
index aff9992d8b4c..8ba3a28c87f0 100644
--- a/editeng/source/outliner/outlvw.cxx
+++ b/editeng/source/outliner/outlvw.cxx
@@ -773,13 +773,11 @@ void OutlinerView::ImpPasted( sal_Int32 nStart, sal_Int32 
nPrevPa

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

2020-12-18 Thread Mike Kaganski (via logerrit)
 sw/qa/extras/ooxmlexport/data/croppedAndRotated.odt |binary
 sw/qa/extras/ooxmlexport/ooxmlexport13.cxx  |4 -
 sw/qa/extras/ooxmlexport/ooxmlexport16.cxx  |   14 ++
 sw/source/filter/ww8/docxattributeoutput.cxx|   42 
 sw/source/filter/ww8/docxattributeoutput.hxx|3 -
 5 files changed, 45 insertions(+), 18 deletions(-)

New commits:
commit 3dc2e629b247873bfbd3190c11152d8d2bab1a03
Author: Mike Kaganski 
AuthorDate: Fri Dec 18 13:12:50 2020 +0300
Commit: Mike Kaganski 
CommitDate: Fri Dec 18 21:47:14 2020 +0100

tdf#138953: use original (cropped, but unrotated) object size in spPr

This not only fixes the regression from 
b226383a83e41bbced9fc2a02dc09a449401ec97,
but also makes the written size more correct than before, when it was
slightly larger compared to original object size.

Corrected unit test for tdf#116371 reflect that: the object in ODT is
241.78 mm x 240.61 mm. It previously was exported as 241.88 x 240.70;
now the exported size is closer: 241.79 x 240.63.

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

diff --git a/sw/qa/extras/ooxmlexport/data/croppedAndRotated.odt 
b/sw/qa/extras/ooxmlexport/data/croppedAndRotated.odt
new file mode 100644
index ..825db09da8bf
Binary files /dev/null and 
b/sw/qa/extras/ooxmlexport/data/croppedAndRotated.odt differ
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx 
b/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx
index 459d72d38605..c191713a7be9 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx
@@ -610,8 +610,8 @@ DECLARE_OOXMLEXPORT_TEST(testTdf116371, "tdf116371.odt")
 auto xShape(getShape(1));
 CPPUNIT_ASSERT_DOUBLES_EQUAL(4700.0, getProperty(xShape, 
"RotateAngle"), 10);
 auto frameRect = getProperty(xShape, "FrameRect");
-CPPUNIT_ASSERT_EQUAL(sal_Int32(24070), frameRect.Height);
-CPPUNIT_ASSERT_EQUAL(sal_Int32(24188), frameRect.Width);
+CPPUNIT_ASSERT_EQUAL(sal_Int32(24063), frameRect.Height);
+CPPUNIT_ASSERT_EQUAL(sal_Int32(24179), frameRect.Width);
 }
 
 DECLARE_OOXMLEXPORT_EXPORTONLY_TEST(testFrameSizeExport, 
"floating-tables-anchor.docx")
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport16.cxx 
b/sw/qa/extras/ooxmlexport/ooxmlexport16.cxx
index 174f2f0f7330..e12804e58289 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport16.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport16.cxx
@@ -38,6 +38,20 @@ DECLARE_OOXMLEXPORT_TEST(testTdf138892_noNumbering, 
"tdf138892_noNumbering.docx"
 CPPUNIT_ASSERT_MESSAGE("Para3: ", 
getProperty(getParagraph(3), "NumberingStyleName").isEmpty());
 }
 
+DECLARE_OOXMLEXPORT_TEST(testTdf138953, "croppedAndRotated.odt")
+{
+CPPUNIT_ASSERT_EQUAL(1, getShapes());
+CPPUNIT_ASSERT_EQUAL(1, getPages());
+// Make sure the rotation is exported correctly, and size not distorted
+auto xShape(getShape(1));
+CPPUNIT_ASSERT_EQUAL(27000.0, getProperty(xShape, "RotateAngle"));
+auto frameRect = getProperty(xShape, "FrameRect");
+// Before the fix, original object size (i.e., before cropping) was 
written to spPr in OOXML,
+// and the resulting object size was much larger than should be.
+CPPUNIT_ASSERT_EQUAL(sal_Int32(12961), frameRect.Height);
+CPPUNIT_ASSERT_EQUAL(sal_Int32(8664), frameRect.Width);
+}
+
 CPPUNIT_PLUGIN_IMPLEMENT();
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx 
b/sw/source/filter/ww8/docxattributeoutput.cxx
index cd2af8bc8859..bc2955566213 100644
--- a/sw/source/filter/ww8/docxattributeoutput.cxx
+++ b/sw/source/filter/ww8/docxattributeoutput.cxx
@@ -4834,13 +4834,12 @@ void DocxAttributeOutput::DefaultStyle()
 /* Writes  tag back to document.xml if a file contains a cropped 
image.
 *  NOTE : Tested on images of type JPEG,EMF/WMF,BMP, PNG and GIF.
 */
-void DocxAttributeOutput::WriteSrcRect(const SdrObject* pSdrObj, const 
SwFrameFormat* pFrameFormat )
+void DocxAttributeOutput::WriteSrcRect(
+const css::uno::Reference& xShapePropSet,
+const SwFrameFormat* pFrameFormat)
 {
-uno::Reference< drawing::XShape > xShape( 
const_cast(pSdrObj)->getUnoShape(), uno::UNO_QUERY );
-uno::Reference< beans::XPropertySet > xPropSet( xShape, uno::UNO_QUERY );
-
 uno::Reference xGraphic;
-xPropSet->getPropertyValue("Graphic") >>= xGraphic;
+xShapePropSet->getPropertyValue("Graphic") >>= xGraphic;
 const Graphic aGraphic(xGraphic);
 
 Size aOriginalSize(aGraphic.GetPrefSize());
@@ -4853,7 +4852,7 @@ void DocxAttributeOutput::WriteSrcRect(const SdrObject* 
pSdrObj, const SwFrameFo
 }
 
 css::text::GraphicCrop aGraphicCropStruct;
-xPropSet->getPropertyValue( "GraphicCrop" ) >>= aGraphicCropStruct;
+xShapePropSet->getPropertyValue("GraphicCrop") >>= aGraph

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

2020-12-18 Thread Caolán McNamara (via logerrit)
 basctl/source/basicide/baside2.hxx  |2 --
 basctl/source/basicide/baside2b.cxx |   30 +-
 2 files changed, 13 insertions(+), 19 deletions(-)

New commits:
commit f3c63fc6024a95daf51aa3ca14ba57dacfecad31
Author: Caolán McNamara 
AuthorDate: Fri Dec 18 16:54:46 2020 +
Commit: Caolán McNamara 
CommitDate: Fri Dec 18 21:58:37 2020 +0100

weld basctl popup menus

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

diff --git a/basctl/source/basicide/baside2.hxx 
b/basctl/source/basicide/baside2.hxx
index dfe78c588ebe..06045356bccb 100644
--- a/basctl/source/basicide/baside2.hxx
+++ b/basctl/source/basicide/baside2.hxx
@@ -164,7 +164,6 @@ class BreakPointWindow final : public vcl::Window
 sal_uInt16  nMarkerPos;
 BreakPointList  aBreakPointList;
 boolbErrorMarker;
-std::unique_ptr mpUIBuilder;
 
 virtual void DataChanged(DataChangedEvent const & rDCEvt) override;
 
@@ -180,7 +179,6 @@ class BreakPointWindow final : public vcl::Window
 
 public:
 BreakPointWindow (vcl::Window* pParent, ModulWindow*);
-virtual voiddispose() override;
 
 voidSetMarkerPos( sal_uInt16 nLine, bool bErrorMarker = false 
);
 voidSetNoMarker ();
diff --git a/basctl/source/basicide/baside2b.cxx 
b/basctl/source/basicide/baside2b.cxx
index 4a8ab6fe0e54..5ebca907749e 100644
--- a/basctl/source/basicide/baside2b.cxx
+++ b/basctl/source/basicide/baside2b.cxx
@@ -46,10 +46,10 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
-#include 
 #include 
 #include 
 #include 
@@ -1493,18 +1493,20 @@ void BreakPointWindow::Command( const CommandEvent& 
rCEvt )
 if ( rCEvt.GetCommand() != CommandEventId::ContextMenu )
 return;
 
-if (!mpUIBuilder)
-mpUIBuilder.reset(new VclBuilder(nullptr, AllSettings::GetUIRootDir(), 
"modules/BasicIDE/ui/breakpointmenus.ui", ""));
-
 Point aPos( rCEvt.IsMouseEvent() ? rCEvt.GetMousePosPixel() : Point(1,1) );
+tools::Rectangle aRect(aPos, Size(1, 1));
+weld::Window* pPopupParent = weld::GetPopupParent(*this, aRect);
+
+std::unique_ptr 
xUIBuilder(Application::CreateBuilder(pPopupParent, 
"modules/BasicIDE/ui/breakpointmenus.ui"));
+
 Point aEventPos( PixelToLogic( aPos ) );
 BreakPoint* pBrk = rCEvt.IsMouseEvent() ? FindBreakPoint( aEventPos ) : 
nullptr;
 if ( pBrk )
 {
 // test if break point is enabled...
-VclPtr xBrkPropMenu = mpUIBuilder->get_menu("breakmenu");
-xBrkPropMenu->CheckItem("active", pBrk->bEnabled);
-OString sCommand = 
xBrkPropMenu->GetItemIdent(xBrkPropMenu->Execute(this, aPos));
+std::unique_ptr xBrkPropMenu = 
xUIBuilder->weld_menu("breakmenu");
+xBrkPropMenu->set_active("active", pBrk->bEnabled);
+OString sCommand = xBrkPropMenu->popup_at_rect(pPopupParent, aRect);
 if (sCommand == "active")
 {
 pBrk->bEnabled = !pBrk->bEnabled;
@@ -1513,7 +1515,7 @@ void BreakPointWindow::Command( const CommandEvent& rCEvt 
)
 }
 else if (sCommand == "properties")
 {
-BreakPointDialog aBrkDlg(GetFrameWeld(), GetBreakPoints());
+BreakPointDialog aBrkDlg(pPopupParent, GetBreakPoints());
 aBrkDlg.SetCurrentBreakPoint( *pBrk );
 aBrkDlg.run();
 Invalidate();
@@ -1521,11 +1523,11 @@ void BreakPointWindow::Command( const CommandEvent& 
rCEvt )
 }
 else
 {
-VclPtr xBrkListMenu = 
mpUIBuilder->get_menu("breaklistmenu");
-OString sCommand = 
xBrkListMenu->GetItemIdent(xBrkListMenu->Execute(this, aPos));
+std::unique_ptr xBrkListMenu = 
xUIBuilder->weld_menu("breaklistmenu");
+OString sCommand = xBrkListMenu->popup_at_rect(pPopupParent, aRect);
 if (sCommand == "manage")
 {
-BreakPointDialog aBrkDlg(GetFrameWeld(), GetBreakPoints());
+BreakPointDialog aBrkDlg(pPopupParent, GetBreakPoints());
 aBrkDlg.run();
 Invalidate();
 }
@@ -1570,12 +1572,6 @@ void BreakPointWindow::setBackgroundColor(Color aColor)
 SetBackground(Wallpaper(aColor));
 }
 
-void BreakPointWindow::dispose()
-{
-mpUIBuilder.reset();
-Window::dispose();
-}
-
 namespace {
 
 struct WatchItem
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Stephan Bergmann (via logerrit)
 bridges/source/cpp_uno/gcc3_linux_aarch64/cpp2uno.cxx |4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit d85a3887bf36ff1e4dddb111f2c5634b66eb9510
Author: Stephan Bergmann 
AuthorDate: Fri Dec 18 12:11:05 2020 +0100
Commit: Stephan Bergmann 
CommitDate: Fri Dec 18 22:01:54 2020 +0100

Mention relevant Clang bug in comment

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

diff --git a/bridges/source/cpp_uno/gcc3_linux_aarch64/cpp2uno.cxx 
b/bridges/source/cpp_uno/gcc3_linux_aarch64/cpp2uno.cxx
index 77fa3c03bbf4..b31d87655d0c 100644
--- a/bridges/source/cpp_uno/gcc3_linux_aarch64/cpp2uno.cxx
+++ b/bridges/source/cpp_uno/gcc3_linux_aarch64/cpp2uno.cxx
@@ -559,7 +559,9 @@ void bridges::cpp_uno::shared::VtableFactory::flushCode(
 // "extend.texi (__clear_cache): Correct signature" that 
__builtin___clear_cache takes void*
 // parameters, while Clang uses char* ever since
 // 

 "Add
-// support for __builtin___clear_cache in Clang":
+// support for __builtin___clear_cache in Clang" (TODO: see
+//  
"__builtin___clear_cache() has a different
+// prototype than GCC"; once fixed for our Clang baseline, we can drop the 
reinterpret_casts):
 __builtin___clear_cache(
 reinterpret_cast(const_cast(begin)),
 reinterpret_cast(const_cast(end)));
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Henry Castro (via logerrit)
 sfx2/source/sidebar/Deck.cxx |6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 92990e87a66758189e3324995ebe29cc026687a2
Author: Henry Castro 
AuthorDate: Tue Dec 8 09:06:45 2020 -0400
Commit: Henry Castro 
CommitDate: Fri Dec 18 22:21:34 2020 +0100

lok: fix "children" node type

In order to build the dialog on the client side,
the "children" object should be constructed with array type.

Change-Id: Iccde39aa9ff2f423fd4a67072ca0bf25e406d220
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107413
Tested-by: Jenkins
Reviewed-by: Henry Castro 

diff --git a/sfx2/source/sidebar/Deck.cxx b/sfx2/source/sidebar/Deck.cxx
index 4a05db81f000..0cd35d9e819f 100644
--- a/sfx2/source/sidebar/Deck.cxx
+++ b/sfx2/source/sidebar/Deck.cxx
@@ -200,7 +200,7 @@ void Deck::DumpAsPropertyTree(tools::JsonWriter& 
rJsonWriter)
 rJsonWriter.put("text", GetText());
 rJsonWriter.put("enabled", IsEnabled());
 
-auto childrenNode = rJsonWriter.startNode("children");
+auto childrenNode = rJsonWriter.startArray("children");
 for (auto &it : maPanels)
 {
 if (it->IsLurking())
@@ -214,13 +214,13 @@ void Deck::DumpAsPropertyTree(tools::JsonWriter& 
rJsonWriter)
 if (!pWindow)
 continue;
 
-auto childNode = rJsonWriter.startNode("");
+auto childNode = rJsonWriter.startStruct();
 rJsonWriter.put("id", it->GetId());
 rJsonWriter.put("type", "panel");
 rJsonWriter.put("text", it->GetText());
 rJsonWriter.put("enabled", it->IsEnabled());
 
-auto children2Node = rJsonWriter.startNode("children");
+auto children2Node = rJsonWriter.startArray("children");
 pWindow->DumpAsPropertyTree(rJsonWriter);
 }
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Henry Castro (via logerrit)
 stoc/source/javavm/javavm.cxx |3 +++
 1 file changed, 3 insertions(+)

New commits:
commit 8c5c6b8993a52c40b9de231e778204bcdca16333
Author: Henry Castro 
AuthorDate: Fri Dec 4 16:11:12 2020 -0400
Commit: Henry Castro 
CommitDate: Fri Dec 18 22:22:58 2020 +0100

lok: add pre-condition "DontEnableJava"

The context data "DontEnableJava" is set when
it is not required to JVM to get involved,
in particular case when the Macro Selector Dialog
tries to fill the macro scripts, but the client side
has disabled the JVM and it produces a lot of checks
to try to get booted the JVM.

Is there any reason why it is not a pre-condition
at the beginning of the function?

Change-Id: I3bd4a22ddef12a130ea5ecd08c67f1db66bbac72
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107242
Tested-by: Jenkins
Reviewed-by: Henry Castro 

diff --git a/stoc/source/javavm/javavm.cxx b/stoc/source/javavm/javavm.cxx
index 1b7a86e712ec..ccb8ca232813 100644
--- a/stoc/source/javavm/javavm.cxx
+++ b/stoc/source/javavm/javavm.cxx
@@ -574,6 +574,9 @@ JavaVirtualMachine::getJavaVM(css::uno::Sequence< sal_Int8 
> const & rProcessId)
 if (aId != aProcessId)
 return css::uno::Any();
 
+if (comphelper::IsContextFlagActive("DontEnableJava"))
+return css::uno::Any();
+
 std::unique_ptr info;
 while (!m_xVirtualMachine.is()) // retry until successful
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Eike Rathke (via logerrit)
 sc/source/core/tool/token.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 121d4f610a2b4caa871aa0132eccbd4e12d13b3f
Author: Eike Rathke 
AuthorDate: Fri Dec 18 20:27:34 2020 +0100
Commit: Eike Rathke 
CommitDate: Fri Dec 18 22:47:36 2020 +0100

Resolves: tdf#138710 Do not push an out-of-bounds bound to boundaries

... if a virtual non-existent row is being shifted in for
MAXROWCOUNT (MAXROW+1), so sc/source/core/tool/sharedformula.cxx
SharedFormulaUtil::splitFormulaCellGroups() is not triggered to
split a group there, which would throw an exception. Instead of
returning false ...

CellStoreType::position_type aPos = rCells.position(nRow);
if (aPos.first == rCells.end())
return false;

However, avoiding the cause is the solution.

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

diff --git a/sc/source/core/tool/token.cxx b/sc/source/core/tool/token.cxx
index df968b26a4fb..91e73e4ac49f 100644
--- a/sc/source/core/tool/token.cxx
+++ b/sc/source/core/tool/token.cxx
@@ -4530,7 +4530,8 @@ void checkBounds(
 // No intersections.
 return;
 
-if (aAbs.aStart.Row() <= rCheckRange.aStart.Row())
+// rCheckRange may be a virtual non-existent row being shifted in.
+if (aAbs.aStart.Row() <= rCheckRange.aStart.Row() && 
rCheckRange.aStart.Row() < rLimits.GetMaxRowCount())
 {
 //+-+ < top
 //| |
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Xisco Fauli (via logerrit)
 filter/qa/cppunit/data/tiff/tdf138818.tif |binary
 filter/qa/cppunit/filters-tiff-test.cxx   |   20 
 2 files changed, 20 insertions(+)

New commits:
commit 4db61e4cb26a8bf739701876aa806479a61bb447
Author: Xisco Fauli 
AuthorDate: Fri Dec 18 10:21:36 2020 +0100
Commit: Xisco Fauli 
CommitDate: Sat Dec 19 00:16:16 2020 +0100

tdf#138818: libtest_filter_tiff: Add unittest

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

diff --git a/filter/qa/cppunit/data/tiff/tdf138818.tif 
b/filter/qa/cppunit/data/tiff/tdf138818.tif
new file mode 100644
index ..bb3e51011b25
Binary files /dev/null and b/filter/qa/cppunit/data/tiff/tdf138818.tif differ
diff --git a/filter/qa/cppunit/filters-tiff-test.cxx 
b/filter/qa/cppunit/filters-tiff-test.cxx
index 4a5647ca7867..93968e9be9b7 100644
--- a/filter/qa/cppunit/filters-tiff-test.cxx
+++ b/filter/qa/cppunit/filters-tiff-test.cxx
@@ -47,11 +47,13 @@ public:
 void testCVEs();
 void testTdf126460();
 void testTdf115863();
+void testTdf138818();
 
 CPPUNIT_TEST_SUITE(TiffFilterTest);
 CPPUNIT_TEST(testCVEs);
 CPPUNIT_TEST(testTdf126460);
 CPPUNIT_TEST(testTdf115863);
+CPPUNIT_TEST(testTdf138818);
 CPPUNIT_TEST_SUITE_END();
 };
 
@@ -107,6 +109,24 @@ void TiffFilterTest::testTdf115863()
 
 }
 
+void TiffFilterTest::testTdf138818()
+{
+OUString aURL = getUrl() + "tdf138818.tif";
+SvFileStream aFileStream(aURL, StreamMode::READ);
+Graphic aGraphic;
+GraphicFilter& rFilter = GraphicFilter::GetGraphicFilter();
+
+ErrCode bResult = rFilter.ImportGraphic(aGraphic, aURL, aFileStream);
+
+CPPUNIT_ASSERT_EQUAL(ERRCODE_NONE, bResult);
+
+// Without the fix in place, this test would have failed with
+// - Expected: 46428
+// - Actual  : 45951
+CPPUNIT_ASSERT_EQUAL(sal_uInt32(46428), 
aGraphic.GetGfxLink().GetDataSize());
+
+}
+
 CPPUNIT_TEST_SUITE_REGISTRATION(TiffFilterTest);
 
 CPPUNIT_PLUGIN_IMPLEMENT();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Christian Lohmaier (via logerrit)
 configure.ac |6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

New commits:
commit 315c7570c4a72f4c834086082825533b1e50d1bf
Author: Christian Lohmaier 
AuthorDate: Fri Dec 18 16:23:59 2020 +0100
Commit: Christian Lohmaier 
CommitDate: Sat Dec 19 00:25:51 2020 +0100

cross-compile: make sure configure fails if build-side configure fails

testing for existance of config_host.mk is flawed/doesn't catch all kind
of errors and thus gives false "OK" for incremental builds and not even for
builds after make clean
see also d691b46e52d173cf945130df01bd35b5c4c0f539

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

diff --git a/configure.ac b/configure.ac
index 89c44b74e4f9..29d553b7c198 100644
--- a/configure.ac
+++ b/configure.ac
@@ -5226,7 +5226,9 @@ if test "$cross_compiling" = "yes"; then
 $sub_conf_opts \
 --srcdir=$srcdir \
 2>&1 | sed -e 's/^//'
-test -f ./config_host.mk 2>/dev/null || exit
+if test [${PIPESTATUS[0]}] -ne 0; then
+AC_MSG_ERROR([Running the configure script for BUILD side failed, see 
CONF-FOR-BUILD/config.log])
+fi
 
 # filter permitted build targets
 PERMITTED_BUILD_TARGETS="
@@ -5346,7 +5348,7 @@ if test "$cross_compiling" = "yes"; then
 done
 
 )
-test -f CONF-FOR-BUILD/build-config || AC_MSG_ERROR([Running configure 
script for BUILD system failed, see CONF-FOR-BUILD/config.log])
+test -f CONF-FOR-BUILD/build-config || AC_MSG_ERROR([setup/configure for 
BUILD side failed, see CONF-FOR-BUILD/config.log])
 test -f config_build.mk || AC_MSG_ERROR([A file called config_build.mk was 
supposed to have been copied here, but it isn't found])
 perl -pi -e 's,/(workdir|instdir)(/|$),/\1_for_build\2,g;' \
  -e 's,/CONF-FOR-BUILD,,g;' config_build.mk
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Update for Occitan dictionary

2020-12-18 Thread Quentin PAGÈS
Hello Jan-Marek,

Thanks for your complete answer!
I'm confident with Git =/ I'll give it a try tomorrow.

Best regards

Quentin

Le Vendredi 18 décembre 2020, Jan-Marek Glogowski a écrit :
> Hi Quentin,
> 
> Am 18.12.20 um 20:15 schrieb Quentin PAGÈS:
> > I'm writing this mail to ask for a review of my Pull Request located 
> > here: https://github.com/LibreOffice/dictionaries/pull/30
> > It includes an update of the Occitan dictionary.
> 
> LibreOffice uses Gerrit (https://gerrit.libreoffice.org) for development 
> and patches. I guess you can follow 
> https://wiki.documentfoundation.org/Development/GetInvolved, just skip 
> the whole LO build stuff and git clone 
> "https://git.libreoffice.org/dictionaries"; instead of core and submit 
> your patches to Gerrit.
> 
> HTH
> 
> Jan-Marek
>

-- 
Quentin PAGÈS
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2020-12-18 Thread Andras Timar (via logerrit)
 sc/uiconfig/scalc/ui/filterdropdown.ui |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 12b10714003693a238c5f5b66c26d61e26c05a7a
Author: Andras Timar 
AuthorDate: Sat Dec 19 00:29:12 2020 +0100
Commit: Andras Timar 
CommitDate: Sat Dec 19 00:29:12 2020 +0100

Set correct interface domain

Change-Id: Iaab2c0da9782132204d22d1dc84b2d444ba8dd8f

diff --git a/sc/uiconfig/scalc/ui/filterdropdown.ui 
b/sc/uiconfig/scalc/ui/filterdropdown.ui
index 07c484c67ae8..429edb11e9b7 100644
--- a/sc/uiconfig/scalc/ui/filterdropdown.ui
+++ b/sc/uiconfig/scalc/ui/filterdropdown.ui
@@ -1,6 +1,6 @@
 
 
-
+
   
   
 True
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: icon-themes/elementary icon-themes/elementary_svg

2020-12-18 Thread Rizal Muttaqin (via logerrit)
 icon-themes/elementary/cmd/32/basicideappear.png  |binary
 icon-themes/elementary/cmd/32/dbformedit.png  |binary
 icon-themes/elementary/cmd/32/dbqueryedit.png |binary
 icon-themes/elementary/cmd/32/dbreportedit.png|binary
 icon-themes/elementary/cmd/32/dbtableedit.png |binary
 icon-themes/elementary/cmd/32/editannotation.png  |binary
 icon-themes/elementary/cmd/32/editcurindex.png|binary
 icon-themes/elementary/cmd/32/editdoc.png |binary
 icon-themes/elementary/cmd/32/edithyperlink.png   |binary
 icon-themes/elementary/cmd/32/editprintarea.png   |binary
 icon-themes/elementary/cmd/32/editstyle.png   |binary
 icon-themes/elementary/cmd/32/ko/editstyle.png|binary
 icon-themes/elementary/cmd/32/trackchangesbar.png |binary
 icon-themes/elementary/cmd/ko/lc_editstyle.png|binary
 icon-themes/elementary/cmd/lc_basicideappear.png  |binary
 icon-themes/elementary/cmd/lc_dbformedit.png  |binary
 icon-themes/elementary/cmd/lc_dbqueryedit.png |binary
 icon-themes/elementary/cmd/lc_dbreportedit.png|binary
 icon-themes/elementary/cmd/lc_dbtableedit.png |binary
 icon-themes/elementary/cmd/lc_editannotation.png  |binary
 icon-themes/elementary/cmd/lc_editcurindex.png|binary
 icon-themes/elementary/cmd/lc_editdoc.png |binary
 icon-themes/elementary/cmd/lc_edithyperlink.png   |binary
 icon-themes/elementary/cmd/lc_editprintarea.png   |binary
 icon-themes/elementary/cmd/lc_editstyle.png   |binary
 icon-themes/elementary/cmd/lc_trackchangesbar.png |binary
 icon-themes/elementary/cmd/sc_basicideappear.png  |binary
 icon-themes/elementary/cmd/sc_dbformedit.png  |binary
 icon-themes/elementary/cmd/sc_dbqueryedit.png |binary
 icon-themes/elementary/cmd/sc_dbreportedit.png|binary
 icon-themes/elementary/cmd/sc_dbtableedit.png |binary
 icon-themes/elementary/cmd/sc_editannotation.png  |binary
 icon-themes/elementary/cmd/sc_editcurindex.png|binary
 icon-themes/elementary/cmd/sc_editdoc.png |binary
 icon-themes/elementary/cmd/sc_edithyperlink.png   |binary
 icon-themes/elementary/cmd/sc_editprintarea.png   |binary
 icon-themes/elementary/cmd/sc_editstyle.png   |binary
 icon-themes/elementary/cmd/sc_trackchangesbar.png |binary
 icon-themes/elementary/links.txt  |8 
 icon-themes/elementary_svg/cmd/32/basicideappear.svg  |2 +-
 icon-themes/elementary_svg/cmd/32/dbformedit.svg  |2 +-
 icon-themes/elementary_svg/cmd/32/dbqueryedit.svg |2 +-
 icon-themes/elementary_svg/cmd/32/dbreportedit.svg|2 +-
 icon-themes/elementary_svg/cmd/32/dbtableedit.svg |2 +-
 icon-themes/elementary_svg/cmd/32/editannotation.svg  |2 +-
 icon-themes/elementary_svg/cmd/32/editcurindex.svg|2 +-
 icon-themes/elementary_svg/cmd/32/editdoc.svg |2 +-
 icon-themes/elementary_svg/cmd/32/edithyperlink.svg   |2 +-
 icon-themes/elementary_svg/cmd/32/editprintarea.svg   |2 +-
 icon-themes/elementary_svg/cmd/32/editstyle.svg   |2 +-
 icon-themes/elementary_svg/cmd/32/ko/editstyle.svg|2 +-
 icon-themes/elementary_svg/cmd/32/trackchangesbar.svg |2 +-
 icon-themes/elementary_svg/cmd/ko/lc_editstyle.svg|2 +-
 icon-themes/elementary_svg/cmd/lc_basicideappear.svg  |2 +-
 icon-themes/elementary_svg/cmd/lc_dbformedit.svg  |2 +-
 icon-themes/elementary_svg/cmd/lc_dbqueryedit.svg |2 +-
 icon-themes/elementary_svg/cmd/lc_dbreportedit.svg|2 +-
 icon-themes/elementary_svg/cmd/lc_dbtableedit.svg |2 +-
 icon-themes/elementary_svg/cmd/lc_editannotation.svg  |2 +-
 icon-themes/elementary_svg/cmd/lc_editcurindex.svg|2 +-
 icon-themes/elementary_svg/cmd/lc_editdoc.svg |2 +-
 icon-themes/elementary_svg/cmd/lc_edithyperlink.svg   |2 +-
 icon-themes/elementary_svg/cmd/lc_editprintarea.svg   |2 +-
 icon-themes/elementary_svg/cmd/lc_editstyle.svg   |2 +-
 icon-themes/elementary_svg/cmd/lc_trackchangesbar.svg |2 +-
 icon-themes/elementary_svg/cmd/sc_basicideappear.svg  |2 +-
 icon-themes/elementary_svg/cmd/sc_dbformedit.svg  |2 +-
 icon-themes/elementary_svg/cmd/sc_dbqueryedit.svg |2 +-
 icon-themes/elementary_svg/cmd/sc_dbreportedit.svg|5 +++--
 icon-themes/elementary_svg/cmd/sc_dbtableedit.svg |2 +-
 icon-themes/elementary_svg/cmd/sc_editannotation.svg  |2 +-
 icon-themes/elementary_svg/cmd/sc_editcurindex.svg|2 +-
 icon-themes/elementary_svg/cmd/sc_editdoc.svg |2 +-
 icon-themes/elementary_svg/cmd/sc_edithyperlink.svg   |2 +-
 icon-themes/elementary_svg/cmd/sc_editprintarea.svg   |2 +-
 icon-themes/elementary_svg/cmd/sc_editstyle.svg   |2 +-
 icon-themes/elementary_svg/cmd/sc_trackchangesbar.svg |2 +-
 77 files changed, 44 insertions(+), 43 deletions(-)

New com

[Libreoffice-commits] core.git: Branch 'feature/drawinglayercore' - 9 commits - drawinglayer/inc drawinglayer/Library_drawinglayercore.mk drawinglayer/Library_drawinglayer.mk drawinglayer/source filte

2020-12-18 Thread Tomaž Vajngerl (via logerrit)
Rebased ref, commits from common ancestor:
commit 0ff53149e1845781ae24fce08cb09dbaf718e910
Author: Tomaž Vajngerl 
AuthorDate: Fri Jul 17 15:09:49 2020 +0200
Commit: Tomaž Vajngerl 
CommitDate: Sat Dec 19 10:44:47 2020 +0900

Revert "hack for gradients split into adjacent polygons (tdf#133016)"

This reverts commit 777ac5456a1f24fea29931ede983b5b8ad9a063d.

diff --git a/drawinglayer/source/primitive2d/svggradientprimitive2d.cxx 
b/drawinglayer/source/primitive2d/svggradientprimitive2d.cxx
index 7c9eb8441306..9b9d258046cc 100644
--- a/drawinglayer/source/primitive2d/svggradientprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/svggradientprimitive2d.cxx
@@ -30,7 +30,7 @@
 #include 
 #include 
 #include 
-#include 
+
 
 using namespace com::sun::star;
 
@@ -868,12 +868,6 @@ namespace drawinglayer::primitive2d
 // use color distance and discrete lengths to calculate step count
 const sal_uInt32 nSteps(calculateStepsForSvgGradient(getColorA(), 
getColorB(), fDelta, fDiscreteUnit));
 
-// HACK: Splitting a gradient into adjacent polygons with 
gradually changing color is silly.
-// If antialiasing is used to draw them, the AA-ed adjacent edges 
won't line up perfectly
-// because of the AA (see 
SkiaSalGraphicsImpl::mergePolyPolygonToPrevious()).
-// Make the polygons a bit wider, so they the partial overlap 
"fixes" this.
-const double fixup = SkiaHelper::isVCLSkiaEnabled() ? 
fDiscreteUnit / 2 : 0;
-
 // tdf#117949 Use a small amount of discrete overlap at the edges. 
Usually this
 // should be exactly 0.0 and 1.0, but there were cases when this 
gets clipped
 // against the mask polygon which got numerically problematic.
@@ -887,7 +881,7 @@ namespace drawinglayer::primitive2d
 basegfx::B2DRange(
 getOffsetA() - fDiscreteUnit,
 -0.0001, //  -> should be 0.0, see comment above
-getOffsetA() + (fDelta / nSteps) + fDiscreteUnit + 
fixup,
+getOffsetA() + (fDelta / nSteps) + fDiscreteUnit,
 1.0001))); //  -> should be 1.0, see comment above
 
 // prepare loop (inside to outside, [0.0 .. 1.0[)
commit daf8850ecf4a02af5b16be745384e7897bdf3fb8
Author: Tomaž Vajngerl 
AuthorDate: Mon Jun 15 19:39:35 2020 +0200
Commit: Tomaž Vajngerl 
CommitDate: Sat Dec 19 10:44:47 2020 +0900

vcl: add a Bitmap interface to basegfx, BitmapEx implementing it

Change-Id: I758f421d545191883e615f5016e9fc643459556e

diff --git a/include/basegfx/bitmap/Bitmap.hxx 
b/include/basegfx/bitmap/Bitmap.hxx
new file mode 100644
index ..b91b702aa212
--- /dev/null
+++ b/include/basegfx/bitmap/Bitmap.hxx
@@ -0,0 +1,23 @@
+/* -*- 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/.
+ *
+ */
+
+#pragma once
+
+#include 
+
+namespace basegfx
+{
+class BASEGFX_DLLPUBLIC IBitmap
+{
+};
+
+} // end of namespace basegfx
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/vcl/bitmapex.hxx b/include/vcl/bitmapex.hxx
index 14bbee535485..41e59a90f5e9 100644
--- a/include/vcl/bitmapex.hxx
+++ b/include/vcl/bitmapex.hxx
@@ -26,6 +26,8 @@
 #include 
 #include 
 
+#include 
+
 #include 
 
 namespace com::sun::star::rendering {
@@ -41,7 +43,7 @@ enum class TransparentType
 Bitmap
 };
 
-class SAL_WARN_UNUSED VCL_DLLPUBLIC BitmapEx
+class SAL_WARN_UNUSED VCL_DLLPUBLIC BitmapEx : basegfx::IBitmap
 {
 public:
 
commit 3d6e5e06d52af1a9a78784c472eb1033f2e86691
Author: Tomaž Vajngerl 
AuthorDate: Wed May 27 12:49:05 2020 +0200
Commit: Tomaž Vajngerl 
CommitDate: Sat Dec 19 10:44:47 2020 +0900

add o3tl version of hash_combine to not depend on boost for this

Change-Id: I081f8d116ef811baa8aa5de35a6cb51fa4de7d56

diff --git a/include/o3tl/hash_combine.hxx b/include/o3tl/hash_combine.hxx
new file mode 100644
index ..17419b3e2c0f
--- /dev/null
+++ b/include/o3tl/hash_combine.hxx
@@ -0,0 +1,29 @@
+/* -*- 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/.
+ */
+
+#pragma once
+
+namespace o3tl
+{
+template  = 
false>
+inline void hash_combine(N& nSeed, T const& nValue)
+{
+static_assert(sizeof(nSeed) == 4);
+nSeed ^= std::hash{}(nValue) + 0x9E3779B9u + (nSeed << 6) + (nSeed >> 
2);
+}
+
+template  = 
false>
+inline void hash_co

About preparing migration towards gtk4

2020-12-18 Thread julien2412
Hello,

Gtk4 has been released 2 days ago, I know that migration from a version to
another version is not a 1 month work, but thought it could be interesting
and it can't hurt the current state of LO to begin to prepare it by
following:
https://developer.gnome.org/gtk4/4.0/gtk-migrating-3-to-4.html#id-1.7.4.3.
I don't pretend I'd be able to propose some patches because I know nothing
about gtk but if I find some low hanging fruits, is it ok and/or does it
worth it to submit some?

Any thoughts?

Julien




--
Sent from: 
http://document-foundation-mail-archive.969070.n3.nabble.com/Dev-f1639786.html
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2020-12-18 Thread Eike Rathke (via logerrit)
 sc/source/core/tool/token.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit abecbc3eb6d6d9fa6b51c45a52c24a2001ded195
Author: Eike Rathke 
AuthorDate: Fri Dec 18 20:27:34 2020 +0100
Commit: Eike Rathke 
CommitDate: Sat Dec 19 02:48:07 2020 +0100

Resolves: tdf#138710 Do not push an out-of-bounds bound to boundaries

... if a virtual non-existent row is being shifted in for
MAXROWCOUNT (MAXROW+1), so sc/source/core/tool/sharedformula.cxx
SharedFormulaUtil::splitFormulaCellGroups() is not triggered to
split a group there, which would throw an exception. Instead of
returning false ...

CellStoreType::position_type aPos = rCells.position(nRow);
if (aPos.first == rCells.end())
return false;

However, avoiding the cause is the solution.

Change-Id: I8f9adcb62bb78bc98092677b5d4fdc7fc3baf150
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107979
Reviewed-by: Eike Rathke 
Tested-by: Jenkins
(cherry picked from commit 121d4f610a2b4caa871aa0132eccbd4e12d13b3f)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107994

diff --git a/sc/source/core/tool/token.cxx b/sc/source/core/tool/token.cxx
index 859b44327a78..3cb4a8836d61 100644
--- a/sc/source/core/tool/token.cxx
+++ b/sc/source/core/tool/token.cxx
@@ -4538,7 +4538,8 @@ void checkBounds(
 // No intersections.
 return;
 
-if (aAbs.aStart.Row() <= rCheckRange.aStart.Row())
+// rCheckRange may be a virtual non-existent row being shifted in.
+if (aAbs.aStart.Row() <= rCheckRange.aStart.Row() && 
rCheckRange.aStart.Row() < rLimits.GetMaxRowCount())
 {
 //+-+ < top
 //| |
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: ESC meeting agenda: 2020-12-17 16:00 Berlin time

2020-12-18 Thread julien2412
julien2412 wrote
> Miklos Vajna-6 wrote
> ...
> Also there's the wrong named "Firebird" Address Data Source in Writer
> wizards, should we remove this (or rename it if it works with Mozilla
> Suite/Seamonkey but does it worth it?), knowing that the only remaining
> entry would be "Other" (not very UI friendly...)?
> .

Argh, I meant the "wrong named "Firefox" Address Data source". (words were
too closed for me :-) )



--
Sent from: 
http://document-foundation-mail-archive.969070.n3.nabble.com/Dev-f1639786.html
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: icon-themes/elementary icon-themes/elementary_svg

2020-12-18 Thread Rizal Muttaqin (via logerrit)
 icon-themes/elementary/cmd/32/recsearch.png|binary
 icon-themes/elementary/cmd/32/searchdialog.png |binary
 icon-themes/elementary/cmd/lc_recsearch.png|binary
 icon-themes/elementary/cmd/lc_searchdialog.png |binary
 icon-themes/elementary/cmd/sc_recsearch.png|binary
 icon-themes/elementary/cmd/sc_searchdialog.png |binary
 icon-themes/elementary_svg/cmd/32/recsearch.svg|2 +-
 icon-themes/elementary_svg/cmd/32/searchdialog.svg |2 +-
 icon-themes/elementary_svg/cmd/lc_recsearch.svg|2 +-
 icon-themes/elementary_svg/cmd/lc_searchdialog.svg |2 +-
 icon-themes/elementary_svg/cmd/sc_recsearch.svg|5 +
 icon-themes/elementary_svg/cmd/sc_searchdialog.svg |2 +-
 12 files changed, 6 insertions(+), 9 deletions(-)

New commits:
commit a08e356e1afdf7d79d508570bec409436e237dbd
Author: Rizal Muttaqin 
AuthorDate: Sat Dec 19 07:20:51 2020 +0700
Commit: Rizal Muttaqin 
CommitDate: Sat Dec 19 04:14:42 2020 +0100

elementary: tdf#139047: redesign Find/Search and Find-Replace icons

Change-Id: I1c60c1a5789a577dafc531bb9e9c718ae30ebde5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107987
Tested-by: Jenkins
Reviewed-by: Rizal Muttaqin 

diff --git a/icon-themes/elementary/cmd/32/recsearch.png 
b/icon-themes/elementary/cmd/32/recsearch.png
index 083fd23b9fe9..eaca62bc31c2 100644
Binary files a/icon-themes/elementary/cmd/32/recsearch.png and 
b/icon-themes/elementary/cmd/32/recsearch.png differ
diff --git a/icon-themes/elementary/cmd/32/searchdialog.png 
b/icon-themes/elementary/cmd/32/searchdialog.png
index 84f1b2ce2964..a87d3d759cf4 100644
Binary files a/icon-themes/elementary/cmd/32/searchdialog.png and 
b/icon-themes/elementary/cmd/32/searchdialog.png differ
diff --git a/icon-themes/elementary/cmd/lc_recsearch.png 
b/icon-themes/elementary/cmd/lc_recsearch.png
index 526fe322e9ea..b166399be9b3 100644
Binary files a/icon-themes/elementary/cmd/lc_recsearch.png and 
b/icon-themes/elementary/cmd/lc_recsearch.png differ
diff --git a/icon-themes/elementary/cmd/lc_searchdialog.png 
b/icon-themes/elementary/cmd/lc_searchdialog.png
index 983a42df795f..4ad73e817971 100644
Binary files a/icon-themes/elementary/cmd/lc_searchdialog.png and 
b/icon-themes/elementary/cmd/lc_searchdialog.png differ
diff --git a/icon-themes/elementary/cmd/sc_recsearch.png 
b/icon-themes/elementary/cmd/sc_recsearch.png
index 40ce96f3a4cc..3c6b4d90aa62 100644
Binary files a/icon-themes/elementary/cmd/sc_recsearch.png and 
b/icon-themes/elementary/cmd/sc_recsearch.png differ
diff --git a/icon-themes/elementary/cmd/sc_searchdialog.png 
b/icon-themes/elementary/cmd/sc_searchdialog.png
index 1f97a4ba431f..b7bd5c164b51 100644
Binary files a/icon-themes/elementary/cmd/sc_searchdialog.png and 
b/icon-themes/elementary/cmd/sc_searchdialog.png differ
diff --git a/icon-themes/elementary_svg/cmd/32/recsearch.svg 
b/icon-themes/elementary_svg/cmd/32/recsearch.svg
index 78bc5793757a..ae61533af4a6 100644
--- a/icon-themes/elementary_svg/cmd/32/recsearch.svg
+++ b/icon-themes/elementary_svg/cmd/32/recsearch.svg
@@ -1 +1 @@
-http://www.w3.org/2000/svg"; 
xmlns:xlink="http://www.w3.org/1999/xlink";>
\ No newline at end of file
+http://www.w3.org/2000/svg"; 
xmlns:xlink="http://www.w3.org/1999/xlink";>
\ No newline at end of file
diff --git a/icon-themes/elementary_svg/cmd/32/searchdialog.svg 
b/icon-themes/elementary_svg/cmd/32/searchdialog.svg
index e1bfd78ae09f..0f1a7170251c 100644
--- a/icon-themes/elementary_svg/cmd/32/searchdialog.svg
+++ b/icon-themes/elementary_svg/cmd/32/searchdialog.svg
@@ -1 +1 @@
-http://www.w3.org/2000/svg"; 
xmlns:xlink="http://www.w3.org/1999/xlink";>
\ No newline at end of file
+http://www.w3.org/2000/svg"; 
xmlns:xlink="http://www.w3.org/1999/xlink";>
 
\ No newline at end of file
diff --git a/icon-themes/elementary_svg/cmd/lc_recsearch.svg 
b/icon-themes/elementary_svg/cmd/lc_recsearch.svg
index e751f3c81b13..14ddbe72ffe1 100644
--- a/icon-themes/elementary_svg/cmd/lc_recsearch.svg
+++ b/icon-themes/elementary_svg/cmd/lc_recsearch.svg
@@ -1 +1 @@
-http://www.w3.org/2000/svg"; 
xmlns:xlink="http://www.w3.org/1999/xlink";>
\ No newline at end of file
+http://www.w3.org/2000/svg"; 
xmlns:xlink="http://www.w3.org/1999/xlink";>
\ No newline at end of file
diff --git a/icon-themes/elementary_svg/cmd/lc_searchdialog.svg 
b/icon-themes/elementary_svg/cmd/lc_searchdialog.svg
index f5dd6058da5e..814e463f16bf 100644
--- a/icon-themes/elementary_svg/cmd/lc_searchdialog.svg
+++ b/icon-themes/elementary_svg/cmd/lc_searchdialog.svg
@@ -1 +1 @@
-http://www.w3.org/2000/svg"; 
xmlns:xlink="http://www.w3.org/1999/xlink";>
\ No newline at end of file
+http://www.w3.org/2000/svg"; 
xmlns:xlink="http://www.w3.org/1999/xlink";>stop-color="#d4d4d4"/>stop-color="#7e8087"/>gradientTransform="matrix(.4040235 -.4056919 .6073752 .6022679 -17.867764 
 >.693027)" gradientUnits="userSpaceOnUse" x1="30.037716" x2="30.037716" 
 >xlink:href="#k" y1="24.989594" y2="30.0

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

2020-12-18 Thread Chris Sherlock (via logerrit)
 vcl/qa/cppunit/BitmapTest.cxx |   35 ++-
 1 file changed, 34 insertions(+), 1 deletion(-)

New commits:
commit af05c3a9a7672c2233f7df7729736259f7b0f0dc
Author: Chris Sherlock 
AuthorDate: Fri Dec 18 16:08:11 2020 +1100
Commit: Tomaž Vajngerl 
CommitDate: Sat Dec 19 04:15:19 2020 +0100

vcl: add unit test for certain sizes of bitmaps to be dithered

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

diff --git a/vcl/qa/cppunit/BitmapTest.cxx b/vcl/qa/cppunit/BitmapTest.cxx
index 67f897cd9ef4..8a931df524eb 100644
--- a/vcl/qa/cppunit/BitmapTest.cxx
+++ b/vcl/qa/cppunit/BitmapTest.cxx
@@ -1,4 +1,3 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
 /*
  * This file is part of the LibreOffice project.
  *
@@ -46,6 +45,7 @@ class BitmapTest : public CppUnit::TestFixture
 void testBitmap32();
 void testOctree();
 void testEmptyAccess();
+void testDitherSize();
 
 CPPUNIT_TEST_SUITE(BitmapTest);
 CPPUNIT_TEST(testCreation);
@@ -61,6 +61,7 @@ class BitmapTest : public CppUnit::TestFixture
 CPPUNIT_TEST(testBitmap32);
 CPPUNIT_TEST(testOctree);
 CPPUNIT_TEST(testEmptyAccess);
+CPPUNIT_TEST(testDitherSize);
 CPPUNIT_TEST_SUITE_END();
 };
 
@@ -650,6 +651,38 @@ void BitmapTest::testEmptyAccess()
 CPPUNIT_ASSERT_EQUAL(tools::Long(0), access.Height());
 }
 
+void BitmapTest::testDitherSize()
+{
+// no need to do anything for a 1x1 pixel bitmap
+{
+Bitmap aBitmap(Size(1, 1), 24);
+CPPUNIT_ASSERT(aBitmap.Dither());
+}
+
+// cannot dither a bitmap with a width of 2 or 3 pixels
+{
+Bitmap aBitmap(Size(2, 4), 24);
+CPPUNIT_ASSERT(!aBitmap.Dither());
+}
+
+{
+Bitmap aBitmap(Size(3, 4), 24);
+CPPUNIT_ASSERT(!aBitmap.Dither());
+}
+
+// cannot dither a bitmap with a height of 2 pixels
+{
+Bitmap aBitmap(Size(4, 2), 24);
+CPPUNIT_ASSERT(!aBitmap.Dither());
+}
+
+// only dither bitmaps with a width > 3 pixels and height > 2 pixels
+{
+Bitmap aBitmap(Size(4, 3), 24);
+CPPUNIT_ASSERT(aBitmap.Dither());
+}
+}
+
 } // namespace
 
 CPPUNIT_TEST_SUITE_REGISTRATION(BitmapTest);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Chris Sherlock (via logerrit)
 vcl/source/gdi/bitmap3.cxx |   18 --
 1 file changed, 8 insertions(+), 10 deletions(-)

New commits:
commit f1469adf0e81e6e7c8aa650c95d9e7a93bb18e85
Author: Chris Sherlock 
AuthorDate: Fri Dec 18 15:32:27 2020 +1100
Commit: Tomaž Vajngerl 
CommitDate: Sat Dec 19 04:16:31 2020 +0100

vcl: remove bRet variable from Bitmap::Dither()

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

diff --git a/vcl/source/gdi/bitmap3.cxx b/vcl/source/gdi/bitmap3.cxx
index e037c0c38c99..cd7232ed1b82 100644
--- a/vcl/source/gdi/bitmap3.cxx
+++ b/vcl/source/gdi/bitmap3.cxx
@@ -847,8 +847,6 @@ bool Bitmap::Dither()
 if( aSize.Width() == 1 || aSize.Height() == 1 )
 return true;
 
-bool bRet = false;
-
 if( ( aSize.Width() > 3 ) && ( aSize.Height() > 2 ) )
 {
 ScopedReadAccess pReadAcc(*this);
@@ -964,14 +962,9 @@ bool Bitmap::Dither()
 pWriteAcc->SetPixelOnData( pScanline, nWidth1, 
BitmapColor(static_cast(nVCLBLut[ nBC ] + nVCLGLut[nGC ] + 
nVCLRLut[nRC ])) );
 }
 
-bRet = true;
-}
-
-pReadAcc.reset();
-pWriteAcc.reset();
+pReadAcc.reset();
+pWriteAcc.reset();
 
-if( bRet )
-{
 const MapMode aMap( maPrefMapMode );
 const Size aPrefSize( maPrefSize );
 
@@ -979,10 +972,15 @@ bool Bitmap::Dither()
 
 maPrefMapMode = aMap;
 maPrefSize = aPrefSize;
+
+return true;
 }
+
+pReadAcc.reset();
+pWriteAcc.reset();
 }
 
-return bRet;
+return false;
 }
 
 void Bitmap::Vectorize( GDIMetaFile& rMtf, sal_uInt8 cReduce, const 
Link* pProgress )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Chris Sherlock (via logerrit)
 include/vcl/bitmap.hxx |2 ++
 vcl/source/gdi/bitmap3.cxx |2 --
 vcl/source/gdi/gdimtf.cxx  |2 --
 3 files changed, 2 insertions(+), 4 deletions(-)

New commits:
commit 26f504eccfcfaa548f0648703925360e08d4a0c2
Author: Chris Sherlock 
AuthorDate: Fri Dec 18 15:47:59 2020 +1100
Commit: Tomaž Vajngerl 
CommitDate: Sat Dec 19 04:17:49 2020 +0100

vcl: move GAMMA define to bitmap.hxx

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

diff --git a/include/vcl/bitmap.hxx b/include/vcl/bitmap.hxx
index 810ece4e5286..ef27679bc9fc 100644
--- a/include/vcl/bitmap.hxx
+++ b/include/vcl/bitmap.hxx
@@ -30,6 +30,8 @@
 #include 
 #include 
 
+#define GAMMA( _def_cVal, _def_InvGamma )   
(static_cast(MinMax(FRound(pow( 
_def_cVal/255.0,_def_InvGamma)*255.0),0,255)))
+
 class Color;
 
 template  class Link;
diff --git a/vcl/source/gdi/bitmap3.cxx b/vcl/source/gdi/bitmap3.cxx
index cd7232ed1b82..6f760d0f1602 100644
--- a/vcl/source/gdi/bitmap3.cxx
+++ b/vcl/source/gdi/bitmap3.cxx
@@ -46,8 +46,6 @@
 
 #include 
 
-#define GAMMA( _def_cVal, _def_InvGamma )   
(static_cast(MinMax(FRound(pow( 
_def_cVal/255.0,_def_InvGamma)*255.0),0,255)))
-
 #define CALC_ERRORS
 \
 nTemp = p1T[nX++] >> 12;  \
 nBErr = MinMax( nTemp, 0, 255 );   
 \
diff --git a/vcl/source/gdi/gdimtf.cxx b/vcl/source/gdi/gdimtf.cxx
index 02f47b5c6bba..980d1170bc7e 100644
--- a/vcl/source/gdi/gdimtf.cxx
+++ b/vcl/source/gdi/gdimtf.cxx
@@ -49,8 +49,6 @@
 
 using namespace com::sun::star;
 
-#define GAMMA( _def_cVal, _def_InvGamma )   
(static_cast(MinMax(FRound(pow( 
_def_cVal/255.0,_def_InvGamma)*255.0),0,255)))
-
 namespace {
 
 struct ImplColAdjustParam
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Chris Sherlock (via logerrit)
 solenv/clang-format/excludelist |1 
 vcl/source/gdi/bitmap3.cxx  |  108 -
 vcl/source/gdi/floyd.hxx|  129 
 3 files changed, 131 insertions(+), 107 deletions(-)

New commits:
commit 9a575298bd4c704718084481cb57db93259eca68
Author: Chris Sherlock 
AuthorDate: Fri Dec 18 16:18:45 2020 +1100
Commit: Tomaž Vajngerl 
CommitDate: Sat Dec 19 04:19:27 2020 +0100

vcl: move Floyd-Steinberg constants and defines to own local header

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

diff --git a/solenv/clang-format/excludelist b/solenv/clang-format/excludelist
index 52aaffe7a504..1e5b10f9f73e 100644
--- a/solenv/clang-format/excludelist
+++ b/solenv/clang-format/excludelist
@@ -15012,6 +15012,7 @@ vcl/source/gdi/configsettings.cxx
 vcl/source/gdi/cvtgrf.cxx
 vcl/source/gdi/dibtools.cxx
 vcl/source/gdi/embeddedfontshelper.cxx
+vcl/source/gdi/floyd.hxx
 vcl/source/gdi/gdimetafiletools.cxx
 vcl/source/gdi/gdimtf.cxx
 vcl/source/gdi/gfxlink.cxx
diff --git a/vcl/source/gdi/bitmap3.cxx b/vcl/source/gdi/bitmap3.cxx
index 6f760d0f1602..aba33b41c754 100644
--- a/vcl/source/gdi/bitmap3.cxx
+++ b/vcl/source/gdi/bitmap3.cxx
@@ -42,39 +42,11 @@
 #include 
 #include 
 
+#include "floyd.hxx"
 #include "impvect.hxx"
 
 #include 
 
-#define CALC_ERRORS
 \
-nTemp = p1T[nX++] >> 12;  \
-nBErr = MinMax( nTemp, 0, 255 );   
 \
-nBErr = nBErr - FloydIndexMap[ nBC = FloydMap[nBErr] 
]; \
-nTemp = p1T[nX++] >> 12;  \
-nGErr = MinMax( nTemp, 0, 255 );   
 \
-nGErr = nGErr - FloydIndexMap[ nGC = FloydMap[nGErr] 
]; \
-nTemp = p1T[nX] >> 12;\
-nRErr = MinMax( nTemp, 0, 255 );   
 \
-nRErr = nRErr - FloydIndexMap[ nRC = FloydMap[nRErr] ];
-
-#define CALC_TABLES3\
-p2T[nX++] += FloydError3[nBErr];\
-p2T[nX++] += FloydError3[nGErr];\
-p2T[nX++] += FloydError3[nRErr];
-
-#define CALC_TABLES5\
-p2T[nX++] += FloydError5[nBErr];\
-p2T[nX++] += FloydError5[nGErr];\
-p2T[nX++] += FloydError5[nRErr];
-
-#define CALC_TABLES7\
-p1T[++nX] += FloydError7[nBErr];\
-p2T[nX++] += FloydError1[nBErr];\
-p1T[nX] += FloydError7[nGErr];  \
-p2T[nX++] += FloydError1[nGErr];\
-p1T[nX] += FloydError7[nRErr];  \
-p2T[nX] += FloydError1[nRErr];
-
 const extern sal_uLong nVCLRLut[ 6 ] = { 16, 17, 18, 19, 20, 21 };
 const extern sal_uLong nVCLGLut[ 6 ] = { 0, 6, 12, 18, 24, 30 };
 const extern sal_uLong nVCLBLut[ 6 ] = { 0, 36, 72, 108, 144, 180 };
@@ -143,84 +115,6 @@ const extern sal_uLong nVCLLut[ 256 ] =
 318928,320214,321500,322786,324072,325358,326644,327930
 };
 
-const tools::Long FloydMap[256] =
-{
-0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
-0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1,
-1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
-1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2,
-2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
-2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
-2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
-3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
-3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
-3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
-3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
-4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
-4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
-4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
-5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5
-};
-
-const tools::Long FloydError1[61] =
-{
--7680, -7424, -7168, -6912, -6656, -6400, -6144,
--5888, -5632, -5376, -5120, -4864, -4608, -4352,
--4096, -3840, -3584, -3328, -3072, -2816, -2560,
--2304, -2048, -1792, -1536, -1280, -1024, -768,
--512, -256, 0, 256, 512, 768, 1024, 1280, 1536,
-1792, 2048, 2304, 2560, 2816, 3072, 3328, 3584,
-3840, 4096, 4352, 4608, 4864, 5120, 5376, 5632,
-5888, 6144, 6400, 6656, 6912, 7168, 7424, 7680
-};
-
-const tools::Long FloydError3[61] =
-{
--23040, -22272, -21504, -20736, -19968

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

2020-12-18 Thread Chris Sherlock (via logerrit)
 vcl/source/gdi/bitmap3.cxx |   10 +-
 1 file changed, 5 insertions(+), 5 deletions(-)

New commits:
commit f0e1f861d537e95bafeb52e240d093e574aa2ee9
Author: Chris Sherlock 
AuthorDate: Fri Dec 18 16:30:54 2020 +1100
Commit: Tomaž Vajngerl 
CommitDate: Sat Dec 19 04:20:02 2020 +0100

vcl: move variables in Dither() closer to where they are used

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

diff --git a/vcl/source/gdi/bitmap3.cxx b/vcl/source/gdi/bitmap3.cxx
index aba33b41c754..293f1682e00c 100644
--- a/vcl/source/gdi/bitmap3.cxx
+++ b/vcl/source/gdi/bitmap3.cxx
@@ -751,18 +751,15 @@ bool Bitmap::Dither()
 tools::Long nWidth = pReadAcc->Width();
 tools::Long nWidth1 = nWidth - 1;
 tools::Long nHeight = pReadAcc->Height();
-tools::Long nX;
 tools::Long nW = nWidth * 3;
 tools::Long nW2 = nW - 3;
-tools::Long nRErr, nGErr, nBErr;
-tools::Long nRC, nGC, nBC;
 std::unique_ptr p1(new tools::Long[ nW ]);
 std::unique_ptr p2(new tools::Long[ nW ]);
 tools::Long* p1T = p1.get();
 tools::Long* p2T = p2.get();
 tools::Long* pTmp;
-bool bPal = pReadAcc->HasPalette();
 
+bool bPal = pReadAcc->HasPalette();
 pTmp = p2T;
 
 if( bPal )
@@ -790,6 +787,9 @@ bool Bitmap::Dither()
 }
 }
 
+tools::Long nRErr, nGErr, nBErr;
+tools::Long nRC, nGC, nBC;
+
 for( tools::Long nY = 1, nYAcc = 0; nY <= nHeight; nY++, nYAcc++ )
 {
 pTmp = p1T;
@@ -825,7 +825,7 @@ bool Bitmap::Dither()
 }
 
 // Examine first Pixel separately
-nX = 0;
+tools::Long nX = 0;
 tools::Long nTemp;
 CALC_ERRORS;
 CALC_TABLES7;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Chris Sherlock (via logerrit)
 vcl/source/gdi/bitmap3.cxx |   31 +++
 1 file changed, 11 insertions(+), 20 deletions(-)

New commits:
commit 0920491fef0f20cea19d31547589e66a0d0912d7
Author: Chris Sherlock 
AuthorDate: Fri Dec 18 17:27:59 2020 +1100
Commit: Tomaž Vajngerl 
CommitDate: Sat Dec 19 04:20:32 2020 +0100

vcl: refactor - new local function shiftColor()

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

diff --git a/vcl/source/gdi/bitmap3.cxx b/vcl/source/gdi/bitmap3.cxx
index 293f1682e00c..5c27100ef50a 100644
--- a/vcl/source/gdi/bitmap3.cxx
+++ b/vcl/source/gdi/bitmap3.cxx
@@ -732,6 +732,13 @@ void Bitmap::AdaptBitCount(Bitmap& rNew) const
 }
 }
 
+static void shiftColor(tools::Long* pColorArray, BitmapColor const& rColor)
+{
+*pColorArray++ = static_cast(rColor.GetBlue()) << 12;
+*pColorArray++ = static_cast(rColor.GetGreen()) << 12;
+*pColorArray++ = static_cast(rColor.GetRed()) << 12;
+}
+
 bool Bitmap::Dither()
 {
 const Size aSize( GetSizePixel() );
@@ -767,11 +774,7 @@ bool Bitmap::Dither()
 Scanline pScanlineRead = pReadAcc->GetScanline(0);
 for( tools::Long nZ = 0; nZ < nWidth; nZ++ )
 {
-aColor = pReadAcc->GetPaletteColor( 
pReadAcc->GetIndexFromData( pScanlineRead, nZ ) );
-
-*pTmp++ = static_cast(aColor.GetBlue()) << 12;
-*pTmp++ = static_cast(aColor.GetGreen()) << 
12;
-*pTmp++ = static_cast(aColor.GetRed()) << 12;
+shiftColor(pTmp, 
pReadAcc->GetPaletteColor(pReadAcc->GetIndexFromData(pScanlineRead, nZ)));
 }
 }
 else
@@ -779,11 +782,7 @@ bool Bitmap::Dither()
 Scanline pScanlineRead = pReadAcc->GetScanline(0);
 for( tools::Long nZ = 0; nZ < nWidth; nZ++ )
 {
-aColor = pReadAcc->GetPixelFromData( pScanlineRead, nZ );
-
-*pTmp++ = static_cast(aColor.GetBlue()) << 12;
-*pTmp++ = static_cast(aColor.GetGreen()) << 
12;
-*pTmp++ = static_cast(aColor.GetRed()) << 12;
+shiftColor(pTmp, pReadAcc->GetPixelFromData(pScanlineRead, 
nZ));
 }
 }
 
@@ -803,11 +802,7 @@ bool Bitmap::Dither()
 Scanline pScanlineRead = pReadAcc->GetScanline(nY);
 for( tools::Long nZ = 0; nZ < nWidth; nZ++ )
 {
-aColor = pReadAcc->GetPaletteColor( 
pReadAcc->GetIndexFromData( pScanlineRead, nZ ) );
-
-*pTmp++ = 
static_cast(aColor.GetBlue()) << 12;
-*pTmp++ = 
static_cast(aColor.GetGreen()) << 12;
-*pTmp++ = 
static_cast(aColor.GetRed()) << 12;
+shiftColor(pTmp, 
pReadAcc->GetPaletteColor(pReadAcc->GetIndexFromData(pScanlineRead, nZ)));
 }
 }
 else
@@ -815,11 +810,7 @@ bool Bitmap::Dither()
 Scanline pScanlineRead = pReadAcc->GetScanline(nY);
 for( tools::Long nZ = 0; nZ < nWidth; nZ++ )
 {
-aColor = pReadAcc->GetPixelFromData( 
pScanlineRead, nZ );
-
-*pTmp++ = 
static_cast(aColor.GetBlue()) << 12;
-*pTmp++ = 
static_cast(aColor.GetGreen()) << 12;
-*pTmp++ = 
static_cast(aColor.GetRed()) << 12;
+shiftColor(pTmp, 
pReadAcc->GetPixelFromData(pScanlineRead, nZ));
 }
 }
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Chris Sherlock (via logerrit)
 vcl/source/gdi/bitmap3.cxx |   26 ++
 1 file changed, 14 insertions(+), 12 deletions(-)

New commits:
commit 641d6c35f3494f7e62d5ca3089b1f0764cfeb0a8
Author: Chris Sherlock 
AuthorDate: Fri Dec 18 17:35:41 2020 +1100
Commit: Tomaž Vajngerl 
CommitDate: Sat Dec 19 04:21:23 2020 +0100

vcl: remove duplicate pScanlineRead assignment

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

diff --git a/vcl/source/gdi/bitmap3.cxx b/vcl/source/gdi/bitmap3.cxx
index 5c27100ef50a..a6c83bb52cc1 100644
--- a/vcl/source/gdi/bitmap3.cxx
+++ b/vcl/source/gdi/bitmap3.cxx
@@ -769,20 +769,22 @@ bool Bitmap::Dither()
 bool bPal = pReadAcc->HasPalette();
 pTmp = p2T;
 
-if( bPal )
 {
 Scanline pScanlineRead = pReadAcc->GetScanline(0);
-for( tools::Long nZ = 0; nZ < nWidth; nZ++ )
+
+if( bPal )
 {
-shiftColor(pTmp, 
pReadAcc->GetPaletteColor(pReadAcc->GetIndexFromData(pScanlineRead, nZ)));
+for (tools::Long nZ = 0; nZ < nWidth; nZ++)
+{
+shiftColor(pTmp, 
pReadAcc->GetPaletteColor(pReadAcc->GetIndexFromData(pScanlineRead, nZ)));
+}
 }
-}
-else
-{
-Scanline pScanlineRead = pReadAcc->GetScanline(0);
-for( tools::Long nZ = 0; nZ < nWidth; nZ++ )
+else
 {
-shiftColor(pTmp, pReadAcc->GetPixelFromData(pScanlineRead, 
nZ));
+for (tools::Long nZ = 0; nZ < nWidth; nZ++)
+{
+shiftColor(pTmp, 
pReadAcc->GetPixelFromData(pScanlineRead, nZ));
+}
 }
 }
 
@@ -795,11 +797,12 @@ bool Bitmap::Dither()
 p1T = p2T;
 p2T = pTmp;
 
-if( nY < nHeight )
+if (nY < nHeight)
 {
+Scanline pScanlineRead = pReadAcc->GetScanline(nY);
+
 if( bPal )
 {
-Scanline pScanlineRead = pReadAcc->GetScanline(nY);
 for( tools::Long nZ = 0; nZ < nWidth; nZ++ )
 {
 shiftColor(pTmp, 
pReadAcc->GetPaletteColor(pReadAcc->GetIndexFromData(pScanlineRead, nZ)));
@@ -807,7 +810,6 @@ bool Bitmap::Dither()
 }
 else
 {
-Scanline pScanlineRead = pReadAcc->GetScanline(nY);
 for( tools::Long nZ = 0; nZ < nWidth; nZ++ )
 {
 shiftColor(pTmp, 
pReadAcc->GetPixelFromData(pScanlineRead, nZ));
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Chris Sherlock (via logerrit)
 vcl/source/gdi/bitmap3.cxx |   49 +++--
 1 file changed, 17 insertions(+), 32 deletions(-)

New commits:
commit dfd69eb0ce4d1bb0442d65be2fcd8741fe9cb6ef
Author: Chris Sherlock 
AuthorDate: Fri Dec 18 17:55:54 2020 +1100
Commit: Tomaž Vajngerl 
CommitDate: Sat Dec 19 04:25:36 2020 +0100

vcl: refactor - new local function getColor()

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

diff --git a/vcl/source/gdi/bitmap3.cxx b/vcl/source/gdi/bitmap3.cxx
index a6c83bb52cc1..8f57aa3d958c 100644
--- a/vcl/source/gdi/bitmap3.cxx
+++ b/vcl/source/gdi/bitmap3.cxx
@@ -732,11 +732,23 @@ void Bitmap::AdaptBitCount(Bitmap& rNew) const
 }
 }
 
-static void shiftColor(tools::Long* pColorArray, BitmapColor const& rColor)
+static tools::Long* shiftColor(tools::Long* pColorArray, BitmapColor const& 
rColor)
 {
 *pColorArray++ = static_cast(rColor.GetBlue()) << 12;
 *pColorArray++ = static_cast(rColor.GetGreen()) << 12;
 *pColorArray++ = static_cast(rColor.GetRed()) << 12;
+
+return pColorArray;
+}
+
+static BitmapColor getColor(BitmapReadAccess *pReadAcc, tools::Long nZ)
+{
+Scanline pScanlineRead = pReadAcc->GetScanline(0);
+
+if (pReadAcc->HasPalette())
+return 
pReadAcc->GetPaletteColor(pReadAcc->GetIndexFromData(pScanlineRead, nZ));
+else
+return pReadAcc->GetPixelFromData(pScanlineRead, nZ);
 }
 
 bool Bitmap::Dither()
@@ -766,26 +778,11 @@ bool Bitmap::Dither()
 tools::Long* p2T = p2.get();
 tools::Long* pTmp;
 
-bool bPal = pReadAcc->HasPalette();
 pTmp = p2T;
 
+for (tools::Long nZ = 0; nZ < nWidth; nZ++)
 {
-Scanline pScanlineRead = pReadAcc->GetScanline(0);
-
-if( bPal )
-{
-for (tools::Long nZ = 0; nZ < nWidth; nZ++)
-{
-shiftColor(pTmp, 
pReadAcc->GetPaletteColor(pReadAcc->GetIndexFromData(pScanlineRead, nZ)));
-}
-}
-else
-{
-for (tools::Long nZ = 0; nZ < nWidth; nZ++)
-{
-shiftColor(pTmp, 
pReadAcc->GetPixelFromData(pScanlineRead, nZ));
-}
-}
+pTmp = shiftColor(pTmp, getColor(pReadAcc.get(), nZ));
 }
 
 tools::Long nRErr, nGErr, nBErr;
@@ -799,21 +796,9 @@ bool Bitmap::Dither()
 
 if (nY < nHeight)
 {
-Scanline pScanlineRead = pReadAcc->GetScanline(nY);
-
-if( bPal )
-{
-for( tools::Long nZ = 0; nZ < nWidth; nZ++ )
-{
-shiftColor(pTmp, 
pReadAcc->GetPaletteColor(pReadAcc->GetIndexFromData(pScanlineRead, nZ)));
-}
-}
-else
+for (tools::Long nZ = 0; nZ < nWidth; nZ++)
 {
-for( tools::Long nZ = 0; nZ < nWidth; nZ++ )
-{
-shiftColor(pTmp, 
pReadAcc->GetPixelFromData(pScanlineRead, nZ));
-}
+pTmp = shiftColor(pTmp, getColor(pReadAcc.get(), nZ));
 }
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: editeng/source include/editeng include/svl sc/inc sc/source sd/inc sd/source svl/source sw/source

2020-12-18 Thread Noel (via logerrit)
 editeng/source/uno/unoipset.cxx |2 +-
 editeng/source/uno/unotext.cxx  |2 +-
 include/editeng/unoipset.hxx|2 +-
 include/editeng/unotext.hxx |2 +-
 include/svl/itemprop.hxx|4 ++--
 sc/inc/optuno.hxx   |4 ++--
 sc/inc/styleuno.hxx |   10 +-
 sc/source/ui/unoobj/optuno.cxx  |4 ++--
 sc/source/ui/unoobj/styleuno.cxx|   18 +-
 sd/inc/stlsheet.hxx |2 +-
 sd/source/core/stlsheet.cxx |2 +-
 sd/source/ui/unoidl/unopback.cxx|2 +-
 sd/source/ui/unoidl/unopback.hxx|2 +-
 svl/source/items/itemprop.cxx   |6 +++---
 sw/source/core/unocore/unofield.cxx |2 +-
 15 files changed, 32 insertions(+), 32 deletions(-)

New commits:
commit 27d585cd2d0a0157896c4af11f2463f0197e3eb2
Author: Noel 
AuthorDate: Fri Dec 18 20:23:40 2020 +0200
Commit: Noel Grandin 
CommitDate: Sat Dec 19 08:02:56 2020 +0100

use more string_view in SfxItemPropertyMap

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

diff --git a/editeng/source/uno/unoipset.cxx b/editeng/source/uno/unoipset.cxx
index c9d54c83e972..523b29794461 100644
--- a/editeng/source/uno/unoipset.cxx
+++ b/editeng/source/uno/unoipset.cxx
@@ -246,7 +246,7 @@ void SvxItemPropertySet::setPropertyValue( const 
SfxItemPropertySimpleEntry* pMa
 }
 
 
-const SfxItemPropertySimpleEntry* 
SvxItemPropertySet::getPropertyMapEntry(const OUString &rName) const
+const SfxItemPropertySimpleEntry* 
SvxItemPropertySet::getPropertyMapEntry(std::u16string_view rName) const
 {
 return m_aPropertyMap.getByName( rName );
  }
diff --git a/editeng/source/uno/unotext.cxx b/editeng/source/uno/unotext.cxx
index 6761f8b8b622..9476ba7659c7 100644
--- a/editeng/source/uno/unotext.cxx
+++ b/editeng/source/uno/unotext.cxx
@@ -1017,7 +1017,7 @@ beans::PropertyState 
SvxUnoTextRangeBase::_getPropertyState(const SfxItemPropert
 throw beans::UnknownPropertyException();
 }
 
-beans::PropertyState SvxUnoTextRangeBase::_getPropertyState(const OUString& 
PropertyName, sal_Int32 nPara /* = -1 */)
+beans::PropertyState 
SvxUnoTextRangeBase::_getPropertyState(std::u16string_view PropertyName, 
sal_Int32 nPara /* = -1 */)
 {
 SolarMutexGuard aGuard;
 
diff --git a/include/editeng/unoipset.hxx b/include/editeng/unoipset.hxx
index c05ff656ee9c..0a4d8c2fe3ad 100644
--- a/include/editeng/unoipset.hxx
+++ b/include/editeng/unoipset.hxx
@@ -59,7 +59,7 @@ public:
 
 css::uno::Reference< css::beans::XPropertySetInfo > const & 
getPropertySetInfo() const;
 const SfxItemPropertyMap& getPropertyMap() const { return m_aPropertyMap;}
-const SfxItemPropertySimpleEntry* getPropertyMapEntry(const OUString 
&rName) const;
+const SfxItemPropertySimpleEntry* getPropertyMapEntry(std::u16string_view 
rName) const;
 };
 
 /** converts the given any with a metric to 100th/mm if needed */
diff --git a/include/editeng/unotext.hxx b/include/editeng/unotext.hxx
index 86841fbb0d56..a07a8cf059e1 100644
--- a/include/editeng/unotext.hxx
+++ b/include/editeng/unotext.hxx
@@ -274,7 +274,7 @@ protected:
 css::beans::PropertyState _getPropertyState( const 
SfxItemPropertySimpleEntry* pMap, sal_Int32 nPara = -1 );
 /// @throws css::beans::UnknownPropertyException
 /// @throws css::uno::RuntimeException
-css::beans::PropertyState _getPropertyState( const OUString& PropertyName, 
sal_Int32 nPara = -1 );
+css::beans::PropertyState _getPropertyState(  std::u16string_view 
PropertyName, sal_Int32 nPara = -1 );
 /// @throws css::beans::UnknownPropertyException
 /// @throws css::uno::RuntimeException
 css::uno::Sequence< css::beans::PropertyState > _getPropertyStates( const 
css::uno::Sequence< OUString >& aPropertyName, sal_Int32 nPara = -1  );
diff --git a/include/svl/itemprop.hxx b/include/svl/itemprop.hxx
index e985977f265a..67cedb7a64b6 100644
--- a/include/svl/itemprop.hxx
+++ b/include/svl/itemprop.hxx
@@ -124,11 +124,11 @@ public:
 SfxItemPropertyMap( const SfxItemPropertyMap& rSource );
 ~SfxItemPropertyMap();
 
-const SfxItemPropertySimpleEntry*  getByName( const OUString &rName ) 
const;
+const SfxItemPropertySimpleEntry*  getByName( std::u16string_view rName ) 
const;
 css::uno::Sequence< css::beans::Property > const & getProperties() const;
 /// @throws css::beans::UnknownPropertyException
 css::beans::Property getPropertyByName( const OUString & rName ) const;
-bool hasPropertyByName( const OUString& rName ) const;
+bool hasPropertyByName( std::u16string_view rName ) const;
 
 void mergeProperties( const css::uno::Sequence< css::beans::Property >& 
rPropSeq );
 PropertyEntryVector_t getPropertyEntries() const;
diff --git a/sc/inc/optuno.hxx b/sc/inc/optuno.hxx
index 35e7ad28e3d5..8ce6d9c149d1 100644
--- a/sc/inc/optuno.hxx
+++ 

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

2020-12-18 Thread Andras Timar (via logerrit)
 sc/uiconfig/scalc/ui/filterdropdown.ui |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 4ca7aee61825c586f54d9212aef2f28f355bec00
Author: Andras Timar 
AuthorDate: Sat Dec 19 00:29:12 2020 +0100
Commit: Andras Timar 
CommitDate: Sat Dec 19 08:26:12 2020 +0100

Set correct interface domain

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

diff --git a/sc/uiconfig/scalc/ui/filterdropdown.ui 
b/sc/uiconfig/scalc/ui/filterdropdown.ui
index 5956073fbed1..21e4f99edc3f 100644
--- a/sc/uiconfig/scalc/ui/filterdropdown.ui
+++ b/sc/uiconfig/scalc/ui/filterdropdown.ui
@@ -1,6 +1,6 @@
 
 
-
+
   
   
 True
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2020-12-18 Thread Seth Chaiklin (via logerrit)
 sfx2/uiconfig/ui/saveastemplatedlg.ui |6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

New commits:
commit 817c22456408b3d8af022be85c9734989604deb5
Author: Seth Chaiklin 
AuthorDate: Thu Dec 17 14:58:12 2020 +0100
Commit: Heiko Tietze 
CommitDate: Sat Dec 19 08:49:46 2020 +0100

add tooltips and improve labels to Save as Template dialog

   Add action verbs to labels and colon (because they have a buddy control)

Change-Id: I90602587425993c91bbb75ecd66f7e40181e01b3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107813
Tested-by: Jenkins
Reviewed-by: Seth Chaiklin 
Reviewed-by: Heiko Tietze 

diff --git a/sfx2/uiconfig/ui/saveastemplatedlg.ui 
b/sfx2/uiconfig/ui/saveastemplatedlg.ui
index 980878d8336b..0a5fdda665c6 100644
--- a/sfx2/uiconfig/ui/saveastemplatedlg.ui
+++ b/sfx2/uiconfig/ui/saveastemplatedlg.ui
@@ -99,7 +99,8 @@
   
 True
 False
-Template _Name
+Enter Template _Name:
+Enter a name for the 
template.
 True
 name_entry
 0
@@ -149,7 +150,8 @@
   
 True
 False
-Template _Category
+Select Template _Category:
+Save template in selected 
category.
 True
 categorylb
 0
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits