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

2021-11-17 Thread Vasily Melenchuk (via logerrit)
 sw/qa/extras/ooxmlexport/data/tdf81507.docx  |binary
 sw/qa/extras/ooxmlexport/ooxmlexport17.cxx   |   22 ++
 sw/source/filter/ww8/docxattributeoutput.cxx |   58 ---
 sw/source/filter/ww8/docxattributeoutput.hxx |3 +
 writerfilter/source/dmapper/DomainMapper.cxx |3 +
 writerfilter/source/ooxml/model.xml  |5 +-
 6 files changed, 84 insertions(+), 7 deletions(-)

New commits:
commit 75a49947c2eeb831a8e02192f1c4856eac62a743
Author: Vasily Melenchuk 
AuthorDate: Thu Nov 11 10:39:32 2021 +0300
Commit: Thorsten Behrens 
CommitDate: Thu Nov 18 08:42:43 2021 +0100

tdf#81507: word content control support for w:multiLine

 is now supported for import/export
to DOCX. Like other content control items it is stored in
grabbag.

Change-Id: Id6f1aa0072dc5db980d0fa43cab4b38a0aa047fc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125024
Tested-by: Jenkins
Reviewed-by: Thorsten Behrens 

diff --git a/sw/qa/extras/ooxmlexport/data/tdf81507.docx 
b/sw/qa/extras/ooxmlexport/data/tdf81507.docx
new file mode 100644
index ..2c00ee44cb24
Binary files /dev/null and b/sw/qa/extras/ooxmlexport/data/tdf81507.docx differ
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport17.cxx 
b/sw/qa/extras/ooxmlexport/ooxmlexport17.cxx
index 36555f71a671..0a7879269a75 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport17.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport17.cxx
@@ -115,6 +115,28 @@ DECLARE_OOXMLEXPORT_TEST(testTdf142407, "tdf142407.docx")
 CPPUNIT_ASSERT_EQUAL( sal_Int16(36), nGridLines);   // was 23, left large 
space before text.
 }
 
+DECLARE_OOXMLEXPORT_TEST(testTdf81507, "tdf81507.docx")
+{
+xmlDocUniquePtr pXmlDoc = parseExport("word/document.xml");
+if (!pXmlDoc)
+   return; // initial import, no futher checks
+
+// Ensure that we have 
+CPPUNIT_ASSERT_EQUAL(OUString("1"), getXPath(pXmlDoc, 
"/w:document/w:body/w:sdt[1]/w:sdtPr/w:text", "multiLine"));
+
+// Ensure that we have 
+CPPUNIT_ASSERT_EQUAL(OUString("0"), getXPath(pXmlDoc, 
"/w:document/w:body/w:sdt[2]/w:sdtPr/w:text", "multiLine"));
+
+// Ensure that we have 
+getXPath(pXmlDoc, "/w:document/w:body/w:sdt[3]/w:sdtPr/w:text", "");
+
+// Ensure that we have no  (not quite correct case, but to ensure 
import/export are okay)
+xmlXPathObjectPtr pXmlObj = getXPathNode(pXmlDoc, 
"/w:document/w:body/w:sdt[4]/w:sdtPr/w:text");
+CPPUNIT_ASSERT_EQUAL(sal_Int32(0),
+   
static_cast(xmlXPathNodeSetGetLength(pXmlObj->nodesetval)));
+xmlXPathFreeObject(pXmlObj);
+}
+
 DECLARE_OOXMLEXPORT_TEST(testTdf144668, "tdf144668.odt")
 {
 uno::Reference xPara1(getParagraph(1, u"level1"), 
uno::UNO_QUERY);
diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx 
b/sw/source/filter/ww8/docxattributeoutput.cxx
index 4d49f2bf95a8..9dee5cbf5a5a 100644
--- a/sw/source/filter/ww8/docxattributeoutput.cxx
+++ b/sw/source/filter/ww8/docxattributeoutput.cxx
@@ -583,12 +583,18 @@ static OString convertToOOXMLHoriOrientRel(sal_Int16 
nOrientRel)
 }
 }
 
-static void lcl_deleteAndResetTheLists( 
rtl::Reference& pSdtPrTokenChildren, 
rtl::Reference& pSdtPrDataBindingAttrs, 
OUString& rSdtPrAlias)
+static void lcl_deleteAndResetTheLists(
+rtl::Reference& pSdtPrTokenChildren,
+rtl::Reference& pSdtPrDataBindingAttrs,
+rtl::Reference& pSdtPrTextAttrs,
+OUString& rSdtPrAlias)
 {
 if( pSdtPrTokenChildren.is() )
 pSdtPrTokenChildren.clear();
 if( pSdtPrDataBindingAttrs.is() )
 pSdtPrDataBindingAttrs.clear();
+if (pSdtPrTextAttrs.is())
+pSdtPrTextAttrs.clear();
 if (!rSdtPrAlias.isEmpty())
 rSdtPrAlias.clear();
 }
@@ -797,14 +803,14 @@ void DocxAttributeOutput::EndParagraph( 
ww8::WW8TableNodeInfoInner::Pointer_t pT
 m_pSerializer->endElementNS( XML_w, XML_p );
 // on export sdt blocks are never nested ATM
 if( !m_bAnchorLinkedToNode && !m_bStartedParaSdt )
-WriteSdtBlock( m_nParagraphSdtPrToken, m_pParagraphSdtPrTokenChildren, 
m_pParagraphSdtPrTokenAttributes, m_pParagraphSdtPrDataBindingAttrs, 
m_aParagraphSdtPrAlias, /*bPara=*/true );
+WriteSdtBlock( m_nParagraphSdtPrToken, m_pParagraphSdtPrTokenChildren, 
m_pParagraphSdtPrTokenAttributes, m_pParagraphSdtPrDataBindingAttrs, 
m_pParagraphSdtPrTextAttrs, m_aParagraphSdtPrAlias, /*bPara=*/true );
 else
 {
 //These should be written out to the actual Node and not to the anchor.
 //Clear them as they will be repopulated when the node is processed.
 m_nParagraphSdtPrToken = 0;
 m_bParagraphSdtHasId = false;
-lcl_deleteAndResetTheLists( m_pParagraphSdtPrTokenChildren, 
m_pParagraphSdtPrDataBindingAttrs, m_aParagraphSdtPrAlias );
+lcl_deleteAndResetTheLists( m_pParagraphSdtPrTokenChildren, 
m_pParagraphSdtPrDataBindingAttrs, m_pParagraphSdtPrTextAttrs, 
m_aParagraphSdtPrAlias );
 }
 
 m_pSerializer->mark(Tag_StartParag

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

2021-11-17 Thread Vasily Melenchuk (via logerrit)
 sw/qa/uitest/data/tdf145215.docx |binary
 sw/qa/uitest/writer_tests5/tdf145215.py  |   24 +++
 writerfilter/source/dmapper/NumberingManager.cxx |9 
 3 files changed, 24 insertions(+), 9 deletions(-)

New commits:
commit 43f8051986042a2c7943c716e764f4cfdd81723c
Author: Vasily Melenchuk 
AuthorDate: Sat Oct 23 11:48:07 2021 +0200
Commit: Thorsten Behrens 
CommitDate: Thu Nov 18 08:12:43 2021 +0100

tdf#145215: docx: do not initialize prefix/suffix and include levels

On DOCX import we do not need to provide prefix, suffix and included
levels: these values are calculated in SvxNumberFormat out from list
format. Moreover these values are incorrect and do not correspond
not to DOCX data nor to internal writer representation of list level.

For 7.2 backport testcase was stripped: original testcase relies
on tdf#141964 changes not backproted to 7.2. Thus for test doc
"Chapter Numbering" dialog still looks weird.

Change-Id: I91ec9de679e67056ba3746f2e1a0bd923532d76c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124090
Tested-by: Jenkins
Reviewed-by: Vasily Melenchuk 
Signed-off-by: Xisco Fauli 
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124136
Reviewed-by: Thorsten Behrens 

diff --git a/sw/qa/uitest/data/tdf145215.docx b/sw/qa/uitest/data/tdf145215.docx
new file mode 100644
index ..b91d13b286c8
Binary files /dev/null and b/sw/qa/uitest/data/tdf145215.docx differ
diff --git a/sw/qa/uitest/writer_tests5/tdf145215.py 
b/sw/qa/uitest/writer_tests5/tdf145215.py
new file mode 100644
index ..479e7f009e58
--- /dev/null
+++ b/sw/qa/uitest/writer_tests5/tdf145215.py
@@ -0,0 +1,24 @@
+# -*- tab-width: 4; indent-tabs-mode: nil; py-indent-offset: 4 -*-
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+#
+
+from uitest.framework import UITestCase
+from uitest.uihelper.common import get_url_for_data_file, get_state_as_dict
+
+class Tdf145215(UITestCase):
+
+def test_tdf145215(self):
+writer_doc = 
self.ui_test.load_file(get_url_for_data_file("tdf145215.docx"))
+
+# Check field value (there is only one field)
+textfields = writer_doc.getTextFields()
+textfields.refresh()
+for textfield in textfields:
+
self.assertTrue(textfield.supportsService("com.sun.star.text.TextField.GetReference"))
+self.assertEqual(textfield.CurrentPresentation, "1.2.1(i)")
+
+self.ui_test.close_doc()
+# vim: set shiftwidth=4 softtabstop=4 expandtab:
diff --git a/writerfilter/source/dmapper/NumberingManager.cxx 
b/writerfilter/source/dmapper/NumberingManager.cxx
index 9a3f372d7161..6b2d118a2464 100644
--- a/writerfilter/source/dmapper/NumberingManager.cxx
+++ b/writerfilter/source/dmapper/NumberingManager.cxx
@@ -548,8 +548,6 @@ void ListDef::CreateNumberingRules( DomainMapper& rDMapper,
 
aLvlProps.push_back(comphelper::makePropertyValue(getPropertyName(PROP_CHAR_STYLE_NAME),
 sStyle));
 }
 
-// Get the prefix / suffix / Parent numbering
-// and add them to the level properties
 OUString sText = pAbsLevel
? pAbsLevel->GetBulletChar()
: OUString();
@@ -557,15 +555,8 @@ void ListDef::CreateNumberingRules( DomainMapper& rDMapper,
 if (pLevel && pLevel->HasBulletChar())
 sText = pLevel->GetBulletChar( );
 
-
aLvlProps.push_back(comphelper::makePropertyValue(getPropertyName(PROP_PREFIX), 
OUString("")));
-
aLvlProps.push_back(comphelper::makePropertyValue(getPropertyName(PROP_SUFFIX), 
OUString("")));
 
aLvlProps.push_back(comphelper::makePropertyValue(getPropertyName(PROP_LIST_FORMAT),
 sText));
 
-// Total count of replacement holders is determining amount of 
required parent numbering to include
-// TODO: not sure how "%" symbol is escaped. This is not supported 
yet
-sal_Int16 nParentNum = comphelper::string::getTokenCount(sText, 
'%');
-
aLvlProps.push_back(comphelper::makePropertyValue(getPropertyName(PROP_PARENT_NUMBERING),
 nParentNum));
-
 
aLvlProps.push_back(comphelper::makePropertyValue(getPropertyName(PROP_POSITION_AND_SPACE_MODE),
 sal_Int16(text::PositionAndSpaceMode::LABEL_ALIGNMENT)));
 
 // Replace the numbering rules for the level


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

2021-11-17 Thread Miklos Vajna (via logerrit)
 sw/source/uibase/docvw/edtwin.cxx |9 -
 1 file changed, 9 deletions(-)

New commits:
commit 1d80f90afb479227044bdf0876c5576007abfdce
Author: Miklos Vajna 
AuthorDate: Wed Nov 17 20:06:53 2021 +0100
Commit: Miklos Vajna 
CommitDate: Thu Nov 18 08:09:54 2021 +0100

sw: remove useless debug code in SwEditWin

The IsCursorInProtectedArea user pref flag can already toggle this, so
this is not needed.

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

diff --git a/sw/source/uibase/docvw/edtwin.cxx 
b/sw/source/uibase/docvw/edtwin.cxx
index b38b0a521326..52022b1a465a 100644
--- a/sw/source/uibase/docvw/edtwin.cxx
+++ b/sw/source/uibase/docvw/edtwin.cxx
@@ -1627,15 +1627,6 @@ void SwEditWin::KeyInput(const KeyEvent &rKEvt)
 case SwKeyState::CheckKey:
 eKeyState = SwKeyState::KeyToView;   // default forward to View
 
-#if OSL_DEBUG_LEVEL > 1
-//
-// for switching cursor behaviour in ReadOnly regions
-if( 0x7210 == rKeyCode.GetFullCode() )
-rSh.SetReadOnlyAvailable( !rSh.IsReadOnlyAvailable() );
-else
-//
-#endif
-
 if (!comphelper::LibreOfficeKit::isActive() &&
 !rKeyCode.IsMod2() && '=' == aCh &&
 !rSh.IsTableMode() && rSh.GetTableFormat() &&


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

2021-11-17 Thread Sarper Akdemir (via logerrit)
 include/oox/drawingml/color.hxx  |1 +
 oox/source/drawingml/color.cxx   |   16 
 oox/source/drawingml/textcharacterproperties.cxx |1 +
 3 files changed, 18 insertions(+)

New commits:
commit 3ed69deb04cca67e377c15956679f7bb9794e4ff
Author: Sarper Akdemir 
AuthorDate: Wed Aug 25 02:24:42 2021 +0300
Commit: Miklos Vajna 
CommitDate: Thu Nov 18 08:08:14 2021 +0100

implement color tint or shade import for pptx

[ Miklos: althought the PowerPoint UI doesn't seem to have a way to
generate this markup. ]

(cherry picked from commit de40c940c3a94588d44a3d1f6d8cd4191cca4f73)

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

diff --git a/include/oox/drawingml/color.hxx b/include/oox/drawingml/color.hxx
index 00473cfe6f27..bd67982c6e92 100644
--- a/include/oox/drawingml/color.hxx
+++ b/include/oox/drawingml/color.hxx
@@ -99,6 +99,7 @@ public:
 /** Returns the scheme name from the a:schemeClr element for 
interoperability purposes */
 const OUString& getSchemeColorName() const { return msSchemeName; }
 sal_Int16   getSchemeColorIndex() const;
+sal_Int16   getTintOrShade();
 
 /** Returns the unaltered list of transformations for interoperability 
purposes */
 const css::uno::Sequence< css::beans::PropertyValue >& 
getTransformations() const { return maInteropTransformations;}
diff --git a/oox/source/drawingml/color.cxx b/oox/source/drawingml/color.cxx
index 2ced5345904e..426197102160 100644
--- a/oox/source/drawingml/color.cxx
+++ b/oox/source/drawingml/color.cxx
@@ -479,6 +479,22 @@ void Color::clearTransparence()
 mnAlpha = MAX_PERCENT;
 }
 
+sal_Int16 Color::getTintOrShade()
+{
+for(auto const& aTransform : maTransforms)
+{
+switch(aTransform.mnToken)
+{
+case XML_tint:
+// from 1000th percent to 100th percent...
+return aTransform.mnValue/10;
+case XML_shade:
+// from 1000th percent to 100th percent...
+return -aTransform.mnValue/10;
+}
+}
+return 0;
+}
 ::Color Color::getColor( const GraphicHelper& rGraphicHelper, ::Color nPhClr ) 
const
 {
 const sal_Int32 nTempC1 = mnC1;
diff --git a/oox/source/drawingml/textcharacterproperties.cxx 
b/oox/source/drawingml/textcharacterproperties.cxx
index 90b0e38c1d3a..bd4d051a490b 100644
--- a/oox/source/drawingml/textcharacterproperties.cxx
+++ b/oox/source/drawingml/textcharacterproperties.cxx
@@ -113,6 +113,7 @@ void TextCharacterProperties::pushToPropMap( PropertyMap& 
rPropMap, const XmlFil
 rPropMap.setProperty(PROP_CharColor, 
aColor.getColor(rFilter.getGraphicHelper()));
 // set color theme index
 rPropMap.setProperty(PROP_CharColorTheme, 
aColor.getSchemeColorIndex());
+rPropMap.setProperty(PROP_CharColorTintOrShade, 
aColor.getTintOrShade());
 
 if (aColor.hasTransparency())
 {


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

2021-11-17 Thread Luboš Luňák (via logerrit)
 vcl/skia/gdiimpl.cxx |   47 ++-
 1 file changed, 22 insertions(+), 25 deletions(-)

New commits:
commit 5e6e45eb4247bf8bd57d157b44f49577dde38716
Author: Luboš Luňák 
AuthorDate: Wed Nov 17 16:35:31 2021 +0100
Commit: Luboš Luňák 
CommitDate: Thu Nov 18 08:01:12 2021 +0100

handle also curved lines for nojoin skia polylines (tdf#143837)

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

diff --git a/vcl/skia/gdiimpl.cxx b/vcl/skia/gdiimpl.cxx
index 6a01601662a4..f15954f95117 100644
--- a/vcl/skia/gdiimpl.cxx
+++ b/vcl/skia/gdiimpl.cxx
@@ -55,33 +55,28 @@ namespace
 // bottom-most line of pixels of the bounding rectangle (see
 // 
https://lists.freedesktop.org/archives/libreoffice/2019-November/083709.html).
 // So be careful with rectangle->polygon conversions (generally avoid them).
-void addPolygonToPath(const basegfx::B2DPolygon& rPolygon, SkPath& rPath,
-  bool* hasOnlyOrthogonal = nullptr)
+void addPolygonToPath(const basegfx::B2DPolygon& rPolygon, SkPath& rPath, 
sal_uInt32 nFirstIndex,
+  sal_uInt32 nLastIndex, const sal_uInt32 nPointCount, 
const bool bClosePath,
+  const bool bHasCurves, bool* hasOnlyOrthogonal = nullptr)
 {
-const sal_uInt32 nPointCount(rPolygon.count());
+assert(nFirstIndex < nPointCount);
+assert(nLastIndex <= nPointCount);
 
 if (nPointCount <= 1)
 return;
 
-const bool bClosePath(rPolygon.isClosed());
-const bool bHasCurves(rPolygon.areControlPointsUsed());
-
 bool bFirst = true;
+sal_uInt32 nPreviousIndex = nFirstIndex == 0 ? nPointCount - 1 : 
nFirstIndex - 1;
+basegfx::B2DPoint aPreviousPoint = rPolygon.getB2DPoint(nPreviousIndex);
 
-sal_uInt32 nCurrentIndex = 0;
-sal_uInt32 nPreviousIndex = nPointCount - 1;
-
-basegfx::B2DPoint aCurrentPoint;
-basegfx::B2DPoint aPreviousPoint;
-
-for (sal_uInt32 nIndex = 0; nIndex <= nPointCount; nIndex++)
+for (sal_uInt32 nIndex = nFirstIndex; nIndex <= nLastIndex; nIndex++)
 {
 if (nIndex == nPointCount && !bClosePath)
 continue;
 
 // Make sure we loop the last point to first point
-nCurrentIndex = nIndex % nPointCount;
-aCurrentPoint = rPolygon.getB2DPoint(nCurrentIndex);
+sal_uInt32 nCurrentIndex = nIndex % nPointCount;
+basegfx::B2DPoint aCurrentPoint = rPolygon.getB2DPoint(nCurrentIndex);
 
 if (bFirst)
 {
@@ -132,12 +127,19 @@ void addPolygonToPath(const basegfx::B2DPolygon& 
rPolygon, SkPath& rPath,
 aPreviousPoint = aCurrentPoint;
 nPreviousIndex = nCurrentIndex;
 }
-if (bClosePath)
+if (bClosePath && nFirstIndex == 0 && nLastIndex == nPointCount)
 {
 rPath.close();
 }
 }
 
+void addPolygonToPath(const basegfx::B2DPolygon& rPolygon, SkPath& rPath,
+  bool* hasOnlyOrthogonal = nullptr)
+{
+addPolygonToPath(rPolygon, rPath, 0, rPolygon.count(), rPolygon.count(), 
rPolygon.isClosed(),
+ rPolygon.areControlPointsUsed(), hasOnlyOrthogonal);
+}
+
 void addPolyPolygonToPath(const basegfx::B2DPolyPolygon& rPolyPolygon, SkPath& 
rPath,
   bool* hasOnlyOrthogonal = nullptr)
 {
@@ -1246,7 +1248,6 @@ bool SkiaSalGraphicsImpl::drawPolyLine(const 
basegfx::B2DHomMatrix& rObjectToDev
 {
 SkPath aPath;
 aPath.incReserve(aPolyLine.count() * 3); // because cubicTo is 3 
elements
-aPath.setFillType(SkPathFillType::kEvenOdd);
 addPolygonToPath(aPolyLine, aPath);
 aPath.offset(toSkX(0) + posFix, toSkY(0) + posFix, nullptr);
 addUpdateRegion(aPath.getBounds());
@@ -1256,16 +1257,12 @@ bool SkiaSalGraphicsImpl::drawPolyLine(const 
basegfx::B2DHomMatrix& rObjectToDev
 {
 sal_uInt32 nPoints = aPolyLine.count();
 bool bClosed = aPolyLine.isClosed();
-for (sal_uInt32 j = 0; j < (bClosed ? nPoints : nPoints - 1); ++j)
+bool bHasCurves = aPolyLine.areControlPointsUsed();
+for (sal_uInt32 j = 0; j < nPoints; ++j)
 {
-sal_uInt32 index1 = (j + 0) % nPoints;
-sal_uInt32 index2 = (j + 1) % nPoints;
 SkPath aPath;
-aPath.moveTo(aPolyLine.getB2DPoint(index1).getX(),
- aPolyLine.getB2DPoint(index1).getY());
-aPath.lineTo(aPolyLine.getB2DPoint(index2).getX(),
- aPolyLine.getB2DPoint(index2).getY());
-
+aPath.incReserve(2 * 3); // because cubicTo is 3 elements
+addPolygonToPath(aPolyLine, aPath, j, j + 1, nPoints, bClosed, 
bHasCurves);
 aPath.offset(toSkX(0) + posFix, toSkY(0) + posFix, nullptr);
 addUpdateRegion(aPath.getBounds());
 getDrawCanvas()->drawPath(aPath, aPaint);


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

2021-11-17 Thread Heiko Tietze (via logerrit)
 basctl/source/basicide/linenumberwindow.cxx |4 +++-
 basctl/source/basicide/linenumberwindow.hxx |1 +
 2 files changed, 4 insertions(+), 1 deletion(-)

New commits:
commit f0334d62da608e140073e8831fdbbd0b5e4b1e39
Author: Heiko Tietze 
AuthorDate: Wed Nov 17 15:38:02 2021 +0100
Commit: Heiko Tietze 
CommitDate: Thu Nov 18 07:02:26 2021 +0100

Resolves tdf#143462 - Fixes black row number on dark backgroud in Basic IDE

Using WindowColor for background and WindowTextColor for font color now

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

diff --git a/basctl/source/basicide/linenumberwindow.cxx 
b/basctl/source/basicide/linenumberwindow.cxx
index be9fe3752045..7dcbff0ddd7f 100644
--- a/basctl/source/basicide/linenumberwindow.cxx
+++ b/basctl/source/basicide/linenumberwindow.cxx
@@ -21,7 +21,8 @@ LineNumberWindow::LineNumberWindow(vcl::Window* pParent, 
ModulWindow* pModulWind
 , m_pModulWindow(pModulWindow)
 , m_nCurYOffset(0)
 {
-SetBackground(Wallpaper(GetSettings().GetStyleSettings().GetFieldColor()));
+
SetBackground(Wallpaper(GetSettings().GetStyleSettings().GetWindowColor()));
+m_FontColor = GetSettings().GetStyleSettings().GetWindowTextColor();
 m_nBaseWidth = GetTextWidth("8");
 m_nWidth = m_nBaseWidth * 3 + m_nBaseWidth / 2;
 }
@@ -78,6 +79,7 @@ void LineNumberWindow::Paint(vcl::RenderContext& 
rRenderContext, const tools::Re
 }
 
 sal_Int64 y = (nStartLine - 1) * static_cast(nLineHeight);
+rRenderContext.SetTextColor(m_FontColor);
 for (sal_uInt32 n = nStartLine; n <= nEndLine; ++n, y += nLineHeight)
 rRenderContext.DrawText(Point(0, y - m_nCurYOffset), 
OUString::number(n));
 }
diff --git a/basctl/source/basicide/linenumberwindow.hxx 
b/basctl/source/basicide/linenumberwindow.hxx
index 14305116ef10..a2e457f71103 100644
--- a/basctl/source/basicide/linenumberwindow.hxx
+++ b/basctl/source/basicide/linenumberwindow.hxx
@@ -22,6 +22,7 @@ private:
 int m_nWidth;
 tools::Long m_nCurYOffset;
 int m_nBaseWidth;
+Color m_FontColor;
 virtual void DataChanged(DataChangedEvent const& rDCEvt) override;
 
 protected:


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

2021-11-17 Thread Jim Raykowski (via logerrit)
 sw/source/uibase/utlui/content.cxx |  196 -
 1 file changed, 111 insertions(+), 85 deletions(-)

New commits:
commit 4be0ae19065b1b50870bc0b2a28189ad39c96a8a
Author: Jim Raykowski 
AuthorDate: Sat Nov 13 18:27:01 2021 -0900
Commit: Jim Raykowski 
CommitDate: Thu Nov 18 00:40:40 2021 +0100

SwNavigator: Improve which entry is selected in the content tree

after the tree is updated and when current document cursor position is
at content that is set to not track

Intended behavior when the content tree display is updated is for the
selected entry before update to be reselected after update if the entry
is still in the tree. Currently, if the selected entry before update is
a content type, the selected entry after update is the first entry in
the tree. If the selected entry before update is not present, e.g. the
selected entry is the only member of a content type and is deleted, the
first entry in the tree is selected. In these cases, this patch changes
the selected entry after update to be the content type entry.

Instead of reselecting by entry name, which can result in incorrect
selection when non unique entry names are possible, as in Headings,
this patch improves entry reselect by comparing unique entry user data.

Content tracking is improved by not falling through to other tracked
content, e.g. when tables are not being tracked and sections are being
tracked, clicking in a table in a section will not select the section
in the content tree, the selected entry in the content tree will be
unchanged.

Change-Id: I8d82059db8688c31c7c0d705445c1d8b4272bec6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125176
Tested-by: Jenkins
Reviewed-by: Jim Raykowski 

diff --git a/sw/source/uibase/utlui/content.cxx 
b/sw/source/uibase/utlui/content.cxx
index 19af01d363a8..2227cb04f4c8 100644
--- a/sw/source/uibase/utlui/content.cxx
+++ b/sw/source/uibase/utlui/content.cxx
@@ -2365,16 +2365,15 @@ void SwContentTree::Display( bool bActive )
 std::unique_ptr xOldSelEntry(m_xTreeView->make_iterator());
 if (!m_xTreeView->get_selected(xOldSelEntry.get()))
 xOldSelEntry.reset();
-OUString sEntryName;  // Name of the entry
+OUString sOldSelEntryId;
 size_t nEntryRelPos = 0; // relative position to their parent
 size_t nOldEntryCount = GetEntryCount();
 sal_Int32 nOldScrollPos = 0;
 if (xOldSelEntry)
 {
 UpdateLastSelType();
-
+sOldSelEntryId = m_xTreeView->get_id(*xOldSelEntry);
 nOldScrollPos = m_xTreeView->vadjustment_get_value();
-sEntryName = m_xTreeView->get_text(*xOldSelEntry);
 std::unique_ptr xParentEntry = 
m_xTreeView->make_iterator(xOldSelEntry.get());
 while (m_xTreeView->get_iter_depth(*xParentEntry))
 m_xTreeView->iter_parent(*xParentEntry);
@@ -2447,40 +2446,44 @@ void SwContentTree::Display( bool bActive )
 for (const auto& rNode : aNodesToExpand)
 m_xTreeView->expand_row(*rNode);
 
-(void)m_xTreeView->get_iter_first(*xEntry);
-for (ContentTypeId nCntType : o3tl::enumrange())
+// reselect the old selected entry if it is available, else select 
the entry that is at
+// the position of the old selected entry
+if (xOldSelEntry)
 {
-sal_Int32 nExpandOptions = (State::HIDDEN == m_eState)
-? m_nHiddenBlock
-: m_nActiveBlock;
-if (nExpandOptions & (1 << static_cast(nCntType)))
+(void)m_xTreeView->get_iter_first(*xEntry);
+for (ContentTypeId nCntType : o3tl::enumrange())
 {
-if (nEntryRelPos && nCntType == m_nLastSelType)
+if (nCntType == m_nLastSelType)
 {
-// reselect the entry
-std::unique_ptr 
xChild(m_xTreeView->make_iterator(xEntry.get()));
-std::unique_ptr xTemp;
-sal_uLong nPos = 1;
-while (m_xTreeView->iter_next(*xChild))
+// nEntryRelPos == 0 means the old selected entry was 
a content type
+if (nEntryRelPos)
 {
-// The old text will be slightly favored
-if (sEntryName == m_xTreeView->get_text(*xChild) ||
-nPos == nEntryRelPos)
+std::unique_ptr 
xIter(m_xTreeView->make_iterator(xEntry.get()));
+std::unique_ptr 
xTemp(m_xTreeView->make_iterator(xIter.get()));
+sal_uLong nPos = 1;
+while (m_xTreeView->iter_next(*xIter) &&
+  

Re: FYI: ccache for MSVC/Windows

2021-11-17 Thread Thorsten Behrens
Hi Luboš,

thanks for that & the related changes!

Luboš Luňák wrote:
>  Given that AFAIK Windows bots are now the Jenkins bottleneck, I suppose it 
> could help there too, but I'll leave it to the admins to decide when it's a 
> good idea to use a random WIP patched ccache.
> 
Note that ccache performs surprisingly poor on io-starved Windows
setups [1], which possibly is true for the Jenkins VMs.

So there's no way but trying - how about we equip half of the Windows
builders with your ccache.exe & see what we end up with?

Along the same line, I've also recently added support for sccache, but
YMMV there, too (I'd choose ccache over sccache for local caches any
time). Might be interesting for our dev mentoring team though, since
sccache enables sharing of cache content via hyperscaler blob storage
[2].

[1] 
https://gerrit.libreoffice.org/c/core/+/125179/2#message-54c45dace529cc0b577a0a40d4e8200b05ba1e47
[2] https://github.com/mozilla/sccache

Cheers,

-- Thorsten


signature.asc
Description: PGP signature


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

2021-11-17 Thread Xisco Fauli (via logerrit)
 sw/qa/uitest/writer_tests7/tdf131936.py |3 ---
 1 file changed, 3 deletions(-)

New commits:
commit 96e9dad60bf82153bf678a15f93fb77c8cafcf43
Author: Xisco Fauli 
AuthorDate: Wed Nov 17 13:58:08 2021 +0100
Commit: Xisco Fauli 
CommitDate: Wed Nov 17 21:52:48 2021 +0100

uitest: sw: I don't think this time.sleep is needed

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

diff --git a/sw/qa/uitest/writer_tests7/tdf131936.py 
b/sw/qa/uitest/writer_tests7/tdf131936.py
index 773386b658ff..56247711dbfe 100644
--- a/sw/qa/uitest/writer_tests7/tdf131936.py
+++ b/sw/qa/uitest/writer_tests7/tdf131936.py
@@ -4,8 +4,6 @@
 
 from uitest.framework import UITestCase
 from uitest.uihelper.common import get_state_as_dict, get_url_for_data_file
-from uitest.config import DEFAULT_SLEEP
-import time
 
 class tdf131936(UITestCase):
 
@@ -13,7 +11,6 @@ class tdf131936(UITestCase):
 with self.ui_test.load_file(get_url_for_data_file("tdf131936.docx")):
 
 with self.ui_test.execute_dialog_through_command(".uno:SaveAs", 
close_button="cancel") as xDialog:
-time.sleep(DEFAULT_SLEEP)
 xFileTypeCombo = xDialog.getChild("file_type")
 state = get_state_as_dict(xFileTypeCombo)
 self.assertEqual(state["SelectEntryText"], "Office Open XML 
Text (Transitional) (.docx)")


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

2021-11-17 Thread Xisco Fauli (via logerrit)
 sc/qa/uitest/chart/create_chart.py |5 -
 1 file changed, 5 deletions(-)

New commits:
commit 69cc5b565d38eb4b50be3b6540138bb1ec880ea4
Author: Xisco Fauli 
AuthorDate: Wed Nov 17 14:02:39 2021 +0100
Commit: Xisco Fauli 
CommitDate: Wed Nov 17 21:52:25 2021 +0100

uitest: sc: remove sleep

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

diff --git a/sc/qa/uitest/chart/create_chart.py 
b/sc/qa/uitest/chart/create_chart.py
index 678aca31e564..5a6a9f233a0b 100644
--- a/sc/qa/uitest/chart/create_chart.py
+++ b/sc/qa/uitest/chart/create_chart.py
@@ -10,9 +10,6 @@ from libreoffice.uno.propertyvalue import mkPropertyValues
 from uitest.framework import UITestCase
 from uitest.uihelper.calc import enter_text_to_cell
 
-import time
-import unittest
-
 class CalcChartUIDemo(UITestCase):
 
 def fill_spreadsheet(self):
@@ -78,8 +75,6 @@ class CalcChartUIDemo(UITestCase):
 
 xGridWindow.executeAction("DESELECT", mkPropertyValues({"OBJECT": 
""}))
 
-time.sleep(2)
-
 
 def test_activate_chart(self):
 


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

2021-11-17 Thread Julien Nabet (via logerrit)
 forms/source/solar/component/navbarcontrol.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit ae22b5c49c1c0c56cea2022c2979568b7fa4871e
Author: Julien Nabet 
AuthorDate: Wed Nov 17 18:25:38 2021 +0100
Commit: Julien Nabet 
CommitDate: Wed Nov 17 21:45:29 2021 +0100

tdf#145731: fix crash closing document

Regression from:

https://cgit.freedesktop.org/libreoffice/core/commit/?id=73334560b2dd2d60ac58d2cc2b1a5295490b03e1
author  Julien Nabet   2021-11-07 15:40:37 +0100
committer   Julien Nabet   2021-11-07 21:58:53 
+0100
commit  73334560b2dd2d60ac58d2cc2b1a5295490b03e1 (patch)
treeb5bc4f69dd8ed455c78ea05ab1c5e2f3c25b909e
parent  6be03ac71e0d4927612b4a57ead3d0b245c29c77 (diff)
Replace some macros in forms part 16

Thank you Xisco for having spotted it!

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

diff --git a/forms/source/solar/component/navbarcontrol.cxx 
b/forms/source/solar/component/navbarcontrol.cxx
index ce70d2336c22..082a670faa4d 100644
--- a/forms/source/solar/component/navbarcontrol.cxx
+++ b/forms/source/solar/component/navbarcontrol.cxx
@@ -180,7 +180,7 @@ namespace frm
 Reference< XDispatchProviderInterception > xTypedPeer(getPeer(), 
UNO_QUERY);
 if (xTypedPeer.is())
 {
-xTypedPeer->registerDispatchProviderInterceptor(_rxInterceptor);
+xTypedPeer->releaseDispatchProviderInterceptor(_rxInterceptor);
 }
 }
 


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

2021-11-17 Thread Michael Weghorn (via logerrit)
 sc/inc/markmulti.hxx |3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit 4180b2f7855479f9187cd259d57c06e9fedfb802
Author: Michael Weghorn 
AuthorDate: Wed Nov 17 16:56:30 2021 +0100
Commit: Michael Weghorn 
CommitDate: Wed Nov 17 21:22:39 2021 +0100

sc: Drop 'typedef std::vector MapType'

Its only use is in the next line, and it's not even
a map anymore, but a vector.

Change-Id: Ib7920c420f5e3e18658f3530244097a4b1633951
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125411
Tested-by: Michael Weghorn 
Reviewed-by: Michael Weghorn 

diff --git a/sc/inc/markmulti.hxx b/sc/inc/markmulti.hxx
index c02fd5c6f0ab..0ddc6530a50c 100644
--- a/sc/inc/markmulti.hxx
+++ b/sc/inc/markmulti.hxx
@@ -31,8 +31,7 @@ class SC_DLLPUBLIC ScMultiSel
 {
 
 private:
-typedef std::vector MapType;
-MapType aMultiSelContainer;
+std::vector aMultiSelContainer;
 ScMarkArray aRowSel;
 const ScSheetLimits& mrSheetLimits;
 


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

2021-11-17 Thread Chris Sherlock (via logerrit)
 include/vcl/outdev.hxx |3 ++-
 vcl/source/outdev/gradient.cxx |   41 ++---
 2 files changed, 32 insertions(+), 12 deletions(-)

New commits:
commit 4c3c94704704e5090c0382476251caee7a904454
Author: Chris Sherlock 
AuthorDate: Sun Oct 31 21:34:49 2021 +1100
Commit: Tomaž Vajngerl 
CommitDate: Wed Nov 17 20:57:42 2021 +0100

vcl: split GetGradientSteps() into Get{Complex|Linear}GradientSteps()

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

diff --git a/include/vcl/outdev.hxx b/include/vcl/outdev.hxx
index e82bf1e357a6..eec957e14973 100644
--- a/include/vcl/outdev.hxx
+++ b/include/vcl/outdev.hxx
@@ -815,7 +815,8 @@ private:
 SAL_DLLPRIVATE void DrawLinearGradientToMetafile( const 
tools::Rectangle& rRect, const Gradient& rGradient );
 SAL_DLLPRIVATE void DrawComplexGradientToMetafile( const 
tools::Rectangle& rRect, const Gradient& rGradient );
 
-SAL_DLLPRIVATE tools::Long GetGradientSteps( const Gradient& 
rGradient, const tools::Rectangle& rRect, bool bMtf, bool bComplex=false );
+SAL_DLLPRIVATE tools::Long  GetLinearGradientSteps( const Gradient& 
rGradient, const tools::Rectangle& rRect, bool bMtf);
+SAL_DLLPRIVATE tools::Long  GetComplexGradientSteps( const Gradient& 
rGradient, const tools::Rectangle& rRect, bool bMtf);
 
 SAL_DLLPRIVATE ColorGetSingleColorGradientFill();
 ///@}
diff --git a/vcl/source/outdev/gradient.cxx b/vcl/source/outdev/gradient.cxx
index 6bb6e8de64fc..7dc5523480db 100644
--- a/vcl/source/outdev/gradient.cxx
+++ b/vcl/source/outdev/gradient.cxx
@@ -357,7 +357,7 @@ void OutputDevice::DrawLinearGradient( const 
tools::Rectangle& rRect,
 }
 
 // calculate step count
-tools::LongnStepCount  = GetGradientSteps( rGradient, aRect, 
false/*bMtf*/ );
+tools::Long nStepCount = GetLinearGradientSteps(rGradient, aRect, 
false/*bMtf*/);
 
 // minimal three steps and maximal as max color steps
 tools::Long   nAbsRedSteps   = std::abs( nEndRed   - nStartRed );
@@ -479,7 +479,7 @@ void OutputDevice::DrawComplexGradient( const 
tools::Rectangle& rRect,
 if ( UsePolyPolygonForComplexGradient() )
 xPolyPoly = tools::PolyPolygon( 2 );
 
-tools::Long nStepCount = GetGradientSteps( rGradient, rRect, 
false/*bMtf*/, true/*bComplex*/ );
+tools::Long nStepCount = GetComplexGradientSteps(rGradient, rRect, 
false/*bMtf*/);
 
 // at least three steps and at most the number of colour differences
 tools::Long nSteps = std::max( nStepCount, tools::Long(2) );
@@ -715,7 +715,7 @@ void OutputDevice::DrawLinearGradientToMetafile( const 
tools::Rectangle& rRect,
 }
 }
 
-tools::LongnStepCount  = GetGradientSteps( rGradient, aRect, 
true/*bMtf*/ );
+tools::LongnStepCount  = GetLinearGradientSteps( rGradient, aRect, 
true/*bMtf*/ );
 
 // minimal three steps and maximal as max color steps
 tools::Long   nAbsRedSteps   = std::abs( nEndRed   - nStartRed );
@@ -816,7 +816,7 @@ void OutputDevice::DrawComplexGradientToMetafile( const 
tools::Rectangle& rRect,
 xPolyPoly = tools::PolyPolygon( 2 );
 
 // last parameter - true if complex gradient, false if linear
-tools::Long nStepCount = GetGradientSteps(rGradient, rRect, true, true);
+tools::Long nStepCount = GetComplexGradientSteps(rGradient, rRect, true);
 
 // at least three steps and at most the number of colour differences
 tools::Long nSteps = std::max(nStepCount, tools::Long(2));
@@ -951,25 +951,44 @@ tools::Long OutputDevice::GetGradientStepCount( 
tools::Long nMinRect )
 return nInc;
 }
 
-tools::Long OutputDevice::GetGradientSteps( const Gradient& rGradient, const 
tools::Rectangle& rRect, bool bMtf, bool bComplex )
+tools::Long OutputDevice::GetLinearGradientSteps(Gradient const& rGradient, 
tools::Rectangle const& rRect, bool bMtf)
 {
 // calculate step count
 tools::Long nStepCount  = rGradient.GetSteps();
-tools::Long nMinRect;
 
 // generate nStepCount, if not passed
-if (bComplex)
-nMinRect = std::min( rRect.GetWidth(), rRect.GetHeight() );
-else
-nMinRect = rRect.GetHeight();
+tools::Long nMinRect = rRect.GetHeight();
 
 if ( !nStepCount )
 {
 tools::Long nInc;
 
-nInc = GetGradientStepCount (nMinRect);
+nInc = GetGradientStepCount(nMinRect);
 if ( !nInc || bMtf )
 nInc = 1;
+
+nStepCount = nMinRect / nInc;
+}
+
+return nStepCount;
+}
+
+tools::Long OutputDevice::GetComplexGradientSteps(Gradient const& rGradient, 
tools::Rectangle const& rRect, bool bMtf)
+{
+// calculate step count
+tools::Long nStepCount  = rGradient.GetSteps();
+
+// generate nStepCount, if not passed
+tools::Long nMinRect = std::min(rRect.GetWidth(), rRect.GetHeight());
+
+if ( !nStepCou

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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sc/source/ui/view/gridwin.cxx|   11 ---
 svx/source/tbxctrls/tbcontrl.cxx |1 +
 2 files changed, 9 insertions(+), 3 deletions(-)

New commits:
commit b5c22a9371e22162ff7305ffaa393ed908eee610
Author: Caolán McNamara 
AuthorDate: Wed Nov 17 17:07:49 2021 +
Commit: Caolán McNamara 
CommitDate: Wed Nov 17 20:49:59 2021 +0100

use ListBoxPreview size for the color shown in autofilter color list

it's used for a similar case in the color button,
GetToolbarIconSizePixel is relatively narrow and we have a hectare of
space available here.

Draw a border around the color as we do for the similar color button
case.

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

diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx
index 3530e9d69d5a..acd2973075c1 100644
--- a/sc/source/ui/view/gridwin.cxx
+++ b/sc/source/ui/view/gridwin.cxx
@@ -950,10 +950,15 @@ void 
ScGridWindow::UpdateAutoFilterFromMenu(AutoFilterMode eMode)
 }
 else
 {
+// ColorListBox::ShowPreview is similar
 ScopedVclPtr 
xDev(pPopupParent->create_virtual_device());
-
xDev->SetOutputSize(Application::GetSettings().GetStyleSettings().GetToolbarIconSizePixel());
-xDev->SetBackground(rColor);
-xDev->Erase();
+const StyleSettings& rStyleSettings = 
Application::GetSettings().GetStyleSettings();
+Size 
aImageSize(rStyleSettings.GetListBoxPreviewDefaultPixelSize());
+xDev->SetOutputSize(aImageSize);
+const tools::Rectangle aRect(Point(0, 0), aImageSize);
+xDev->SetFillColor(rColor);
+xDev->SetLineColor(rStyleSettings.GetDisableColor());
+xDev->DrawRect(aRect);
 
 xColorMenu->insert(-1, OUString::number(i), OUString(),
nullptr, xDev.get(), nullptr, 
TRISTATE_TRUE);
diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx
index 5a1239bdea77..04ae3e0ec4fa 100644
--- a/svx/source/tbxctrls/tbcontrl.cxx
+++ b/svx/source/tbxctrls/tbcontrl.cxx
@@ -4021,6 +4021,7 @@ void ColorListBox::LockWidthRequest()
 
 void ColorListBox::ShowPreview(const NamedColor &rColor)
 {
+// ScGridWindow::UpdateAutoFilterFromMenu is similar
 const StyleSettings& rStyleSettings = 
Application::GetSettings().GetStyleSettings();
 Size aImageSize(rStyleSettings.GetListBoxPreviewDefaultPixelSize());
 


[Libreoffice-commits] core.git: include/vcl sc/source sc/uiconfig sc/UIConfig_scalc.mk vcl/source

2021-11-17 Thread Caolán McNamara (via logerrit)
 include/vcl/menu.hxx  |4 
 sc/UIConfig_scalc.mk  |1 +
 sc/source/ui/view/gridwin.cxx |   23 ---
 sc/uiconfig/scalc/ui/colormenu.ui |9 +
 vcl/source/window/menu.cxx|   14 --
 5 files changed, 26 insertions(+), 25 deletions(-)

New commits:
commit c3c526e0192b9cf429d326b129ce9e94ec9e346b
Author: Caolán McNamara 
AuthorDate: Wed Nov 17 16:26:19 2021 +
Commit: Caolán McNamara 
CommitDate: Wed Nov 17 20:49:41 2021 +0100

weld colormenu

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

diff --git a/include/vcl/menu.hxx b/include/vcl/menu.hxx
index f96c775fa64d..7834fe22519e 100644
--- a/include/vcl/menu.hxx
+++ b/include/vcl/menu.hxx
@@ -24,7 +24,6 @@
 #include 
 
 #include 
-#include 
 #include 
 #include 
 #include 
@@ -303,9 +302,6 @@ public:
 void SetItemImage( sal_uInt16 nItemId, const Image& rImage );
 Image GetItemImage( sal_uInt16 nItemId ) const;
 
-// Instead of an image, draw a color
-void SetItemColor( sal_uInt16 nItemId, const Color& rColor );
-
 void SetItemCommand( sal_uInt16 nItemId, const OUString& rCommand );
 OUString GetItemCommand( sal_uInt16 nItemId ) const;
 
diff --git a/sc/UIConfig_scalc.mk b/sc/UIConfig_scalc.mk
index ce625df9f301..c1bd1b075926 100644
--- a/sc/UIConfig_scalc.mk
+++ b/sc/UIConfig_scalc.mk
@@ -94,6 +94,7 @@ $(eval $(call gb_UIConfig_add_uifiles,modules/scalc,\
sc/uiconfig/scalc/ui/chardialog \
sc/uiconfig/scalc/ui/checkwarningdialog \
sc/uiconfig/scalc/ui/chisquaretestdialog \
+   sc/uiconfig/scalc/ui/colormenu \
sc/uiconfig/scalc/ui/colorrowdialog \
sc/uiconfig/scalc/ui/colwidthdialog \
sc/uiconfig/scalc/ui/condformatmanager \
diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx
index 39c2f7d8fd98..3530e9d69d5a 100644
--- a/sc/source/ui/view/gridwin.cxx
+++ b/sc/source/ui/view/gridwin.cxx
@@ -43,6 +43,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -928,7 +929,10 @@ void ScGridWindow::UpdateAutoFilterFromMenu(AutoFilterMode 
eMode)
 ScFilterEntries aFilterEntries;
 rDoc.GetFilterEntries(rPos.Col(), rPos.Row(), rPos.Tab(), 
aFilterEntries);
 
-VclPtr pColorMenu = VclPtr::Create();
+weld::Window* pPopupParent = mpAutoFilterPopup->GetFrameWeld();
+std::unique_ptr 
xBuilder(Application::CreateBuilder(pPopupParent, 
"modules/scalc/ui/colormenu.ui"));
+std::unique_ptr 
xColorMenu(xBuilder->weld_menu("menu"));
+
 std::set aColors = eMode == AutoFilterMode::TextColor
   ? aFilterEntries.getTextColors()
   : 
aFilterEntries.getBackgroundColors();
@@ -942,12 +946,17 @@ void 
ScGridWindow::UpdateAutoFilterFromMenu(AutoFilterMode eMode)
 OUString sText = eMode == AutoFilterMode::TextColor
  ? 
ScResId(SCSTR_FILTER_AUTOMATIC_COLOR)
  : ScResId(SCSTR_FILTER_NO_FILL);
-pColorMenu->InsertItem(i, sText, 
MenuItemBits::CHECKABLE);
+xColorMenu->append_check(OUString::number(i), sText);
 }
 else
 {
-pColorMenu->InsertItem(i, OUString(), 
MenuItemBits::CHECKABLE);
-pColorMenu->SetItemColor(i, rColor);
+ScopedVclPtr 
xDev(pPopupParent->create_virtual_device());
+
xDev->SetOutputSize(Application::GetSettings().GetStyleSettings().GetToolbarIconSizePixel());
+xDev->SetBackground(rColor);
+xDev->Erase();
+
+xColorMenu->insert(-1, OUString::number(i), OUString(),
+   nullptr, xDev.get(), nullptr, 
TRISTATE_TRUE);
 }
 auto aItem = pEntry->GetQueryItem();
 if (aItem.maColor == rColor
@@ -957,14 +966,14 @@ void 
ScGridWindow::UpdateAutoFilterFromMenu(AutoFilterMode eMode)
 && aItem.meType == 
ScQueryEntry::ByBackgroundColor)))
 {
 nActive = i;
-pColorMenu->CheckItem(i, true);
+xColorMenu->set_active(OString::number(i), true);
 }
 i++;
 }
 
 tools::Rectangle aRect = rControl.GetSubMenuParentRect();
-sal_uInt16 nSelected = pColorMenu->Execute(mpAutoFilterPopup, 
aRect, PopupMenuFlags::ExecuteRight);
-pColorMenu.disposeAndClear();
+  

[Libreoffice-commits] core.git: Branch 'distro/cib/libreoffice-6-1' - 44 commits - chart2/source configure.ac connectivity/source download.lst external/graphite external/libabw external/libcdr externa

2021-11-17 Thread Michael Stahl (via logerrit)
 chart2/source/tools/InternalDataProvider.cxx   
  |7 
 configure.ac   
  |2 
 connectivity/source/commontools/dbconversion.cxx   
  |9 -
 connectivity/source/drivers/dbase/DTable.cxx   
  |   13 +
 download.lst   
  |   58 
 external/graphite/StaticLibrary_graphite.mk
  |4 
 external/graphite/UnpackedTarball_graphite.mk  
  |4 
 external/graphite/graphite2.issue1115.patch.1  
  |   22 ---
 external/graphite/graphite2.win64.patch.1  
  |   60 
 external/graphite/ubsan.patch  
  |   53 ---
 external/libabw/UnpackedTarball_libabw.mk  
  |4 
 external/libabw/libabw-msvc.patch.1
  |   46 --
 external/libcdr/UnpackedTarball_libcdr.mk  
  |4 
 external/libcdr/libcdr-visibility-win.patch
  |   11 +
 external/libetonyek/Library_etonyek.mk 
  |1 
 external/libetonyek/UnpackedTarball_libetonyek.mk  
  |1 
 external/libetonyek/initial-creator.patch.1
  |   26 ---
 external/libetonyek/libetonyek-bundled-soname.patch.0  
  |3 
 external/libjpeg-turbo/UnpackedTarball_libjpeg-turbo.mk
  |1 
 external/libjpeg-turbo/c76f4a08263b0cea40d2967560ac7c21f6959079.patch.1
  |   38 +
 external/libmwaw/0001-ssize_t-is-not-std-type.patch.1  
  |   27 ---
 external/libmwaw/Library_mwaw.mk   
  |5 
 external/libmwaw/UnpackedTarball_libmwaw.mk
  |4 
 external/libmwaw/libmwaw-bundled-soname.patch.0
  |6 
 
external/libodfgen/0001-tdf-101077-make-double-string-conversion-locale-agno.patch.1
 |   58 
 external/libodfgen/ExternalProject_libodfgen.mk
  |4 
 external/libodfgen/Library_odfgen.mk   
  |3 
 external/libodfgen/UnpackedTarball_libodfgen.mk
  |4 
 external/libodfgen/libodfgen-bundled-soname.patch.0
  |5 
 external/libvisio/0001-fix-debug-build.patch.1 
  |   40 -
 external/libvisio/UnpackedTarball_libvisio.mk  
  |1 
 external/libvisio/ubsan.patch  
  |4 
 external/libwpd/Library_wpd.mk 
  |2 
 external/libwpd/include.patch  
  |4 
 external/libwpd/libwpd-bundled-soname.patch.0  
  |3 
 external/pdfium/Library_pdfium.mk  
  |   44 +++---
 external/pdfium/README 
  |2 
 external/pdfium/build.patch.1  
  |   71 +-
 external/pdfium/msvc2015.patch.1   
  |2 
 external/pdfium/ubsan.patch
  |6 
 external/poppler/StaticLibrary_poppler.mk  
  |2 
 external/poppler/poppler-config.patch.1
  |   58 ++--
 include/vcl/BitmapTools.hxx
  |5 
 lotuswordpro/source/filter/lwpfribptr.cxx  
  |   35 ++--
 lotuswordpro/source/filter/lwpfribptr.hxx  
  |4 
 sc/source/core/tool/compiler.cxx   
  |9 +
 sc/source/core/tool/interpr1.cxx   
  |2 
 solenv/flatpak-manifest.in 
  |   55 +++
 svtools/source/svhtml/parhtml.cxx  
  |8 -
 sw/qa/core/data/html/pass/ofz40593-1.html  
  |binary
 sw/qa/core/data/ww5/pass/ooo37322-1-WW2.doc
  |binary
 sw/qa/core/data/ww8/pass/ofz34749-1.doc 

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

2021-11-17 Thread Caolán McNamara (via logerrit)
 include/vcl/weld.hxx  |   10 +-
 vcl/inc/salvtables.hxx|3 ++-
 vcl/source/app/salvtables.cxx |   11 ---
 vcl/unx/gtk3/gtkinst.cxx  |   21 +++--
 4 files changed, 38 insertions(+), 7 deletions(-)

New commits:
commit 6b4b82626a30418c2d566c4fc1ecfe559557bf2b
Author: Caolán McNamara 
AuthorDate: Wed Nov 17 17:00:58 2021 +
Commit: Caolán McNamara 
CommitDate: Wed Nov 17 20:49:22 2021 +0100

allow menu placement either under or at end

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

diff --git a/include/vcl/weld.hxx b/include/vcl/weld.hxx
index df036c8fde1a..b25e9abe5383 100644
--- a/include/vcl/weld.hxx
+++ b/include/vcl/weld.hxx
@@ -2277,6 +2277,12 @@ private:
 virtual void click(const Point& rPos) = 0;
 };
 
+enum class Placement
+{
+Under,
+End
+};
+
 class VCL_DLLPUBLIC Menu
 {
 protected:
@@ -2285,7 +2291,9 @@ protected:
 void signal_activate(const OString& rIdent) { m_aActivateHdl.Call(rIdent); 
}
 
 public:
-virtual OString popup_at_rect(weld::Widget* pParent, const 
tools::Rectangle& rRect) = 0;
+virtual OString popup_at_rect(weld::Widget* pParent, const 
tools::Rectangle& rRect,
+  Placement ePlace = Placement::Under)
+= 0;
 
 void connect_activate(const Link& rLink) { 
m_aActivateHdl = rLink; }
 
diff --git a/vcl/inc/salvtables.hxx b/vcl/inc/salvtables.hxx
index 57f6149ff7bc..c97b39df575d 100644
--- a/vcl/inc/salvtables.hxx
+++ b/vcl/inc/salvtables.hxx
@@ -145,7 +145,8 @@ private:
 
 public:
 SalInstanceMenu(PopupMenu* pMenu, bool bTakeOwnership);
-virtual OString popup_at_rect(weld::Widget* pParent, const 
tools::Rectangle& rRect) override;
+virtual OString popup_at_rect(weld::Widget* pParent, const 
tools::Rectangle& rRect,
+  weld::Placement ePlace = 
weld::Placement::Under) override;
 virtual void set_sensitive(const OString& rIdent, bool bSensitive) 
override;
 virtual bool get_sensitive(const OString& rIdent) const override;
 virtual void set_active(const OString& rIdent, bool bActive) override;
diff --git a/vcl/source/app/salvtables.cxx b/vcl/source/app/salvtables.cxx
index 792534a92517..987a9ffe2aeb 100644
--- a/vcl/source/app/salvtables.cxx
+++ b/vcl/source/app/salvtables.cxx
@@ -772,12 +772,17 @@ SalInstanceMenu::SalInstanceMenu(PopupMenu* pMenu, bool 
bTakeOwnership)
 m_nLastId = nCount ? pMenu->GetItemId(nCount - 1) : 0;
 m_xMenu->SetSelectHdl(LINK(this, SalInstanceMenu, SelectMenuHdl));
 }
-OString SalInstanceMenu::popup_at_rect(weld::Widget* pParent, const 
tools::Rectangle& rRect)
+OString SalInstanceMenu::popup_at_rect(weld::Widget* pParent, const 
tools::Rectangle& rRect,
+   weld::Placement ePlace)
 {
 SalInstanceWidget* pVclWidget = dynamic_cast(pParent);
 assert(pVclWidget);
-m_xMenu->Execute(pVclWidget->getWidget(), rRect,
- PopupMenuFlags::ExecuteDown | 
PopupMenuFlags::NoMouseUpClose);
+PopupMenuFlags eFlags = PopupMenuFlags::NoMouseUpClose;
+if (ePlace == weld::Placement::Under)
+eFlags = eFlags | PopupMenuFlags::ExecuteDown;
+else
+eFlags = eFlags | PopupMenuFlags::ExecuteRight;
+m_xMenu->Execute(pVclWidget->getWidget(), rRect, eFlags);
 return m_xMenu->GetCurItemIdent();
 }
 void SalInstanceMenu::set_sensitive(const OString& rIdent, bool bSensitive)
diff --git a/vcl/unx/gtk3/gtkinst.cxx b/vcl/unx/gtk3/gtkinst.cxx
index 93035fd27cbb..6ce18a346ac4 100644
--- a/vcl/unx/gtk3/gtkinst.cxx
+++ b/vcl/unx/gtk3/gtkinst.cxx
@@ -10718,7 +10718,7 @@ public:
 #endif
 }
 
-virtual OString popup_at_rect(weld::Widget* pParent, const 
tools::Rectangle &rRect) override
+virtual OString popup_at_rect(weld::Widget* pParent, const 
tools::Rectangle &rRect, weld::Placement ePlace) override
 {
 m_sActivated.clear();
 
@@ -10743,6 +10743,15 @@ public:
 GtkWidget* pOrigParent = gtk_widget_get_parent(GTK_WIDGET(m_pMenu));
 gtk_widget_set_parent(GTK_WIDGET(m_pMenu), pWidget);
 gtk_popover_set_pointing_to(GTK_POPOVER(m_pMenu), &aRect);
+if (ePlace == weld::Placement::Under)
+gtk_popover_set_position(GTK_POPOVER(m_pMenu), GTK_POS_BOTTOM);
+else
+{
+if (SwapForRTL(pWidget))
+gtk_popover_set_position(GTK_POPOVER(m_pMenu), GTK_POS_LEFT);
+else
+gtk_popover_set_position(GTK_POPOVER(m_pMenu), GTK_POS_RIGHT);
+}
 gtk_popover_popup(GTK_POPOVER(m_pMenu));
 #else
 gulong nSignalId = g_signal_connect_swapped(G_OBJECT(m_pMenu), 
"deactivate", G_CALLBACK(g_main_loop_quit), pLoop);
@@ -10765,7 +10774,15 @@ public:
 if (!pTriggerEvent)
 pTriggerEvent = pKeyEvent;
 
-gtk_menu_popup_a

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

2021-11-17 Thread Caolán McNamara (via logerrit)
 compilerplugins/clang/unusedenumconstants.readonly.results |2 --
 include/vcl/menu.hxx   |8 +---
 vcl/source/window/menu.cxx |3 ---
 3 files changed, 1 insertion(+), 12 deletions(-)

New commits:
commit 9f68cc110c16cc096f5549a4a0812cee56cb09db
Author: Caolán McNamara 
AuthorDate: Wed Nov 17 16:31:07 2021 +
Commit: Caolán McNamara 
CommitDate: Wed Nov 17 20:49:02 2021 +0100

drop unused PopupMenuFlags::NoHorzPlacement

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

diff --git a/compilerplugins/clang/unusedenumconstants.readonly.results 
b/compilerplugins/clang/unusedenumconstants.readonly.results
index 935e74505021..02ec1e8a728f 100644
--- a/compilerplugins/clang/unusedenumconstants.readonly.results
+++ b/compilerplugins/clang/unusedenumconstants.readonly.results
@@ -512,8 +512,6 @@ include/vcl/keycodes.hxx:175
 enum ModKeyFlags Mod2Msk
 include/vcl/menu.hxx:78
 enum PopupMenuFlags ExecuteUp
-include/vcl/menu.hxx:86
-enum PopupMenuFlags NoHorzPlacement
 include/vcl/pdf/PDFAnnotationSubType.hxx:17
 enum vcl::pdf::PDFAnnotationSubType Unknown
 include/vcl/pdf/PDFAnnotationSubType.hxx:26
diff --git a/include/vcl/menu.hxx b/include/vcl/menu.hxx
index c0a627a30f88..f96c775fa64d 100644
--- a/include/vcl/menu.hxx
+++ b/include/vcl/menu.hxx
@@ -77,17 +77,11 @@ enum class PopupMenuFlags
 ExecuteUp   = 0x0002,
 ExecuteRight= 0x0008,
 NoMouseUpClose  = 0x0010,
-//If there isn't enough space to put the menu where it wants
-//to go, then they will be autoplaced. Toggle this bit
-//on to force menus to be placed either above or below
-//the starting rectangle and shrunk to fit and then scroll rather than place
-//the menu beside that rectangle
-NoHorzPlacement = 0x0020,
 };
 
 namespace o3tl
 {
-template<> struct typed_flags : 
is_typed_flags {};
+template<> struct typed_flags : 
is_typed_flags {};
 }
 
 enum class MenuFlags
diff --git a/vcl/source/window/menu.cxx b/vcl/source/window/menu.cxx
index 797740d127b8..53f5e28e6f53 100644
--- a/vcl/source/window/menu.cxx
+++ b/vcl/source/window/menu.cxx
@@ -2798,9 +2798,6 @@ sal_uInt16 PopupMenu::Execute( vcl::Window* pExecWindow, 
const tools::Rectangle&
 if (nFlags & PopupMenuFlags::NoMouseUpClose )  // 
allow popup menus to stay open on mouse button up
 nPopupModeFlags |= FloatWinPopupFlags::NoMouseUpClose;// useful if 
the menu was opened on mousebutton down (eg toolbox configuration)
 
-if (nFlags & PopupMenuFlags::NoHorzPlacement)
-nPopupModeFlags |= FloatWinPopupFlags::NoHorzPlacement;
-
 return ImplExecute( pExecWindow, rRect, nPopupModeFlags, nullptr, false );
 }
 


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sc/source/ui/cctrl/checklistmenu.cxx |9 -
 sc/source/ui/inc/checklistmenu.hxx   |5 +
 sc/source/ui/view/gridwin.cxx|6 +++---
 3 files changed, 16 insertions(+), 4 deletions(-)

New commits:
commit 2b3cc82b88d0c6508e9c0c6ccc53e0f9bfb4069e
Author: Caolán McNamara 
AuthorDate: Wed Nov 17 15:20:33 2021 +
Commit: Caolán McNamara 
CommitDate: Wed Nov 17 20:47:55 2021 +0100

tdf#142420 color menu should be a child of the autofilter, not a sibling

which is why it doesn't appear at all under wayland. This should also
get it positioned better rather than using a fixed pixel offset.

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

diff --git a/sc/source/ui/cctrl/checklistmenu.cxx 
b/sc/source/ui/cctrl/checklistmenu.cxx
index 56fb60477220..328c51718364 100644
--- a/sc/source/ui/cctrl/checklistmenu.cxx
+++ b/sc/source/ui/cctrl/checklistmenu.cxx
@@ -283,6 +283,13 @@ void ScCheckListMenuControl::queueCloseSubMenu()
 maCloseTimer.maTimer.Start();
 }
 
+tools::Rectangle ScCheckListMenuControl::GetSubMenuParentRect()
+{
+if (!mxMenu->get_selected(mxScratchIter.get()))
+return tools::Rectangle();
+return mxMenu->get_row_area(*mxScratchIter);
+}
+
 void ScCheckListMenuControl::launchSubMenu(bool bSetMenuPos)
 {
 ScCheckListMenuWindow* pSubMenu = maOpenTimer.mpSubMenu;
@@ -292,7 +299,7 @@ void ScCheckListMenuControl::launchSubMenu(bool bSetMenuPos)
 if (!mxMenu->get_selected(mxScratchIter.get()))
 return;
 
-tools::Rectangle aRect = mxMenu->get_row_area(*mxScratchIter);
+tools::Rectangle aRect = GetSubMenuParentRect();
 ScCheckListMenuControl& rSubMenuControl = pSubMenu->get_widget();
 rSubMenuControl.StartPopupMode(aRect, FloatWinPopupFlags::Right);
 if (bSetMenuPos)
diff --git a/sc/source/ui/inc/checklistmenu.hxx 
b/sc/source/ui/inc/checklistmenu.hxx
index 302f2bd0b55d..cb78bf226a45 100644
--- a/sc/source/ui/inc/checklistmenu.hxx
+++ b/sc/source/ui/inc/checklistmenu.hxx
@@ -177,6 +177,11 @@ public:
  */
 void terminateAllPopupMenus();
 
+/**
+ * Get the area of the active row. Suitable as the parent rectangle
+ * argument for Executing a popup
+*/
+tools::Rectangle GetSubMenuParentRect();
 private:
 
 std::vector maMenuItems;
diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx
index 6013848bb85c..39c2f7d8fd98 100644
--- a/sc/source/ui/view/gridwin.cxx
+++ b/sc/source/ui/view/gridwin.cxx
@@ -961,9 +961,9 @@ void ScGridWindow::UpdateAutoFilterFromMenu(AutoFilterMode 
eMode)
 }
 i++;
 }
-Point pos(mpAutoFilterPopup->GetPosPixel());
-pos.Move(150, 0);
-sal_uInt16 nSelected = pColorMenu->Execute(this, pos);
+
+tools::Rectangle aRect = rControl.GetSubMenuParentRect();
+sal_uInt16 nSelected = pColorMenu->Execute(mpAutoFilterPopup, 
aRect, PopupMenuFlags::ExecuteRight);
 pColorMenu.disposeAndClear();
 rControl.terminateAllPopupMenus();
 


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sc/source/ui/view/gridwin.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 3c4c98784d352c6edeae598233fd46775373d332
Author: Caolán McNamara 
AuthorDate: Wed Nov 17 14:51:39 2021 +
Commit: Caolán McNamara 
CommitDate: Wed Nov 17 20:46:29 2021 +0100

wrong function name in comment

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

diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx
index d850ac042872..6013848bb85c 100644
--- a/sc/source/ui/view/gridwin.cxx
+++ b/sc/source/ui/view/gridwin.cxx
@@ -502,7 +502,7 @@ public:
 virtual bool execute() override
 {
 mpWindow->UpdateAutoFilterFromMenu(meMode);
-// RefreshAutoFilterButton manually closes the popup so return
+// UpdateAutoFilterFromMenu manually closes the popup so return
 // false to not attempt a second close
 return false;
 }


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

2021-11-17 Thread Michael Stahl (via logerrit)
 download.lst |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit a4b570ef8da51881aedcd25d66430ca9d9c69221
Author: Michael Stahl 
AuthorDate: Tue Nov 16 14:41:57 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 20:37:42 2021 +0100

postgresql: upgrade to release 13.5

Fixes CVE-2021-23222.

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125308
Tested-by: Jenkins
Reviewed-by: Michael Stahl 
(cherry picked from commit 71b9369f1cc40143108e3f2189d96e402895e315)

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

diff --git a/download.lst b/download.lst
index 22cd0fb9ed4c..d20af4b159f7 100644
--- a/download.lst
+++ b/download.lst
@@ -208,8 +208,8 @@ export LIBPNG_SHA256SUM := 
505e70834d35383537b6491e7ae8641f1a4bed1876dbfe361201f
 export LIBPNG_TARBALL := libpng-1.6.37.tar.xz
 export POPPLER_SHA256SUM := 
31b76b5cac0a48612fdd154c02d9eca01fd38fb8eaa77c1196840ecdeb53a584
 export POPPLER_TARBALL := poppler-21.11.0.tar.xz
-export POSTGRESQL_SHA256SUM := 
12345c83b89aa29808568977f5200d6da00f88a035517f925293355432ffe61f
-export POSTGRESQL_TARBALL := postgresql-13.1.tar.bz2
+export POSTGRESQL_SHA256SUM := 
9b81067a55edbaabc418aacef457dd8477642827499560b00615a6ea6c13f6b3
+export POSTGRESQL_TARBALL := postgresql-13.5.tar.bz2
 export PYTHON_SHA256SUM := 
c24a37c63a67f53bdd09c5f287b5cff8e8b98f857bf348c577d454d3f74db049
 export PYTHON_TARBALL := Python-3.5.9.tar.xz
 export QXP_SHA256SUM := 
e137b6b110120a52c98edd02ebdc4095ee08d0d5295a94316a981750095a945c


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

2021-11-17 Thread László Németh (via logerrit)
 sw/inc/strings.hrc |2 ++
 sw/source/uibase/docvw/edtwin2.cxx |   10 --
 2 files changed, 10 insertions(+), 2 deletions(-)

New commits:
commit 970f8ec7c8eb6007181ce55d885eef771dd49cc6
Author: László Németh 
AuthorDate: Wed Nov 17 15:39:59 2021 +0100
Commit: László Németh 
CommitDate: Wed Nov 17 20:08:22 2021 +0100

tdf#145721 sw track changes: sign text moving in redline tooltips

Write "Moved (deletion)" and "Moved (insertion)" instead of
"Deleted" and "Inserted" in tooltip of tracked text movings.

Follow-up to commit f51fa7534421a195a58b4a737a2e836d8c25ba81
"tdf#145718 sw, DOCX import: complete tracked text moving"

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

diff --git a/sw/inc/strings.hrc b/sw/inc/strings.hrc
index 852e46ec9450..d5aaf979b66f 100644
--- a/sw/inc/strings.hrc
+++ b/sw/inc/strings.hrc
@@ -1243,6 +1243,8 @@
 #define STR_REDLINE_TABLE_ROW_DELETE
NC_("STR_REDLINE_TABLE_ROW_DELETE", "Row Deleted")
 #define STR_REDLINE_TABLE_CELL_INSERT   
NC_("STR_REDLINE_TABLE_CELL_INSERT", "Cell Inserted")
 #define STR_REDLINE_TABLE_CELL_DELETE   
NC_("STR_REDLINE_TABLE_CELL_DELETE", "Cell Deleted")
+#define STR_REDLINE_INSERT_MOVED
NC_("STR_REDLINE_INSERT_MOVED", "Moved (insertion)")
+#define STR_REDLINE_DELETE_MOVED
NC_("STR_REDLINE_DELETE_MOVED", "Moved (deletion)")
 #define STR_ENDNOTE NC_("STR_ENDNOTE", "Endnote: ")
 #define STR_FTNNOTE NC_("STR_FTNNOTE", "Footnote: 
")
 #define STR_SMARTTAG_CLICK  NC_("STR_SMARTTAG_CLICK", 
"%s-click to open Smart Tag menu")
diff --git a/sw/source/uibase/docvw/edtwin2.cxx 
b/sw/source/uibase/docvw/edtwin2.cxx
index 5b4f6ce4c5c6..8117db026e92 100644
--- a/sw/source/uibase/docvw/edtwin2.cxx
+++ b/sw/source/uibase/docvw/edtwin2.cxx
@@ -60,8 +60,14 @@ static OUString lcl_GetRedlineHelp( const SwRangeRedline& 
rRedl, bool bBalloon )
 TranslateId pResId;
 switch( rRedl.GetType() )
 {
-case RedlineType::Insert:   pResId = STR_REDLINE_INSERT; break;
-case RedlineType::Delete:   pResId = STR_REDLINE_DELETE; break;
+case RedlineType::Insert:   pResId = rRedl.IsMoved()
+? STR_REDLINE_INSERT_MOVED
+: STR_REDLINE_INSERT;
+break;
+case RedlineType::Delete:   pResId = rRedl.IsMoved()
+? STR_REDLINE_DELETE_MOVED
+: STR_REDLINE_DELETE;
+break;
 case RedlineType::Format:   pResId = STR_REDLINE_FORMAT; break;
 case RedlineType::Table:pResId = STR_REDLINE_TABLE; break;
 case RedlineType::FmtColl:  pResId = STR_REDLINE_FMTCOLL; break;


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

2021-11-17 Thread László Németh (via logerrit)
 offapi/com/sun/star/text/XRedline.idl |1 +
 sw/inc/redline.hxx|6 +-
 sw/qa/extras/layout/data/tdf104797.docx   |binary
 sw/qa/extras/layout/layout2.cxx   |   20 
 sw/qa/extras/ooxmlexport/ooxmlexport11.cxx|   20 +++-
 sw/qa/extras/ooxmlexport/ooxmlexport13.cxx|   20 
 sw/qa/extras/uiwriter/uiwriter2.cxx   |7 +++
 sw/source/core/doc/DocumentRedlineManager.cxx |7 ++-
 sw/source/core/doc/docredln.cxx   |   20 +---
 sw/source/core/text/redlnitr.cxx  |2 +-
 sw/source/core/text/txtfld.cxx|2 +-
 sw/source/core/unocore/unocrsrhelper.cxx  |6 ++
 writerfilter/source/dmapper/DomainMapper_Impl.cxx |9 -
 13 files changed, 103 insertions(+), 17 deletions(-)

New commits:
commit f51fa7534421a195a58b4a737a2e836d8c25ba81
Author: László Németh 
AuthorDate: Tue Nov 16 16:08:57 2021 +0100
Commit: László Németh 
CommitDate: Wed Nov 17 20:05:46 2021 +0100

tdf#145718 sw, DOCX import: complete tracked text moving

Add IsMoved bit to SwRangeRedline, and keep it in both
parts of a split Delete/Insert redline. Set this bit
during DOCX import, fixing incomplete import of
moveFrom/moveTo elements.

Details:

- Search text moving only at redline Insert() and AppendRedline()
  instead in the layout code (which was much slower, because
  triggered by also mouse hovering):

- detect text moving in Hide Changes mode, too;

- Insertion inside or directly after tracked text moving keeps
  "moved text" layout of the original moved text parts (before
  and after the insertion).

- at detection of text moving, invalidate (update) layout of the
  redline pair, too.

- fix DOCX import: extend makeRedline() with property RedlineMoved
  to keep all moveFrom/moveTo stored in DOCX instead of
  losing them (joining them with normal redlines) in the case
  of missing Delete/Insert pair (see unit test document);

Follow-up to commit ec577f566fa3e6d2666069180f8ec8474054aea9
"tdf#145233 sw track changes: show moved text in green color",
commit bcdebc832b272662d28035007a4796e42d1305ae
"tdf#104797 DOCX change tracking: handle moveFrom and moveTo"
and commit d32d9a2b3c5e3963f4a18f6c7bbf50fab2e9b2be
"tdf#123460 DOCX track changes: moveFrom completely".

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

diff --git a/offapi/com/sun/star/text/XRedline.idl 
b/offapi/com/sun/star/text/XRedline.idl
index 9b259e8b9e58..a07c92ddfc62 100644
--- a/offapi/com/sun/star/text/XRedline.idl
+++ b/offapi/com/sun/star/text/XRedline.idl
@@ -46,6 +46,7 @@ published interface XRedline
 [readonly, property] string RedlineAuthor;
 [readonly, property] com::sun::star::util::DateTime 
RedlineDateTime;
 [readonly, property] string RedlineComment;
+[readonly, optional, property] boolean RedlineMoved;
 */
 void makeRedline( [in]string RedlineType, [in] 
com::sun::star::beans::PropertyValues  RedlineProperties)
 raises( com::sun::star::lang::IllegalArgumentException 
);
diff --git a/sw/inc/redline.hxx b/sw/inc/redline.hxx
index 0c5b8408d54c..8d17948205fa 100644
--- a/sw/inc/redline.hxx
+++ b/sw/inc/redline.hxx
@@ -155,6 +155,7 @@ class SW_DLLPUBLIC SwRangeRedline final : public SwPaM
 SwNodeIndex* m_pContentSect;
 bool m_bDelLastPara : 1;
 bool m_bIsVisible : 1;
+bool m_bIsMoved : 1;
 sal_uInt32 m_nId;
 
 std::optional m_oLOKLastNodeTop;
@@ -174,7 +175,7 @@ public:
 SwRangeRedline(SwRedlineData* pData, const SwPosition& rPos,
bool bDelLP) :
 SwPaM( rPos ), m_pRedlineData( pData ), m_pContentSect( nullptr ),
-m_bDelLastPara( bDelLP ), m_bIsVisible( true ), m_nId( s_nLastId++ )
+m_bDelLastPara( bDelLP ), m_bIsVisible( true ), m_bIsMoved( false ), 
m_nId( s_nLastId++ )
 {}
 SwRangeRedline( const SwRangeRedline& );
 virtual ~SwRangeRedline() override;
@@ -261,6 +262,9 @@ public:
 void dumpAsXml(xmlTextWriterPtr pWriter) const;
 
 void MaybeNotifyRedlinePositionModification(tools::Long nTop);
+
+void SetMoved() { m_bIsMoved = true; }
+bool IsMoved() const { return m_bIsMoved; }
 };
 
 void MaybeNotifyRedlineModification(SwRangeRedline& rRedline, SwDoc& rDoc);
diff --git a/sw/qa/extras/layout/data/tdf104797.docx 
b/sw/qa/extras/layout/data/tdf104797.docx
new file mode 100644
index ..6e52190ce671
Binary files /dev/null and b/sw/qa/extras/layout/data/tdf104797.docx differ
diff --git a/sw/qa/extras/layout/layout2.cxx b/sw/qa/extras

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

2021-11-17 Thread Sarper Akdemir (via logerrit)
 include/oox/drawingml/color.hxx  |4 ++--
 oox/source/drawingml/color.cxx   |2 +-
 oox/source/drawingml/shape.cxx   |   14 +++---
 oox/source/drawingml/shape3dproperties.cxx   |2 +-
 oox/source/drawingml/textcharacterproperties.cxx |2 +-
 5 files changed, 12 insertions(+), 12 deletions(-)

New commits:
commit 9acb80943da5aaaf5d515a794f8a825d88bda430
Author: Sarper Akdemir 
AuthorDate: Tue Aug 24 23:58:35 2021 +0300
Commit: Miklos Vajna 
CommitDate: Wed Nov 17 19:58:01 2021 +0100

rename getSchemeName getSchemeIndex to remove ambiguity

[ Miklos: i.e. index could be a theme index or an index into a color
set, this one is the later case. ]

(cherry picked from commit aef22c3bbf1b4bb8ab9ba2bccb7005e0d0c75cb3,
from the feature/themesupport2 branch)

Conflicts:
oox/source/drawingml/shape.cxx
oox/source/drawingml/shape3dproperties.cxx

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

diff --git a/include/oox/drawingml/color.hxx b/include/oox/drawingml/color.hxx
index f213dba9a973..00473cfe6f27 100644
--- a/include/oox/drawingml/color.hxx
+++ b/include/oox/drawingml/color.hxx
@@ -97,8 +97,8 @@ public:
 sal_Int16   getTransparency() const;
 
 /** Returns the scheme name from the a:schemeClr element for 
interoperability purposes */
-const OUString& getSchemeName() const { return msSchemeName; }
-sal_Int16   getSchemeIndex() const;
+const OUString& getSchemeColorName() const { return msSchemeName; }
+sal_Int16   getSchemeColorIndex() const;
 
 /** Returns the unaltered list of transformations for interoperability 
purposes */
 const css::uno::Sequence< css::beans::PropertyValue >& 
getTransformations() const { return maInteropTransformations;}
diff --git a/oox/source/drawingml/color.cxx b/oox/source/drawingml/color.cxx
index 9f4026727b56..2ced5345904e 100644
--- a/oox/source/drawingml/color.cxx
+++ b/oox/source/drawingml/color.cxx
@@ -661,7 +661,7 @@ sal_Int16 Color::getTransparency() const
 return sal_Int16(std::round( (1.0 * (MAX_PERCENT - mnAlpha)) / 
PER_PERCENT) );
 }
 
-sal_Int16 Color::getSchemeIndex() const
+sal_Int16 Color::getSchemeColorIndex() const
 {
 static std::map const aSchemeColorNameToIndex{
 { "dk1", 0 }, { "lt1", 1 }, { "dk2", 2 }, { "lt2", 3 },
diff --git a/oox/source/drawingml/shape.cxx b/oox/source/drawingml/shape.cxx
index 69bf775ee5da..1f1d430e241d 100644
--- a/oox/source/drawingml/shape.cxx
+++ b/oox/source/drawingml/shape.cxx
@@ -1064,7 +1064,7 @@ Reference< XShape > const & Shape::createAndInsert(
 // Store style-related properties to InteropGrabBag to be able 
to export them back
 uno::Sequence aProperties = 
comphelper::InitPropertySequence(
 {
-{"SchemeClr", 
uno::makeAny(pLineRef->maPhClr.getSchemeName())},
+{"SchemeClr", 
uno::makeAny(pLineRef->maPhClr.getSchemeColorName())},
 {"Idx", uno::makeAny(pLineRef->mnThemedIdx)},
 {"Color", uno::makeAny(nLinePhClr)},
 {"LineStyle", 
uno::makeAny(aLineProperties.getLineStyle())},
@@ -1082,7 +1082,7 @@ Reference< XShape > const & Shape::createAndInsert(
 nFillPhClr = pFillRef->maPhClr.getColor(rGraphicHelper);
 }
 
-OUString sColorScheme = pFillRef->maPhClr.getSchemeName();
+OUString sColorScheme = pFillRef->maPhClr.getSchemeColorName();
 if( !sColorScheme.isEmpty() )
 {
 uno::Sequence aProperties = 
comphelper::InitPropertySequence(
@@ -1104,7 +1104,7 @@ Reference< XShape > const & Shape::createAndInsert(
 // Store style-related properties to InteropGrabBag to be able 
to export them back
 uno::Sequence aProperties = 
comphelper::InitPropertySequence(
 {
-{"SchemeClr", 
uno::makeAny(pEffectRef->maPhClr.getSchemeName())},
+{"SchemeClr", 
uno::makeAny(pEffectRef->maPhClr.getSchemeColorName())},
 {"Idx", uno::makeAny(pEffectRef->mnThemedIdx)},
 {"Transformations", 
uno::makeAny(pEffectRef->maPhClr.getTransformations())}
 });
@@ -1356,13 +1356,13 @@ Reference< XShape > const & Shape::createAndInsert(
 comphelper::makePropertyValue("OriginalSolidFillClr", 
aShapeProps.getProperty(PROP_FillColor)),
 comphelper::makePropertyValue("OriginalLnSolidFillClr", 
aShapeProps.getProperty(PROP_LineColor))
 };
-OUString sColorFillScheme = 
aFillProperties.maFillColor.getSchemeName();
+OUString sColorFillScheme = 
aFillProperti

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

2021-11-17 Thread Michael Stahl (via logerrit)
 svtools/source/svhtml/parhtml.cxx |8 ++--
 1 file changed, 6 insertions(+), 2 deletions(-)

New commits:
commit 5199c8d02779e61c0c7f3a50b94e008648f50796
Author: Michael Stahl 
AuthorDate: Tue Nov 16 14:28:15 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 19:41:10 2021 +0100

ofz#40766 svtools, sw: HTMLParser: really stop inserting control chars

35d248cab1f0d4800f72abb5cb6afb56f40d9083 forgot to fix one place where
control characters were in a presumed XML declaration.

Another place looks missing where comments are handled, but it's not
clear if these can be passed on to Writer.

Revert the previous fix from commit
b3325ef8cdfc2c82eec34e747106f75a9fccb7e4.

Change-Id: I11ad13de9122533626e512ce0384051e3e5bd97f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125306
Tested-by: Jenkins
Reviewed-by: Michael Stahl 
(cherry picked from commit a7116b890ccd6dd1721413b4de6591a8057668ef)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125390
Tested-by: Michael Stahl 

diff --git a/svtools/source/svhtml/parhtml.cxx 
b/svtools/source/svhtml/parhtml.cxx
index dad59b28a2ab..8e0e64ec9bf3 100644
--- a/svtools/source/svhtml/parhtml.cxx
+++ b/svtools/source/svhtml/parhtml.cxx
@@ -1069,6 +1069,7 @@ HtmlTokenId HTMLParser::GetNextToken_()
 aToken += sTmpBuffer.makeStringAndClear();
 nNextCh = GetNextChar();
 } while( '>' != nNextCh && '/' != nNextCh && 
!rtl::isAsciiWhiteSpace( nNextCh ) &&
+!linguistic::IsControlChar(nNextCh) &&
  IsParserWorking() && !rInput.eof() );
 
 if( !sTmpBuffer.isEmpty() )
@@ -1141,8 +1142,11 @@ HtmlTokenId HTMLParser::GetNextToken_()
 if( !bDone )
 aToken += OUString(&nNextCh,1);
 }
-else
-aToken += OUString(&nNextCh,1);
+else if (!linguistic::IsControlChar(nNextCh)
+|| nNextCh == '\r' || nNextCh == '\n' || 
nNextCh == '\t')
+{
+aToken += OUString(&nNextCh, 1);
+}
 if( !bDone )
 nNextCh = GetNextChar();
 }


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

2021-11-17 Thread Xisco Fauli (via logerrit)
 sc/qa/extras/scpdfexport.cxx|   43 
 sc/qa/extras/testdocuments/tdf84012.ods |binary
 2 files changed, 43 insertions(+)

New commits:
commit fe1121cb8c79b0843b26331325332c3953049a92
Author: Xisco Fauli 
AuthorDate: Wed Nov 17 17:14:17 2021 +0100
Commit: Xisco Fauli 
CommitDate: Wed Nov 17 19:36:22 2021 +0100

tdf#84012: sc_pdf_export: Add unittest

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

diff --git a/sc/qa/extras/scpdfexport.cxx b/sc/qa/extras/scpdfexport.cxx
index a9f7c1df4e77..a85e0d24 100644
--- a/sc/qa/extras/scpdfexport.cxx
+++ b/sc/qa/extras/scpdfexport.cxx
@@ -70,6 +70,7 @@ public:
 void testUnoCommands_Tdf120161();
 void testTdf64703_hiddenPageBreak();
 void testTdf143978();
+void testTdf84012();
 
 CPPUNIT_TEST_SUITE(ScPDFExportTest);
 CPPUNIT_TEST(testExportRange_Tdf120161);
@@ -77,6 +78,7 @@ public:
 CPPUNIT_TEST(testUnoCommands_Tdf120161);
 CPPUNIT_TEST(testTdf64703_hiddenPageBreak);
 CPPUNIT_TEST(testTdf143978);
+CPPUNIT_TEST(testTdf84012);
 CPPUNIT_TEST_SUITE_END();
 };
 
@@ -502,6 +504,47 @@ void ScPDFExportTest::testTdf143978()
 CPPUNIT_ASSERT_EQUAL(OUString("2021-11-17"), sText2);
 }
 
+void ScPDFExportTest::testTdf84012()
+{
+std::shared_ptr pPDFium = vcl::pdf::PDFiumLibrary::get();
+if (!pPDFium)
+{
+return;
+}
+
+mxComponent = loadFromDesktop(m_directories.getURLFromSrc(DATA_DIRECTORY) 
+ "tdf84012.ods",
+  "com.sun.star.sheet.SpreadsheetDocument");
+uno::Reference xModel(mxComponent, uno::UNO_QUERY);
+
+// A1
+ScRange range1(0, 0, 0, 0, 0, 0);
+std::shared_ptr pPDFFile = exportToPDF(xModel, range1);
+// Parse the export result with pdfium.
+SvFileStream aFile(pPDFFile->GetURL(), StreamMode::READ);
+SvMemoryStream aMemory;
+aMemory.WriteStream(aFile);
+std::unique_ptr pPdfDocument
+= pPDFium->openDocument(aMemory.GetData(), aMemory.GetSize());
+CPPUNIT_ASSERT(pPdfDocument);
+CPPUNIT_ASSERT_EQUAL(1, pPdfDocument->getPageCount());
+
+// Get the first page
+std::unique_ptr pPdfPage = 
pPdfDocument->openPage(/*nIndex=*/0);
+CPPUNIT_ASSERT(pPdfPage);
+std::unique_ptr pTextPage = 
pPdfPage->getTextPage();
+
+int nChars = pTextPage->countChars();
+std::vector aChars(nChars);
+for (int i = 0; i < nChars; i++)
+aChars[i] = pTextPage->getUnicode(i);
+OUString aActualText(aChars.data(), aChars.size());
+
+// Without the fix in place, this test would have failed with
+// - Expected: Blah blah (blah, blah)
+// - Actual  : Blah blah
+CPPUNIT_ASSERT_EQUAL(OUString("Blah blah (blah, blah)"), aActualText);
+}
+
 CPPUNIT_TEST_SUITE_REGISTRATION(ScPDFExportTest);
 CPPUNIT_PLUGIN_IMPLEMENT();
 
diff --git a/sc/qa/extras/testdocuments/tdf84012.ods 
b/sc/qa/extras/testdocuments/tdf84012.ods
new file mode 100644
index ..c2f30e0f4978
Binary files /dev/null and b/sc/qa/extras/testdocuments/tdf84012.ods differ


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

2021-11-17 Thread Xisco Fauli (via logerrit)
 sw/qa/extras/uiwriter/uiwriter3.cxx |   11 +++
 1 file changed, 3 insertions(+), 8 deletions(-)

New commits:
commit 82067a6e996c197d84394a82aa0adef243ed8f69
Author: Xisco Fauli 
AuthorDate: Wed Nov 17 16:14:40 2021 +0100
Commit: Xisco Fauli 
CommitDate: Wed Nov 17 19:35:48 2021 +0100

CppunitTest_sw_uiwriter3: simplify test a bit

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

diff --git a/sw/qa/extras/uiwriter/uiwriter3.cxx 
b/sw/qa/extras/uiwriter/uiwriter3.cxx
index b2d65f2f7233..23e8113f63dc 100644
--- a/sw/qa/extras/uiwriter/uiwriter3.cxx
+++ b/sw/qa/extras/uiwriter/uiwriter3.cxx
@@ -1839,14 +1839,9 @@ CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testTdf145584)
 std::unique_ptr pPdfTextPage = 
pPdfPage->getTextPage();
 CPPUNIT_ASSERT(pPdfTextPage);
 
-int nChars = pPdfTextPage->countChars();
-CPPUNIT_ASSERT_EQUAL(5, nChars);
-
-std::vector aChars(nChars);
-for (int i = 0; i < nChars; i++)
-aChars[i] = pPdfTextPage->getUnicode(i);
-OUString aActualText(aChars.data(), aChars.size());
-CPPUNIT_ASSERT_EQUAL(OUString("World"), aActualText);
+std::unique_ptr pPageObject = 
pPdfPage->getObject(0);
+OUString sText = pPageObject->getText(pPdfTextPage);
+CPPUNIT_ASSERT_EQUAL(OUString("World"), sText);
 }
 
 CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testTdf116315)


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

2021-11-17 Thread Xisco Fauli (via logerrit)
 sc/CppunitTest_sc_pdf_export.mk  |1 
 sc/qa/extras/scpdfexport.cxx |   51 +++
 sc/qa/extras/testdocuments/tdf143978.ods |binary
 3 files changed, 52 insertions(+)

New commits:
commit 2678f500fa4cf20a83c29fc28969efa71027b1ec
Author: Xisco Fauli 
AuthorDate: Wed Nov 17 15:59:20 2021 +0100
Commit: Xisco Fauli 
CommitDate: Wed Nov 17 19:35:28 2021 +0100

tdf#143978: sc_pdf_export: Add unittest

Exporting to PDF is the only way I could find
to test this issue
Change-Id: I05da96cadc2785d31a9a63925ee072456ec72a93

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

diff --git a/sc/CppunitTest_sc_pdf_export.mk b/sc/CppunitTest_sc_pdf_export.mk
index 9da73eed40d6..19b67515cb14 100644
--- a/sc/CppunitTest_sc_pdf_export.mk
+++ b/sc/CppunitTest_sc_pdf_export.mk
@@ -38,6 +38,7 @@ $(eval $(call gb_CppunitTest_use_libraries,sc_pdf_export, \
 tl \
 unotest \
 utl \
+vcl \
 ))
 
 $(eval $(call gb_CppunitTest_set_include,sc_pdf_export,\
diff --git a/sc/qa/extras/scpdfexport.cxx b/sc/qa/extras/scpdfexport.cxx
index 9ccfa8edc978..a9f7c1df4e77 100644
--- a/sc/qa/extras/scpdfexport.cxx
+++ b/sc/qa/extras/scpdfexport.cxx
@@ -28,6 +28,8 @@
 #include 
 #include 
 
+#include 
+
 #if USE_TLS_NSS
 #include 
 #endif
@@ -67,12 +69,14 @@ public:
 void testExportFitToPage_Tdf103516();
 void testUnoCommands_Tdf120161();
 void testTdf64703_hiddenPageBreak();
+void testTdf143978();
 
 CPPUNIT_TEST_SUITE(ScPDFExportTest);
 CPPUNIT_TEST(testExportRange_Tdf120161);
 CPPUNIT_TEST(testExportFitToPage_Tdf103516);
 CPPUNIT_TEST(testUnoCommands_Tdf120161);
 CPPUNIT_TEST(testTdf64703_hiddenPageBreak);
+CPPUNIT_TEST(testTdf143978);
 CPPUNIT_TEST_SUITE_END();
 };
 
@@ -451,6 +455,53 @@ void ScPDFExportTest::testTdf64703_hiddenPageBreak()
 }
 }
 
+void ScPDFExportTest::testTdf143978()
+{
+std::shared_ptr pPDFium = vcl::pdf::PDFiumLibrary::get();
+if (!pPDFium)
+{
+return;
+}
+
+mxComponent = loadFromDesktop(m_directories.getURLFromSrc(DATA_DIRECTORY) 
+ "tdf143978.ods",
+  "com.sun.star.sheet.SpreadsheetDocument");
+uno::Reference xModel(mxComponent, uno::UNO_QUERY);
+
+// A1:A2
+ScRange range1(0, 0, 0, 0, 1, 0);
+std::shared_ptr pPDFFile = exportToPDF(xModel, range1);
+// Parse the export result with pdfium.
+SvFileStream aFile(pPDFFile->GetURL(), StreamMode::READ);
+SvMemoryStream aMemory;
+aMemory.WriteStream(aFile);
+std::unique_ptr pPdfDocument
+= pPDFium->openDocument(aMemory.GetData(), aMemory.GetSize());
+CPPUNIT_ASSERT(pPdfDocument);
+CPPUNIT_ASSERT_EQUAL(1, pPdfDocument->getPageCount());
+
+// Get the first page
+std::unique_ptr pPdfPage = 
pPdfDocument->openPage(/*nIndex=*/0);
+CPPUNIT_ASSERT(pPdfPage);
+std::unique_ptr pTextPage = 
pPdfPage->getTextPage();
+
+int nPageObjectCount = pPdfPage->getObjectCount();
+CPPUNIT_ASSERT_EQUAL(2, nPageObjectCount);
+
+// Without the fix in place, this test would have failed with
+// - Expected: Dies ist viel zu viel Text
+// - Actual  : Dies ist vie
+std::unique_ptr pPageObject1 = 
pPdfPage->getObject(0);
+OUString sText1 = pPageObject1->getText(pTextPage);
+CPPUNIT_ASSERT_EQUAL(OUString("Dies ist viel zu viel Text"), sText1);
+
+// and it would also have failed with
+// - Expected: 2021-11-17
+// - Actual  : ###
+std::unique_ptr pPageObject2 = 
pPdfPage->getObject(1);
+OUString sText2 = pPageObject2->getText(pTextPage);
+CPPUNIT_ASSERT_EQUAL(OUString("2021-11-17"), sText2);
+}
+
 CPPUNIT_TEST_SUITE_REGISTRATION(ScPDFExportTest);
 CPPUNIT_PLUGIN_IMPLEMENT();
 
diff --git a/sc/qa/extras/testdocuments/tdf143978.ods 
b/sc/qa/extras/testdocuments/tdf143978.ods
new file mode 100644
index ..25a79defc66e
Binary files /dev/null and b/sc/qa/extras/testdocuments/tdf143978.ods differ


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

2021-11-17 Thread Mike Kaganski (via logerrit)
 sal/rtl/math.cxx |   10 +-
 1 file changed, 5 insertions(+), 5 deletions(-)

New commits:
commit b254ecc2bbc716343fccf303f58dfb034b487bca
Author: Mike Kaganski 
AuthorDate: Wed Nov 17 16:25:55 2021 +0200
Commit: Mike Kaganski 
CommitDate: Wed Nov 17 19:28:05 2021 +0100

Use C++17 hex-exponent floating point literals

... instead of some calculated/hardcoded decimal literals.
The new syntax represents the power of 2 exponent directly.

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

diff --git a/sal/rtl/math.cxx b/sal/rtl/math.cxx
index 6acf3a943fb2..bec83c380b32 100644
--- a/sal/rtl/math.cxx
+++ b/sal/rtl/math.cxx
@@ -1130,7 +1130,7 @@ double SAL_CALL rtl_math_round(double fValue, int 
nDecPlaces,
 // make sense, do not even try to multiply/divide and introduce inaccuracy.
 // For same reasons, do not attempt to round integers to decimals.
 if (nDecPlaces >= 0
-&& (fValue >= (static_cast(1) << 52)
+&& (fValue >= 0x1p52
 || isRepresentableInteger(fValue)))
 return fOrigValue;
 
@@ -1181,7 +1181,7 @@ double SAL_CALL rtl_math_round(double fValue, int 
nDecPlaces,
 // 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))
+if (fValue < 0x1p52)
 {
 switch ( eMode )
 {
@@ -1276,7 +1276,7 @@ double SAL_CALL rtl_math_pow10Exp(double fValue, int 
nExp) SAL_THROW_EXTERN_C()
 
 double SAL_CALL rtl_math_approxValue( double fValue ) SAL_THROW_EXTERN_C()
 {
-const double fBigInt = 219902322.0; // 2^41 -> only 11 bits left for 
fractional part, fine as decimal
+const double fBigInt = 0x1p41; // 2^41 -> only 11 bits left for fractional 
part, fine as decimal
 if (fValue == 0.0 || fValue == HUGE_VAL || !std::isfinite( fValue) || 
fValue > fBigInt)
 {
 // We don't handle these conditions.  Bail out.
@@ -1325,8 +1325,8 @@ double SAL_CALL rtl_math_approxValue( double fValue ) 
SAL_THROW_EXTERN_C()
 
 bool SAL_CALL rtl_math_approxEqual(double a, double b) SAL_THROW_EXTERN_C()
 {
-static const double e48 = 1.0 / (16777216.0 * 16777216.0);
-static const double e44 = e48 * 16.0;
+static const double e48 = 0x1p-48;
+static const double e44 = 0x1p-44;
 
 if (a == b)
 return true;


[Libreoffice-commits] core.git: Branch 'distro/cib/libreoffice-6-4' - 34 commits - chart2/source configure.ac connectivity/source download.lst external/icu external/libjpeg-turbo external/libmwaw exte

2021-11-17 Thread Michael Stahl (via logerrit)
 chart2/source/tools/InternalDataProvider.cxx   
  |7 
 configure.ac   
  |2 
 connectivity/source/commontools/dbconversion.cxx   
  |9 
 connectivity/source/drivers/dbase/DTable.cxx   
  |   13 -
 download.lst   
  |   30 +--
 external/icu/UnpackedTarball_icu.mk
  |2 
 external/icu/cec7de7a390dd6907b0ea0feb4488ed3934ee71d.patch.2  
  |   94 ++
 external/icu/e450fa50fc242282551f56b941dc93b9a8a0bcbb.patch.2  
  |   39 
 external/libjpeg-turbo/UnpackedTarball_libjpeg-turbo.mk
  |1 
 external/libjpeg-turbo/c76f4a08263b0cea40d2967560ac7c21f6959079.patch.1
  |   38 
 external/libmwaw/Library_mwaw.mk   
  |4 
 
external/libodfgen/0001-tdf-101077-make-double-string-conversion-locale-agno.patch.1
 |   58 --
 external/libodfgen/ExternalProject_libodfgen.mk
  |4 
 external/libodfgen/Library_odfgen.mk   
  |3 
 external/libodfgen/UnpackedTarball_libodfgen.mk
  |8 
 external/libodfgen/c++11.patch 
  |   44 
 external/libodfgen/libodfgen-bundled-soname.patch.0
  |5 
 external/pdfium/Library_pdfium.mk  
  |   44 ++--
 external/pdfium/README 
  |2 
 external/pdfium/build.patch.1  
  |   79 +++-
 external/pdfium/inc/pch/precompiled_pdfium.hxx 
  |   49 ++---
 external/pdfium/ubsan.patch
  |6 
 external/poppler/StaticLibrary_poppler.mk  
  |2 
 external/poppler/poppler-config.patch.1
  |   58 --
 include/vcl/BitmapTools.hxx
  |5 
 lotuswordpro/source/filter/lwpfribptr.cxx  
  |   35 +--
 lotuswordpro/source/filter/lwpfribptr.hxx  
  |4 
 sc/source/core/tool/compiler.cxx   
  |9 
 sc/source/core/tool/interpr1.cxx   
  |2 
 solenv/flatpak-manifest.in 
  |   19 +-
 svtools/source/svhtml/parhtml.cxx  
  |6 
 svx/source/svdraw/svdpdf.cxx   
  |   12 -
 sw/qa/core/data/html/pass/ofz40593-1.html  
  |binary
 sw/qa/core/data/ww5/pass/ooo37322-1-WW2.doc
  |binary
 sw/qa/core/data/ww8/pass/ofz34749-1.doc
  |binary
 sw/qa/core/data/ww8/pass/ofz38011-1.doc
  |binary
 sw/source/core/inc/layact.hxx  
  |8 
 sw/source/core/layout/layact.cxx   
  |   65 ++
 sw/source/core/layout/objectformattertxtfrm.cxx
  |2 
 sw/source/core/layout/pagechg.cxx  
  |2 
 sw/source/core/text/itrform2.cxx   
  |4 
 sw/source/core/undo/undobj.cxx 
  |   11 -
 sw/source/filter/html/htmltab.cxx  
  |   32 +++
 sw/source/filter/ww8/ww8par.cxx
  |   13 +
 sw/source/filter/ww8/ww8par.hxx
  |   12 +
 sw/source/filter/ww8/ww8par2.cxx   
  |9 
 sw/source/filter/ww8/ww8par6.cxx   
  |3 
 tools/source/generic/poly.cxx  
  |2 
 vcl/qa/cppunit/pdfexport/pdfexport.cxx 
  |   11 -
 vcl/source/gdi/jobset.cxx  
  |7 
 vcl/source/graphic/Manager.cxx 
  |7 
 vcl/unx/generic/printer/cpdmgr.cxx

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

2021-11-17 Thread Caolán McNamara (via logerrit)
 connectivity/source/commontools/dbconversion.cxx |9 ++---
 1 file changed, 6 insertions(+), 3 deletions(-)

New commits:
commit 04719364141815a59ce0ca035e3274dab52e8ae6
Author: Caolán McNamara 
AuthorDate: Sun Sep 26 14:23:54 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 19:05:46 2021 +0100

ofz#39301 month has to be in range [1-12]

Change-Id: I5a4ca534b24098342d8f465a32bc1887f40f5b63
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122629
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit 4a93b7a2f8a3fc13fed800d93e2103b785abeb62)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125387
Tested-by: Michael Stahl 
Reviewed-by: Michael Stahl 

diff --git a/connectivity/source/commontools/dbconversion.cxx 
b/connectivity/source/commontools/dbconversion.cxx
index fe600a7b8063..10fcda252ee4 100644
--- a/connectivity/source/commontools/dbconversion.cxx
+++ b/connectivity/source/commontools/dbconversion.cxx
@@ -27,6 +27,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -167,10 +168,13 @@ namespace dbtools
 ;
 }
 
-
 static sal_Int32 implDaysInMonth(sal_Int32 _nMonth, sal_Int32 _nYear)
 {
-OSL_ENSURE(_nMonth > 0 && _nMonth < 13,"Month as invalid value!");
+SAL_WARN_IF(_nMonth < 1 || _nMonth > 12, "connectivity.commontools", 
"Month has invalid value: " << _nMonth);
+if (_nMonth < 1)
+_nMonth = 1;
+else if (_nMonth > 12)
+_nMonth = 12;
 if (_nMonth != 2)
 return aDaysInMonth[_nMonth-1];
 else
@@ -182,7 +186,6 @@ namespace dbtools
 }
 }
 
-
 static sal_Int32 implRelativeToAbsoluteNull(const css::util::Date& _rDate)
 {
 sal_Int32 nDays = 0;


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sw/qa/core/data/html/pass/ofz40593-1.html |binary
 sw/source/filter/html/htmltab.cxx |   33 +++---
 2 files changed, 30 insertions(+), 3 deletions(-)

New commits:
commit 1a271a0d9a8ce2ceba3bf15dc38a0ff39b11e55d
Author: Caolán McNamara 
AuthorDate: Mon Nov 1 17:34:23 2021 +
Commit: Michael Stahl 
CommitDate: Wed Nov 17 19:03:47 2021 +0100

ofz#40593 remove Objects from m_xResizeDrawObjects if deleted during parse

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124563
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit 2f01faaf88b6d172d7293f0c9e2a061d99b8ceb5)

fix misplaced line

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124630
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit 4ed359093c991291216c39cffe14a60e607ec551)

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

diff --git a/sw/qa/core/data/html/pass/ofz40593-1.html 
b/sw/qa/core/data/html/pass/ofz40593-1.html
new file mode 100644
index ..43510d5d00b2
Binary files /dev/null and b/sw/qa/core/data/html/pass/ofz40593-1.html differ
diff --git a/sw/source/filter/html/htmltab.cxx 
b/sw/source/filter/html/htmltab.cxx
index 47d47fd64b3d..9972e4fee6ed 100644
--- a/sw/source/filter/html/htmltab.cxx
+++ b/sw/source/filter/html/htmltab.cxx
@@ -35,6 +35,8 @@
 #include 
 #include 
 #include 
+#include 
+#include 
 
 #include 
 #include 
@@ -369,7 +371,7 @@ typedef std::vector HTMLTableColumns;
 
 typedef std::vector SdrObjects;
 
-class HTMLTable
+class HTMLTable : public sdr::ObjectUser
 {
 OUString m_aId;
 OUString m_aStyle;
@@ -517,6 +519,8 @@ private:
 sal_uInt16 GetBorderWidth( const SvxBorderLine& rBLine,
bool bWithDistance=false ) const;
 
+virtual void ObjectInDestruction(const SdrObject& rObject) override;
+
 public:
 
 bool m_bFirstCell;// is there a cell created already?
@@ -526,7 +530,7 @@ public:
   bool bHasToFly,
   const HTMLTableOptions& rOptions);
 
-~HTMLTable();
+virtual ~HTMLTable();
 
 // Identifying of a cell
 const HTMLTableCell& GetCell(sal_uInt16 nRow, sal_uInt16 nCell) const;
@@ -1055,11 +1059,33 @@ void SwHTMLParser::DeregisterHTMLTable(HTMLTable* pOld)
 m_aTables.erase(std::remove(m_aTables.begin(), m_aTables.end(), pOld));
 }
 
+// if any m_pResizeDrawObjects members are deleted during parse, remove them
+// from m_pResizeDrawObjects and m_pDrawObjectPrcWidths
+void HTMLTable::ObjectInDestruction(const SdrObject& rObject)
+{
+auto it = std::find(m_pResizeDrawObjects->begin(), 
m_pResizeDrawObjects->end(), &rObject);
+assert(it != m_pResizeDrawObjects->end());
+auto nIndex = std::distance(m_pResizeDrawObjects->begin(), it);
+m_pResizeDrawObjects->erase(it);
+auto otherit = m_pDrawObjectPrcWidths->begin() + nIndex * 3;
+m_pDrawObjectPrcWidths->erase(otherit, otherit + 3);
+}
+
 HTMLTable::~HTMLTable()
 {
 m_pParser->DeregisterHTMLTable(this);
 
-delete m_pResizeDrawObjects;
+if (m_pResizeDrawObjects)
+{
+size_t nCount = m_pResizeDrawObjects->size();
+for (size_t i = 0; i < nCount; ++i)
+{
+SdrObject *pObj = (*m_pResizeDrawObjects)[i];
+pObj->RemoveObjectUser(*this);
+}
+delete m_pResizeDrawObjects;
+}
+
 delete m_pDrawObjectPrcWidths;
 
 delete m_pContext;
@@ -2454,6 +2480,7 @@ void HTMLTable::RegisterDrawObject( SdrObject *pObj, 
sal_uInt8 nPrcWidth )
 if( !m_pResizeDrawObjects )
 m_pResizeDrawObjects = new SdrObjects;
 m_pResizeDrawObjects->push_back( pObj );
+pObj->AddObjectUser(*this);
 
 if( !m_pDrawObjectPrcWidths )
 m_pDrawObjectPrcWidths = new std::vector;


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 connectivity/source/drivers/dbase/DTable.cxx |   13 -
 1 file changed, 8 insertions(+), 5 deletions(-)

New commits:
commit ceab615e834b4d2b4cbe51421bab28ac55df2887
Author: Caolán McNamara 
AuthorDate: Sun Sep 26 14:05:37 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 19:02:56 2021 +0100

ofz#39304 short timestamp record

Change-Id: I8f783473dd5d4679846c7c866cd1853ef7d919fc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122628
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit bfc70a9f314bbb5b03247be25544e9b4cc467f8d)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125388
Tested-by: Michael Stahl 
Reviewed-by: Michael Stahl 

diff --git a/connectivity/source/drivers/dbase/DTable.cxx 
b/connectivity/source/drivers/dbase/DTable.cxx
index f0112d35a03e..8d9539996452 100644
--- a/connectivity/source/drivers/dbase/DTable.cxx
+++ b/connectivity/source/drivers/dbase/DTable.cxx
@@ -775,10 +775,8 @@ bool ODbaseTable::fetchRow(OValueRefRow& _rRow, const 
OSQLColumns & _rCols, bool
 for (std::size_t i = 1; aIter != aEnd && nByteOffset <= m_nBufferSize && i 
< nCount;++aIter, i++)
 {
 // Lengths depending on data type:
-sal_Int32 nLen = 0;
-sal_Int32 nType = 0;
-nLen= m_aPrecisions[i-1];
-nType   = m_aTypes[i-1];
+sal_Int32 nLen = m_aPrecisions[i-1];
+sal_Int32 nType = m_aTypes[i-1];
 
 switch(nType)
 {
@@ -837,8 +835,13 @@ bool ODbaseTable::fetchRow(OValueRefRow& _rRow, const 
OSQLColumns & _rCols, bool
 else if ( DataType::TIMESTAMP == nType )
 {
 sal_Int32 nDate = 0,nTime = 0;
+if (nLen < 8)
+{
+SAL_WARN("connectivity.drivers", "short TIMESTAMP");
+return false;
+}
 memcpy(&nDate, pData, 4);
-memcpy(&nTime, pData+ 4, 4);
+memcpy(&nTime, pData + 4, 4);
 if ( !nDate && !nTime )
 {
 (_rRow->get())[i]->setNull();


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sw/source/filter/ww8/ww8par.cxx |4 ++--
 sw/source/filter/ww8/ww8par.hxx |5 +++--
 2 files changed, 5 insertions(+), 4 deletions(-)

New commits:
commit fe1e7f120581aad3b818e55fc341a1f668b91aae
Author: Caolán McNamara 
AuthorDate: Sat Sep 25 19:57:36 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 19:00:05 2021 +0100

ofz#39252 use safer SwUnoCursor for the pos to move back to

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122611
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit ca844cbdc3e933e3082e9cde0632445916de819e)

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

diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index 5d512e2d9d37..c2cf93d00bcb 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -1975,7 +1975,7 @@ void SwWW8ImplReader::ImportDopTypography(const 
WW8DopTypography &rTypo)
  * Footnotes and Endnotes
  */
 WW8ReaderSave::WW8ReaderSave(SwWW8ImplReader* pRdr ,WW8_CP nStartCp) :
-maTmpPos(*pRdr->m_pPaM->GetPoint()),
+mxTmpPos(pRdr->m_rDoc.CreateUnoCursor(*pRdr->m_pPaM->GetPoint())),
 mxOldStck(std::move(pRdr->m_xCtrlStck)),
 mxOldAnchorStck(std::move(pRdr->m_xAnchorStck)),
 mxOldRedlines(std::move(pRdr->m_xRedlineStack)),
@@ -2073,7 +2073,7 @@ void WW8ReaderSave::Restore( SwWW8ImplReader* pRdr )
 pRdr->DeleteAnchorStack();
 pRdr->m_xAnchorStck = std::move(mxOldAnchorStck);
 
-*pRdr->m_pPaM->GetPoint() = maTmpPos;
+*pRdr->m_pPaM->GetPoint() = GetStartPos();
 
 if (mxOldPlcxMan != pRdr->m_xPlcxMan)
 pRdr->m_xPlcxMan = mxOldPlcxMan;
diff --git a/sw/source/filter/ww8/ww8par.hxx b/sw/source/filter/ww8/ww8par.hxx
index a0d500a6eb81..82d861adc0a8 100644
--- a/sw/source/filter/ww8/ww8par.hxx
+++ b/sw/source/filter/ww8/ww8par.hxx
@@ -46,6 +46,7 @@
 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -584,7 +585,7 @@ class WW8ReaderSave
 {
 private:
 WW8PLCFxSaveAll maPLCFxSave;
-SwPosition maTmpPos;
+std::shared_ptr mxTmpPos;
 std::deque maOldApos;
 std::deque maOldFieldStack;
 std::unique_ptr mxOldStck;
@@ -612,7 +613,7 @@ private:
 public:
 WW8ReaderSave(SwWW8ImplReader* pRdr, WW8_CP nStart=-1);
 void Restore(SwWW8ImplReader* pRdr);
-const SwPosition &GetStartPos() const { return maTmpPos; }
+const SwPosition &GetStartPos() const { return *mxTmpPos->GetPoint(); }
 };
 
 enum class eF_ResT { OK, TEXT, TAGIGN, READ_FSPA };


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sw/qa/core/data/ww8/pass/ofz38011-1.doc |binary
 sw/source/filter/ww8/ww8par2.cxx|9 +
 2 files changed, 9 insertions(+)

New commits:
commit d574dd113e9b7b45804a6eafadda844ac5fc2031
Author: Caolán McNamara 
AuthorDate: Thu Sep 2 13:35:34 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 18:59:20 2021 +0100

ofz#38011 save and restore m_pLastAnchorPos via UnoCursor

when we do some operations that may delete paragraphs

Change-Id: I2165dd287771f06c6d0fd061dd7659b06db4bd72
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121511
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit bc7baa18435000f47f90e47d3300710bcb4cf56b)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125385
Tested-by: Michael Stahl 
Reviewed-by: Michael Stahl 

diff --git a/sw/qa/core/data/ww8/pass/ofz38011-1.doc 
b/sw/qa/core/data/ww8/pass/ofz38011-1.doc
new file mode 100644
index ..8ef58ca5395d
Binary files /dev/null and b/sw/qa/core/data/ww8/pass/ofz38011-1.doc differ
diff --git a/sw/source/filter/ww8/ww8par2.cxx b/sw/source/filter/ww8/ww8par2.cxx
index e4dc5323324e..bc80e1447783 100644
--- a/sw/source/filter/ww8/ww8par2.cxx
+++ b/sw/source/filter/ww8/ww8par2.cxx
@@ -2744,8 +2744,17 @@ void WW8TabDesc::FinishSwTable()
 {
 m_pIo->m_xRedlineStack->closeall(*m_pIo->m_pPaM->GetPoint());
 m_pIo->m_aFrameRedlines.emplace(std::move(m_pIo->m_xRedlineStack));
+
+// ofz#38011 drop m_pLastAnchorPos during RedlineStack dtor and restore it 
afterwards to the same
+// place, or somewhere close if that place got destroyed
+std::shared_ptr xLastAnchorCursor(m_pIo->m_pLastAnchorPos ? 
m_pIo->m_rDoc.CreateUnoCursor(*m_pIo->m_pLastAnchorPos) : nullptr);
+m_pIo->m_pLastAnchorPos.reset();
+
 m_pIo->m_xRedlineStack = std::move(mxOldRedlineStack);
 
+if (xLastAnchorCursor)
+m_pIo->m_pLastAnchorPos.reset(new 
SwPosition(*xLastAnchorCursor->GetPoint()));
+
 WW8DupProperties aDup(m_pIo->m_rDoc,m_pIo->m_xCtrlStck.get());
 m_pIo->m_xCtrlStck->SetAttr( *m_pIo->m_pPaM->GetPoint(), 0, false);
 


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 include/vcl/BitmapTools.hxx |5 +
 1 file changed, 5 insertions(+)

New commits:
commit 0a14572868917feafe0c93a37284be352cb4789c
Author: Caolán McNamara 
AuthorDate: Sun Aug 29 16:58:11 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 18:58:29 2021 +0100

ofz#37796 limit to numeric_limits::max

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121230
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit 72da4c623baf60eb2b7073697cd36ffb3022847d)

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

diff --git a/include/vcl/BitmapTools.hxx b/include/vcl/BitmapTools.hxx
index 2ff0f69eea79..941ef8c9c381 100644
--- a/include/vcl/BitmapTools.hxx
+++ b/include/vcl/BitmapTools.hxx
@@ -24,6 +24,7 @@
 #include 
 #include 
 #include 
+#include 
 
 namespace vcl {
 namespace bitmap {
@@ -43,6 +44,10 @@ public:
   mnBitCount(nBitCount)
 {
 assert(nBitCount == 24 || nBitCount == 32);
+if (rSize.getWidth() > std::numeric_limits::max() || 
rSize.getWidth() < 0)
+throw std::bad_alloc();
+if (rSize.getHeight() > std::numeric_limits::max() || 
rSize.getHeight() < 0)
+throw std::bad_alloc();
 sal_Int32 nRowSize, nDataSize;
 if (o3tl::checked_multiply(rSize.getWidth(), nBitCount/8, 
nRowSize) ||
 o3tl::checked_multiply(nRowSize, rSize.getHeight(), 
nDataSize) ||


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sw/qa/core/data/ww5/pass/ooo37322-1-WW2.doc |binary
 sw/source/filter/ww8/ww8par.cxx |9 +
 2 files changed, 9 insertions(+)

New commits:
commit 218eb2af815c89ec88342492ceb9b8ea57b1bf06
Author: Caolán McNamara 
AuthorDate: Wed Aug 18 16:57:18 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 18:56:34 2021 +0100

ofz#37322 Bad-cast

use a SwUnoCursor for the LastAnchorPos around here, this is similar to
ofz#9858 Bad-cast

Change-Id: I194a39ae13c382740b0ba8145dcc33fb2107105d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120679
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit c1cd505c67a53a0a27589889b34641612d10946d)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125383
Tested-by: Michael Stahl 
Reviewed-by: Michael Stahl 

diff --git a/sw/qa/core/data/ww5/pass/ooo37322-1-WW2.doc 
b/sw/qa/core/data/ww5/pass/ooo37322-1-WW2.doc
new file mode 100644
index ..fd64eeed2963
Binary files /dev/null and b/sw/qa/core/data/ww5/pass/ooo37322-1-WW2.doc differ
diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index d151a4ea4414..5d512e2d9d37 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -2059,8 +2059,17 @@ void WW8ReaderSave::Restore( SwWW8ImplReader* pRdr )
 
 pRdr->m_xRedlineStack->closeall(*pRdr->m_pPaM->GetPoint());
 pRdr->m_aFrameRedlines.emplace(std::move(pRdr->m_xRedlineStack));
+
+// ofz#37322 drop m_pLastAnchorPos during RedlineStack dtor and restore it 
afterwards to the same
+// place, or somewhere close if that place got destroyed
+std::shared_ptr xLastAnchorCursor(pRdr->m_pLastAnchorPos ? 
pRdr->m_rDoc.CreateUnoCursor(*pRdr->m_pLastAnchorPos) : nullptr);
+pRdr->m_pLastAnchorPos.reset();
+
 pRdr->m_xRedlineStack = std::move(mxOldRedlines);
 
+if (xLastAnchorCursor)
+pRdr->m_pLastAnchorPos.reset(new 
SwPosition(*xLastAnchorCursor->GetPoint()));
+
 pRdr->DeleteAnchorStack();
 pRdr->m_xAnchorStck = std::move(mxOldAnchorStck);
 


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 editeng/source/misc/svxacorr.cxx |3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit 5cfe6907be9d7fec09c10db59a1fb29c278c23a5
Author: Caolán McNamara 
AuthorDate: Tue Nov 16 14:46:57 2021 +
Commit: Michael Stahl 
CommitDate: Wed Nov 17 18:55:46 2021 +0100

Related: tdf#142719 the first time undo adds an exception it gets lost

Change-Id: Ie963e92a15ddd45316f999e950fff359d7dd6f5d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125314
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit 75a14a1e962793de1483ceea1bc36cc78144e386)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125145
Reviewed-by: Michael Stahl 
Tested-by: Michael Stahl 

diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx
index 4507cd5523b5..6c7efa0e170b 100644
--- a/editeng/source/misc/svxacorr.cxx
+++ b/editeng/source/misc/svxacorr.cxx
@@ -2406,8 +2406,7 @@ bool 
SvxAutoCorrectLanguageLists::AddToCplSttExceptList(const OUString& rNew)
 bool SvxAutoCorrectLanguageLists::AddToWrdSttExceptList(const OUString& rNew)
 {
 bool bRet = false;
-SvStringsISortDtor* pExceptList = LoadWrdSttExceptList();
-if( !rNew.isEmpty() && pExceptList && pExceptList->insert( rNew ).second )
+if( !rNew.isEmpty() && GetWrdSttExceptList()->insert( rNew ).second )
 {
 MakeUserStorage_Impl();
 tools::SvRef xStg = new SotStorage( sUserAutoCorrFile, 
StreamMode::READWRITE );


FYI: ccache for MSVC/Windows

2021-11-17 Thread Luboš Luňák


 Hello,

 current master now can build also Windows builds using ccache. MSVC support 
in ccache is a work in progress and so currently it's necessary to use a 
patched ccache, either from [1] or get a binary from [2]. You can put it 
in /opt/lo/bin and configure should find it.

 It doesn't help as much as on Linux due to generally worse Windows build 
performance, but it still can help.

 Given that AFAIK Windows bots are now the Jenkins bottleneck, I suppose it 
could help there too, but I'll leave it to the admins to decide when it's a 
good idea to use a random WIP patched ccache.

[1] https://github.com/llunak/ccache/tree/msvc
[2] https://people.collabora.com/~llunak/download/ccache.exe

-- 
 Luboš Luňák
 l.lu...@collabora.com


License Statement

2021-11-17 Thread Harjot Singh
All of my past & future contributions to LibreOffice may be licensed under
the MPLv2/LGPLv3+ dual license.

Regards
Harjot


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

2021-11-17 Thread Sarper Akdemir (via logerrit)
 include/oox/drawingml/color.hxx  |2 ++
 oox/source/drawingml/color.cxx   |   15 +++
 oox/source/drawingml/textcharacterproperties.cxx |2 ++
 oox/source/token/properties.txt  |2 ++
 4 files changed, 21 insertions(+)

New commits:
commit f394e2519c99cd1514c859cda67b1c09e68e6c19
Author: Sarper Akdemir 
AuthorDate: Fri Aug 20 00:45:55 2021 +0300
Commit: Miklos Vajna 
CommitDate: Wed Nov 17 18:00:39 2021 +0100

implement initial pptx theme color import

[ Miklos: this only handles colors as-is, without any effects. ]

(cherry picked from commit ec68ca0b5fb6773f42600f6a5825b4794cdb0990,
from the feature/themesupport2 branch)
Change-Id: I89890cf7ba6ec758698011752b63d7a60872bef2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125404
Tested-by: Jenkins
Reviewed-by: Miklos Vajna 

diff --git a/include/oox/drawingml/color.hxx b/include/oox/drawingml/color.hxx
index 59f417cfac52..f213dba9a973 100644
--- a/include/oox/drawingml/color.hxx
+++ b/include/oox/drawingml/color.hxx
@@ -98,6 +98,8 @@ public:
 
 /** Returns the scheme name from the a:schemeClr element for 
interoperability purposes */
 const OUString& getSchemeName() const { return msSchemeName; }
+sal_Int16   getSchemeIndex() const;
+
 /** Returns the unaltered list of transformations for interoperability 
purposes */
 const css::uno::Sequence< css::beans::PropertyValue >& 
getTransformations() const { return maInteropTransformations;}
 
diff --git a/oox/source/drawingml/color.cxx b/oox/source/drawingml/color.cxx
index 3c9ac2f6ac44..9f4026727b56 100644
--- a/oox/source/drawingml/color.cxx
+++ b/oox/source/drawingml/color.cxx
@@ -661,6 +661,21 @@ sal_Int16 Color::getTransparency() const
 return sal_Int16(std::round( (1.0 * (MAX_PERCENT - mnAlpha)) / 
PER_PERCENT) );
 }
 
+sal_Int16 Color::getSchemeIndex() const
+{
+static std::map const aSchemeColorNameToIndex{
+{ "dk1", 0 }, { "lt1", 1 }, { "dk2", 2 }, { "lt2", 3 },
+{ "accent1", 4 }, { "accent2", 5 }, { "accent3", 6 }, { "accent4", 7 },
+{ "accent5", 8 }, { "accent6", 9 }, { "hlink", 10 },  { "folHlink", 11 
}
+};
+
+auto aIt = aSchemeColorNameToIndex.find(msSchemeName);
+if( aIt == aSchemeColorNameToIndex.end() )
+return -1;
+else
+return aIt->second;
+}
+
 // private 
 
 void Color::setResolvedRgb( ::Color nRgb ) const
diff --git a/oox/source/drawingml/textcharacterproperties.cxx 
b/oox/source/drawingml/textcharacterproperties.cxx
index 4eb5acaffb56..9cbc331d05fa 100644
--- a/oox/source/drawingml/textcharacterproperties.cxx
+++ b/oox/source/drawingml/textcharacterproperties.cxx
@@ -111,6 +111,8 @@ void TextCharacterProperties::pushToPropMap( PropertyMap& 
rPropMap, const XmlFil
 {
 Color aColor = maFillProperties.getBestSolidColor();
 rPropMap.setProperty(PROP_CharColor, 
aColor.getColor(rFilter.getGraphicHelper()));
+// set color theme index
+rPropMap.setProperty(PROP_CharColorTheme, aColor.getSchemeIndex());
 
 if (aColor.hasTransparency())
 {
diff --git a/oox/source/token/properties.txt b/oox/source/token/properties.txt
index 2c56d0f46804..951a03e7eba0 100644
--- a/oox/source/token/properties.txt
+++ b/oox/source/token/properties.txt
@@ -54,6 +54,8 @@ CharBackColor
 CharCaseMap
 CharColor
 CharContoured
+CharColorTheme
+CharColorTintOrShade
 CharEscapement
 CharEscapementHeight
 CharFontCharSet


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

2021-11-17 Thread Xisco Fauli (via logerrit)
 sc/qa/uitest/calc_dialogs/openDialogs.py |6 --
 sc/qa/uitest/calc_tests9/tdf126673.py|7 +++
 sc/qa/uitest/textToColumns/tdf89907.py   |8 +++-
 3 files changed, 14 insertions(+), 7 deletions(-)

New commits:
commit de4c17e7a7af37196dd36bb62967b557f9aa84f7
Author: Xisco Fauli 
AuthorDate: Wed Nov 17 13:14:35 2021 +0100
Commit: Xisco Fauli 
CommitDate: Wed Nov 17 17:44:39 2021 +0100

uitest: sc: use existing tests to test SetOptimalColumnWidth...

... and SetOptimalRowHeight dialogs

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

diff --git a/sc/qa/uitest/calc_dialogs/openDialogs.py 
b/sc/qa/uitest/calc_dialogs/openDialogs.py
index a816b177341a..1370449d5c9d 100644
--- a/sc/qa/uitest/calc_dialogs/openDialogs.py
+++ b/sc/qa/uitest/calc_dialogs/openDialogs.py
@@ -46,10 +46,12 @@ dialogs = [
 # tested in sc/qa/uitest/calc_tests/formatCells.py
 # {"command": ".uno:RowHeight", "closeButton": "cancel"},
 # tested in sc/qa/uitest/calc_tests/rows.py
-{"command": ".uno:SetOptimalRowHeight", "closeButton": "cancel"},
+# {"command": ".uno:SetOptimalRowHeight", "closeButton": "cancel"},
+# tested in sc/qa/uitest/calc_tests9/tdf126673.py
 # {"command": ".uno:ColumnWidth", "closeButton": "cancel"},
 # tested in sc/qa/uitest/calc_tests/columns.py
-{"command": ".uno:SetOptimalColumnWidth", "closeButton": "cancel"},
+# {"command": ".uno:SetOptimalColumnWidth", "closeButton": "cancel"},
+# tested in sc/qa/uitest/textToColumns/tdf89907.py
 # {"command": ".uno:PageFormatDialog", "closeButton": "cancel"},
 # tested in sc/qa/uitest/pageFormat/tdf123508.py
 {"command": ".uno:EditPrintArea", "closeButton": "cancel", "skipTestOK": 
True},
diff --git a/sc/qa/uitest/calc_tests9/tdf126673.py 
b/sc/qa/uitest/calc_tests9/tdf126673.py
index a303949d0f1a..bcc2c49b69a0 100644
--- a/sc/qa/uitest/calc_tests9/tdf126673.py
+++ b/sc/qa/uitest/calc_tests9/tdf126673.py
@@ -26,15 +26,14 @@ class tdf126673(UITestCase):
 gridwin.executeAction("SELECT", mkPropertyValues({"CELL": "A2"}))
 #optimal row height
 with 
self.ui_test.execute_dialog_through_command(".uno:SetOptimalRowHeight") as 
xDialog:
-pass
+xvalue = xDialog.getChild("value")
+self.assertEqual("0.00 cm", get_state_as_dict(xvalue)["Text"])
 
 #select A2
 gridwin.executeAction("SELECT", mkPropertyValues({"CELL": "A2"}))
 #row height
 with self.ui_test.execute_dialog_through_command(".uno:RowHeight", 
close_button="cancel") as xDialog:
 xvalue = xDialog.getChild("value")
-heightStrOrig = get_state_as_dict(xvalue)["Text"]
-heightVal = heightStrOrig[:4]  #default 0.45 cm,
-self.assertEqual(heightVal > '0.45', True)  #new value is 
bigger then default
+self.assertEqual("1.2365 cm", 
get_state_as_dict(xvalue)["Text"])
 
 # vim: set shiftwidth=4 softtabstop=4 expandtab:
diff --git a/sc/qa/uitest/textToColumns/tdf89907.py 
b/sc/qa/uitest/textToColumns/tdf89907.py
index b046b758a9d8..1270db408bb2 100644
--- a/sc/qa/uitest/textToColumns/tdf89907.py
+++ b/sc/qa/uitest/textToColumns/tdf89907.py
@@ -9,6 +9,7 @@ from uitest.uihelper.common import get_state_as_dict
 from uitest.uihelper.calc import enter_text_to_cell
 from libreoffice.calc.document import get_cell_by_position
 from libreoffice.uno.propertyvalue import mkPropertyValues
+from uitest.uihelper.common import change_measurement_unit
 #Bug 89907 - Text to columns only affects first line when width is auto set
 
 class tdf89907(UITestCase):
@@ -17,6 +18,8 @@ class tdf89907(UITestCase):
 xCalcDoc = self.xUITest.getTopFocusWindow()
 gridwin = xCalcDoc.getChild("grid_window")
 
+change_measurement_unit(self, "Centimeter")
+
 #Add data
 enter_text_to_cell(gridwin, "A1", "afasdfs.fdfasd.fsadf.fasd")
 enter_text_to_cell(gridwin, "A2", "3242.43242.3242.2342")
@@ -26,7 +29,10 @@ class tdf89907(UITestCase):
 gridwin.executeAction("SELECT", mkPropertyValues({"CELL": "A1"}))
 self.xUITest.executeCommand(".uno:SelectColumn")
 #Optimal Width
-self.xUITest.executeCommand(".uno:SetOptimalColumnWidthDirect")
+with 
self.ui_test.execute_dialog_through_command(".uno:SetOptimalColumnWidth") as 
xDialog:
+xvalue = xDialog.getChild("value")
+self.assertEqual("0.20 cm", get_state_as_dict(xvalue)["Text"])
+
 # Data - Text to Columns
 with 
self.ui_test.execute_dialog_through_command(".uno:TextToColumns") as xDialog:
 xother = xDialog.getChild("other")


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

2021-11-17 Thread Xisco Fauli (via logerrit)
 sd/qa/uitest/impress_tests/tdf137637.py |   34 
 1 file changed, 34 insertions(+)

New commits:
commit 041379f6420f6d67bfd2bb952968e8c183f13a9d
Author: Xisco Fauli 
AuthorDate: Wed Aug 18 11:18:42 2021 +0200
Commit: Xisco Fauli 
CommitDate: Wed Nov 17 17:12:54 2021 +0100

tdf#137637: sd: Add UItest

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

diff --git a/sd/qa/uitest/impress_tests/tdf137637.py 
b/sd/qa/uitest/impress_tests/tdf137637.py
new file mode 100644
index ..a76c0c970b29
--- /dev/null
+++ b/sd/qa/uitest/impress_tests/tdf137637.py
@@ -0,0 +1,34 @@
+# -*- tab-width: 4; indent-tabs-mode: nil; py-indent-offset: 4 -*-
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+from uitest.framework import UITestCase
+from libreoffice.uno.propertyvalue import mkPropertyValues
+
+class Tdf137637(UITestCase):
+
+   def test_tdf137637(self):
+with self.ui_test.create_doc_in_start_center("impress") as document:
+
+xTemplateDlg = self.xUITest.getTopFocusWindow()
+xCancelBtn = xTemplateDlg.getChild("close")
+self.ui_test.close_dialog_through_button(xCancelBtn)
+
+# Insert shape with Ctrl key
+xArgs = mkPropertyValues({"KeyModifier": 8192})
+
self.xUITest.executeCommandWithParameters(".uno:BasicShapes.rectangle", xArgs)
+
+self.assertEqual("com.sun.star.drawing.SvxShapeCollection", 
document.CurrentSelection.getImplementationName())
+
+xImpressDoc = self.xUITest.getTopFocusWindow()
+
+xEditWin = xImpressDoc.getChild("impress_win")
+
+xEditWin.executeAction("SIDEBAR", mkPropertyValues({"PANEL": 
"SdCustomAnimationPanel"}))
+
+# Without the fix in place, this test would have failed with
+# AttributeError: 'NoneType' object has no attribute 
'getImplementationName'
+self.assertEqual("com.sun.star.drawing.SvxShapeCollection", 
document.CurrentSelection.getImplementationName())
+


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

2021-11-17 Thread Xisco Fauli (via logerrit)
 sc/qa/uitest/calc_tests/columns.py |   15 ---
 sc/qa/uitest/calc_tests/rows.py|   16 +---
 2 files changed, 17 insertions(+), 14 deletions(-)

New commits:
commit 1d98c34e647edb44457bcc4ac2d6ff7ec237f556
Author: Xisco Fauli 
AuthorDate: Wed Nov 17 12:06:10 2021 +0100
Commit: Xisco Fauli 
CommitDate: Wed Nov 17 17:11:07 2021 +0100

tdf#144247: sc: Add UItest

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

diff --git a/sc/qa/uitest/calc_tests/columns.py 
b/sc/qa/uitest/calc_tests/columns.py
index bae551b4ed27..dafd825c76c8 100644
--- a/sc/qa/uitest/calc_tests/columns.py
+++ b/sc/qa/uitest/calc_tests/columns.py
@@ -24,15 +24,16 @@ class CalcColumns(UITestCase):
 xvalue = xDialog.getChild("value")
 xdefault = xDialog.getChild("default")
 self.assertEqual(get_state_as_dict(xdefault)["Selected"], 
"true")  #default selected
-heightStrOrig = get_state_as_dict(xvalue)["Text"]
-heightVal = heightStrOrig[:4]  #default 2.26 cm
-xvalue.executeAction("UP", tuple())  #2.36 cm
-heightStr = get_state_as_dict(xvalue)["Text"]
-heightValNew = heightStr[:4]
+
+# tdf#144247: Without the fix in place, this test would have 
failed with
+# AssertionError: '2.26 cm' != '2.2578 cm'
+self.assertEqual("2.26 cm", get_state_as_dict(xvalue)["Text"])
+xvalue.executeAction("UP", tuple())
+self.assertEqual("2.30 cm", get_state_as_dict(xvalue)["Text"])
 self.assertEqual(get_state_as_dict(xdefault)["Selected"], 
"false")  #default not selected
-self.assertEqual(heightValNew > heightVal, True)  #new value 
is bigger
 xdefault.executeAction("CLICK", tuple())  #click default
-self.assertEqual(get_state_as_dict(xvalue)["Text"] == 
heightStrOrig, True)  #default value set
+self.assertEqual("2.26 cm", get_state_as_dict(xvalue)["Text"])
+
 #write your own value
 xvalue.executeAction("TYPE", 
mkPropertyValues({"KEYCODE":"CTRL+A"}))
 xvalue.executeAction("TYPE", 
mkPropertyValues({"KEYCODE":"BACKSPACE"}))
diff --git a/sc/qa/uitest/calc_tests/rows.py b/sc/qa/uitest/calc_tests/rows.py
index bdc9a1a102d4..1e426623 100644
--- a/sc/qa/uitest/calc_tests/rows.py
+++ b/sc/qa/uitest/calc_tests/rows.py
@@ -24,15 +24,17 @@ class CalcRows(UITestCase):
 xvalue = xDialog.getChild("value")
 xdefault = xDialog.getChild("default")
 self.assertEqual(get_state_as_dict(xdefault)["Selected"], 
"true")  #default selected
-heightStrOrig = get_state_as_dict(xvalue)["Text"]
-heightVal = heightStrOrig[:4]  #default 0.45 cm
-xvalue.executeAction("UP", tuple())  #0.50 cm
-heightStr = get_state_as_dict(xvalue)["Text"]
-heightValNew = heightStr[:4]
+
+# tdf#144247: Without the fix in place, this test would have 
failed with
+# AssertionError: '0.45 cm' != '0.4516 cm'
+self.assertEqual("0.45 cm", get_state_as_dict(xvalue)["Text"])
+xvalue.executeAction("UP", tuple())
+self.assertEqual("0.50 cm", get_state_as_dict(xvalue)["Text"])
+
 self.assertEqual(get_state_as_dict(xdefault)["Selected"], 
"false")  #default not selected
-self.assertEqual(heightValNew > heightVal, True)  #new value 
is bigger
 xdefault.executeAction("CLICK", tuple())  #click default
-self.assertEqual(get_state_as_dict(xvalue)["Text"] == 
heightStrOrig, True)  #default value set
+self.assertEqual("0.45 cm", get_state_as_dict(xvalue)["Text"])
+
 #write your own value
 xvalue.executeAction("TYPE", 
mkPropertyValues({"KEYCODE":"CTRL+A"}))
 xvalue.executeAction("TYPE", 
mkPropertyValues({"KEYCODE":"BACKSPACE"}))


[Libreoffice-commits] core.git: jvmfwk/plugins

2021-11-17 Thread Stephan Bergmann (via logerrit)
 jvmfwk/plugins/sunmajor/pluginlib/vendorbase.cxx |4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit f05a42ef8c8192186f91a169047742e5c3ae9b9e
Author: Stephan Bergmann 
AuthorDate: Wed Nov 17 14:01:55 2021 +0100
Commit: Stephan Bergmann 
CommitDate: Wed Nov 17 16:53:47 2021 +0100

tdf#144695 VendorBase::isValidArch also for macOS

Lets extend it only to macOS (where there is some confusion now with 
Rosetta-
translated vs. native processes on Apple M1 machines), not to all Unix-like 
OSs:
The comment that it "is not defined what the exact [os.arch] values are" is
still relevant.  At least for OpenJDK, while Windows has a hardcoded list of
possible values in GetJavaProperties at

,
the corresponding non-Windows code in GetJavaProperties at


uses ARCHPROPNAME which, via

> -DARCHPROPNAME='"$(OPENJDK_TARGET_CPU_OSARCH)"'

at

,
appears to somehow come out of Autoconf at

,
so probably can show some variance in actual values being used.

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

diff --git a/jvmfwk/plugins/sunmajor/pluginlib/vendorbase.cxx 
b/jvmfwk/plugins/sunmajor/pluginlib/vendorbase.cxx
index 8863df3352ff..f4cf14a9ab3f 100644
--- a/jvmfwk/plugins/sunmajor/pluginlib/vendorbase.cxx
+++ b/jvmfwk/plugins/sunmajor/pluginlib/vendorbase.cxx
@@ -175,10 +175,12 @@ bool VendorBase::isValidArch() const
 // It is not defined what the exact values are.
 // Oracle JRE 8 has "x86" and "amd64", the others were found at 
http://lopica.sourceforge.net/os.html .
 // There might still be missing some options; we need to extend the check 
once we find out.
-#if defined _WIN64
+#if defined _WIN64 || (defined MACOSX && defined __x86_64__)
 return m_sArch == "amd64" || m_sArch == "x86_64";
 #elif defined _WIN32
 return m_sArch == "x86" || m_sArch == "i386" || m_sArch == "i686";
+#elif defined MACOSX && defined __aarch64__
+return m_sArch == "aarch64";
 #else
 (void)this;
 return true;


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

2021-11-17 Thread Jan-Marek Glogowski (via logerrit)
 vcl/inc/qt5/QtFrame.hxx |1 +
 vcl/qt5/QtFrame.cxx |   10 --
 vcl/qt5/QtObject.cxx|2 --
 3 files changed, 9 insertions(+), 4 deletions(-)

New commits:
commit f3bd9ef889d1834f7b1feb49197a58e679826c00
Author: Jan-Marek Glogowski 
AuthorDate: Wed Nov 17 13:26:09 2021 +0100
Commit: Jan-Marek Glogowski 
CommitDate: Wed Nov 17 16:51:42 2021 +0100

Qt resolve native winId() on demand

As for gtk3 in commit ac9789dbb36f45dcc1caf7dd2951353b1574c8ea
("tdf#139609 avoid fetching unnecessary xid under gtk3").

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

diff --git a/vcl/inc/qt5/QtFrame.hxx b/vcl/inc/qt5/QtFrame.hxx
index 965ecbaba0e1..c3c9cdb9f309 100644
--- a/vcl/inc/qt5/QtFrame.hxx
+++ b/vcl/inc/qt5/QtFrame.hxx
@@ -210,6 +210,7 @@ public:
 
 virtual void SetScreenNumber(unsigned int) override;
 virtual void SetApplicationID(const OUString&) override;
+virtual void ResolveWindowHandle(SystemEnvData& rData) const override;
 
 inline bool CallCallback(SalEvent nEvent, const void* pEvent) const;
 
diff --git a/vcl/qt5/QtFrame.cxx b/vcl/qt5/QtFrame.cxx
index ce504c10b8db..5b8a6fad6d96 100644
--- a/vcl/qt5/QtFrame.cxx
+++ b/vcl/qt5/QtFrame.cxx
@@ -184,8 +184,6 @@ QtFrame::QtFrame(QtFrame* pParent, SalFrameStyleFlags 
nStyle, bool bUseCairo)
 }
 
 FillSystemEnvData(m_aSystemData, reinterpret_cast(this), 
m_pQWidget);
-if (m_aSystemData.platform != SystemEnvData::Platform::Wayland)
-m_aSystemData.SetWindowHandle(m_pQWidget->winId());
 
 SetIcon(SV_ICON_ID_OFFICE);
 
@@ -1344,6 +1342,14 @@ void QtFrame::SetApplicationID(const OUString& rWMClass)
 #endif
 }
 
+void QtFrame::ResolveWindowHandle(SystemEnvData& rData) const
+{
+if (!rData.pWidget)
+return;
+if (rData.platform != SystemEnvData::Platform::Wayland)
+rData.SetWindowHandle(static_cast(rData.pWidget)->winId());
+}
+
 // Drag'n'drop foo
 
 void QtFrame::registerDragSource(QtDragSource* pDragSource)
diff --git a/vcl/qt5/QtObject.cxx b/vcl/qt5/QtObject.cxx
index b8c30af2d340..569586a0dc98 100644
--- a/vcl/qt5/QtObject.cxx
+++ b/vcl/qt5/QtObject.cxx
@@ -42,8 +42,6 @@ QtObject::QtObject(QtFrame* pParent, bool bShow)
 m_pQWidget->show();
 
 QtFrame::FillSystemEnvData(m_aSystemData, 
reinterpret_cast(this), m_pQWidget);
-if (m_aSystemData.platform != SystemEnvData::Platform::Wayland)
-m_aSystemData.SetWindowHandle(m_pQWidget->winId());
 }
 
 QtObject::~QtObject()


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

2021-11-17 Thread Jan-Marek Glogowski (via logerrit)
 vcl/inc/qt5/QtFrame.hxx |1 
 vcl/qt5/QtFrame.cxx |   51 +---
 vcl/qt5/QtObject.cxx|   25 ++-
 3 files changed, 27 insertions(+), 50 deletions(-)

New commits:
commit 76611452da46aec18ba14954671beee4f6dacf49
Author: Jan-Marek Glogowski 
AuthorDate: Wed Nov 17 13:03:23 2021 +0100
Commit: Jan-Marek Glogowski 
CommitDate: Wed Nov 17 16:51:14 2021 +0100

Qt refactor SystemEnvData setup

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

diff --git a/vcl/inc/qt5/QtFrame.hxx b/vcl/inc/qt5/QtFrame.hxx
index a338b106eaeb..965ecbaba0e1 100644
--- a/vcl/inc/qt5/QtFrame.hxx
+++ b/vcl/inc/qt5/QtFrame.hxx
@@ -215,6 +215,7 @@ public:
 
 void setInputLanguage(LanguageType);
 inline bool isPopup() const;
+static void FillSystemEnvData(SystemEnvData&, sal_IntPtr pWindow, QWidget* 
pWidget);
 };
 
 inline bool QtFrame::CallCallback(SalEvent nEvent, const void* pEvent) const
diff --git a/vcl/qt5/QtFrame.cxx b/vcl/qt5/QtFrame.cxx
index db91e48a256c..ce504c10b8db 100644
--- a/vcl/qt5/QtFrame.cxx
+++ b/vcl/qt5/QtFrame.cxx
@@ -183,39 +183,34 @@ QtFrame::QtFrame(QtFrame* pParent, SalFrameStyleFlags 
nStyle, bool bUseCairo)
 pChildWindow->setTransientParent(pParentWindow);
 }
 
-// Calling 'QWidget::winId()' implicitly enables native windows to be used
-// rather than "alien widgets" that are unknown to the windowing system,
-// s. https://doc.qt.io/qt-5/qwidget.html#native-widgets-vs-alien-widgets
-// Avoid this on Wayland due to problems with missing 'mouseMoveEvent's,
-// s. tdf#122293/QTBUG-75766
-const bool bWayland = QGuiApplication::platformName() == "wayland";
-if (!bWayland)
+FillSystemEnvData(m_aSystemData, reinterpret_cast(this), 
m_pQWidget);
+if (m_aSystemData.platform != SystemEnvData::Platform::Wayland)
 m_aSystemData.SetWindowHandle(m_pQWidget->winId());
-else
-{
-// TODO implement as needed for Wayland,
-// s.a. commit c0d4f3ad3307c which did this for gtk3
-// QPlatformNativeInterface* native = 
QGuiApplication::platformNativeInterface();
-// m_aSystemData.pDisplay = native->nativeResourceForWindow("display", 
nullptr);
-// m_aSystemData.aWindow = reinterpret_cast(
-// native->nativeResourceForWindow("surface", 
m_pQWidget->windowHandle()));
-}
-
-m_aSystemData.aShellWindow = reinterpret_cast(this);
-//m_aSystemData.pSalFrame = this;
-m_aSystemData.pWidget = m_pQWidget;
-//m_aSystemData.nScreen = m_nXScreen.getXScreen();
-m_aSystemData.toolkit = SystemEnvData::Toolkit::Qt;
-if (!bWayland)
-m_aSystemData.platform = SystemEnvData::Platform::Xcb;
-else
-m_aSystemData.platform = SystemEnvData::Platform::Wayland;
 
 SetIcon(SV_ICON_ID_OFFICE);
 
 fixICCCMwindowGroup();
 }
 
+void QtFrame::FillSystemEnvData(SystemEnvData& rData, sal_IntPtr pWindow, 
QWidget* pWidget)
+{
+if (QGuiApplication::platformName() == "wayland")
+rData.platform = SystemEnvData::Platform::Wayland;
+else if (QGuiApplication::platformName() == "xcb")
+rData.platform = SystemEnvData::Platform::Xcb;
+else
+{
+// maybe add a SystemEnvData::Platform::Unsupported to avoid special 
cases and not abort?
+SAL_WARN("vcl.qt",
+ "Unsupported qt VCL platform: " << 
toOUString(QGuiApplication::platformName()));
+std::abort();
+}
+
+rData.toolkit = SystemEnvData::Toolkit::Qt;
+rData.aShellWindow = pWindow;
+rData.pWidget = pWidget;
+}
+
 void QtFrame::fixICCCMwindowGroup()
 {
 #if QT_VERSION < QT_VERSION_CHECK(6, 0, 0) && QT5_USING_X11 && 
QT5_HAVE_XCB_ICCCM
@@ -226,7 +221,7 @@ void QtFrame::fixICCCMwindowGroup()
 return;
 g_bNeedsWmHintsWindowGroup = false;
 
-if (QGuiApplication::platformName() != "xcb")
+if (m_aSystemData.platform != SystemEnvData::Platform::Xcb)
 return;
 if (QVersionNumber::fromString(qVersion()) >= QVersionNumber(5, 12))
 return;
@@ -1327,7 +1322,7 @@ void QtFrame::SetScreenNumber(unsigned int nScreen)
 void QtFrame::SetApplicationID(const OUString& rWMClass)
 {
 #if QT_VERSION < QT_VERSION_CHECK(6, 0, 0) && QT5_USING_X11
-if (QGuiApplication::platformName() != "xcb" || !m_pTopLevel)
+if (m_aSystemData.platform != SystemEnvData::Platform::Xcb || !m_pTopLevel)
 return;
 
 OString aResClass = OUStringToOString(rWMClass, RTL_TEXTENCODING_ASCII_US);
diff --git a/vcl/qt5/QtObject.cxx b/vcl/qt5/QtObject.cxx
index 155a78da8ce1..b8c30af2d340 100644
--- a/vcl/qt5/QtObject.cxx
+++ b/vcl/qt5/QtObject.cxx
@@ -41,28 +41,9 @@ QtObject::QtObject(QtFrame* pParent, bool bShow)
 if (bShow)
 m_pQWidget->show();
 
-m_aSystemData.aShellWindow = reinterpret_cast(this);
-//m_aSystemData.pSalFrame 

[Libreoffice-commits] core.git: Branch 'libreoffice-7-2-3' - readlicense_oo/license

2021-11-17 Thread Christian Lohmaier (via logerrit)
 readlicense_oo/license/CREDITS.fodt | 4134 ++--
 1 file changed, 2077 insertions(+), 2057 deletions(-)

New commits:
commit 7143485be0bf9519a55f3700341238c55b16cd1f
Author: Christian Lohmaier 
AuthorDate: Wed Nov 17 16:28:54 2021 +0100
Commit: Christian Lohmaier 
CommitDate: Wed Nov 17 16:32:15 2021 +0100

update credits

Change-Id: I0012889f2018c40479bd22c9d34848a6e70ee041
(cherry picked from commit 6d0d4d943f3b63ef45160b2c0f77c2bb0ea3428c)
(cherry picked from commit aa0daec58784504807e70d054644b44c2aeb0c2d)

diff --git a/readlicense_oo/license/CREDITS.fodt 
b/readlicense_oo/license/CREDITS.fodt
index e5ddde09fe23..58fbbc9413d2 100644
--- a/readlicense_oo/license/CREDITS.fodt
+++ b/readlicense_oo/license/CREDITS.fodt
@@ -1,10 +1,10 @@
 
 
 http://openoffice.org/2009/office"; 
xmlns:css3t="http://www.w3.org/TR/css3-text/"; 
xmlns:grddl="http://www.w3.org/2003/g/data-view#"; 
xmlns:xhtml="http://www.w3.org/1999/xhtml"; 
xmlns:formx="urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0"
 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns:xsd="http://www.w3.org/2001/XMLSchema"; 
xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" 
xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" 
xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" 
xmlns:oooc="http://openoffice.org/2004/calc"; 
xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" 
xmlns:ooow="http://openoffice.org/2004/writer"; 
xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" 
xmlns:dc="http://purl.org/dc/elements/1.1/"; 
xmlns:rpt="http://openoffice.org/2005/report"; 
xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" 
xmlns:config="urn:oasis:names:tc:opendocument:xmlns
 :config:1.0" xmlns:xlink="http://www.w3.org/1999/xlink"; 
xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" 
xmlns:ooo="http://openoffice.org/2004/office"; 
xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" 
xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" 
xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" 
xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" 
xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" 
xmlns:calcext="urn:org:documentfoundation:names:experimental:calc:xmlns:calcext:1.0"
 xmlns:tableooo="http://openoffice.org/2009/table"; 
xmlns:drawooo="http://openoffice.org/2010/draw"; 
xmlns:loext="urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.0"
 xmlns:dom="http://www.w3.org/2001/xml-events"; 
xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0" 
xmlns:math="http://www.w3.org/1998/Math/MathML"; 
xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:script="ur
 n:oasis:names:tc:opendocument:xmlns:script:1.0" 
xmlns:xforms="http://www.w3.org/2002/xforms"; office:version="1.3" 
office:mimetype="application/vnd.oasis.opendocument.text">
- Credits » 
LibreOfficeCreditscontributorscodersdevelopersCredits
 for the LibreOffice 
development/coding.LibreOffice/7.2.2.2$Linux_X86_64
 
LibreOffice_project/02b2acce88a210515b4a5bb2e46cbfb63fe97d562012-02-20T22:17:18.06000PT14M12S3JUebjoxEpqXoQcpltWRTwzBZEEHtch3wApdhgiQPFiA
+ Credits » 
LibreOfficeCreditscontributorscodersdevelopersCredits
 for the LibreOffice 
development/coding.LibreOffice/7.2.2.2$Linux_X86_64
 
LibreOffice_project/02b2acce88a210515b4a5bb2e46cbfb63fe97d562012-02-20T22:17:18.06000PT14M12S3JUebjoxEpqXoQcpltWRTwzBZEEHtch3wApdhgiQPFiA
  
   
-   1051
+   1072
501
55167
31302
@@ -16,9 +16,9 @@
  3649
  3434
  501
- 1051
+ 1072
  55667
- 32351
+ 32373
  0
  0
  false
@@ -97,7 +97,7 @@


true
-   10307458
+   10320621

true
false
@@ -165,7 +165,7 @@
  
   

-   
+   
 


@@ -343,24 +343,21 @@
  
  
   
-   
+   
   
   

   
   
-   
-  
-  

   
-  
-   
+  
+   
   
   

   
-  
+  

   
   
@@ -421,26 +418,23 @@

   
   
-   
+   
   
   

   
   
-   
+   
   
   
-   
+   
   
   
-   
+   
   
   

   
-  
-   
-  
   

   
@@ -1080,20 +1074,20 @@


 Credits
-1704 individuals contributed to 
OpenOffice.org (and whose contributions were imported into LibreOffice) or 
LibreOffice until 2021-10-13 10:11:36.
+1707 individuals contributed to 
OpenOffice.org (and whose contributions were imported into LibreOffice) or 
LibreOffice until 2021-11-17 13:36:19.
 * marks developers whose first contributions 
happened after 2010-09-28.
 Developers 
committing code since 2010-09-28
 
  
  
  
- 
- 
+ 
+ 
   
Ruediger 
TimmCommits: 82464Joined: 
2000-10-10
   
   
-   Caolán 
McNamaraCommits: 31879Joined: 
2000-10-10
+   Caolán 
McNamaraCommits: 32009Joined: 
2000-10-10
   
   
Kurt 
ZenkerCommits: 31752Joined: 
2000-09-

[Libreoffice-commits] core.git: Branch 'libreoffice-7-2' - readlicense_oo/license

2021-11-17 Thread Christian Lohmaier (via logerrit)
 readlicense_oo/license/CREDITS.fodt | 4134 ++--
 1 file changed, 2077 insertions(+), 2057 deletions(-)

New commits:
commit aa0daec58784504807e70d054644b44c2aeb0c2d
Author: Christian Lohmaier 
AuthorDate: Wed Nov 17 16:28:54 2021 +0100
Commit: Christian Lohmaier 
CommitDate: Wed Nov 17 16:30:31 2021 +0100

update credits

Change-Id: I0012889f2018c40479bd22c9d34848a6e70ee041
(cherry picked from commit 6d0d4d943f3b63ef45160b2c0f77c2bb0ea3428c)

diff --git a/readlicense_oo/license/CREDITS.fodt 
b/readlicense_oo/license/CREDITS.fodt
index e5ddde09fe23..58fbbc9413d2 100644
--- a/readlicense_oo/license/CREDITS.fodt
+++ b/readlicense_oo/license/CREDITS.fodt
@@ -1,10 +1,10 @@
 
 
 http://openoffice.org/2009/office"; 
xmlns:css3t="http://www.w3.org/TR/css3-text/"; 
xmlns:grddl="http://www.w3.org/2003/g/data-view#"; 
xmlns:xhtml="http://www.w3.org/1999/xhtml"; 
xmlns:formx="urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0"
 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns:xsd="http://www.w3.org/2001/XMLSchema"; 
xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" 
xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" 
xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" 
xmlns:oooc="http://openoffice.org/2004/calc"; 
xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" 
xmlns:ooow="http://openoffice.org/2004/writer"; 
xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" 
xmlns:dc="http://purl.org/dc/elements/1.1/"; 
xmlns:rpt="http://openoffice.org/2005/report"; 
xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" 
xmlns:config="urn:oasis:names:tc:opendocument:xmlns
 :config:1.0" xmlns:xlink="http://www.w3.org/1999/xlink"; 
xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" 
xmlns:ooo="http://openoffice.org/2004/office"; 
xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" 
xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" 
xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" 
xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" 
xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" 
xmlns:calcext="urn:org:documentfoundation:names:experimental:calc:xmlns:calcext:1.0"
 xmlns:tableooo="http://openoffice.org/2009/table"; 
xmlns:drawooo="http://openoffice.org/2010/draw"; 
xmlns:loext="urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.0"
 xmlns:dom="http://www.w3.org/2001/xml-events"; 
xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0" 
xmlns:math="http://www.w3.org/1998/Math/MathML"; 
xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:script="ur
 n:oasis:names:tc:opendocument:xmlns:script:1.0" 
xmlns:xforms="http://www.w3.org/2002/xforms"; office:version="1.3" 
office:mimetype="application/vnd.oasis.opendocument.text">
- Credits » 
LibreOfficeCreditscontributorscodersdevelopersCredits
 for the LibreOffice 
development/coding.LibreOffice/7.2.2.2$Linux_X86_64
 
LibreOffice_project/02b2acce88a210515b4a5bb2e46cbfb63fe97d562012-02-20T22:17:18.06000PT14M12S3JUebjoxEpqXoQcpltWRTwzBZEEHtch3wApdhgiQPFiA
+ Credits » 
LibreOfficeCreditscontributorscodersdevelopersCredits
 for the LibreOffice 
development/coding.LibreOffice/7.2.2.2$Linux_X86_64
 
LibreOffice_project/02b2acce88a210515b4a5bb2e46cbfb63fe97d562012-02-20T22:17:18.06000PT14M12S3JUebjoxEpqXoQcpltWRTwzBZEEHtch3wApdhgiQPFiA
  
   
-   1051
+   1072
501
55167
31302
@@ -16,9 +16,9 @@
  3649
  3434
  501
- 1051
+ 1072
  55667
- 32351
+ 32373
  0
  0
  false
@@ -97,7 +97,7 @@


true
-   10307458
+   10320621

true
false
@@ -165,7 +165,7 @@
  
   

-   
+   
 


@@ -343,24 +343,21 @@
  
  
   
-   
+   
   
   

   
   
-   
-  
-  

   
-  
-   
+  
+   
   
   

   
-  
+  

   
   
@@ -421,26 +418,23 @@

   
   
-   
+   
   
   

   
   
-   
+   
   
   
-   
+   
   
   
-   
+   
   
   

   
-  
-   
-  
   

   
@@ -1080,20 +1074,20 @@


 Credits
-1704 individuals contributed to 
OpenOffice.org (and whose contributions were imported into LibreOffice) or 
LibreOffice until 2021-10-13 10:11:36.
+1707 individuals contributed to 
OpenOffice.org (and whose contributions were imported into LibreOffice) or 
LibreOffice until 2021-11-17 13:36:19.
 * marks developers whose first contributions 
happened after 2010-09-28.
 Developers 
committing code since 2010-09-28
 
  
  
  
- 
- 
+ 
+ 
   
Ruediger 
TimmCommits: 82464Joined: 
2000-10-10
   
   
-   Caolán 
McNamaraCommits: 31879Joined: 
2000-10-10
+   Caolán 
McNamaraCommits: 32009Joined: 
2000-10-10
   
   
Kurt 
ZenkerCommits: 31752Joined: 
2000-09-25
@@ -1102,7 +1096,7 @@
Oliver 
BolteCommits: 31008Joined: 
2000

[Libreoffice-commits] core.git: readlicense_oo/license

2021-11-17 Thread Christian Lohmaier (via logerrit)
 readlicense_oo/license/CREDITS.fodt | 4134 ++--
 1 file changed, 2077 insertions(+), 2057 deletions(-)

New commits:
commit 6d0d4d943f3b63ef45160b2c0f77c2bb0ea3428c
Author: Christian Lohmaier 
AuthorDate: Wed Nov 17 16:28:54 2021 +0100
Commit: Christian Lohmaier 
CommitDate: Wed Nov 17 16:28:54 2021 +0100

update credits

Change-Id: I0012889f2018c40479bd22c9d34848a6e70ee041

diff --git a/readlicense_oo/license/CREDITS.fodt 
b/readlicense_oo/license/CREDITS.fodt
index e5ddde09fe23..58fbbc9413d2 100644
--- a/readlicense_oo/license/CREDITS.fodt
+++ b/readlicense_oo/license/CREDITS.fodt
@@ -1,10 +1,10 @@
 
 
 http://openoffice.org/2009/office"; 
xmlns:css3t="http://www.w3.org/TR/css3-text/"; 
xmlns:grddl="http://www.w3.org/2003/g/data-view#"; 
xmlns:xhtml="http://www.w3.org/1999/xhtml"; 
xmlns:formx="urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0"
 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns:xsd="http://www.w3.org/2001/XMLSchema"; 
xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" 
xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" 
xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" 
xmlns:oooc="http://openoffice.org/2004/calc"; 
xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" 
xmlns:ooow="http://openoffice.org/2004/writer"; 
xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" 
xmlns:dc="http://purl.org/dc/elements/1.1/"; 
xmlns:rpt="http://openoffice.org/2005/report"; 
xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" 
xmlns:config="urn:oasis:names:tc:opendocument:xmlns
 :config:1.0" xmlns:xlink="http://www.w3.org/1999/xlink"; 
xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" 
xmlns:ooo="http://openoffice.org/2004/office"; 
xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" 
xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" 
xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" 
xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" 
xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" 
xmlns:calcext="urn:org:documentfoundation:names:experimental:calc:xmlns:calcext:1.0"
 xmlns:tableooo="http://openoffice.org/2009/table"; 
xmlns:drawooo="http://openoffice.org/2010/draw"; 
xmlns:loext="urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.0"
 xmlns:dom="http://www.w3.org/2001/xml-events"; 
xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0" 
xmlns:math="http://www.w3.org/1998/Math/MathML"; 
xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:script="ur
 n:oasis:names:tc:opendocument:xmlns:script:1.0" 
xmlns:xforms="http://www.w3.org/2002/xforms"; office:version="1.3" 
office:mimetype="application/vnd.oasis.opendocument.text">
- Credits » 
LibreOfficeCreditscontributorscodersdevelopersCredits
 for the LibreOffice 
development/coding.LibreOffice/7.2.2.2$Linux_X86_64
 
LibreOffice_project/02b2acce88a210515b4a5bb2e46cbfb63fe97d562012-02-20T22:17:18.06000PT14M12S3JUebjoxEpqXoQcpltWRTwzBZEEHtch3wApdhgiQPFiA
+ Credits » 
LibreOfficeCreditscontributorscodersdevelopersCredits
 for the LibreOffice 
development/coding.LibreOffice/7.2.2.2$Linux_X86_64
 
LibreOffice_project/02b2acce88a210515b4a5bb2e46cbfb63fe97d562012-02-20T22:17:18.06000PT14M12S3JUebjoxEpqXoQcpltWRTwzBZEEHtch3wApdhgiQPFiA
  
   
-   1051
+   1072
501
55167
31302
@@ -16,9 +16,9 @@
  3649
  3434
  501
- 1051
+ 1072
  55667
- 32351
+ 32373
  0
  0
  false
@@ -97,7 +97,7 @@


true
-   10307458
+   10320621

true
false
@@ -165,7 +165,7 @@
  
   

-   
+   
 


@@ -343,24 +343,21 @@
  
  
   
-   
+   
   
   

   
   
-   
-  
-  

   
-  
-   
+  
+   
   
   

   
-  
+  

   
   
@@ -421,26 +418,23 @@

   
   
-   
+   
   
   

   
   
-   
+   
   
   
-   
+   
   
   
-   
+   
   
   

   
-  
-   
-  
   

   
@@ -1080,20 +1074,20 @@


 Credits
-1704 individuals contributed to 
OpenOffice.org (and whose contributions were imported into LibreOffice) or 
LibreOffice until 2021-10-13 10:11:36.
+1707 individuals contributed to 
OpenOffice.org (and whose contributions were imported into LibreOffice) or 
LibreOffice until 2021-11-17 13:36:19.
 * marks developers whose first contributions 
happened after 2010-09-28.
 Developers 
committing code since 2010-09-28
 
  
  
  
- 
- 
+ 
+ 
   
Ruediger 
TimmCommits: 82464Joined: 
2000-10-10
   
   
-   Caolán 
McNamaraCommits: 31879Joined: 
2000-10-10
+   Caolán 
McNamaraCommits: 32009Joined: 
2000-10-10
   
   
Kurt 
ZenkerCommits: 31752Joined: 
2000-09-25
@@ -1102,7 +1096,7 @@
Oliver 
BolteCommits: 31008Joined: 
2000-09-19
   
  
- 
+ 
   
Jens-Heiner Rechtien 

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

2021-11-17 Thread Stephan Bergmann (via logerrit)
 jvmfwk/source/framework.cxx |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit b9ecede5762831ff590a33cd04dc7cb381307000
Author: Stephan Bergmann 
AuthorDate: Wed Nov 17 13:36:19 2021 +0100
Commit: Stephan Bergmann 
CommitDate: Wed Nov 17 15:46:44 2021 +0100

Don't fail jfw_findAllJREs for just one JRE of WrongArch

...otherwise if one such JRE had found its way into a user's configuration,
"Tools - Options... - LibreOffice - Advanced" would no longer show *any* 
JREs.

Regression introduced with 9143dd4ebe37b608e43d04434cf831624bf55b65 "Related
tdf#54443 List only matching JREs", which added WrongArch to the 
javaPluginError
enum.

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

diff --git a/jvmfwk/source/framework.cxx b/jvmfwk/source/framework.cxx
index 40bbf629a36f..200724b5483f 100644
--- a/jvmfwk/source/framework.cxx
+++ b/jvmfwk/source/framework.cxx
@@ -101,6 +101,8 @@ javaFrameworkError 
jfw_findAllJREs(std::vector> *pparI
 continue;
 if (plerr == javaPluginError::FailedVersion)
 continue;
+if (plerr == javaPluginError::WrongArch)
+continue;
 else if (plerr != javaPluginError::NONE)
 return JFW_E_ERROR;
 


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

2021-11-17 Thread Sarper Akdemir (via logerrit)
 include/editeng/unoprnms.hxx|2 ++
 include/editeng/unotext.hxx |4 +++-
 svx/source/unodraw/unoprov.cxx  |4 +++-
 svx/source/unodraw/unoshap2.cxx |2 ++
 4 files changed, 10 insertions(+), 2 deletions(-)

New commits:
commit 013ec5ef7ac038b6b1b8b937e81880f30434098a
Author: Sarper Akdemir 
AuthorDate: Wed Aug 18 16:04:37 2021 +0300
Commit: Miklos Vajna 
CommitDate: Wed Nov 17 15:40:25 2021 +0100

expose the SvxColorItem theme related uno for draw/impress

[ Miklos: added the missing SvxShapeControlPropertyMapping entries,
breaking tests. ]

(cherry picked from commit 88b6801ff2aa61ed2f0d64cef94fe6a9c09f3a35,
from the feature/themesupport2 branch)

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

diff --git a/include/editeng/unoprnms.hxx b/include/editeng/unoprnms.hxx
index 97aaa77dd86a..91273845fbd2 100644
--- a/include/editeng/unoprnms.hxx
+++ b/include/editeng/unoprnms.hxx
@@ -327,6 +327,8 @@
 #define UNO_NAME_EDIT_CHAR_LOCALE_COMPLEX   "CharLocaleComplex"
 
 #define UNO_NAME_EDIT_CHAR_COLOR"CharColor"
+#define UNO_NAME_EDIT_CHAR_COLOR_THEME  "CharColorTheme"
+#define UNO_NAME_EDIT_CHAR_COLOR_TINT_OR_SHADE  "CharColorTintOrShade"
 #define UNO_NAME_EDIT_CHAR_TRANSPARENCE "CharTransparence"
 #define UNO_NAME_EDIT_CHAR_CROSSEDOUT   "CharCrossedOut"
 #define UNO_NAME_EDIT_CHAR_STRIKEOUT"CharStrikeout"
diff --git a/include/editeng/unotext.hxx b/include/editeng/unotext.hxx
index 5b92daf4d8aa..c9c4b9580f72 100644
--- a/include/editeng/unotext.hxx
+++ b/include/editeng/unotext.hxx
@@ -85,8 +85,10 @@ struct SfxItemPropertyMapEntry;
 { u"" UNO_NAME_EDIT_CHAR_POSTURE, EE_CHAR_ITALIC, 
::cppu::UnoType::get(),0, MID_POSTURE }, \
 { u"" UNO_NAME_EDIT_CHAR_WEIGHT,  EE_CHAR_WEIGHT, 
cppu::UnoType::get(),0, MID_WEIGHT }, \
 { u"" UNO_NAME_EDIT_CHAR_LOCALE,  EE_CHAR_LANGUAGE,   
::cppu::UnoType::get(),0, MID_LANG_LOCALE }, \
-{ u"" UNO_NAME_EDIT_CHAR_COLOR,   EE_CHAR_COLOR,  
::cppu::UnoType::get(),0, 0 }, \
+{ u"" UNO_NAME_EDIT_CHAR_COLOR,   EE_CHAR_COLOR,  
::cppu::UnoType::get(),0, MID_COLOR_RGB }, \
 { u"" UNO_NAME_EDIT_CHAR_TRANSPARENCE,EE_CHAR_COLOR,  
::cppu::UnoType::get(),0, MID_COLOR_ALPHA }, \
+{ u"" UNO_NAME_EDIT_CHAR_COLOR_THEME, EE_CHAR_COLOR,  
::cppu::UnoType::get(),0, MID_COLOR_THEME_INDEX }, \
+{ u"" UNO_NAME_EDIT_CHAR_COLOR_TINT_OR_SHADE, EE_CHAR_COLOR, 
::cppu::UnoType::get(), 0, MID_COLOR_TINT_OR_SHADE }, \
 { u"CharBackColor",EE_CHAR_BKGCOLOR,   
::cppu::UnoType::get(),0, 0 }, \
 { u"CharBackTransparent",  EE_CHAR_BKGCOLOR,   
::cppu::UnoType::get(), 0, MID_GRAPHIC_TRANSPARENT }, \
 { u"" UNO_NAME_EDIT_CHAR_ESCAPEMENT,  EE_CHAR_ESCAPEMENT, 
::cppu::UnoType::get(),0, MID_ESC }, \
diff --git a/svx/source/unodraw/unoprov.cxx b/svx/source/unodraw/unoprov.cxx
index 39369d880448..b459280c8b01 100644
--- a/svx/source/unodraw/unoprov.cxx
+++ b/svx/source/unodraw/unoprov.cxx
@@ -582,7 +582,9 @@ static SfxItemPropertyMapEntry const * 
ImplGetSvxControlShapePropertyMap()
 { u"" UNO_NAME_EDIT_CHAR_UNDERLINE,   0,  
cppu::UnoType::get(),0, 0 },
 { u"" UNO_NAME_EDIT_CHAR_STRIKEOUT,   0,  
cppu::UnoType::get(),0, 0},
 { u"" UNO_NAME_EDIT_CHAR_CASEMAP, 0,  
cppu::UnoType::get(),0, 0 },
-{ u"" UNO_NAME_EDIT_CHAR_COLOR,   0,  
cppu::UnoType::get(),0, 0 },
+{ u"" UNO_NAME_EDIT_CHAR_COLOR,   0,  
cppu::UnoType::get(),0, MID_COLOR_RGB },
+{ u"" UNO_NAME_EDIT_CHAR_COLOR_THEME, 0,  
cppu::UnoType::get(),0, MID_COLOR_THEME_INDEX },
+{ u"" UNO_NAME_EDIT_CHAR_COLOR_TINT_OR_SHADE, 0, 
cppu::UnoType::get(), 0, MID_COLOR_TINT_OR_SHADE },
 { u"CharBackColor",0,  
cppu::UnoType::get(),0, 0 },
 { u"CharBackTransparent",  0,  cppu::UnoType::get(), 
0, 0 },
 { u"CharRelief",   0,  
cppu::UnoType::get(),0, 0 },
diff --git a/svx/source/unodraw/unoshap2.cxx b/svx/source/unodraw/unoshap2.cxx
index 710f2e38099d..415ddf95eeb9 100644
--- a/svx/source/unodraw/unoshap2.cxx
+++ b/svx/source/unodraw/unoshap2.cxx
@@ -595,6 +595,8 @@ const SvxShapeControlPropertyMapping[] =
 { RTL_CONSTASCII_STRINGPARAM("ControlTypeinMSO"), 
RTL_CONSTASCII_STRINGPARAM("ControlTypeinMSO") },
 { RTL_CONSTASCII_STRINGPARAM("ObjIDinMSO"), 
RTL_CONSTASCII_STRINGPARAM("ObjIDinMSO") },
 { RTL_CONSTASCII_STRINGPARAM("CharCaseMap"), 
RTL_CONSTASCII_STRINGPARAM("CharCaseMap") },
+{ RTL_CONSTASCII_STRINGPARAM("CharColorTheme"), 
RTL_CONSTASCII_STRINGPARAM("CharColorTheme") },
+{ RTL_CON

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

2021-11-17 Thread Christian Lohmaier (via logerrit)
 translations |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 76e6405d9d3673e4b49976d4f562cbb9a0d9ea0a
Author: Christian Lohmaier 
AuthorDate: Wed Nov 17 15:33:05 2021 +0100
Commit: Gerrit Code Review 
CommitDate: Wed Nov 17 15:33:05 2021 +0100

Update git submodules

* Update translations from branch 'libreoffice-7-2-3'
  to 465f795ebd54ae65f2b2b844bb0cde8e99080e53
  - update translations for 7.2.3 rc2

and force-fix errors using pocheck

Change-Id: I9831ca0a142e497522ca9235841fdfe83b0ac156
(cherry picked from commit 51986575f2cbca313f14375d2a4906612b0f6d34)

diff --git a/translations b/translations
index 46c2dbc56c98..465f795ebd54 16
--- a/translations
+++ b/translations
@@ -1 +1 @@
-Subproject commit 46c2dbc56c98d8d5999c4302529b5154ec049ab8
+Subproject commit 465f795ebd54ae65f2b2b844bb0cde8e99080e53


[Libreoffice-commits] translations.git: Branch 'libreoffice-7-2-3' - source/am source/ast source/bg source/bn-IN source/ca source/cs source/da source/de source/el source/es source/eu source/fi source/

2021-11-17 Thread Christian Lohmaier (via logerrit)
 source/am/vcl/messages.po  
   |4 
 source/ast/cui/messages.po 
   |   17 
 source/ast/editeng/messages.po 
   |8 
 source/ast/filter/source/config/fragments/filters.po   
   |4 
 source/ast/helpcontent2/source/text/shared/01.po   
   |6 
 source/ast/helpcontent2/source/text/shared/guide.po
   |   10 
 source/ast/helpcontent2/source/text/shared/menu.po 
   |   12 
 source/ast/officecfg/registry/data/org/openoffice/Office.po
   |   10 
 source/ast/officecfg/registry/data/org/openoffice/Office/UI.po 
   |6 
 source/ast/sfx2/messages.po
   |8 
 source/ast/svx/messages.po 
   |   49 
 source/ast/sw/messages.po  
   |   22 
 source/bg/helpcontent2/source/text/swriter/01.po   
   |   10 
 source/bn-IN/connectivity/messages.po  
   |   14 
 source/bn-IN/connectivity/registry/evoab2/org/openoffice/Office/DataAccess.po  
   |   25 
 
source/bn-IN/connectivity/registry/mysql_jdbc/org/openoffice/Office/DataAccess.po
 |   23 
 source/bn-IN/desktop/messages.po   
   |   14 
 source/bn-IN/dictionaries/ru_RU/dialog.po  
   |   32 
 source/bn-IN/editeng/messages.po   
   |   20 
 source/bn-IN/filter/source/config/fragments/types.po   
   |   24 
 source/bn-IN/framework/messages.po 
   |   14 
 source/bn-IN/helpcontent2/source/auxiliary.po  
   |  122 +-
 source/bn-IN/helpcontent2/source/text/sbasic/shared/01.po  
   |   85 +
 source/bn-IN/helpcontent2/source/text/scalc.po 
   |   42 
 source/bn-IN/helpcontent2/source/text/shared/01.po 
   |   18 
 source/bn-IN/helpcontent2/source/text/shared/menu.po   
   |   28 
 source/bn-IN/instsetoo_native/inc_openoffice/windows/msi_languages.po  
   |8 
 source/bn-IN/nlpsolver/src/locale.po   
   |   17 
 source/bn-IN/officecfg/registry/data/org/openoffice/Office/UI.po   
   |   16 
 source/bn-IN/readlicense_oo/docs.po
   |   22 
 source/bn-IN/reportdesign/messages.po  
   |   22 
 source/bn-IN/sc/messages.po
   |   17 
 source/bn-IN/scp2/source/ooo.po
   |   16 
 source/bn-IN/scp2/source/writer.po 
   |   49 
 source/bn-IN/sd/messages.po
   |   24 
 source/bn-IN/setup_native/source/mac.po
   |   15 
 source/bn-IN/sfx2/messages.po  
   |   10 
 source/bn-IN/svtools/messages.po   
   |   30 
 source/bn-IN/svx/messages.po   
   |   22 
 source/bn-IN/sw/messages.po
   |   32 
 source/bn-IN/swext/mediawiki/help.po   
   |  107 +-
 source/bn-IN/swext/mediawiki/src.po
   |   21 
 source/bn-IN/uui/messages.po   
   |   13 
 source/ca/cui/messages.po  
   |   22 
 source/ca/helpcontent2/source/text/scalc.po
   |4 
 source/ca/helpcontent2/source/text/scalc/guide.po  
   |4 
 source/ca/helpcontent2/source/text/sdraw.po
   |4 
 source/ca/helpcontent2/source/text/sdraw/guide.po  
   |   11 
 source/ca/helpcontent2/source/text/shared/01.po
   |6 
 source/ca/helpcontent2/source/text/shared/explorer/database.po 
   |4 
 source/ca/helpcontent2/source/text/simpress/00.po  
   |   12 
 source/ca/helpcontent2/source/text/simpress/01.po  
   |   36 
 source/ca/helpcontent2/source/text/simpress/02.po  
   |   16 
 source/ca/helpcontent2/source/text/simpress/guide.po   
   |5 
 source/ca/officecfg/regi

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

2021-11-17 Thread Xisco Fauli (via logerrit)
 sw/qa/uitest/writer_tests7/tdf141158.py |   22 --
 1 file changed, 8 insertions(+), 14 deletions(-)

New commits:
commit 192a16d6b0bad2d312b244a5576dfce3f4b05c36
Author: Xisco Fauli 
AuthorDate: Wed Nov 17 13:42:15 2021 +0100
Commit: Xisco Fauli 
CommitDate: Wed Nov 17 15:30:35 2021 +0100

uitest: sw: Use execute_dialog_through_command and remove sleeps

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

diff --git a/sw/qa/uitest/writer_tests7/tdf141158.py 
b/sw/qa/uitest/writer_tests7/tdf141158.py
index 6624530ee3cd..cefb8ed2da7b 100644
--- a/sw/qa/uitest/writer_tests7/tdf141158.py
+++ b/sw/qa/uitest/writer_tests7/tdf141158.py
@@ -5,26 +5,21 @@ from libreoffice.uno.propertyvalue import mkPropertyValues
 from uitest.uihelper.common import get_state_as_dict
 from uitest.uihelper.common import select_pos
 from uitest.uihelper.common import get_url_for_data_file
-import time
 
 class TestTdf141158(UITestCase):
 def test_tdf141158(self):
 # load the desired bugdoc
-with 
self.ui_test.load_file(get_url_for_data_file("TestHiddenHeadersFooters.docx")):
+with 
self.ui_test.load_file(get_url_for_data_file("TestHiddenHeadersFooters.docx")) 
as document:
 xWriterDoc = self.xUITest.getTopFocusWindow()
 xWriterEdit = xWriterDoc.getChild("writer_edit")
-document = self.ui_test.get_component()
 # open the page styles dialog and select the headers tab
-self.xUITest.executeCommand(".uno:PageStyleName")
-TemplateDialog8 = self.xUITest.getTopFocusWindow()
-xTabs = TemplateDialog8.getChild("tabcontrol")
-select_pos(xTabs, "4")
-# make the same left right page header state to off  and apply the 
setting
-checkSameLR = TemplateDialog8.getChild("checkSameLR")
-checkSameLR.executeAction("CLICK",tuple())
-ok = TemplateDialog8.getChild("ok")
-self.ui_test.close_dialog_through_button(ok)
-time.sleep(1)
+with 
self.ui_test.execute_dialog_through_command(".uno:PageStyleName") as xDialog:
+xTabs = xDialog.getChild("tabcontrol")
+select_pos(xTabs, "4")
+# make the same left right page header state to off  and apply 
the setting
+checkSameLR = xDialog.getChild("checkSameLR")
+checkSameLR.executeAction("CLICK",tuple())
+
 # go to the left header
 xWriterEdit.executeAction("GOTO", mkPropertyValues({"PAGE": "2"}))
 self.xUITest.executeCommand(".uno:JumpToHeader")
@@ -35,6 +30,5 @@ class TestTdf141158(UITestCase):
 # without the fix in place it was "Right Header" (lost hidden left 
header),
 # with the fix it should pass...
 self.assertEqual("Left Header", xHeaderLeftText)
-time.sleep(1)
 
 # vim: set shiftwidth=4 softtabstop=4 expandtab:


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

2021-11-17 Thread Christian Lohmaier (via logerrit)
 translations |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 8eb7c38cd65fdc4f5e1423389a5d3867712b6cc8
Author: Christian Lohmaier 
AuthorDate: Wed Nov 17 15:30:35 2021 +0100
Commit: Gerrit Code Review 
CommitDate: Wed Nov 17 15:30:35 2021 +0100

Update git submodules

* Update translations from branch 'libreoffice-7-2'
  to 51986575f2cbca313f14375d2a4906612b0f6d34
  - update translations for 7.2.3 rc2

and force-fix errors using pocheck

Change-Id: I9831ca0a142e497522ca9235841fdfe83b0ac156

diff --git a/translations b/translations
index 02c8a7274100..51986575f2cb 16
--- a/translations
+++ b/translations
@@ -1 +1 @@
-Subproject commit 02c8a727410041ca784120d6c7182a84599e5a43
+Subproject commit 51986575f2cbca313f14375d2a4906612b0f6d34


[Libreoffice-commits] translations.git: Branch 'libreoffice-7-2' - source/am source/ast source/bg source/bn-IN source/ca source/cs source/da source/de source/el source/es source/eu source/fi source/fr

2021-11-17 Thread Christian Lohmaier (via logerrit)
 source/am/vcl/messages.po  
   |4 
 source/ast/cui/messages.po 
   |   17 
 source/ast/editeng/messages.po 
   |8 
 source/ast/filter/source/config/fragments/filters.po   
   |4 
 source/ast/helpcontent2/source/text/shared/01.po   
   |6 
 source/ast/helpcontent2/source/text/shared/guide.po
   |   10 
 source/ast/helpcontent2/source/text/shared/menu.po 
   |   12 
 source/ast/officecfg/registry/data/org/openoffice/Office.po
   |   10 
 source/ast/officecfg/registry/data/org/openoffice/Office/UI.po 
   |6 
 source/ast/sfx2/messages.po
   |8 
 source/ast/svx/messages.po 
   |   49 
 source/ast/sw/messages.po  
   |   22 
 source/bg/helpcontent2/source/text/swriter/01.po   
   |   10 
 source/bn-IN/connectivity/messages.po  
   |   14 
 source/bn-IN/connectivity/registry/evoab2/org/openoffice/Office/DataAccess.po  
   |   25 
 
source/bn-IN/connectivity/registry/mysql_jdbc/org/openoffice/Office/DataAccess.po
 |   23 
 source/bn-IN/desktop/messages.po   
   |   14 
 source/bn-IN/dictionaries/ru_RU/dialog.po  
   |   32 
 source/bn-IN/editeng/messages.po   
   |   20 
 source/bn-IN/filter/source/config/fragments/types.po   
   |   24 
 source/bn-IN/framework/messages.po 
   |   14 
 source/bn-IN/helpcontent2/source/auxiliary.po  
   |  122 +-
 source/bn-IN/helpcontent2/source/text/sbasic/shared/01.po  
   |   85 +
 source/bn-IN/helpcontent2/source/text/scalc.po 
   |   42 
 source/bn-IN/helpcontent2/source/text/shared/01.po 
   |   18 
 source/bn-IN/helpcontent2/source/text/shared/menu.po   
   |   28 
 source/bn-IN/instsetoo_native/inc_openoffice/windows/msi_languages.po  
   |8 
 source/bn-IN/nlpsolver/src/locale.po   
   |   17 
 source/bn-IN/officecfg/registry/data/org/openoffice/Office/UI.po   
   |   16 
 source/bn-IN/readlicense_oo/docs.po
   |   22 
 source/bn-IN/reportdesign/messages.po  
   |   22 
 source/bn-IN/sc/messages.po
   |   17 
 source/bn-IN/scp2/source/ooo.po
   |   16 
 source/bn-IN/scp2/source/writer.po 
   |   49 
 source/bn-IN/sd/messages.po
   |   24 
 source/bn-IN/setup_native/source/mac.po
   |   15 
 source/bn-IN/sfx2/messages.po  
   |   10 
 source/bn-IN/svtools/messages.po   
   |   30 
 source/bn-IN/svx/messages.po   
   |   22 
 source/bn-IN/sw/messages.po
   |   32 
 source/bn-IN/swext/mediawiki/help.po   
   |  107 +-
 source/bn-IN/swext/mediawiki/src.po
   |   21 
 source/bn-IN/uui/messages.po   
   |   13 
 source/ca/cui/messages.po  
   |   22 
 source/ca/helpcontent2/source/text/scalc.po
   |4 
 source/ca/helpcontent2/source/text/scalc/guide.po  
   |4 
 source/ca/helpcontent2/source/text/sdraw.po
   |4 
 source/ca/helpcontent2/source/text/sdraw/guide.po  
   |   11 
 source/ca/helpcontent2/source/text/shared/01.po
   |6 
 source/ca/helpcontent2/source/text/shared/explorer/database.po 
   |4 
 source/ca/helpcontent2/source/text/simpress/00.po  
   |   12 
 source/ca/helpcontent2/source/text/simpress/01.po  
   |   36 
 source/ca/helpcontent2/source/text/simpress/02.po  
   |   16 
 source/ca/helpcontent2/source/text/simpress/guide.po   
   |5 
 source/ca/officecfg/regi

[Libreoffice-commits] core.git: config_host.mk.in configure.ac external/curl external/openssl solenv/gbuild solenv/gcc-wrappers

2021-11-17 Thread Luboš Luňák (via logerrit)
 config_host.mk.in  |1 
 configure.ac   |  112 +++--
 external/curl/ExternalProject_curl.mk  |1 
 external/curl/UnpackedTarball_curl.mk  |1 
 external/curl/configurable-z-option.patch.0|   20 
 external/openssl/ExternalProject_openssl.mk|1 
 external/openssl/UnpackedTarball_openssl.mk|1 
 external/openssl/configurable-z-option.patch.0 |   34 +++
 solenv/gbuild/PrecompiledHeaders.mk|2 
 solenv/gbuild/gbuild.mk|   18 
 solenv/gbuild/platform/com_GCC_class.mk|6 -
 solenv/gbuild/platform/com_GCC_defs.mk |   14 ---
 solenv/gbuild/platform/com_MSC_class.mk|   18 +++-
 solenv/gbuild/platform/com_MSC_defs.mk |   13 ++
 solenv/gcc-wrappers/wrapper.cxx|   50 ---
 solenv/gcc-wrappers/wrapper.hxx|3 
 16 files changed, 234 insertions(+), 61 deletions(-)

New commits:
commit c48a5f2653f7e76421c140cbd6018deffefccaf9
Author: Luboš Luňák 
AuthorDate: Sat Nov 13 16:20:46 2021 +
Commit: Luboš Luňák 
CommitDate: Wed Nov 17 15:21:44 2021 +0100

support ccache for MSVC too

There's no official MSVC support in ccache yet, but there are patches
in progress of getting upstreamed. So right now it's necessary
to get a patched ccache.
Ccache cannot work with -Zi option, since sharing debuginfo in a .PDB
cannot be cached. Added --enable-z7-symbols that gets enabled
by default if ccache is detected.
It works even with PCHs enabled, and externals seem to work too.
I get almost 100% hit rate on a rebuild, although such a rebuild
is slower than on Linux.

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

diff --git a/config_host.mk.in b/config_host.mk.in
index ec22f695d782..a03ac19747bc 100644
--- a/config_host.mk.in
+++ b/config_host.mk.in
@@ -209,6 +209,7 @@ export ENABLE_SYMBOLS_FOR=@ENABLE_SYMBOLS_FOR@
 export ENABLE_VALGRIND=@ENABLE_VALGRIND@
 export ENABLE_WASM_STRIP=@ENABLE_WASM_STRIP@
 export ENABLE_WERROR=@ENABLE_WERROR@
+export ENABLE_Z7_DEBUG=@ENABLE_Z7_DEBUG@
 export ENDIANNESS=@ENDIANNESS@
 export EPM=@EPM@
 export EPM_FLAGS=@EPM_FLAGS@
diff --git a/configure.ac b/configure.ac
index 7ebeeaf6e62f..0ee46bed9c74 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1758,7 +1758,7 @@ libo_FUZZ_ARG_ENABLE(cups,
 AC_ARG_ENABLE(ccache,
 AS_HELP_STRING([--disable-ccache],
 [Do not try to use ccache automatically.
- By default, unless on Windows, we will try to detect if ccache is 
available; in that case if
+ By default we will try to detect if ccache is available; in that case 
if
  CC/CXX are not yet set, and --enable-icecream is not given, we
  attempt to use ccache. --disable-ccache disables ccache completely.
  Additionally ccache's depend mode is enabled if possible,
@@ -1766,6 +1766,12 @@ AC_ARG_ENABLE(ccache,
 ]),
 ,)
 
+AC_ARG_ENABLE(z7-debug,
+AS_HELP_STRING([--enable-z7-debug],
+[Makes the MSVC compiler use -Z7 for debugging instead of the default 
-Zi. Using this option takes
+ more disk spaces but allows to use ccache. Final PDB files are 
created even with this option enabled.
+ Enabled by default if ccache is detected.]))
+
 libo_FUZZ_ARG_ENABLE(online-update,
 AS_HELP_STRING([--enable-online-update],
 [Enable the online update service that will check for new versions of
@@ -3029,26 +3035,6 @@ dnl 
===
 CCACHE_DEPEND_MODE=
 if test "$enable_ccache" = "no"; then
 CCACHE=""
-elif test "$_os" = "WINNT"; then
-# on windows/VC build do not use ccache - but perhaps sccache is around?
-case "%$CC%$CXX%" in
-# If $CC and/or $CXX already contain "sccache" (possibly suffixed with 
some version number etc),
-# assume that's good then
-*%sccache[[-_' ']]*|*/sccache[[-_' ']]*)
-AC_MSG_NOTICE([sccache seems to be included in a pre-defined CC and/or 
CXX])
-CCACHE_DEPEND_MODE=1
-;;
-*)
-# for sharing code below, reuse CCACHE env var
-AC_PATH_PROG([CCACHE],[sccache],[not found])
-if test "$CCACHE" = "not found"; then
-CCACHE=""
-else
-CCACHE=`win_short_path_for_make "$CCACHE"`
-CCACHE_DEPEND_MODE=1
-fi
-;;
-esac
 elif test -n "$enable_ccache" -o \( "$enable_ccache" = "" -a 
"$enable_icecream" != "yes" \); then
 case "%$CC%$CXX%" in
 # If $CC and/or $CXX already contain "ccache" (possibly suffixed with some 
version number etc),
@@ -3058,10 +3044,59 @@ elif test -n "$enable_ccache" -o \( "$enable_ccache" = 
"" -a "$enable_icecream"
 CCACHE_DEPEND_MODE=1
 ;;
 *)
+# try to use our

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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sc/inc/strings.hrc   |7 +
 sc/source/ui/dbgui/filtdlg.cxx   |7 +
 sc/uiconfig/scalc/ui/standardfilterdialog.ui |   96 +--
 3 files changed, 58 insertions(+), 52 deletions(-)

New commits:
commit 938fbac669bc59cf0b388bd0d21a2f14c4399757
Author: Caolán McNamara 
AuthorDate: Wed Nov 17 09:29:08 2021 +
Commit: Caolán McNamara 
CommitDate: Wed Nov 17 14:40:51 2021 +0100

SCSTR_FILTER_TEXT_COLOR is used in two different contexts

in the autofilter popup and the standard filter combobox.

In the autofilter we want title case to match the other
entries there, for the standard filter we need the same
text as appears in the combobox list

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

diff --git a/sc/inc/strings.hrc b/sc/inc/strings.hrc
index 59e1efd14b02..0cdbf7f1e540 100644
--- a/sc/inc/strings.hrc
+++ b/sc/inc/strings.hrc
@@ -35,8 +35,11 @@
 #define SCSTR_TOP10FILTER   NC_("SCSTR_TOP10FILTER", 
"Top 10")
 #define SCSTR_FILTER_EMPTY  NC_("SCSTR_FILTER_EMPTY", 
"Empty")
 #define SCSTR_FILTER_NOTEMPTY   
NC_("SCSTR_FILTER_NOTEMPTY", "Not Empty")
-#define SCSTR_FILTER_TEXT_COLOR 
NC_("SCSTR_FILTER_TEXT_COLOR", "Text color")
-#define SCSTR_FILTER_BACKGROUND_COLOR   
NC_("SCSTR_FILTER_BACKGROUND_COLOR", "Background color")
+#define SCSTR_FILTER_TEXT_COLOR 
NC_("SCSTR_FILTER_TEXT_COLOR", "Text Color")
+#define SCSTR_FILTER_BACKGROUND_COLOR   
NC_("SCSTR_FILTER_BACKGROUND_COLOR", "Background Color")
+// This must match the translation of the same strings of 
standardfilterdialog|cond
+#define SCSTR_FILTER_TEXT_COLOR_COND
NC_("STANDARDFILTERDIALOG_COND", "Text color")
+#define SCSTR_FILTER_BACKGROUND_COLOR_COND  
NC_("STANDARDFILTERDIALOG_COND", "Background color")
 #define SCSTR_FILTER_NO_FILL
NC_("SCSTR_FILTER_NO_FILL", "No Fill")
 #define SCSTR_FILTER_AUTOMATIC_COLOR
NC_("SCSTR_FILTER_AUTOMATIC_COLOR", "Automatic")
 #define SCSTR_NONAMENC_("SCSTR_NONAME", 
"unnamed")
diff --git a/sc/source/ui/dbgui/filtdlg.cxx b/sc/source/ui/dbgui/filtdlg.cxx
index e5eb4a7b333c..8b4c0b852a8b 100644
--- a/sc/source/ui/dbgui/filtdlg.cxx
+++ b/sc/source/ui/dbgui/filtdlg.cxx
@@ -60,8 +60,8 @@ ScFilterDlg::ScFilterDlg(SfxBindings* pB, SfxChildWindow* 
pCW, weld::Window* pPa
 , aStrEmpty(ScResId(SCSTR_FILTER_EMPTY))
 , aStrNotEmpty(ScResId(SCSTR_FILTER_NOTEMPTY))
 , aStrColumn(ScResId(SCSTR_COLUMN))
-, aStrTextColor(ScResId(SCSTR_FILTER_TEXT_COLOR))
-, aStrBackgroundColor(ScResId(SCSTR_FILTER_BACKGROUND_COLOR))
+, aStrTextColor(ScResId(SCSTR_FILTER_TEXT_COLOR_COND))
+, aStrBackgroundColor(ScResId(SCSTR_FILTER_BACKGROUND_COLOR_COND))
 , nWhichQuery(rArgSet.GetPool()->GetWhich(SID_QUERY))
 , theQueryData(static_cast(rArgSet.Get(nWhichQuery)).GetQueryData())
 , pViewData(nullptr)
@@ -114,6 +114,9 @@ ScFilterDlg::ScFilterDlg(SfxBindings* pB, SfxChildWindow* 
pCW, weld::Window* pPa
 m_xEdCopyArea->SetReferences(this, m_xFtDbAreaLabel.get());
 m_xRbCopyArea->SetReferences(this, m_xEdCopyArea.get());
 
+assert(m_xLbCond1->find_text(aStrTextColor) != -1);
+assert(m_xLbCond1->find_text(aStrBackgroundColor) != -1);
+
 Init( rArgSet );
 
 // Hack: RefInput control
diff --git a/sc/uiconfig/scalc/ui/standardfilterdialog.ui 
b/sc/uiconfig/scalc/ui/standardfilterdialog.ui
index cb5e66ea62bb..359273e11ff7 100644
--- a/sc/uiconfig/scalc/ui/standardfilterdialog.ui
+++ b/sc/uiconfig/scalc/ui/standardfilterdialog.ui
@@ -420,18 +420,18 @@
   <=
   >=
   <>
-  Largest
-  Smallest
-  Largest %
-  Smallest %
-  Contains
-  Does not contain
-  Begins with
-  Does not begin with
-  Ends with
-  Does not end with
-  Text color
-  Background color
+  Largest
+  Smallest
+  Largest %
+  Smallest %
+  Contains
+  Does not contain
+  Begins with
+  Does not begin with
+  Ends with
+  

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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sw/source/filter/html/htmlgrin.cxx |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 6a5c8d9609d2d3b1dc4b7f67ea41fb43add9a993
Author: Caolán McNamara 
AuthorDate: Wed Nov 17 09:43:34 2021 +
Commit: Caolán McNamara 
CommitDate: Wed Nov 17 14:40:26 2021 +0100

ofz#41081 divide by zero

and

ofz#41088 divide by zero

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

diff --git a/sw/source/filter/html/htmlgrin.cxx 
b/sw/source/filter/html/htmlgrin.cxx
index 1d176945394d..582f30caa4f6 100644
--- a/sw/source/filter/html/htmlgrin.cxx
+++ b/sw/source/filter/html/htmlgrin.cxx
@@ -526,9 +526,9 @@ IMAGE_SETEVENT:
 if (!bHeightProvided)
 nHeight = aPixelSize.Height();
 // tdf#142781 - calculate the width/height keeping the aspect ratio
-if (!bPercentWidth && bWidthProvided && !bHeightProvided)
+if (!bPercentWidth && bWidthProvided && !bHeightProvided && 
aPixelSize.Width())
 nHeight = nWidth * aPixelSize.Height() / aPixelSize.Width();
-else if (!bPercentHeight && !bWidthProvided && bHeightProvided)
+else if (!bPercentHeight && !bWidthProvided && bHeightProvided && 
aPixelSize.Height())
 nWidth = nHeight * aPixelSize.Width() / aPixelSize.Height();
 }
 


Re: Contributing to your organisation

2021-11-17 Thread Ilmari Lauhakangas

On 17.11.2021 14.07, Lkshy wrote:

Respected Sir/Mam

My name is Lakshay Chhabra. Currently, I am pursuing a BE in the stream 
of Computer Science Engineering at Thapar institute of Engineering and 
technology, Patiala.
I am a newbie at open source and looking forward to starting my 
opensource journey with your organisation.
I am proficient at C++,Java, HTML, CSS, Bootstrap, Javascript, React and 
Flutter and have a good knowledge about MongoDB, SQL, Node.js.

Could you please help me in getting started?


I have invited you to an interview.

Ilmari


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

2021-11-17 Thread Luboš Luňák (via logerrit)
 canvas/source/vcl/canvashelper.cxx |5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

New commits:
commit b4f03a95db84c1d18c9435d13f41787596d34b12
Author: Luboš Luňák 
AuthorDate: Wed Nov 17 10:36:25 2021 +0100
Commit: Luboš Luňák 
CommitDate: Wed Nov 17 14:12:48 2021 +0100

stop vclcanvas from ruining alpha of bitmaps in Skia mode

According to the comment and tdf#45219 vclcanvas deliberately forces
alpha to be 1bpp because of poor performance. But that's not the case
with Skia, alpha is always 8bpp there, so all the hack does it make
animations look ugly and it also breaks caching capabilities of the
Skia backend because the hack always generates a new bitmap.

I don't know which VCL backend the original problem was related to,
so at least disable the hack for Skia.

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

diff --git a/canvas/source/vcl/canvashelper.cxx 
b/canvas/source/vcl/canvashelper.cxx
index 69ef1922de5a..80a0dc2a8fa6 100644
--- a/canvas/source/vcl/canvashelper.cxx
+++ b/canvas/source/vcl/canvashelper.cxx
@@ -41,6 +41,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 
@@ -707,7 +708,7 @@ namespace vclcanvas
 // actually what mp2ndOutDev is...  well, here we do &
 // assume a 1bpp target - everything beyond 97%
 // transparency is fully transparent
-if( aBmpEx.IsAlpha() )
+if( aBmpEx.IsAlpha() && !SkiaHelper::isVCLSkiaEnabled())
 {
 BitmapFilter::Filter(aBmpEx, 
BitmapAlphaClampFilter(253));
 }
@@ -734,7 +735,7 @@ namespace vclcanvas
 // actually what mp2ndOutDev is...  well, here we do &
 // assume a 1bpp target - everything beyond 97%
 // transparency is fully transparent
-if( aBmpEx.IsAlpha() )
+if( aBmpEx.IsAlpha() && !SkiaHelper::isVCLSkiaEnabled())
 {
 BitmapFilter::Filter(aBmpEx, 
BitmapAlphaClampFilter(253));
 }


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

2021-11-17 Thread Luboš Luňák (via logerrit)
 vcl/skia/SkiaHelper.cxx |2 --
 1 file changed, 2 deletions(-)

New commits:
commit 23b17e409976f3c106028cc6617ca3a841eb839d
Author: Luboš Luňák 
AuthorDate: Wed Nov 17 10:20:33 2021 +0100
Commit: Luboš Luňák 
CommitDate: Wed Nov 17 14:12:29 2021 +0100

Skia dumping is no longer dbgutil-only

This is a mistake from f33b76b4e675818deae244427cef84c576a1a1f8.

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

diff --git a/vcl/skia/SkiaHelper.cxx b/vcl/skia/SkiaHelper.cxx
index cc9303af39f5..631e5b64fe52 100644
--- a/vcl/skia/SkiaHelper.cxx
+++ b/vcl/skia/SkiaHelper.cxx
@@ -47,9 +47,7 @@ bool isVCLSkiaEnabled() { return false; }
 #include 
 #include 
 #include 
-#ifdef DBG_UTIL
 #include 
-#endif
 
 namespace SkiaHelper
 {


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

2021-11-17 Thread Luboš Luňák (via logerrit)
 configure.ac |   12 ++--
 1 file changed, 10 insertions(+), 2 deletions(-)

New commits:
commit 75450b3affc424cccfc68eae13a3271204108b09
Author: Luboš Luňák 
AuthorDate: Wed Nov 17 11:43:00 2021 +0100
Commit: Luboš Luňák 
CommitDate: Wed Nov 17 14:11:57 2021 +0100

disable split debug if --enable-lto

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88389 is right that
split-debug doesn't make sense with LTO. Without -ffat-lto-objects
or with Clang .o files aren't even really object files that
would be normally usable. Since gcc complains if the combination
is used, explicitly avoid it.

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

diff --git a/configure.ac b/configure.ac
index 1872faaafbd7..7ebeeaf6e62f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -4557,8 +4557,16 @@ AC_SUBST(LD_GC_SECTIONS)
 
 HAVE_GSPLIT_DWARF=
 if test "$enable_split_debug" != no; then
+use_split_debug=
+if test -n "$ENABLE_LTO"; then
+true # Inherently incompatible, since no debug info is created while 
compiling, GCC complains.
+elif test "$enable_split_debug" = yes; then
+use_split_debug=1
 dnl Currently by default enabled only on Linux, feel free to set 
test_split_debug above also for other platforms.
-if test "$enable_split_debug" = yes -o \( "$test_split_debug" = "yes" -a 
-n "$ENABLE_DEBUG$ENABLE_DBGUTIL" \); then
+elif test "$test_split_debug" = "yes" -a -n 
"$ENABLE_DEBUG$ENABLE_DBGUTIL"; then
+use_split_debug=1
+fi
+if test -n "$use_split_debug"; then
 AC_MSG_CHECKING([whether $CC_BASE supports -gsplit-dwarf])
 save_CFLAGS=$CFLAGS
 CFLAGS="$CFLAGS -Werror -gsplit-dwarf"
@@ -4574,7 +4582,7 @@ if test "$enable_split_debug" != no; then
 fi
 fi
 fi
-if test -z "$HAVE_GCC_SPLIT_DWARF" -a "$test_split_debug" = "yes" -a -n 
"$ENABLE_DEBUG$ENABLE_DBGUTIL"; then
+if test -z "$HAVE_GCC_SPLIT_DWARF" -a "$test_split_debug" = "yes" -a -n 
"$use_split_debug"; then
 AC_MSG_WARN([Compiler is not capable of creating split debug info, 
linking will require more time and disk space.])
 add_warning "Compiler is not capable of creating split debug info, 
linking will require more time and disk space."
 fi


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sc/inc/strings.hrc |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 32aa44e928ceb5194e37ad0a4fb2f38f1c7371c2
Author: Caolán McNamara 
AuthorDate: Tue Nov 16 16:29:15 2021 +
Commit: Caolán McNamara 
CommitDate: Wed Nov 17 14:01:22 2021 +0100

use title case for "No Fill" like "Not Empty"

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

diff --git a/sc/inc/strings.hrc b/sc/inc/strings.hrc
index ff7094dae69f..59e1efd14b02 100644
--- a/sc/inc/strings.hrc
+++ b/sc/inc/strings.hrc
@@ -37,7 +37,7 @@
 #define SCSTR_FILTER_NOTEMPTY   
NC_("SCSTR_FILTER_NOTEMPTY", "Not Empty")
 #define SCSTR_FILTER_TEXT_COLOR 
NC_("SCSTR_FILTER_TEXT_COLOR", "Text color")
 #define SCSTR_FILTER_BACKGROUND_COLOR   
NC_("SCSTR_FILTER_BACKGROUND_COLOR", "Background color")
-#define SCSTR_FILTER_NO_FILL
NC_("SCSTR_FILTER_NO_FILL", "No fill")
+#define SCSTR_FILTER_NO_FILL
NC_("SCSTR_FILTER_NO_FILL", "No Fill")
 #define SCSTR_FILTER_AUTOMATIC_COLOR
NC_("SCSTR_FILTER_AUTOMATIC_COLOR", "Automatic")
 #define SCSTR_NONAMENC_("SCSTR_NONAME", 
"unnamed")
 #define SCSTR_INSERT_RTLNC_("SCSTR_INSERT_RTL", 
"Shift cells left")


[Libreoffice-commits] core.git: Branch 'libreoffice-7-2' - solenv/bin

2021-11-17 Thread Mike Kaganski (via logerrit)
 solenv/bin/modules/installer/pathanalyzer.pm |4 ++--
 solenv/bin/modules/pre2par/pathanalyzer.pm   |5 +++--
 2 files changed, 5 insertions(+), 4 deletions(-)

New commits:
commit 13a9d141b5933f81f4074dd4dc2ab98509df6518
Author: Mike Kaganski 
AuthorDate: Wed Nov 17 01:17:17 2021 +0300
Commit: Xisco Fauli 
CommitDate: Wed Nov 17 13:44:02 2021 +0100

tdf#145711: filename may be 1-character, and must not contain path separator

Surfaced after 6ea7ca45782a7e1b46e18e994534ec0a7c71951b

Change-Id: I4975f51a7a0ca73eccfd17338abc122254b57113
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125338
Tested-by: Mike Kaganski 
Reviewed-by: Mike Kaganski 
(cherry picked from commit f007f32958a7c875db6cb2e79c09ab0965477a2a)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125347
Tested-by: Jenkins
Reviewed-by: Xisco Fauli 

diff --git a/solenv/bin/modules/installer/pathanalyzer.pm 
b/solenv/bin/modules/installer/pathanalyzer.pm
index 7f3f68a4edb2..312042acb1a0 100644
--- a/solenv/bin/modules/installer/pathanalyzer.pm
+++ b/solenv/bin/modules/installer/pathanalyzer.pm
@@ -47,7 +47,7 @@ sub make_absolute_filename_to_relative_filename
 
 if ( $installer::globals::isunix )
 {
-if ( $$longfilenameref =~ /^.*\/(\S.+\S?)/ )
+if ( $$longfilenameref =~ /^.*\/(?=\S)([^\/]+)(?<=\S)/ )
 {
 $$longfilenameref = $1;
 }
@@ -56,7 +56,7 @@ sub make_absolute_filename_to_relative_filename
 if ( $installer::globals::iswin )
 {
 # Either '/' or '\'. It would be possible to use 
$installer::globals::separator.
-if ( $$longfilenameref =~ /^.*[\/\\](\S.+\S?)/ )
+if ( $$longfilenameref =~ /^.*[\/\\](?=\S)([^\/\\]+)(?<=\S)/ )
 {
 $$longfilenameref = $1;
 }
diff --git a/solenv/bin/modules/pre2par/pathanalyzer.pm 
b/solenv/bin/modules/pre2par/pathanalyzer.pm
index 0aefcd1b43c8..4d2eb31ae073 100644
--- a/solenv/bin/modules/pre2par/pathanalyzer.pm
+++ b/solenv/bin/modules/pre2par/pathanalyzer.pm
@@ -48,7 +48,7 @@ sub make_absolute_filename_to_relative_filename
 
 if ( $pre2par::globals::isunix )
 {
-if ( $$longfilenameref =~ /^.*\/(\S.+\S?)/ )
+if ( $$longfilenameref =~ /^.*\/(?=\S)([^\/]+)(?<=\S)/ )
 {
 $$longfilenameref = $1;
 }
@@ -56,7 +56,8 @@ sub make_absolute_filename_to_relative_filename
 
 if ( $pre2par::globals::iswin )
 {
-if ( $$longfilenameref =~ /^.*\\(\S.+\S?)/ )
+# Either '/' or '\'.
+if ( $$longfilenameref =~ /^.*[\/\\](?=\S)([^\/\\]+)(?<=\S)/ )
 {
 $$longfilenameref = $1;
 }


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 external/liborcus/UnpackedTarball_liborcus.mk  
|4 +
 external/liborcus/crashtesting-crash-on-passing-null-to-std-string_vie.patch.1 
|   27 ++
 2 files changed, 31 insertions(+)

New commits:
commit 037d5454a39260635aeb7064ac32c7a485af8197
Author: Caolán McNamara 
AuthorDate: Wed Nov 17 10:27:03 2021 +
Commit: Caolán McNamara 
CommitDate: Wed Nov 17 13:43:22 2021 +0100

crashtesting: crash on passing null to std::string_view

with many documents, e.g. moz377878-1.xhtml

https: //gitlab.com/orcus/orcus/-/merge_requests/113
Change-Id: I085543ebb28c02a1c0ec487b357f6e0a83004363
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125378
Tested-by: Caolán McNamara 
Reviewed-by: Caolán McNamara 

diff --git a/external/liborcus/UnpackedTarball_liborcus.mk 
b/external/liborcus/UnpackedTarball_liborcus.mk
index 3d2cec42e55e..86c30431e05d 100644
--- a/external/liborcus/UnpackedTarball_liborcus.mk
+++ b/external/liborcus/UnpackedTarball_liborcus.mk
@@ -15,6 +15,9 @@ $(eval $(call gb_UnpackedTarball_set_patchlevel,liborcus,1))
 
 $(eval $(call gb_UnpackedTarball_update_autoconf_configs,liborcus))
 
+# crashtesting-crash-on-passing-null-to-std-string_vie.patch.1 submitted as
+# https://gitlab.com/orcus/orcus/-/merge_requests/113
+
 $(eval $(call gb_UnpackedTarball_add_patches,liborcus,\
external/liborcus/rpath.patch.0 \
external/liborcus/gcc9.patch.0 \
@@ -25,6 +28,7 @@ $(eval $(call gb_UnpackedTarball_add_patches,liborcus,\
external/liborcus/unused-variables.patch.1 \
external/liborcus/boost-filesystem.patch.1 \
external/liborcus/std-get-busted.patch.1 \
+   
external/liborcus/crashtesting-crash-on-passing-null-to-std-string_vie.patch.1 \
 ))
 
 ifeq ($(OS),WNT)
diff --git 
a/external/liborcus/crashtesting-crash-on-passing-null-to-std-string_vie.patch.1
 
b/external/liborcus/crashtesting-crash-on-passing-null-to-std-string_vie.patch.1
new file mode 100644
index ..97e7b8366fde
--- /dev/null
+++ 
b/external/liborcus/crashtesting-crash-on-passing-null-to-std-string_vie.patch.1
@@ -0,0 +1,27 @@
+From ed21a93e132b968d8cd91aa080e1f90e980267c7 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= 
+Date: Wed, 17 Nov 2021 10:21:32 +
+Subject: [PATCH] crashtesting: crash on passing null to std::string_view
+
+with many documents, e.g. moz377878-1.xhtml
+---
+ src/parser/xml_namespace.cpp | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/src/parser/xml_namespace.cpp b/src/parser/xml_namespace.cpp
+index 07942563..66077d9c 100644
+--- a/src/parser/xml_namespace.cpp
 b/src/parser/xml_namespace.cpp
+@@ -223,7 +223,8 @@ xmlns_id_t xmlns_context::push(std::string_view key, 
std::string_view uri)
+ #endif
+ mp_impl->m_trim_all_ns = true;
+ 
+-std::string_view uri_interned = mp_impl->repo->intern(uri);
++xmlns_id_t id = mp_impl->repo->intern(uri);
++std::string_view uri_interned = id ? std::string_view(id) : 
std::string_view();
+ 
+ if (key.empty())
+ {
+-- 
+2.33.1
+


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sc/source/ui/cctrl/checklistmenu.cxx |7 +--
 1 file changed, 5 insertions(+), 2 deletions(-)

New commits:
commit 753f5d65b4a91e179c61eeea2645ae190eb80155
Author: Caolán McNamara 
AuthorDate: Wed Nov 17 10:48:59 2021 +
Commit: Caolán McNamara 
CommitDate: Wed Nov 17 13:42:52 2021 +0100

don't attempt to set cursor to first entry if there are no entries

avoids gtk warning of:
gtk_tree_view_scroll_to_cell: assertion 'tree_view->priv->tree != NULL

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

diff --git a/sc/source/ui/cctrl/checklistmenu.cxx 
b/sc/source/ui/cctrl/checklistmenu.cxx
index 5fcfa27c0c1b..56fb60477220 100644
--- a/sc/source/ui/cctrl/checklistmenu.cxx
+++ b/sc/source/ui/cctrl/checklistmenu.cxx
@@ -623,8 +623,11 @@ void ScCheckListMenuControl::prepWindow()
 {
 mxMenu->set_size_request(-1, mxMenu->get_preferred_size().Height() + 2);
 mnSelectedMenu = 0;
-mxMenu->set_cursor(mnSelectedMenu);
-mxMenu->unselect_all();
+if (mxMenu->n_children())
+{
+mxMenu->set_cursor(mnSelectedMenu);
+mxMenu->unselect_all();
+}
 
 mnWndWidth = mxContainer->get_preferred_size().Width() + 
mxFrame->get_border_width() * 2 + 4;
 }


Contributing to your organisation

2021-11-17 Thread Lkshy
Respected Sir/Mam

My name is Lakshay Chhabra. Currently, I am pursuing a BE in the stream of
Computer Science Engineering at Thapar institute of Engineering and
technology, Patiala.
I am a newbie at open source and looking forward to starting my opensource
journey with your organisation.
I am proficient at C++,Java, HTML, CSS, Bootstrap, Javascript, React and
Flutter and have a good knowledge about MongoDB, SQL, Node.js.
Could you please help me in getting started?

Thanking You
Lakshay Chhabra


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

2021-11-17 Thread Katarina Behrens (via logerrit)
 sd/source/ui/animations/CustomAnimationPane.cxx |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 41b679f73e2001cd2840dd1256911e0b79bacaf8
Author: Katarina Behrens 
AuthorDate: Fri Nov 12 14:32:34 2021 +0100
Commit: Xisco Fauli 
CommitDate: Wed Nov 17 13:27:14 2021 +0100

tdf#135033: Make undo of adding and editing animations possible

weird this somehow sneaked out when converting custom animation
pane to sidebar when undoing other operations (delete etc.) stayed
in place

Change-Id: I6287682839d0e0401cc60bf82257d86765f3a858
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125110
Tested-by: Jenkins
Reviewed-by: Katarina Behrens 
(cherry picked from commit 71a186aedc6060bb4fb834c847f74c657d700f1e)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125357
Reviewed-by: Xisco Fauli 

diff --git a/sd/source/ui/animations/CustomAnimationPane.cxx 
b/sd/source/ui/animations/CustomAnimationPane.cxx
index 4585fd335bdc..d17f1460b91f 100644
--- a/sd/source/ui/animations/CustomAnimationPane.cxx
+++ b/sd/source/ui/animations/CustomAnimationPane.cxx
@@ -1832,6 +1832,7 @@ void CustomAnimationPane::onAdd()
 updateMotionPathTags();
 }
 
+addUndo();
 mrBase.GetDocShell()->SetModified();
 
 updateControls();
@@ -2133,6 +2134,7 @@ IMPL_LINK_NOARG(CustomAnimationPane, SelectionHandler, 
Timer*, void)
 pEffectSequence->replace( pEffect, pDescriptor, fDuration );
 }
 
+addUndo();
 onPreview(false);
 }
 


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

2021-11-17 Thread Sarper Akdemir (via logerrit)
 include/svx/ColorSets.hxx   |   23 +
 include/svx/svdmodel.hxx|7 +
 svx/source/styles/ColorSets.cxx |   53 
 svx/source/svdraw/svdmodel.cxx  |   11 
 4 files changed, 94 insertions(+)

New commits:
commit 3171d185f8c17799f0b85f5931aa59101cbc6b4e
Author: Sarper Akdemir 
AuthorDate: Wed Jul 28 02:03:12 2021 +0300
Commit: Miklos Vajna 
CommitDate: Wed Nov 17 13:26:45 2021 +0100

make colorsets work outside of styles and with direct formatting

[ Miklos: picked only the document model bits, now in SdrModel, next to
styles. ]

(cherry picked from commit 1647d34d8573f4940c0cbb7fb6cd9c6b4e5a4a15,
from the feature/themesupport2 branch)

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

diff --git a/include/svx/ColorSets.hxx b/include/svx/ColorSets.hxx
index 361fe47c622e..eee992da94b5 100644
--- a/include/svx/ColorSets.hxx
+++ b/include/svx/ColorSets.hxx
@@ -18,6 +18,8 @@
 #include 
 #include 
 
+typedef struct _xmlTextWriter* xmlTextWriterPtr;
+
 namespace svx
 {
 
@@ -41,6 +43,8 @@ public:
 {
 return maColors[nIndex];
 }
+
+void dumpAsXml(xmlTextWriterPtr pWriter) const;
 };
 
 class SVXCORE_DLLPUBLIC ColorSets
@@ -64,6 +68,25 @@ public:
 const ColorSet& getColorSet(std::u16string_view rName);
 };
 
+/// A named theme has a named color set.
+class SVXCORE_DLLPUBLIC Theme
+{
+OUString maName;
+std::unique_ptr mpColorSet;
+
+public:
+Theme(OUString const& rName);
+~Theme();
+
+void SetColorSet(std::unique_ptr pColorSet);
+ColorSet* GetColorSet();
+
+void SetName(const OUString& rName);
+const OUString& GetName() const;
+
+void dumpAsXml(xmlTextWriterPtr pWriter) const;
+};
+
 } // end of namespace svx
 
 #endif // INCLUDED_SVX_COLORSETS_HXX
diff --git a/include/svx/svdmodel.hxx b/include/svx/svdmodel.hxx
index 73fc9f646f43..ab9578a7bc93 100644
--- a/include/svx/svdmodel.hxx
+++ b/include/svx/svdmodel.hxx
@@ -90,6 +90,10 @@ namespace com::sun::star::beans {
 struct PropertyValue;
 }
 
+namespace svx
+{
+class Theme;
+}
 
 constexpr const sal_Unicode DEGREE_CHAR = u'\x00B0'; /* U+00B0 DEGREE SIGN */
 
@@ -536,6 +540,9 @@ public:
 SfxStyleSheetBasePool* GetStyleSheetPool() const { return 
mxStyleSheetPool.get(); }
 void SetStyleSheetPool(SfxStyleSheetBasePool* pPool) { 
mxStyleSheetPool=pPool; }
 
+void SetTheme(std::unique_ptr pTheme);
+svx::Theme* GetTheme();
+
 voidSetStarDrawPreviewMode(bool bPreview);
 boolIsStarDrawPreviewMode() const { return m_bStarDrawPreviewMode; }
 
diff --git a/svx/source/styles/ColorSets.cxx b/svx/source/styles/ColorSets.cxx
index 7a04eb4e6314..91a44f1782ea 100644
--- a/svx/source/styles/ColorSets.cxx
+++ b/svx/source/styles/ColorSets.cxx
@@ -10,6 +10,10 @@
 
 #include 
 
+#include 
+
+#include 
+
 namespace svx
 {
 
@@ -21,6 +25,25 @@ ColorSet::ColorSet(OUString const & aColorSetName)
 ColorSets::ColorSets()
 {}
 
+void ColorSet::dumpAsXml(xmlTextWriterPtr pWriter) const
+{
+(void)xmlTextWriterStartElement(pWriter, BAD_CAST("ColorSet"));
+(void)xmlTextWriterWriteFormatAttribute(pWriter, BAD_CAST("ptr"), "%p", 
this);
+(void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST("maColorSetName"),
+  
BAD_CAST(maColorSetName.toUtf8().getStr()));
+
+for (const auto& rColor : maColors)
+{
+(void)xmlTextWriterStartElement(pWriter, BAD_CAST("Color"));
+std::stringstream ss;
+ss << rColor;
+(void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST("value"), 
BAD_CAST(ss.str().c_str()));
+(void)xmlTextWriterEndElement(pWriter);
+}
+
+(void)xmlTextWriterEndElement(pWriter);
+}
+
 ColorSets::~ColorSets()
 {}
 
@@ -102,6 +125,36 @@ const ColorSet& ColorSets::getColorSet(std::u16string_view 
rName)
 return maColorSets[0];
 }
 
+Theme::Theme(const OUString& rName)
+: maName(rName)
+{
+}
+
+Theme::~Theme() {}
+
+void Theme::SetColorSet(std::unique_ptr pColorSet) { mpColorSet = 
std::move(pColorSet); }
+
+ColorSet* Theme::GetColorSet() { return mpColorSet.get(); }
+
+void Theme::SetName(const OUString& rName) { maName = rName; }
+
+const OUString& Theme::GetName() const { return maName; }
+
+void Theme::dumpAsXml(xmlTextWriterPtr pWriter) const
+{
+(void)xmlTextWriterStartElement(pWriter, BAD_CAST("Theme"));
+(void)xmlTextWriterWriteFormatAttribute(pWriter, BAD_CAST("ptr"), "%p", 
this);
+(void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST("maName"),
+  BAD_CAST(maName.toUtf8().getStr()));
+
+if (mpColorSet)
+{
+mpColorSet->dumpAsXml(pWriter);
+}
+
+(void)xmlTextWriterEndElement(pWriter);
+}
+
 } // end of namespace svx
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --gi

[Libreoffice-commits] core.git: compilerplugins/clang solenv/clang-format solenv/CompilerTest_compilerplugins_clang.mk

2021-11-17 Thread Luboš Luňák (via logerrit)
 compilerplugins/clang/test/simplifybool.cxx  |  176 ---
 solenv/CompilerTest_compilerplugins_clang.mk |1 
 solenv/clang-format/excludelist  |2 
 3 files changed, 1 insertion(+), 178 deletions(-)

New commits:
commit eb515f11caae5d1b30f7c306fc32111a0cf617b2
Author: Luboš Luňák 
AuthorDate: Wed Nov 17 10:02:06 2021 +0100
Commit: Luboš Luňák 
CommitDate: Wed Nov 17 12:48:36 2021 +0100

retire loplugin:simplifybool

The plugin was originally written to rewrite dumb old OOo code
like 'variable != 1 ? true : false'. All that code has already
been rewritten, and now this plugin just enforces matter-of-taste
stylistics on new code.

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

diff --git a/compilerplugins/clang/simplifybool.cxx 
b/compilerplugins/clang/store/simplifybool.cxx
similarity index 100%
rename from compilerplugins/clang/simplifybool.cxx
rename to compilerplugins/clang/store/simplifybool.cxx
diff --git a/compilerplugins/clang/test/simplifybool.cxx 
b/compilerplugins/clang/test/simplifybool.cxx
deleted file mode 100644
index a32acccd6c19..
--- a/compilerplugins/clang/test/simplifybool.cxx
+++ /dev/null
@@ -1,176 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; 
fill-column: 100 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- */
-
-#include 
-// expected-note@rtl/ustring.hxx:* 2 {{the presumed corresponding negated 
operator for 'rtl::OUString' and 'rtl::OUString' is declared here 
[loplugin:simplifybool]}}
-#include 
-// expected-note@rtl/string.hxx:* {{the presumed corresponding negated 
operator for 'rtl::OString' and 'rtl::OString' is declared here 
[loplugin:simplifybool]}}
-#include 
-// expected-note@basegfx/tuple/b3dtuple.hxx:* {{the presumed corresponding 
negated operator for 'basegfx::B3DVector' and 'basegfx::B3DVector' is declared 
here [loplugin:simplifybool]}}
-
-#include 
-
-#pragma clang diagnostic ignored "-Wunknown-warning-option" // for Clang < 13
-#pragma clang diagnostic ignored "-Wunused-but-set-variable"
-
-namespace group1
-{
-void f1(int a, int b)
-{
-if (!(a < b))
-{ // expected-error@-1 {{logical negation of comparison operator, can be 
simplified by inverting operator [loplugin:simplifybool]}}
-a = b;
-}
-};
-
-void f2(float a, float b)
-{
-// no warning expected
-if (!(a < b))
-{
-a = b;
-}
-};
-};
-
-// Consistently either warn about all or none of the below occurrences of "!!":
-namespace group2
-{
-enum E1
-{
-E1_1 = 1
-};
-
-enum E2
-{
-E2_1 = 1
-};
-E2 operator&(E2 e1, E2 e2);
-bool operator!(E2 e);
-
-enum class E3
-{
-E1 = 1
-};
-struct W
-{
-operator bool();
-};
-W operator&(E3 e1, E3 e2);
-
-bool f0(int n) { return !!(n & 1); }
-
-bool f1(E1 e) { return !!(e & E1_1); }
-
-bool f2(E2 e) { return !!(e & E2_1); }
-
-bool f3(E3 e) { return !!(e & E3::E1); }
-};
-
-// record types
-namespace group3
-{
-struct Record1
-{
-bool operator==(const Record1&) const;
-};
-
-struct Record2
-{
-bool operator==(const Record2&) const;
-bool operator!=(const Record2&) const;
-// expected-note@-1 {{the presumed corresponding negated operator for 
'group3::Record2' and 'group3::Record2' is declared here 
[loplugin:simplifybool]}}
-};
-
-struct Record3
-{
-};
-
-bool operator==(const Record3&, const Record3&);
-bool operator!=(const Record3&, const Record3&);
-// expected-note@-1 {{the presumed corresponding negated operator for 
'group3::Record3' and 'group3::Record3' is declared here 
[loplugin:simplifybool]}}
-
-void testRecord()
-{
-Record1 a1;
-Record1 a2;
-// no warning expected, because a negated operator does not exist
-bool v = !(a1 == a2);
-Record2 b1;
-Record2 b2;
-v = !(b1 == b2);
-// expected-error@-1 {{logical negation of comparison operator, can be 
simplified by inverting operator [loplugin:simplifybool]}}
-Record3 c1;
-Record3 c2;
-v = !(c1 == c2);
-// expected-error@-1 {{logical negation of comparison operator, can be 
simplified by inverting operator [loplugin:simplifybool]}}
-OUString d1;
-OUString d2;
-v = !(d1 == d2);
-// expected-error@-1 {{logical negation of comparison operator, can be 
simplified by inverting operator [loplugin:simplifybool]}}
-OString e1;
-OString e2;
-v = !(e1 == e2);
-// expected-error@-1 {{logical negation of comparison operator, can be 
simplified by inverting operator [loplugin:simplifybool]}}
-
-// the operator != is in a base-class, and the param is a base-type
-basegfx::B3DVector f1;
-basegfx::B3DVector

[Libreoffice-commits] core.git: compilerplugins/clang solenv/clang-format solenv/CompilerTest_compilerplugins_clang.mk

2021-11-17 Thread Luboš Luňák (via logerrit)
 compilerplugins/clang/test/finalprotected.cxx |   35 --
 solenv/CompilerTest_compilerplugins_clang.mk  |1 
 solenv/clang-format/excludelist   |2 -
 3 files changed, 1 insertion(+), 37 deletions(-)

New commits:
commit bfe589d13fafc0801d709a79144114d289958cae
Author: Luboš Luňák 
AuthorDate: Wed Nov 17 10:04:35 2021 +0100
Commit: Luboš Luňák 
CommitDate: Wed Nov 17 12:48:20 2021 +0100

remove loplugin:finalprotected

It just forces a custom rule that serves no real purpose. There's
no technical difference. If one day a class gets inherited from
then this information will be lost/incorrect. And mixing access
on a virtual function is poor style.

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

diff --git a/compilerplugins/clang/finalprotected.cxx 
b/compilerplugins/clang/store/finalprotected.cxx
similarity index 100%
rename from compilerplugins/clang/finalprotected.cxx
rename to compilerplugins/clang/store/finalprotected.cxx
diff --git a/compilerplugins/clang/test/finalprotected.cxx 
b/compilerplugins/clang/test/finalprotected.cxx
deleted file mode 100644
index c15564874447..
--- a/compilerplugins/clang/test/finalprotected.cxx
+++ /dev/null
@@ -1,35 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; 
fill-column: 100 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- */
-
-
-class S final {
-protected:
-void f(int f) { f1 = f; }  // expected-error {{final class should not have 
protected members - convert them to private [loplugin:finalprotected]}}
-int f1;  // expected-error {{final class should not have protected 
members - convert them to private [loplugin:finalprotected]}}
-public:
-void g();
-int g1;
-private:
-void h();
-int h1;
-};
-
-class S2 {
-protected:
-void f(int f) { f1 = f; }
-int f1;
-public:
-void g();
-int g1;
-private:
-void h();
-int h1;
-};
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */
diff --git a/solenv/CompilerTest_compilerplugins_clang.mk 
b/solenv/CompilerTest_compilerplugins_clang.mk
index 53f51e0759ba..75afd793843e 100644
--- a/solenv/CompilerTest_compilerplugins_clang.mk
+++ b/solenv/CompilerTest_compilerplugins_clang.mk
@@ -38,7 +38,6 @@ $(eval $(call 
gb_CompilerTest_add_exception_objects,compilerplugins_clang, \
 compilerplugins/clang/test/external \
 compilerplugins/clang/test/faileddyncast \
 compilerplugins/clang/test/fakebool \
-compilerplugins/clang/test/finalprotected \
 compilerplugins/clang/test/flatten \
 compilerplugins/clang/test/fragiledestructor \
 compilerplugins/clang/test/getstr \
diff --git a/solenv/clang-format/excludelist b/solenv/clang-format/excludelist
index 2608eb588055..1fd086ffb285 100644
--- a/solenv/clang-format/excludelist
+++ b/solenv/clang-format/excludelist
@@ -1484,7 +1484,6 @@ compilerplugins/clang/externandnotdefined.cxx
 compilerplugins/clang/faileddyncast.cxx
 compilerplugins/clang/fakebool.cxx
 compilerplugins/clang/finalclasses.cxx
-compilerplugins/clang/finalprotected.cxx
 compilerplugins/clang/flatten.cxx
 compilerplugins/clang/fragiledestructor.cxx
 compilerplugins/clang/functionaddress.hxx
@@ -1541,6 +1540,7 @@ compilerplugins/clang/store/deadclass.cxx
 compilerplugins/clang/store/defaultparams.cxx
 compilerplugins/clang/store/deletedspecial.cxx
 compilerplugins/clang/store/derivedclass.cxx
+compilerplugins/clang/store/finalprotected.cxx
 compilerplugins/clang/store/findoncontainer.cxx
 compilerplugins/clang/store/fpcomparison.cxx
 compilerplugins/clang/store/lclstaticfix.cxx


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

2021-11-17 Thread Luboš Luňák (via logerrit)
 solenv/gbuild/PrecompiledHeaders.mk |1 +
 1 file changed, 1 insertion(+)

New commits:
commit d72237ff21db37f0d8c97f47c8583cba99f141df
Author: Luboš Luňák 
AuthorDate: Wed Nov 17 11:06:26 2021 +0100
Commit: Luboš Luňák 
CommitDate: Wed Nov 17 12:47:28 2021 +0100

fix system pch breaking after f22e5078cfac93c50ae5169f6545091

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

diff --git a/solenv/gbuild/PrecompiledHeaders.mk 
b/solenv/gbuild/PrecompiledHeaders.mk
index 312980265eca..9a8763657d2d 100644
--- a/solenv/gbuild/PrecompiledHeaders.mk
+++ b/solenv/gbuild/PrecompiledHeaders.mk
@@ -160,6 +160,7 @@ gb_PrecompiledHeader_ignore_flags_system := \
 -DVCL_INTERNALS \
 -DZLIB_CONST \
 -include $(SRCDIR)/pch/inc/clangfix.hxx \
+$(gb_PrecompiledHeader_ignore_flags_for_flags_file) \
 
 # Probably also update pch/inc/clangfix.hxx if you extend the list.
 


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

2021-11-17 Thread Stephan Bergmann (via logerrit)
 svtools/source/svhtml/parhtml.cxx |1 -
 1 file changed, 1 deletion(-)

New commits:
commit b2065d0ef6ee90387759fdd952fc4e509f264ed3
Author: Stephan Bergmann 
AuthorDate: Wed Nov 17 11:02:09 2021 +0100
Commit: Stephan Bergmann 
CommitDate: Wed Nov 17 12:22:41 2021 +0100

Remove newly redundant break

...after 0047e38da8bdfe09360cc2a658283ad5e18986e7 "svtools: HTMLParser: 
don't
insert EOF into strings"

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

diff --git a/svtools/source/svhtml/parhtml.cxx 
b/svtools/source/svhtml/parhtml.cxx
index e96af0e732a7..8c9d7909602f 100644
--- a/svtools/source/svhtml/parhtml.cxx
+++ b/svtools/source/svhtml/parhtml.cxx
@@ -961,7 +961,6 @@ HtmlTokenId HTMLParser::GetNextRawToken()
 aEndToken.clear();
 nToken = HtmlTokenId::NONE;
 }
-break;
 }
 break;
 default:


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

2021-11-17 Thread Michael Stahl (via logerrit)
 sw/source/filter/html/htmltab.cxx |   10 +++---
 1 file changed, 3 insertions(+), 7 deletions(-)

New commits:
commit f53189e02c6017f2ba6d7d83ead69f763d3b29aa
Author: Michael Stahl 
AuthorDate: Wed Nov 17 11:04:19 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 12:21:26 2021 +0100

oops, fix merge error in commit 08abcae56b13b11d699a30553f7edfc54225d687

"ofz#40593 remove Objects from m_xResizeDrawObjects if deleted during parse"

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

diff --git a/sw/source/filter/html/htmltab.cxx 
b/sw/source/filter/html/htmltab.cxx
index f90b77522319..670ed3ae7aeb 100644
--- a/sw/source/filter/html/htmltab.cxx
+++ b/sw/source/filter/html/htmltab.cxx
@@ -1069,19 +1069,15 @@ bool SwHTMLParser::IsReqIF() const
 }
 
 // if any m_pResizeDrawObjects members are deleted during parse, remove them
-// from m_pResizeDrawObjects and m_xDrawObjectPercentWidths
+// from m_pResizeDrawObjects and m_pDrawObjectPrcWidths
 void HTMLTable::ObjectInDestruction(const SdrObject& rObject)
 {
 auto it = std::find(m_pResizeDrawObjects->begin(), 
m_pResizeDrawObjects->end(), &rObject);
 assert(it != m_pResizeDrawObjects->end());
-#if 0
 auto nIndex = std::distance(m_pResizeDrawObjects->begin(), it);
-#endif
 m_pResizeDrawObjects->erase(it);
-#if 0
-auto otherit = m_xDrawObjectPercentWidths->begin() + nIndex * 3;
-m_xDrawObjectPercentWidths->erase(otherit, otherit + 3);
-#endif
+auto otherit = m_pDrawObjectPrcWidths->begin() + nIndex * 3;
+m_pDrawObjectPrcWidths->erase(otherit, otherit + 3);
 }
 
 HTMLTable::~HTMLTable()


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

2021-11-17 Thread Noel Grandin (via logerrit)
 avmedia/inc/bitmaps.hlst   |4 ++--
 avmedia/inc/helpids.h  |   22 +++---
 avmedia/source/gstreamer/gstplayer.cxx |1 -
 avmedia/source/inc/mediamisc.hxx   |2 +-
 4 files changed, 14 insertions(+), 15 deletions(-)

New commits:
commit 05fd1abb06821be51a6a23a1c8953dfaf24e1187
Author: Noel Grandin 
AuthorDate: Tue Nov 16 12:29:25 2021 +0200
Commit: Noel Grandin 
CommitDate: Wed Nov 17 11:52:43 2021 +0100

loplugin:stringliteraldefine in avmedia

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

diff --git a/avmedia/inc/bitmaps.hlst b/avmedia/inc/bitmaps.hlst
index 0ce3ca1f77c0..758471fbdb3a 100644
--- a/avmedia/inc/bitmaps.hlst
+++ b/avmedia/inc/bitmaps.hlst
@@ -9,7 +9,7 @@
 
 #pragma once
 
-#define AVMEDIA_BMP_AUDIOLOGO   "avmedia/res/avaudiologo.png"
-#define AVMEDIA_BMP_EMPTYLOGO   "avmedia/res/avemptylogo.png"
+inline constexpr OUStringLiteral AVMEDIA_BMP_AUDIOLOGO   = 
u"avmedia/res/avaudiologo.png";
+inline constexpr OUStringLiteral AVMEDIA_BMP_EMPTYLOGO   = 
u"avmedia/res/avemptylogo.png";
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */
diff --git a/avmedia/inc/helpids.h b/avmedia/inc/helpids.h
index c21ba79c9016..1bdf9cc56614 100644
--- a/avmedia/inc/helpids.h
+++ b/avmedia/inc/helpids.h
@@ -19,16 +19,16 @@
 
 #pragma once
 
-#define HID_AVMEDIA_TOOLBOXITEM_PLAY   
"AVMEDIA_HID_AVMEDIA_TOOLBOXITEM_PLAY"
-#define HID_AVMEDIA_TOOLBOXITEM_PAUSE  
"AVMEDIA_HID_AVMEDIA_TOOLBOXITEM_PAUSE"
-#define HID_AVMEDIA_TOOLBOXITEM_STOP   
"AVMEDIA_HID_AVMEDIA_TOOLBOXITEM_STOP"
-#define HID_AVMEDIA_TOOLBOXITEM_MUTE   
"AVMEDIA_HID_AVMEDIA_TOOLBOXITEM_MUTE"
-#define HID_AVMEDIA_TOOLBOXITEM_LOOP   
"AVMEDIA_HID_AVMEDIA_TOOLBOXITEM_LOOP"
-#define HID_AVMEDIA_TOOLBOXITEM_OPEN   
"AVMEDIA_HID_AVMEDIA_TOOLBOXITEM_OPEN"
-#define HID_AVMEDIA_TOOLBOXITEM_INSERT 
"AVMEDIA_HID_AVMEDIA_TOOLBOXITEM_INSERT"
-#define HID_AVMEDIA_ZOOMLISTBOX
"AVMEDIA_HID_AVMEDIA_ZOOMLISTBOX"
-#define HID_AVMEDIA_TIMEEDIT   
"AVMEDIA_HID_AVMEDIA_TIMEEDIT"
-#define HID_AVMEDIA_VOLUMESLIDER   
"AVMEDIA_HID_AVMEDIA_VOLUMESLIDER"
-#define HID_AVMEDIA_PLAYERWINDOW   
"AVMEDIA_HID_AVMEDIA_PLAYERWINDOW"
+inline constexpr OStringLiteral HID_AVMEDIA_TOOLBOXITEM_PLAY   
= "AVMEDIA_HID_AVMEDIA_TOOLBOXITEM_PLAY";
+inline constexpr OStringLiteral HID_AVMEDIA_TOOLBOXITEM_PAUSE  
= "AVMEDIA_HID_AVMEDIA_TOOLBOXITEM_PAUSE";
+inline constexpr OStringLiteral HID_AVMEDIA_TOOLBOXITEM_STOP   
= "AVMEDIA_HID_AVMEDIA_TOOLBOXITEM_STOP";
+inline constexpr OStringLiteral HID_AVMEDIA_TOOLBOXITEM_MUTE   
= "AVMEDIA_HID_AVMEDIA_TOOLBOXITEM_MUTE";
+inline constexpr OStringLiteral HID_AVMEDIA_TOOLBOXITEM_LOOP   
= "AVMEDIA_HID_AVMEDIA_TOOLBOXITEM_LOOP";
+inline constexpr OStringLiteral HID_AVMEDIA_TOOLBOXITEM_OPEN   
= "AVMEDIA_HID_AVMEDIA_TOOLBOXITEM_OPEN";
+inline constexpr OStringLiteral HID_AVMEDIA_TOOLBOXITEM_INSERT 
= "AVMEDIA_HID_AVMEDIA_TOOLBOXITEM_INSERT";
+inline constexpr OStringLiteral HID_AVMEDIA_ZOOMLISTBOX
= "AVMEDIA_HID_AVMEDIA_ZOOMLISTBOX";
+inline constexpr OStringLiteral HID_AVMEDIA_TIMEEDIT   
= "AVMEDIA_HID_AVMEDIA_TIMEEDIT";
+inline constexpr OStringLiteral HID_AVMEDIA_VOLUMESLIDER   
= "AVMEDIA_HID_AVMEDIA_VOLUMESLIDER";
+inline constexpr OStringLiteral HID_AVMEDIA_PLAYERWINDOW   
= "AVMEDIA_HID_AVMEDIA_PLAYERWINDOW";
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/avmedia/source/gstreamer/gstplayer.cxx 
b/avmedia/source/gstreamer/gstplayer.cxx
index 4f12f80f5ded..f25ec5c6bb0c 100644
--- a/avmedia/source/gstreamer/gstplayer.cxx
+++ b/avmedia/source/gstreamer/gstplayer.cxx
@@ -47,7 +47,6 @@
 
 constexpr OUStringLiteral AVMEDIA_GST_PLAYER_IMPLEMENTATIONNAME = 
u"com.sun.star.comp.avmedia.Player_GStreamer";
 constexpr OUStringLiteral AVMEDIA_GST_PLAYER_SERVICENAME= 
u"com.sun.star.media.Player_GStreamer";
-
 #define AVVERSION "gst 1.0: "
 
 using namespace ::com::sun::star;
diff --git a/avmedia/source/inc/mediamisc.hxx b/avmedia/source/inc/mediamisc.hxx
index 542dbe5f1f74..b0f9964d18f9 100644
--- a/avmedia/source/inc/mediamisc.hxx
+++ b/avmedia/source/inc/mediamisc.hxx
@@ -33,7 +33,7 @@
 #endif
 
 // Mime types
-#define AVMEDIA_MIMETYPE_COMMON "application/vnd.sun.star.media"
+inline constexpr OUStringLiteral AVMEDIA_MIMETYPE_COMMON = 
u"application/vnd.sun.star.media";
 
 inline OUString AvmResId

[Libreoffice-commits] core.git: helpcontent2

2021-11-17 Thread Olivier Hallot (via logerrit)
 helpcontent2 |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 8405b8cde173d60c62faae728ec572c383f3af5b
Author: Olivier Hallot 
AuthorDate: Wed Nov 17 07:48:49 2021 -0300
Commit: Gerrit Code Review 
CommitDate: Wed Nov 17 11:48:49 2021 +0100

Update git submodules

* Update helpcontent2 from branch 'master'
  to 890b11c7e389bff4b177beaf79461a6d6cc8ba1c
  - Add Development Tools icon to Help page

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

diff --git a/helpcontent2 b/helpcontent2
index eb45e7df8aee..890b11c7e389 16
--- a/helpcontent2
+++ b/helpcontent2
@@ -1 +1 @@
-Subproject commit eb45e7df8aeeab7791876038c16345d5321e49b1
+Subproject commit 890b11c7e389bff4b177beaf79461a6d6cc8ba1c


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

2021-11-17 Thread Olivier Hallot (via logerrit)
 source/text/shared/guide/dev_tools.xhp |   14 +-
 1 file changed, 13 insertions(+), 1 deletion(-)

New commits:
commit 890b11c7e389bff4b177beaf79461a6d6cc8ba1c
Author: Olivier Hallot 
AuthorDate: Tue Nov 16 17:51:46 2021 -0300
Commit: Olivier Hallot 
CommitDate: Wed Nov 17 11:48:48 2021 +0100

Add Development Tools icon to Help page

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

diff --git a/source/text/shared/guide/dev_tools.xhp 
b/source/text/shared/guide/dev_tools.xhp
index 7a75841ee..680c34961 100644
--- a/source/text/shared/guide/dev_tools.xhp
+++ b/source/text/shared/guide/dev_tools.xhp
@@ -35,6 +35,18 @@
   Inspects objects in 
%PRODUCTNAME documents and shows supported UNO services, as well as available 
methods, properties and implemented interfaces. This feature also allows to 
explore the document structure using the Document Object Model 
(DOM).
   
 Choose 
Tools - Development Tools
+
+
+
+
+Icon Development Tools
+
+
+
+Development Tools
+
+
+
   
   The Development Tools are 
visible in all documents of %PRODUCTNAME Writer, Calc, Impress and Draw. The 
display is persistent and remain visible until deselected.
   When Development 
Tools is enabled, a dockable window is shown at the bottom of the 
screen. This window has two sections:
@@ -144,7 +156,7 @@
   Implementation class: Displays the name of the 
class where the method is implemented.
 
   
-  
+
   
 
   


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

2021-11-17 Thread Mike Kaganski (via logerrit)
 include/rtl/math.hxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit a664d4d44ce66db8d60d8c0ebf8bb793ecf2c462
Author: Mike Kaganski 
AuthorDate: Wed Nov 17 10:35:57 2021 +0200
Commit: Mike Kaganski 
CommitDate: Wed Nov 17 11:35:07 2021 +0100

Fix the calculated constant

rtl::math::isValidArcArg's comment talks about 2^64 = 1.844e19; but
the calculation resulted in 2^63.

Unfortunately we can't use C++17 hex-exponent notation in published
API header.

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

diff --git a/include/rtl/math.hxx b/include/rtl/math.hxx
index d67d4aa75a4a..7da30df6832b 100644
--- a/include/rtl/math.hxx
+++ b/include/rtl/math.hxx
@@ -431,7 +431,7 @@ inline bool isValidArcArg(double d)
 return fabs(d)
 <= (static_cast< double >(static_cast< unsigned long >(0x8000))
 * static_cast< double >(static_cast< unsigned long >(0x8000))
-* 2);
+* 4);
 }
 
 /** Safe sin(), returns NAN if not valid.


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

2021-11-17 Thread Heiko Tietze (via logerrit)
 sc/source/ui/view/cellsh3.cxx |   12 
 1 file changed, 8 insertions(+), 4 deletions(-)

New commits:
commit c6fb8ffc6a35d94002a2c5b5b36c228c161cde85
Author: Heiko Tietze 
AuthorDate: Tue Oct 19 10:40:41 2021 +0200
Commit: Xisco Fauli 
CommitDate: Wed Nov 17 11:34:23 2021 +0100

Resolves tdf#144247 - Change display precision of row height / column width

Use 2 digits by default but 4 in case of user-defined values
for row height and column width.

This partially reverts ad8edac43e73555bc2055514300c5b81a1bb04ea
as the optimal width is back to 2 digits

Change-Id: I4cb53071783c76d9fbea0cc2feaa0b860c73c647
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123802
Tested-by: Jenkins
Reviewed-by: Heiko Tietze 
(cherry picked from commit e396017b598e6ef161e71f18638b4d94cd92e6ee)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125349
Reviewed-by: Xisco Fauli 

diff --git a/sc/source/ui/view/cellsh3.cxx b/sc/source/ui/view/cellsh3.cxx
index b98440d9e552..0bf79d6d108b 100644
--- a/sc/source/ui/view/cellsh3.cxx
+++ b/sc/source/ui/view/cellsh3.cxx
@@ -699,7 +699,9 @@ void ScCellShell::Execute( SfxRequest& rReq )
 ScopedVclPtr 
pDlg(pFact->CreateScMetricInputDlg(
 pTabViewShell->GetFrameWeld(), "RowHeightDialog",
 nCurHeight, ScGlobal::nStdRowHeight,
-eMetric, 4, MAX_ROW_HEIGHT));
+eMetric,
+nCurHeight == ScGlobal::nStdRowHeight ? 2 : 4, //use 4 
digits for user-defined values
+MAX_ROW_HEIGHT));
 
 if ( pDlg->Execute() == RET_OK )
 {
@@ -736,7 +738,7 @@ void ScCellShell::Execute( SfxRequest& rReq )
 ScAbstractDialogFactory* pFact = 
ScAbstractDialogFactory::Create();
 ScopedVclPtr 
pDlg(pFact->CreateScMetricInputDlg(
 pTabViewShell->GetFrameWeld(), 
"OptimalRowHeightDialog",
-ScGlobal::nLastRowHeightExtra, 0, eMetric, 4, 
MAX_EXTRA_HEIGHT));
+ScGlobal::nLastRowHeightExtra, 0, eMetric, 2, 
MAX_EXTRA_HEIGHT));
 if ( pDlg->Execute() == RET_OK )
 {
 tools::Long nVal = pDlg->GetInputValue();
@@ -797,7 +799,9 @@ void ScCellShell::Execute( SfxRequest& rReq )
 ScAbstractDialogFactory* pFact = 
ScAbstractDialogFactory::Create();
 ScopedVclPtr 
pDlg(pFact->CreateScMetricInputDlg(
 pTabViewShell->GetFrameWeld(), "ColWidthDialog", 
nCurHeight,
-STD_COL_WIDTH, eMetric, 4, MAX_COL_WIDTH));
+STD_COL_WIDTH, eMetric,
+nCurHeight == STD_COL_WIDTH ? 2 : 4, //use 4 digits 
for user-defined values
+MAX_COL_WIDTH));
 if ( pDlg->Execute() == RET_OK )
 {
 tools::Long nVal = pDlg->GetInputValue();
@@ -833,7 +837,7 @@ void ScCellShell::Execute( SfxRequest& rReq )
 ScAbstractDialogFactory* pFact = 
ScAbstractDialogFactory::Create();
 ScopedVclPtr 
pDlg(pFact->CreateScMetricInputDlg(
 pTabViewShell->GetFrameWeld(), "OptimalColWidthDialog",
-ScGlobal::nLastColWidthExtra, STD_EXTRA_WIDTH, 
eMetric, 4, MAX_EXTRA_WIDTH));
+ScGlobal::nLastColWidthExtra, STD_EXTRA_WIDTH, 
eMetric, 2, MAX_EXTRA_WIDTH));
 if ( pDlg->Execute() == RET_OK )
 {
 tools::Long nVal = pDlg->GetInputValue();


[Libreoffice-commits] core.git: Branch 'feature/wasm' - static/CustomTarget_wasm_fs_image.mk

2021-11-17 Thread Armin Le Grand (Allotropia) (via logerrit)
 static/CustomTarget_wasm_fs_image.mk |   54 +++
 1 file changed, 54 insertions(+)

New commits:
commit b14687b8fcaf44bde868cdbc80fb52431cbfab4d
Author: Armin Le Grand (Allotropia) 
AuthorDate: Wed Nov 17 10:12:48 2021 +0100
Commit: Armin Le Grand (Allotropia) 
CommitDate: Wed Nov 17 10:12:48 2021 +0100

WASM: Make Chart editing work by adding needed config entries

Change-Id: Id949462ec0ae574986b7064aa8d1c87243b5a8cc

diff --git a/static/CustomTarget_wasm_fs_image.mk 
b/static/CustomTarget_wasm_fs_image.mk
index 82162bbff115..be7f1922f921 100644
--- a/static/CustomTarget_wasm_fs_image.mk
+++ b/static/CustomTarget_wasm_fs_image.mk
@@ -271,6 +271,60 @@ gb_wasm_image_filelist := \
 $(INSTROOT)/share/config/soffice.cfg/filter/ui/warnpdfdialog.ui \
 $(INSTROOT)/share/config/soffice.cfg/filter/ui/pdfoptionsdialog.ui \
 $(INSTROOT)/share/config/soffice.cfg/filter/ui/pdfsignpage.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/menubar/menubar.xml \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/popupmenu/drawtext.xml 
\
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/popupmenu/draw.xml \
+
$(INSTROOT)/share/config/soffice.cfg/modules/schart/statusbar/statusbar.xml \
+
$(INSTROOT)/share/config/soffice.cfg/modules/schart/toolbar/arrowshapes.xml \
+
$(INSTROOT)/share/config/soffice.cfg/modules/schart/toolbar/basicshapes.xml \
+
$(INSTROOT)/share/config/soffice.cfg/modules/schart/toolbar/calloutshapes.xml \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/toolbar/drawbar.xml \
+
$(INSTROOT)/share/config/soffice.cfg/modules/schart/toolbar/flowchartshapes.xml 
\
+
$(INSTROOT)/share/config/soffice.cfg/modules/schart/toolbar/standardbar.xml \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/toolbar/starshapes.xml 
\
+
$(INSTROOT)/share/config/soffice.cfg/modules/schart/toolbar/symbolshapes.xml \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/toolbar/toolbar.xml \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/3dviewdialog.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/combobox.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/insertaxisdlg.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/sidebarerrorbar.ui \
+
$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/tp_3D_SceneAppearance.ui 
\
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/tp_DataLabel.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/tp_RangeChooser.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/attributedialog.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/datarangedialog.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/insertgriddlg.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/sidebarseries.ui \
+
$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/tp_3D_SceneGeometry.ui \
+
$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/tp_DataPointOption.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/tp_Scale.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/chardialog.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/dlg_DataLabel.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/inserttitledlg.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/sidebartype.ui \
+
$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/tp_3D_SceneIllumination.ui
 \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/tp_DataSource.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/tp_SeriesToAxis.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/chartdatadialog.ui \
+
$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/dlg_InsertErrorBars.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/paradialog.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/smoothlinesdlg.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/tp_axisLabel.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/tp_ErrorBars.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/tp_Trendline.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/charttypedialog.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/dlg_InsertLegend.ui 
\
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/sidebaraxis.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/steppedlinesdlg.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/tp_AxisPositions.ui 
\
+
$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/tp_LegendPosition.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/wizelementspage.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/columnfragment.ui \
+$(INSTROOT)/share/config/soffice.cfg/modules/schart/ui/imagefragment

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

2021-11-17 Thread Luboš Luňák (via logerrit)
 vcl/qa/cppunit/skia/skia.cxx |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 22b930fefa68db0c581068045c68cad71879b901
Author: Luboš Luňák 
AuthorDate: Wed Nov 17 09:55:35 2021 +0100
Commit: Luboš Luňák 
CommitDate: Wed Nov 17 11:00:49 2021 +0100

fix SkiaTest::testDrawDelayedScaleImage() with GPU+HiDPI

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

diff --git a/vcl/qa/cppunit/skia/skia.cxx b/vcl/qa/cppunit/skia/skia.cxx
index f6920ccf1d8a..b94e2ede7eba 100644
--- a/vcl/qa/cppunit/skia/skia.cxx
+++ b/vcl/qa/cppunit/skia/skia.cxx
@@ -435,6 +435,8 @@ void SkiaTest::testDrawDelayedScaleImage()
 {
 if (!SkiaHelper::isVCLSkiaEnabled())
 return;
+if (SkiaHelper::renderMethodToUse() != SkiaHelper::RenderRaster)
+return; // This test tests caching that's done only in raster mode.
 ScopedVclPtr device = 
VclPtr::Create(DeviceFormat::DEFAULT);
 device->SetOutputSizePixel(Size(10, 10));
 device->SetBackground(Wallpaper(COL_WHITE));


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

2021-11-17 Thread Luboš Luňák (via logerrit)
 solenv/gbuild/PrecompiledHeaders.mk |6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

New commits:
commit 46520710560e53c6d488d71824694bf5e460ee07
Author: Luboš Luňák 
AuthorDate: Wed Nov 17 09:38:26 2021 +0100
Commit: Luboš Luňák 
CommitDate: Wed Nov 17 10:58:05 2021 +0100

avoid a PCH build failing because of a directory missing

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

diff --git a/solenv/gbuild/PrecompiledHeaders.mk 
b/solenv/gbuild/PrecompiledHeaders.mk
index be0ae7950c4d..312980265eca 100644
--- a/solenv/gbuild/PrecompiledHeaders.mk
+++ b/solenv/gbuild/PrecompiledHeaders.mk
@@ -55,8 +55,10 @@ $(call gb_PrecompiledHeader_get_dep_target,$(1),$(3)) :
 # change, and make the PCH depend on it => the PCH will be rebuilt on any 
flags change
 .PHONY: force
 $(call gb_PrecompiledHeader_get_flags_file,$(1),$(3)) : force
-   echo $(gb_PrecompiledHeader_flags_for_flags_file) | cmp -s - $$@ \
-   || echo $(gb_PrecompiledHeader_flags_for_flags_file) > $$@
+   $$(call gb_Helper_abbreviate_dirs,\
+   mkdir -p $$(dir $$@) && \
+   echo $(gb_PrecompiledHeader_flags_for_flags_file) | cmp -s - 
$$@ \
+   || echo $(gb_PrecompiledHeader_flags_for_flags_file) > $$@)
 
 # despite this being only one .d file, need to run concat-deps on it to
 # re-write external headers from UnpackedTarball


[Libreoffice-commits] core.git: framework/source offapi/com offapi/type_reference offapi/UnoApi_offapi.mk sfx2/source uui/inc uui/Library_uui.mk uui/source

2021-11-17 Thread Matt K (via logerrit)
 framework/source/interaction/quietinteraction.cxx|   15 -
 offapi/UnoApi_offapi.mk  |1 
 offapi/com/sun/star/document/ReadOnlyOpenRequest.idl |   51 ---
 offapi/type_reference/offapi.idl |3 -
 sfx2/source/doc/docfile.cxx  |   43 
 uui/Library_uui.mk   |1 
 uui/inc/strings.hrc  |5 -
 uui/source/iahndl-locking.cxx|   49 --
 uui/source/iahndl.cxx|3 -
 uui/source/iahndl.hxx|3 -
 uui/source/readonlyopen.cxx  |   38 --
 uui/source/readonlyopen.hxx  |   35 -
 12 files changed, 1 insertion(+), 246 deletions(-)

New commits:
commit f9ab31366dbe466ef739015734bb5b6a1a0deca4
Author: Matt K 
AuthorDate: Sun Nov 14 15:33:43 2021 -0600
Commit: Mike Kaganski 
CommitDate: Wed Nov 17 10:51:00 2021 +0100

tdf#143971 Removes pop-up dialog for read-only documents

No longer does the user get a pop-up dialog when opening
documents that are read-only, asking whether they want to be
notified when the document becomes editable.  The change
removes some of the functionality introduced in commit
95eb088802562b75f8b299908160145c7e88d763 "tdf#47065 Add new
file open UI options and implement a new thread".

Change-Id: Ic25e8e293e7224fb5086249a9d4814914fa961d1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125340
Tested-by: Mike Kaganski 
Reviewed-by: Mike Kaganski 

diff --git a/framework/source/interaction/quietinteraction.cxx 
b/framework/source/interaction/quietinteraction.cxx
index feeecf7c6568..e9dc218576e0 100644
--- a/framework/source/interaction/quietinteraction.cxx
+++ b/framework/source/interaction/quietinteraction.cxx
@@ -24,7 +24,6 @@
 #include 
 #include 
 #include 
-#include 
 #include 
 
 #include 
@@ -77,7 +76,6 @@ void SAL_CALL QuietInteraction::handle( const 
css::uno::Reference< css::task::XI
 css::task::ErrorCodeRequest  aErrorCodeRequest;
 css::document::LockedDocumentRequest aLockedDocumentRequest;
 css::document::FilterOptionsRequest  aFilterOptionsRequest;
-css::document::ReadOnlyOpenRequest   aReadOnlyOpenRequest;
 
 if( aRequest >>= aErrorCodeRequest )
 {
@@ -110,19 +108,6 @@ void SAL_CALL QuietInteraction::handle( const 
css::uno::Reference< css::task::XI
 }
 }
 else
-if (aRequest >>= aReadOnlyOpenRequest)
-{
-// allow unit tests to run on read-only SRCDIR
-if (xApprove.is())
-{
-xApprove->select();
-}
-else if (xAbort.is())
-{
-xAbort->select();
-}
-}
-else
 if (xAbort.is())
 xAbort->select();
 }
diff --git a/offapi/UnoApi_offapi.mk b/offapi/UnoApi_offapi.mk
index 6f1dc604a8e3..3eb002520e42 100644
--- a/offapi/UnoApi_offapi.mk
+++ b/offapi/UnoApi_offapi.mk
@@ -2214,7 +2214,6 @@ $(eval $(call 
gb_UnoApi_add_idlfiles,offapi,com/sun/star/document,\
NoSuchFilterRequest \
OwnLockOnDocumentRequest \
PrinterIndependentLayout \
-   ReadOnlyOpenRequest \
RedlineDisplayType \
ReloadEditableRequest \
UndoContextNotClosedException \
diff --git a/offapi/com/sun/star/document/ReadOnlyOpenRequest.idl 
b/offapi/com/sun/star/document/ReadOnlyOpenRequest.idl
deleted file mode 100644
index 49a82b7016f9..
--- a/offapi/com/sun/star/document/ReadOnlyOpenRequest.idl
+++ /dev/null
@@ -1,51 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; 
fill-column: 100 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-#ifndef __com_sun_star_document_ReadOnlyOpenRequest_idl__
-#define __com_sun_star_document_ReadOnlyOpenRequest_idl__
-
-#include 
-
-module com
-{
-module sun
-{
-module star
-{
-module document
-{
-/** Is used for interaction handle to query user decision 
regarding whether to open
-a doc

[Libreoffice-commits] core.git: Branch 'distro/collabora/co-2021' - include/oox oox/source

2021-11-17 Thread Stephan Bergmann (via logerrit)
 include/oox/drawingml/shape.hxx |2 ++
 include/oox/drawingml/theme.hxx |3 ---
 oox/source/drawingml/theme.cxx  |8 
 3 files changed, 2 insertions(+), 11 deletions(-)

New commits:
commit 8037a24dad50d98bd36ddc0f94d98d208ae3788d
Author: Stephan Bergmann 
AuthorDate: Mon Nov 15 12:22:11 2021 +0100
Commit: Miklos Vajna 
CommitDate: Wed Nov 17 10:44:57 2021 +0100

Avoid some -Werror,-Wdeprecated-copy-with-user-provided-dtor

...after e6968f0485cfb2f6c941d11c438386e14a47095d "PPTX import: fix 
handling of
theme overrides in the chart import" introduced a use of 
std::make_shared

Change-Id: I5f6384b81e02034b6b2fdf3a3bad0148de4eb584
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125228
Tested-by: Tor Lillqvist 
Reviewed-by: Tor Lillqvist 
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125279
Tested-by: Jenkins CollaboraOffice 
Reviewed-by: Miklos Vajna 

diff --git a/include/oox/drawingml/shape.hxx b/include/oox/drawingml/shape.hxx
index 1fbe533d3600..746d47a26378 100644
--- a/include/oox/drawingml/shape.hxx
+++ b/include/oox/drawingml/shape.hxx
@@ -106,7 +106,9 @@ public:
 
 explicit Shape( const char* pServiceType = nullptr, bool bDefaultHeight = 
true );
 explicit Shape( const ShapePtr& pSourceShape );
+Shape(Shape const &) = default;
 virtual ~Shape();
+Shape & operator =(Shape const &) = default;
 
 OUString&  getServiceName(){ return msServiceName; }
 voidsetServiceName( const char* pServiceName );
diff --git a/include/oox/drawingml/theme.hxx b/include/oox/drawingml/theme.hxx
index 6d64649f3a69..944e58b6e79c 100644
--- a/include/oox/drawingml/theme.hxx
+++ b/include/oox/drawingml/theme.hxx
@@ -56,9 +56,6 @@ class TextFont;
 class OOX_DLLPUBLIC Theme
 {
 public:
-Theme();
-~Theme();
-
 void setStyleName( const OUString& rStyleName ) { 
maStyleName = rStyleName; }
 
 ClrScheme&   getClrScheme() { return maClrScheme; }
diff --git a/oox/source/drawingml/theme.cxx b/oox/source/drawingml/theme.cxx
index ca26f389904e..036779d21711 100644
--- a/oox/source/drawingml/theme.cxx
+++ b/oox/source/drawingml/theme.cxx
@@ -23,14 +23,6 @@
 
 namespace oox::drawingml {
 
-Theme::Theme()
-{
-}
-
-Theme::~Theme()
-{
-}
-
 namespace {
 
 template< typename Type >


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

2021-11-17 Thread Michael Stahl (via logerrit)
 download.lst |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 5654baec57ffc98b3958b9db4d15874e89e92828
Author: Michael Stahl 
AuthorDate: Tue Nov 16 14:41:57 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 10:33:04 2021 +0100

postgresql: upgrade to release 13.5

Fixes CVE-2021-23222.

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125308
Tested-by: Jenkins
Reviewed-by: Michael Stahl 
(cherry picked from commit 71b9369f1cc40143108e3f2189d96e402895e315)

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

diff --git a/download.lst b/download.lst
index f5c35551682c..2632c4e06f8f 100644
--- a/download.lst
+++ b/download.lst
@@ -210,8 +210,8 @@ export LIBPNG_SHA256SUM := 
505e70834d35383537b6491e7ae8641f1a4bed1876dbfe361201f
 export LIBPNG_TARBALL := libpng-1.6.37.tar.xz
 export POPPLER_SHA256SUM := 
31b76b5cac0a48612fdd154c02d9eca01fd38fb8eaa77c1196840ecdeb53a584
 export POPPLER_TARBALL := poppler-21.11.0.tar.xz
-export POSTGRESQL_SHA256SUM := 
12345c83b89aa29808568977f5200d6da00f88a035517f925293355432ffe61f
-export POSTGRESQL_TARBALL := postgresql-13.1.tar.bz2
+export POSTGRESQL_SHA256SUM := 
9b81067a55edbaabc418aacef457dd8477642827499560b00615a6ea6c13f6b3
+export POSTGRESQL_TARBALL := postgresql-13.5.tar.bz2
 export PYTHON_SHA256SUM := 
f8d82e7572c86ec9d55c8627aae5040124fd2203af400c383c821b980306ee6b
 export PYTHON_TARBALL := Python-3.7.10.tar.xz
 export QRCODEGEN_SHA256SUM := 
fcdf9fd69fde07ae4dca2351d84271a9de8093002f733b77c70f52f1630f6e4a


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

2021-11-17 Thread Michael Stahl (via logerrit)
 svtools/source/svhtml/parhtml.cxx |6 +-
 1 file changed, 5 insertions(+), 1 deletion(-)

New commits:
commit 06588308fb3f3760fd9dce2a0ad0c8859c0b41a3
Author: Michael Stahl 
AuthorDate: Tue Nov 16 14:28:15 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 10:32:31 2021 +0100

ofz#40766 svtools, sw: HTMLParser: really stop inserting control chars

35d248cab1f0d4800f72abb5cb6afb56f40d9083 forgot to fix one place where
control characters were in a presumed XML declaration.

Another place looks missing where comments are handled, but it's not
clear if these can be passed on to Writer.

Revert the previous fix from commit
b3325ef8cdfc2c82eec34e747106f75a9fccb7e4.

Change-Id: I11ad13de9122533626e512ce0384051e3e5bd97f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125306
Tested-by: Jenkins
Reviewed-by: Michael Stahl 
(cherry picked from commit a7116b890ccd6dd1721413b4de6591a8057668ef)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125333
Tested-by: Michael Stahl 

diff --git a/svtools/source/svhtml/parhtml.cxx 
b/svtools/source/svhtml/parhtml.cxx
index 67f5a87862ad..563ef0f76755 100644
--- a/svtools/source/svhtml/parhtml.cxx
+++ b/svtools/source/svhtml/parhtml.cxx
@@ -1058,6 +1058,7 @@ HtmlTokenId HTMLParser::GetNextToken_()
 sTmpBuffer.appendUtf32( nNextCh );
 nNextCh = GetNextChar();
 } while( '>' != nNextCh && '/' != nNextCh && 
!rtl::isAsciiWhiteSpace( nNextCh ) &&
+!linguistic::IsControlChar(nNextCh) &&
  IsParserWorking() && !rInput.eof() );
 
 if( !sTmpBuffer.isEmpty() )
@@ -1135,8 +1136,11 @@ HtmlTokenId HTMLParser::GetNextToken_()
 if( !bDone )
 sTmpBuffer.appendUtf32(nNextCh);
 }
-else
+else if (!linguistic::IsControlChar(nNextCh)
+|| nNextCh == '\r' || nNextCh == '\n' || 
nNextCh == '\t')
+{
 sTmpBuffer.appendUtf32(nNextCh);
+}
 if( !bDone )
 nNextCh = GetNextChar();
 }


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sw/qa/core/data/html/pass/ofz40593-1.html |binary
 sw/source/filter/html/htmltab.cxx |   36 +++---
 2 files changed, 33 insertions(+), 3 deletions(-)

New commits:
commit 08abcae56b13b11d699a30553f7edfc54225d687
Author: Caolán McNamara 
AuthorDate: Mon Nov 1 17:34:23 2021 +
Commit: Michael Stahl 
CommitDate: Wed Nov 17 10:31:44 2021 +0100

ofz#40593 remove Objects from m_xResizeDrawObjects if deleted during parse

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124563
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit 2f01faaf88b6d172d7293f0c9e2a061d99b8ceb5)

fix misplaced line

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124630
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit 4ed359093c991291216c39cffe14a60e607ec551)

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

diff --git a/sw/qa/core/data/html/pass/ofz40593-1.html 
b/sw/qa/core/data/html/pass/ofz40593-1.html
new file mode 100644
index ..43510d5d00b2
Binary files /dev/null and b/sw/qa/core/data/html/pass/ofz40593-1.html differ
diff --git a/sw/source/filter/html/htmltab.cxx 
b/sw/source/filter/html/htmltab.cxx
index ce689df01b9d..f90b77522319 100644
--- a/sw/source/filter/html/htmltab.cxx
+++ b/sw/source/filter/html/htmltab.cxx
@@ -34,6 +34,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 
 #include 
@@ -372,7 +373,7 @@ typedef std::vector HTMLTableColumns;
 
 typedef std::vector SdrObjects;
 
-class HTMLTable
+class HTMLTable : public sdr::ObjectUser
 {
 OUString m_aId;
 OUString m_aStyle;
@@ -520,6 +521,8 @@ private:
 sal_uInt16 GetBorderWidth( const SvxBorderLine& rBLine,
bool bWithDistance=false ) const;
 
+virtual void ObjectInDestruction(const SdrObject& rObject) override;
+
 public:
 
 bool m_bFirstCell;// is there a cell created already?
@@ -529,7 +532,7 @@ public:
   bool bHasToFly,
   const HTMLTableOptions& rOptions);
 
-~HTMLTable();
+virtual ~HTMLTable();
 
 // Identifying of a cell
 const HTMLTableCell& GetCell(sal_uInt16 nRow, sal_uInt16 nCell) const;
@@ -1065,11 +1068,37 @@ bool SwHTMLParser::IsReqIF() const
 return m_bReqIF;
 }
 
+// if any m_pResizeDrawObjects members are deleted during parse, remove them
+// from m_pResizeDrawObjects and m_xDrawObjectPercentWidths
+void HTMLTable::ObjectInDestruction(const SdrObject& rObject)
+{
+auto it = std::find(m_pResizeDrawObjects->begin(), 
m_pResizeDrawObjects->end(), &rObject);
+assert(it != m_pResizeDrawObjects->end());
+#if 0
+auto nIndex = std::distance(m_pResizeDrawObjects->begin(), it);
+#endif
+m_pResizeDrawObjects->erase(it);
+#if 0
+auto otherit = m_xDrawObjectPercentWidths->begin() + nIndex * 3;
+m_xDrawObjectPercentWidths->erase(otherit, otherit + 3);
+#endif
+}
+
 HTMLTable::~HTMLTable()
 {
 m_pParser->DeregisterHTMLTable(this);
 
-m_pResizeDrawObjects.reset();
+if (m_pResizeDrawObjects)
+{
+size_t nCount = m_pResizeDrawObjects->size();
+for (size_t i = 0; i < nCount; ++i)
+{
+SdrObject *pObj = (*m_pResizeDrawObjects)[i];
+pObj->RemoveObjectUser(*this);
+}
+m_pResizeDrawObjects.reset();
+}
+
 m_pDrawObjectPrcWidths.reset();
 
 m_pContext.reset();
@@ -2483,6 +2512,7 @@ void HTMLTable::RegisterDrawObject( SdrObject *pObj, 
sal_uInt8 nPrcWidth )
 if( !m_pResizeDrawObjects )
 m_pResizeDrawObjects.reset(new SdrObjects);
 m_pResizeDrawObjects->push_back( pObj );
+pObj->AddObjectUser(*this);
 
 if( !m_pDrawObjectPrcWidths )
 m_pDrawObjectPrcWidths.reset(new std::vector);


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 connectivity/source/drivers/dbase/DTable.cxx |   13 -
 1 file changed, 8 insertions(+), 5 deletions(-)

New commits:
commit b284fa693da7f4dc9120d5b398917622847a904d
Author: Caolán McNamara 
AuthorDate: Sun Sep 26 14:05:37 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 10:30:38 2021 +0100

ofz#39304 short timestamp record

Change-Id: I8f783473dd5d4679846c7c866cd1853ef7d919fc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122628
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit bfc70a9f314bbb5b03247be25544e9b4cc467f8d)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125331
Tested-by: Michael Stahl 
Reviewed-by: Michael Stahl 

diff --git a/connectivity/source/drivers/dbase/DTable.cxx 
b/connectivity/source/drivers/dbase/DTable.cxx
index ffd4eb2ab30f..6bd9ce2bbaf1 100644
--- a/connectivity/source/drivers/dbase/DTable.cxx
+++ b/connectivity/source/drivers/dbase/DTable.cxx
@@ -773,10 +773,8 @@ bool ODbaseTable::fetchRow(OValueRefRow& _rRow, const 
OSQLColumns & _rCols, bool
 for (std::size_t i = 1; aIter != aEnd && nByteOffset <= m_nBufferSize && i 
< nCount;++aIter, i++)
 {
 // Lengths depending on data type:
-sal_Int32 nLen = 0;
-sal_Int32 nType = 0;
-nLen= m_aPrecisions[i-1];
-nType   = m_aTypes[i-1];
+sal_Int32 nLen = m_aPrecisions[i-1];
+sal_Int32 nType = m_aTypes[i-1];
 
 switch(nType)
 {
@@ -835,8 +833,13 @@ bool ODbaseTable::fetchRow(OValueRefRow& _rRow, const 
OSQLColumns & _rCols, bool
 else if ( DataType::TIMESTAMP == nType )
 {
 sal_Int32 nDate = 0,nTime = 0;
+if (nLen < 8)
+{
+SAL_WARN("connectivity.drivers", "short TIMESTAMP");
+return false;
+}
 memcpy(&nDate, pData, 4);
-memcpy(&nTime, pData+ 4, 4);
+memcpy(&nTime, pData + 4, 4);
 if ( !nDate && !nTime )
 {
 (_rRow->get())[i]->setNull();


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 connectivity/source/commontools/dbconversion.cxx |9 ++---
 1 file changed, 6 insertions(+), 3 deletions(-)

New commits:
commit f5e5592410049ad505c123100e0350579246e391
Author: Caolán McNamara 
AuthorDate: Sun Sep 26 14:23:54 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 10:30:10 2021 +0100

ofz#39301 month has to be in range [1-12]

Change-Id: I5a4ca534b24098342d8f465a32bc1887f40f5b63
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122629
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit 4a93b7a2f8a3fc13fed800d93e2103b785abeb62)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125330
Tested-by: Michael Stahl 
Reviewed-by: Michael Stahl 

diff --git a/connectivity/source/commontools/dbconversion.cxx 
b/connectivity/source/commontools/dbconversion.cxx
index 77e7c871123c..6cd27e46a5ff 100644
--- a/connectivity/source/commontools/dbconversion.cxx
+++ b/connectivity/source/commontools/dbconversion.cxx
@@ -27,6 +27,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -167,10 +168,13 @@ namespace dbtools
 ;
 }
 
-
 static sal_Int32 implDaysInMonth(sal_Int32 _nMonth, sal_Int32 _nYear)
 {
-OSL_ENSURE(_nMonth > 0 && _nMonth < 13,"Month as invalid value!");
+SAL_WARN_IF(_nMonth < 1 || _nMonth > 12, "connectivity.commontools", 
"Month has invalid value: " << _nMonth);
+if (_nMonth < 1)
+_nMonth = 1;
+else if (_nMonth > 12)
+_nMonth = 12;
 if (_nMonth != 2)
 return aDaysInMonth[_nMonth-1];
 else
@@ -182,7 +186,6 @@ namespace dbtools
 }
 }
 
-
 static sal_Int32 implRelativeToAbsoluteNull(const css::util::Date& _rDate)
 {
 sal_Int32 nDays = 0;


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sw/source/filter/ww8/ww8par.cxx |4 ++--
 sw/source/filter/ww8/ww8par.hxx |4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

New commits:
commit 581bb5fedca6644ceac22d4947833dff5396265e
Author: Caolán McNamara 
AuthorDate: Sat Sep 25 19:57:36 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 10:29:21 2021 +0100

ofz#39252 use safer SwUnoCursor for the pos to move back to

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122611
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit ca844cbdc3e933e3082e9cde0632445916de819e)

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

diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index 1a99e0805e98..41beb52670ff 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -1992,7 +1992,7 @@ void SwWW8ImplReader::ImportDopTypography(const 
WW8DopTypography &rTypo)
  * Footnotes and Endnotes
  */
 WW8ReaderSave::WW8ReaderSave(SwWW8ImplReader* pRdr ,WW8_CP nStartCp) :
-maTmpPos(*pRdr->m_pPaM->GetPoint()),
+mxTmpPos(pRdr->m_rDoc.CreateUnoCursor(*pRdr->m_pPaM->GetPoint())),
 mxOldStck(std::move(pRdr->m_xCtrlStck)),
 mxOldAnchorStck(std::move(pRdr->m_xAnchorStck)),
 mxOldRedlines(std::move(pRdr->m_xRedlineStack)),
@@ -2090,7 +2090,7 @@ void WW8ReaderSave::Restore( SwWW8ImplReader* pRdr )
 pRdr->DeleteAnchorStack();
 pRdr->m_xAnchorStck = std::move(mxOldAnchorStck);
 
-*pRdr->m_pPaM->GetPoint() = maTmpPos;
+*pRdr->m_pPaM->GetPoint() = GetStartPos();
 
 if (mxOldPlcxMan != pRdr->m_xPlcxMan)
 pRdr->m_xPlcxMan = mxOldPlcxMan;
diff --git a/sw/source/filter/ww8/ww8par.hxx b/sw/source/filter/ww8/ww8par.hxx
index 9f19f48d463b..f98853d82295 100644
--- a/sw/source/filter/ww8/ww8par.hxx
+++ b/sw/source/filter/ww8/ww8par.hxx
@@ -589,7 +589,7 @@ class WW8ReaderSave
 {
 private:
 WW8PLCFxSaveAll maPLCFxSave;
-SwPosition const maTmpPos;
+std::shared_ptr mxTmpPos;
 std::deque maOldApos;
 std::deque maOldFieldStack;
 std::unique_ptr mxOldStck;
@@ -617,7 +617,7 @@ private:
 public:
 WW8ReaderSave(SwWW8ImplReader* pRdr, WW8_CP nStart=-1);
 void Restore(SwWW8ImplReader* pRdr);
-const SwPosition &GetStartPos() const { return maTmpPos; }
+const SwPosition &GetStartPos() const { return *mxTmpPos->GetPoint(); }
 };
 
 enum class eF_ResT { OK, TEXT, TAGIGN, READ_FSPA };


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sw/qa/core/data/ww8/pass/ofz38011-1.doc |binary
 sw/source/filter/ww8/ww8par2.cxx|9 +
 2 files changed, 9 insertions(+)

New commits:
commit 9c20d9ac002f28f339d0879adf69623f2eb9e396
Author: Caolán McNamara 
AuthorDate: Thu Sep 2 13:35:34 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 10:28:49 2021 +0100

ofz#38011 save and restore m_pLastAnchorPos via UnoCursor

when we do some operations that may delete paragraphs

Change-Id: I2165dd287771f06c6d0fd061dd7659b06db4bd72
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121511
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit bc7baa18435000f47f90e47d3300710bcb4cf56b)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125328
Tested-by: Michael Stahl 
Reviewed-by: Michael Stahl 

diff --git a/sw/qa/core/data/ww8/pass/ofz38011-1.doc 
b/sw/qa/core/data/ww8/pass/ofz38011-1.doc
new file mode 100644
index ..8ef58ca5395d
Binary files /dev/null and b/sw/qa/core/data/ww8/pass/ofz38011-1.doc differ
diff --git a/sw/source/filter/ww8/ww8par2.cxx b/sw/source/filter/ww8/ww8par2.cxx
index 6edc842e48ee..026b0ead213c 100644
--- a/sw/source/filter/ww8/ww8par2.cxx
+++ b/sw/source/filter/ww8/ww8par2.cxx
@@ -2749,8 +2749,17 @@ void WW8TabDesc::FinishSwTable()
 {
 m_pIo->m_xRedlineStack->closeall(*m_pIo->m_pPaM->GetPoint());
 m_pIo->m_aFrameRedlines.emplace(std::move(m_pIo->m_xRedlineStack));
+
+// ofz#38011 drop m_pLastAnchorPos during RedlineStack dtor and restore it 
afterwards to the same
+// place, or somewhere close if that place got destroyed
+std::shared_ptr xLastAnchorCursor(m_pIo->m_pLastAnchorPos ? 
m_pIo->m_rDoc.CreateUnoCursor(*m_pIo->m_pLastAnchorPos) : nullptr);
+m_pIo->m_pLastAnchorPos.reset();
+
 m_pIo->m_xRedlineStack = std::move(mxOldRedlineStack);
 
+if (xLastAnchorCursor)
+m_pIo->m_pLastAnchorPos.reset(new 
SwPosition(*xLastAnchorCursor->GetPoint()));
+
 WW8DupProperties aDup(m_pIo->m_rDoc,m_pIo->m_xCtrlStck.get());
 m_pIo->m_xCtrlStck->SetAttr( *m_pIo->m_pPaM->GetPoint(), 0, false);
 


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 include/vcl/BitmapTools.hxx |5 +
 1 file changed, 5 insertions(+)

New commits:
commit 96e1170b7c88942f500233f3ff220209ef1e80f3
Author: Caolán McNamara 
AuthorDate: Sun Aug 29 16:58:11 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 10:27:40 2021 +0100

ofz#37796 limit to numeric_limits::max

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121230
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit 72da4c623baf60eb2b7073697cd36ffb3022847d)

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

diff --git a/include/vcl/BitmapTools.hxx b/include/vcl/BitmapTools.hxx
index 3652bb849bf4..7c076a451a69 100644
--- a/include/vcl/BitmapTools.hxx
+++ b/include/vcl/BitmapTools.hxx
@@ -20,6 +20,7 @@
 #include 
 #include 
 #include 
+#include 
 
 class SvStream;
 namespace basegfx { class B2DHomMatrix; }
@@ -51,6 +52,10 @@ public:
   mnBitCount(nBitCount)
 {
 assert(nBitCount == 24 || nBitCount == 32);
+if (rSize.getWidth() > std::numeric_limits::max() || 
rSize.getWidth() < 0)
+throw std::bad_alloc();
+if (rSize.getHeight() > std::numeric_limits::max() || 
rSize.getHeight() < 0)
+throw std::bad_alloc();
 sal_Int32 nRowSize, nDataSize;
 if (o3tl::checked_multiply(rSize.getWidth(), nBitCount/8, 
nRowSize) ||
 o3tl::checked_multiply(nRowSize, rSize.getHeight(), 
nDataSize) ||


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sw/qa/core/data/ww5/pass/ooo37322-1-WW2.doc |binary
 sw/source/filter/ww8/ww8par.cxx |9 +
 2 files changed, 9 insertions(+)

New commits:
commit adca4ca24351bb6d02638d8dea48a38120d8bfa2
Author: Caolán McNamara 
AuthorDate: Wed Aug 18 16:57:18 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 10:26:58 2021 +0100

ofz#37322 Bad-cast

use a SwUnoCursor for the LastAnchorPos around here, this is similar to
ofz#9858 Bad-cast

Change-Id: I194a39ae13c382740b0ba8145dcc33fb2107105d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120679
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit c1cd505c67a53a0a27589889b34641612d10946d)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125326
Tested-by: Michael Stahl 
Reviewed-by: Michael Stahl 

diff --git a/sw/qa/core/data/ww5/pass/ooo37322-1-WW2.doc 
b/sw/qa/core/data/ww5/pass/ooo37322-1-WW2.doc
new file mode 100644
index ..fd64eeed2963
Binary files /dev/null and b/sw/qa/core/data/ww5/pass/ooo37322-1-WW2.doc differ
diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index f5bdacffe32d..1a99e0805e98 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -2076,8 +2076,17 @@ void WW8ReaderSave::Restore( SwWW8ImplReader* pRdr )
 
 pRdr->m_xRedlineStack->closeall(*pRdr->m_pPaM->GetPoint());
 pRdr->m_aFrameRedlines.emplace(std::move(pRdr->m_xRedlineStack));
+
+// ofz#37322 drop m_pLastAnchorPos during RedlineStack dtor and restore it 
afterwards to the same
+// place, or somewhere close if that place got destroyed
+std::shared_ptr xLastAnchorCursor(pRdr->m_pLastAnchorPos ? 
pRdr->m_rDoc.CreateUnoCursor(*pRdr->m_pLastAnchorPos) : nullptr);
+pRdr->m_pLastAnchorPos.reset();
+
 pRdr->m_xRedlineStack = std::move(mxOldRedlines);
 
+if (xLastAnchorCursor)
+pRdr->m_pLastAnchorPos.reset(new 
SwPosition(*xLastAnchorCursor->GetPoint()));
+
 pRdr->DeleteAnchorStack();
 pRdr->m_xAnchorStck = std::move(mxOldAnchorStck);
 


[Libreoffice-commits] core.git: Branch 'libreoffice-7-2' - download.lst

2021-11-17 Thread Michael Stahl (via logerrit)
 download.lst |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit c49613bde900d2c15dfea1fe24bdf74a3cc26ad2
Author: Michael Stahl 
AuthorDate: Tue Nov 16 14:41:57 2021 +0100
Commit: Xisco Fauli 
CommitDate: Wed Nov 17 10:27:09 2021 +0100

postgresql: upgrade to release 13.5

Fixes CVE-2021-23222.

Change-Id: I4e16fcc60c634382a864f66b211d0e0170a06db0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125308
Tested-by: Jenkins
Reviewed-by: Michael Stahl 
(cherry picked from commit 71b9369f1cc40143108e3f2189d96e402895e315)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125146
Reviewed-by: Xisco Fauli 

diff --git a/download.lst b/download.lst
index a10a6acb117f..043ced0b294c 100644
--- a/download.lst
+++ b/download.lst
@@ -218,8 +218,8 @@ export POPPLER_SHA256SUM := 
31b76b5cac0a48612fdd154c02d9eca01fd38fb8eaa77c119684
 export POPPLER_TARBALL := poppler-21.11.0.tar.xz
 export POPPLER_DATA_SHA256SUM := 
6e2fcef66ec8c44625f94292ccf8af9f1d918b410d5aa69c274ce67387967b30
 export POPPLER_DATA_TARBALL := poppler-data-0.4.10.tar.gz
-export POSTGRESQL_SHA256SUM := 
12345c83b89aa29808568977f5200d6da00f88a035517f925293355432ffe61f
-export POSTGRESQL_TARBALL := postgresql-13.1.tar.bz2
+export POSTGRESQL_SHA256SUM := 
9b81067a55edbaabc418aacef457dd8477642827499560b00615a6ea6c13f6b3
+export POSTGRESQL_TARBALL := postgresql-13.5.tar.bz2
 export PYTHON_SHA256SUM := 
6af24a66093dd840bcccf371d4044a3027e655cf24591ce26e48022bc79219d9
 export PYTHON_TARBALL := Python-3.8.10.tar.xz
 export QXP_SHA256SUM := 
e137b6b110120a52c98edd02ebdc4095ee08d0d5295a94316a981750095a945c


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sw/source/core/inc/layact.hxx|8 +-
 sw/source/core/layout/layact.cxx |   51 +++
 2 files changed, 58 insertions(+), 1 deletion(-)

New commits:
commit 2710e42b8ef6bd315af663de9295a391c7a236ab
Author: Caolán McNamara 
AuthorDate: Fri Jul 16 12:45:21 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 10:18:14 2021 +0100

crashtesting: UaF on layout of fdo53985-1.docx

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119060
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit ceb32f59d96a17c3007ed883fb44bc880673c8e0)

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

diff --git a/sw/source/core/inc/layact.hxx b/sw/source/core/inc/layact.hxx
index 4e9a01d34830..9ca134c535f1 100644
--- a/sw/source/core/inc/layact.hxx
+++ b/sw/source/core/inc/layact.hxx
@@ -62,6 +62,9 @@ class SwLayAction
 
 SwWait *m_pWait;
 
+std::vector m_aFrameStack;
+std::vector> m_aFrameDeleteGuards;
+
 // If a paragraph (or anything else) moved more than one page when
 // formatting, it adds its new page number here.
 // The InternalAction can then take the appropriate steps.
@@ -115,6 +118,9 @@ class SwLayAction
 
 bool RemoveEmptyBrowserPages();
 
+void PushFormatLayout(SwFrame* pLow);
+void PopFormatLayout();
+
 inline void CheckIdleEnd();
 
 public:
@@ -146,7 +152,7 @@ public:
 void SetReschedule  ( bool bNew )   { m_bReschedule = bNew; }
 void SetWaitAllowed ( bool bNew )   { m_bWaitAllowed = bNew; }
 
-void SetAgain(bool bAgain) { m_bAgain = bAgain; }
+void SetAgain(bool bAgain);
 void SetUpdateExpFields() {m_bUpdateExpFields = true; }
 
 inline void SetCheckPageNum( sal_uInt16 nNew );
diff --git a/sw/source/core/layout/layact.cxx b/sw/source/core/layout/layact.cxx
index b4924390af50..e26c4fd3bafe 100644
--- a/sw/source/core/layout/layact.cxx
+++ b/sw/source/core/layout/layact.cxx
@@ -313,6 +313,53 @@ bool SwLayAction::RemoveEmptyBrowserPages()
 return bRet;
 }
 
+void SwLayAction::SetAgain(bool bAgain)
+{
+if (bAgain == m_bAgain)
+return;
+
+m_bAgain = bAgain;
+
+assert(m_aFrameStack.size() == m_aFrameDeleteGuards.size());
+size_t nCount = m_aFrameStack.size();
+if (m_bAgain)
+{
+// LayAction::FormatLayout is now flagged to exit early and will avoid
+// dereferencing any SwFrames in the stack of FormatLayouts so allow
+// their deletion
+for (size_t i = 0; i < nCount; ++i)
+m_aFrameDeleteGuards[i].reset();
+}
+else
+{
+// LayAction::FormatLayout is now continue normally and will
+// dereference the top SwFrame in the stack of m_aFrameStack as each
+// FormatLevel returns so disallow their deletion
+for (size_t i = 0; i < nCount; ++i)
+m_aFrameDeleteGuards[i] = 
std::make_unique(m_aFrameStack[i]);
+}
+}
+
+void SwLayAction::PushFormatLayout(SwFrame* pLow)
+{
+/* Workaround crash seen in crashtesting with fdo53985-1.docx
+
+   Lock pLow against getting deleted when it will be dereferenced
+   after FormatLayout
+
+   If SetAgain is called to make SwLayAction exit early to avoid that
+   dereference, then it clears these guards
+*/
+m_aFrameStack.push_back(pLow);
+m_aFrameDeleteGuards.push_back(std::make_unique(pLow));
+}
+
+void SwLayAction::PopFormatLayout()
+{
+m_aFrameDeleteGuards.pop_back();
+m_aFrameStack.pop_back();
+}
+
 void SwLayAction::Action(OutputDevice* pRenderContext)
 {
 m_bActionInProgress = true;
@@ -1360,7 +1407,11 @@ bool SwLayAction::FormatLayout( OutputDevice 
*pRenderContext, SwLayoutFrame *pLa
 bTabChanged |= FormatLayoutTab( 
static_cast(pLow), bAddRect );
 // Skip the ones already registered for deletion
 else if( !pLow->IsSctFrame() || 
static_cast(pLow)->GetSection() )
+{
+PushFormatLayout(pLow);
 bChanged |= FormatLayout( pRenderContext, 
static_cast(pLow), bAddRect );
+PopFormatLayout();
+}
 }
 else if ( m_pImp->GetShell()->IsPaintLocked() )
 // Shortcut to minimize the cycles. With Lock, the


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sw/source/core/inc/layact.hxx   |2 +-
 sw/source/core/layout/layact.cxx|   14 +-
 sw/source/core/layout/objectformattertxtfrm.cxx |2 +-
 sw/source/core/layout/pagechg.cxx   |2 +-
 4 files changed, 12 insertions(+), 8 deletions(-)

New commits:
commit 8b9d73f2278d2a2457b9835665cc9d3230ca1d60
Author: Caolán McNamara 
AuthorDate: Thu Jul 15 14:13:35 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 10:17:52 2021 +0100

Only change SwLayAction::m_bAgain via SetAgain

no logic change intended

Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118983
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
(cherry picked from commit 3a5383892e1f0e22558cd56cb77d56a09c515b7a)

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

diff --git a/sw/source/core/inc/layact.hxx b/sw/source/core/inc/layact.hxx
index 9240ef9d2a98..4e9a01d34830 100644
--- a/sw/source/core/inc/layact.hxx
+++ b/sw/source/core/inc/layact.hxx
@@ -146,7 +146,7 @@ public:
 void SetReschedule  ( bool bNew )   { m_bReschedule = bNew; }
 void SetWaitAllowed ( bool bNew )   { m_bWaitAllowed = bNew; }
 
-void SetAgain() { m_bAgain = true; }
+void SetAgain(bool bAgain) { m_bAgain = bAgain; }
 void SetUpdateExpFields() {m_bUpdateExpFields = true; }
 
 inline void SetCheckPageNum( sal_uInt16 nNew );
diff --git a/sw/source/core/layout/layact.cxx b/sw/source/core/layout/layact.cxx
index ae643be49d37..b4924390af50 100644
--- a/sw/source/core/layout/layact.cxx
+++ b/sw/source/core/layout/layact.cxx
@@ -276,12 +276,13 @@ SwLayAction::~SwLayAction()
 
 void SwLayAction::Reset()
 {
+SetAgain(false);
 m_pOptTab = nullptr;
 m_nStartTicks = std::clock();
 m_nInputType = VclInputFlags::NONE;
 m_nEndPage = m_nPreInvaPage = m_nCheckPageNum = USHRT_MAX;
 m_bPaint = m_bComplete = m_bWaitAllowed = m_bCheckPages = true;
-m_bInput = m_bAgain = m_bNextCycle = m_bCalcLayout = m_bIdle = 
m_bReschedule =
+m_bInput = m_bNextCycle = m_bCalcLayout = m_bIdle = m_bReschedule =
 m_bUpdateExpFields = m_bBrowseActionStop = false;
 }
 
@@ -339,12 +340,15 @@ void SwLayAction::Action(OutputDevice* pRenderContext)
 SetCheckPages( false );
 
 InternalAction(pRenderContext);
-m_bAgain |= RemoveEmptyBrowserPages();
+if (RemoveEmptyBrowserPages())
+SetAgain(true);
 while ( IsAgain() )
 {
-m_bAgain = m_bNextCycle = false;
+SetAgain(false);
+m_bNextCycle = false;
 InternalAction(pRenderContext);
-m_bAgain |= RemoveEmptyBrowserPages();
+if (RemoveEmptyBrowserPages())
+SetAgain(true);
 }
 m_pRoot->DeleteEmptySct();
 
@@ -635,7 +639,7 @@ void SwLayAction::InternalAction(OutputDevice* 
pRenderContext)
 {
 bool bOld = IsAgain();
 m_pRoot->RemoveSuperfluous();
-m_bAgain = bOld;
+SetAgain(bOld);
 }
 if ( IsAgain() )
 {
diff --git a/sw/source/core/layout/objectformattertxtfrm.cxx 
b/sw/source/core/layout/objectformattertxtfrm.cxx
index 1af4476d4946..88f0bc28904f 100644
--- a/sw/source/core/layout/objectformattertxtfrm.cxx
+++ b/sw/source/core/layout/objectformattertxtfrm.cxx
@@ -293,7 +293,7 @@ bool SwObjectFormatterTextFrame::DoFormatObjs()
 {
 // notify layout action, thus is can restart the layout process on
 // a previous page.
-GetLayAction()->SetAgain();
+GetLayAction()->SetAgain(true);
 }
 else
 {
diff --git a/sw/source/core/layout/pagechg.cxx 
b/sw/source/core/layout/pagechg.cxx
index fe2f481d3f55..ee49c1fd6f9f 100644
--- a/sw/source/core/layout/pagechg.cxx
+++ b/sw/source/core/layout/pagechg.cxx
@@ -284,7 +284,7 @@ void SwPageFrame::DestroyImpl()
 SwViewShellImp *pImp = pSh->Imp();
 pImp->SetFirstVisPageInvalid();
 if ( pImp->IsAction() )
-pImp->GetLayAction().SetAgain();
+pImp->GetLayAction().SetAgain(true);
 // #i9719# - retouche area of page
 // including border and shadow area.
 const bool bRightSidebar = (SidebarPosition() == 
sw::sidebarwindows::SidebarPosition::RIGHT);


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

2021-11-17 Thread Caolán McNamara (via logerrit)
 sw/source/core/text/itrform2.cxx |4 
 1 file changed, 4 insertions(+)

New commits:
commit fb30c52ced11505fa4a0201a9dc127316133151d
Author: Caolán McNamara 
AuthorDate: Mon Jul 12 16:21:04 2021 +0100
Commit: Michael Stahl 
CommitDate: Wed Nov 17 10:17:15 2021 +0100

crashtesting: UaF on layout of ooo98566-1.odt

in:
sw/source/core/text/itrform2.cxx:2643 SwTextFormatter::NewFlyCntPortion
at: pFly = static_cast(pHint)->GetFlyFrame(pFrame)

(gdb) print m_pCurr
$2 = (SwLineLayout *) 0x55ea220a0020

after calling GetFlyFrame m_pCurr is unchanged and we will call
m_pCurr->MaxAscentDescent
on it.

But m_pCurr is deleted during GetFlyFrame by...

 #18 0x7f98c5cd337f in SwLineLayout::~SwLineLayout() 
(this=this@entry=0x55ea220a0020, __in_chrg=)
 at source/libo-core/sw/source/core/text/portxt.hxx:26
 #19 0x7f98c5cd347a in SwParaPortion::~SwParaPortion() 
(this=0x55ea220a0020, __in_chrg=)
 at source/libo-core/sw/source/core/text/porlay.cxx:2491
 #20 0x7f98c5cd3485 in SwParaPortion::~SwParaPortion() 
(this=0x55ea220a0020, __in_chrg=)
 at source/libo-core/sw/source/core/text/porlay.cxx:2491
 #21 0x7f98c5d05e70 in 
std::default_delete::operator()(SwParaPortion*) const 
(__ptr=, this=)
 at /usr/include/c++/8/bits/unique_ptr.h:75
 #22 0x7f98c5d05e70 in std::unique_ptr >::reset(SwParaPortion*)
 (__p=, this=) at 
/usr/include/c++/8/bits/unique_ptr.h:382
 #23 0x7f98c5d05e70 in SwTextLine::SetPara(SwParaPortion*, bool) 
(bDelete=true, pNew=0x0, this=)
 at source/libo-core/sw/source/core/text/txtcache.hxx:45
 #24 0x7f98c5d05e70 in SwTextFrame::ClearPara() 
(this=this@entry=0x55ea21302b60) at 
source/libo-core/sw/source/core/text/txtcache.cxx:113
 #25 0x7f98c5d1be89 in SwTextFrame::Init() 
(this=this@entry=0x55ea21302b60) at 
source/libo-core/sw/source/core/text/txtfrm.cxx:757
 #26 0x7f98c5d2630c in SwTextFrame::Prepare(PrepareHint, void const*, 
bool)
 (this=0x55ea21302b60, ePrep=PrepareHint::FlyFrameArrive, 
pVoid=, bNotify=)
 at source/libo-core/sw/source/core/text/txtfrm.cxx:3086
 #27 0x7f98c5b1edb8 in 
SwFlyInContentFrame::NotifyBackground(SwPageFrame*, SwRect const&, PrepareHint)
 (this=, rRect=..., eHint=) at 
source/libo-core/sw/inc/anchoredobject.hxx:205
 #28 0x7f98c5b261a6 in Notify(SwFlyFrame*, SwPageFrame*, SwRect const&, 
SwRect const*)
 (pFly=pFly@entry=0x55ea21a18d60, pOld=0x0, rOld=SwRect = {...}, 
pOldPrt=pOldPrt@entry=0x7ffeb50390f8)
 at source/libo-core/sw/source/core/inc/frame.hxx:1177
 #29 0x7f98c5b2ceca in SwFlyNotify::~SwFlyNotify() 
(this=0x7ffeb50390d0, __in_chrg=)
 at source/libo-core/sw/source/core/layout/frmtool.cxx:648
 #30 0x7f98c5b1fa25 in SwFlyInContentFrame::MakeAll(OutputDevice*) 
(this=0x55ea21a18d60)
 at source/libo-core/sw/source/core/inc/frmtool.hxx:419
 #31 0x7f98c5aec3a9 in SwFrame::PrepareMake(OutputDevice*) 
(this=0x55ea21a18d60, pRenderContext=0x55ea212bc4c0)
 at source/libo-core/sw/source/core/layout/calcmove.cxx:375
 #32 0x7f98c5b17ad2 in SwFlyFrame::Calc(OutputDevice*) const 
(this=, pRenderContext=)
 at source/libo-core/sw/source/core/layout/fly.cxx:2890
 #33 0x7f98c5b636c5 in SwObjectFormatter::FormatLayout_(SwLayoutFrame&) 
(this=this@entry=0x55ea2244d150, _rLayoutFrame=...)
 at source/libo-core/include/rtl/ref.hxx:206
 #34 0x7f98c5b6413e in SwObjectFormatter::FormatObj_(SwAnchoredObject&) 
(this=this@entry=0x55ea2244d150, _rAnchoredObj=...)
 at source/libo-core/sw/source/core/layout/objectformatter.cxx:296
 #35 0x7f98c5b6705b in 
SwObjectFormatterTextFrame::DoFormatObj(SwAnchoredObject&, bool)
 (this=0x55ea2244d150, _rAnchoredObj=..., _bCheckForMovedFwd=)
 at source/libo-core/sw/source/core/layout/objectformattertxtfrm.cxx:136
 #36 0x7f98c5b6359f in SwObjectFormatter::FormatObj(SwAnchoredObject&, 
SwFrame*, SwPageFrame const*)
 (_rAnchoredObj=..., _pAnchorFrame=, 
_pPageFrame=)
 at source/libo-core/sw/source/core/layout/objectformatter.cxx:190
 #37 0x7f98c5d717aa in SwTextFlyCnt::GetFlyFrame_(SwFrame const*) 
(this=this@entry=0x55ea214d8810, pCurrFrame=pCurrFrame@entry=0x55ea21302b60)
 at source/libo-core/sw/source/core/inc/frame.hxx:1177
 #38 0x7f98c5cb511b in SwTextFlyCnt::GetFlyFrame(SwFrame const*) 
(pCurrFrame=0x55ea21302b60, this=0x55ea214d8810)
 at source/libo-core/sw/inc/txtflcnt.hxx:48
 #39 0x7f98c5cb511b in 
SwTextFormatter::NewFlyCntPortion(SwTextFormatInfo&, SwTextAttr*) const
 (this=this@entry=0x7ffeb503a6b0, rInf=..., pHint=0x55ea214d8810) at 
source/libo-core/sw/source/core/text/itrform2.cxx:2643

(gdb) print this
(SwLinePortion * const) 0x55ea220a0020

The SwTextFrame of SwTextFrame::ClearPara is the same p

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

2021-11-17 Thread Luboš Luňák (via logerrit)
 sc/qa/unit/data/functions/spreadsheet/fods/vlookup2.fods |   22 +++
 sc/source/core/data/table3.cxx   |9 --
 sc/uiconfig/scalc/ui/optcalculatepage.ui |2 -
 3 files changed, 12 insertions(+), 21 deletions(-)

New commits:
commit 8dec2a98ce29251936cd45ebf864a89ff767ee50
Author: Luboš Luňák 
AuthorDate: Tue Nov 16 01:30:24 2021 +0100
Commit: Luboš Luňák 
CommitDate: Wed Nov 17 10:10:58 2021 +0100

revert "vlookup - optimize SC_EQUAL and NOT_EQUAL." (tdf#139612)

That commit breaks lookup when the  "Search criteria = and <> must
apply to whole cells" option is disabled, as it enforces whole cell
checking regardless of the option. Given that the option is enabled
by default in LO ('SearchCriteria' in Calc.xcs) and it's what
MSOffice does as well, and this default gives good performance
regardless of the option, I don't understand the purpose
of the commit. Possibly it was based on a document where somebody
disabled the option and then indeed got worse performance.
Solution: Don't do that :).

This reverts the code parts of a953fa1c0f6a40a08859570516c511f3a841 .
The test I've kept but switched to ensure that partial matching
does work if the option to match whole cells is disabled. I've
also changed the tooltip for the option to mention performance
and not suggest that off is the default.

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

diff --git a/sc/qa/unit/data/functions/spreadsheet/fods/vlookup2.fods 
b/sc/qa/unit/data/functions/spreadsheet/fods/vlookup2.fods
index d47779d928a1..fd228881a7cb 100644
--- a/sc/qa/unit/data/functions/spreadsheet/fods/vlookup2.fods
+++ b/sc/qa/unit/data/functions/spreadsheet/fods/vlookup2.fods
@@ -1017,14 +1017,14 @@
   TRUE
  
  
-  VLOOKUP tests that ensure there is no partial matching of cell 
contents
+  VLOOKUP tests that ensure there is partial matching of cell 
contents
  
 
 
  
  
  
-  even though the document option of “search on whole cell” is 
turned off.
+  when the document option of “search on whole cell” is turned 
off.
  
 
 
@@ -1095,10 +1095,10 @@
  
   #N/A
  
- 
-  #N/A
+ 
+  2
  
- 
+ 
   TRUE
  
  
@@ -1122,10 +1122,10 @@
  
   #N/A
  
- 
-  #N/A
+ 
+  2
  
- 
+ 
   TRUE
  
  
@@ -1149,10 +1149,10 @@
  
   #N/A
  
- 
-  #N/A
+ 
+  2
  
- 
+ 
   TRUE
  
  
diff --git a/sc/source/core/data/table3.cxx b/sc/source/core/data/table3.cxx
index 9c7417278658..0ef833511dba 100644
--- a/sc/source/core/data/table3.cxx
+++ b/sc/source/core/data/table3.cxx
@@ -2767,11 +2767,6 @@ public:
 
 if (nIndex < 0)
 nStrPos = -1;
-else if (rEntry.eOp == SC_EQUAL ||
- rEntry.eOp == SC_NOT_EQUAL)
-{
-nStrPos = pCellStr == pQuer ? 0 : -1;
-}
 else
 { // OUString::indexOf
 nStrPos = rtl_ustr_indexOfStr_WithLength(
@@ -2803,14 +2798,10 @@ public:
 switch (rEntry.eOp)
 {
 case SC_EQUAL:
-bOk = ( nStrPos == 0 );
-break;
 case SC_CONTAINS:
 bOk = ( nStrPos != -1 );
 break;
 case SC_NOT_EQUAL:
-bOk = ( nStrPos != 0 );
-break;
 case SC_DOES_NOT_CONTAIN:
 bOk = ( nStrPos == -1 );
 break;
diff --git a/sc/uiconfig/scalc/ui/optcalculatepage.ui 
b/sc/uiconfig/scalc/ui/optcalculatepage.ui
index 1af846f48ff1..1c0c7f3c2928 100644
--- a/sc/uiconfig/scalc/ui/optcalculatepage.ui
+++ b/sc/uiconfig/scalc/ui/optcalculatepage.ui
@@ -131,7 +131,7 @@
 True
 True
 False
-Enable this for interoperability 
with Microsoft Excel
+Keep this enabled for 
interoperability with Microsoft Excel or for better performance
 True
 True
 


  1   2   >