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

2018-02-14 Thread Stephan Bergmann
 sw/source/uibase/shells/grfsh.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 552f5835fdc775a77022a49bdc77f84eab697bcf
Author: Stephan Bergmann 
Date:   Wed Feb 14 16:04:30 2018 +0100

SID_ATTR_TRANSFORM_ANGLE is an SfxInt32Item

...as reported by UBSan when rotating an image in Writer:

> sw/source/uibase/shells/grfsh.cxx:531:52: runtime error: downcast of 
address 0x0bba8d80 which does not point to an object of type 'const 
SfxUInt32Item'
> 0x0bba8d80: note: object is of type 'SfxInt32Item'
>  00 00 00 00  f8 8f 04 42 8f 7f 00 00  01 00 00 00 6f 27 00 00  d4 17 00 
00 00 00 00 00  41 00 00 00
>   ^~~
>   vptr for 'SfxInt32Item'
> #0 0x7f8eaf7fcdad in SwGrfShell::Execute(SfxRequest&) 
sw/source/uibase/shells/grfsh.cxx:531:52
> #1 0x7f8eaf7ed2f5 in SfxStubSwGrfShellExecute(SfxShell*, SfxRequest&) 
workdir/SdiTarget/sw/sdi/swslots.hxx:12460:1
> #2 0x7f8f3ff4637a in SfxShell::CallExec(void (*)(SfxShell*, 
SfxRequest&), SfxRequest&) include/sfx2/shell.hxx:211:35
...

Code had been introduced with a42b0985c7619efdc934bb1cf19e5e2c2b6faea2
"RotGrfFlyFrame: Initial adaptions".

Change-Id: Id402244d723bcf653e414a3cd45ce07ad216e29f
Reviewed-on: https://gerrit.libreoffice.org/49738
Tested-by: Jenkins 
Reviewed-by: Stephan Bergmann 

diff --git a/sw/source/uibase/shells/grfsh.cxx 
b/sw/source/uibase/shells/grfsh.cxx
index 0fd6daf05927..0ed1ec139f27 100644
--- a/sw/source/uibase/shells/grfsh.cxx
+++ b/sw/source/uibase/shells/grfsh.cxx
@@ -528,7 +528,7 @@ void SwGrfShell::Execute(SfxRequest &rReq)
 // RotGrfFlyFrame: Get and process evtl. changed RotationAngle
 if ( SfxItemState::SET == 
pSet->GetItemState(SID_ATTR_TRANSFORM_ANGLE, false, &pItem ))
 {
-const sal_uInt32 aNewRotation((static_cast(pItem)->GetValue() / 10) % 3600);
+const sal_Int32 aNewRotation((static_cast(pItem)->GetValue() / 10) % 3600);
 
 // RotGrfFlyFrame: Possible rotation change here, 
SwFlyFrameAttrMgr aMgr is available
 aMgr.SetRotation(nCurrentRotation, aNewRotation, 
aUnrotatedSize);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Aron Budea
 loleaflet/src/control/Control.Menubar.js |5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

New commits:
commit 1cfe416559951ad7079a176d4c02de9aa0c1e5fe
Author: Aron Budea 
Date:   Thu Feb 15 07:30:14 2018 +0100

loleaflet: add download as RTF option

Change-Id: Id258461ff49bcc6d6a0b1e4df826c184e769c5e1
Reviewed-on: https://gerrit.libreoffice.org/49787
Reviewed-by: pranavk 
Tested-by: pranavk 

diff --git a/loleaflet/src/control/Control.Menubar.js 
b/loleaflet/src/control/Control.Menubar.js
index 13338925..e60f7c6f 100644
--- a/loleaflet/src/control/Control.Menubar.js
+++ b/loleaflet/src/control/Control.Menubar.js
@@ -23,7 +23,8 @@ L.Control.Menubar = L.Control.extend({
{name: _('PDF Document (.pdf)'), id: 
'downloadas-pdf', type: 'action'},
{name: _('ODF text document (.odt)'), 
id: 'downloadas-odt', type: 'action'},
{name: _('Microsoft Word 2003 (.doc)'), 
id: 'downloadas-doc', type: 'action'},
-   {name: _('Microsoft Word (.docx)'), id: 
'downloadas-docx', type: 'action'}]},
+   {name: _('Microsoft Word (.docx)'), id: 
'downloadas-docx', type: 'action'},
+   {name: _('Rich Text (.rtf)'), id: 
'downloadas-rtf', type: 'action'}]},
{type: 'separator'},
{uno: '.uno:SetDocumentProperties'}
]},
@@ -378,7 +379,7 @@ L.Control.Menubar = L.Control.extend({
allowedReadonlyMenus: ['file', 'downloadas', 'view', 'help'],
 
allowedViewModeActions: [
-   'downloadas-pdf', 'downloadas-odt', 'downloadas-doc', 
'downloadas-docx', // file menu
+   'downloadas-pdf', 'downloadas-odt', 'downloadas-doc', 
'downloadas-docx', 'downloadas-rtf', // file menu
'downloadas-odp', 'downloadas-ppt', 'downloadas-pptx', 
// file menu
'downloadas-ods', 'downloadas-xls', 'downloadas-xlsx', 
// file menu
'fullscreen', 'zoomin', 'zoomout', 'zoomreset', // view 
menu
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Noel Grandin
 oox/source/export/shapes.cxx|4 -
 reportdesign/source/core/sdr/RptObject.cxx  |4 -
 reportdesign/source/ui/report/DesignView.cxx|4 -
 reportdesign/source/ui/report/EndMarker.cxx |2 
 reportdesign/source/ui/report/ReportSection.cxx |6 -
 reportdesign/source/ui/report/ReportWindow.cxx  |6 -
 reportdesign/source/ui/report/ScrollHelper.cxx  |   12 +--
 reportdesign/source/ui/report/SectionWindow.cxx |   12 +--
 reportdesign/source/ui/report/StartMarker.cxx   |   18 ++--
 reportdesign/source/ui/report/ViewsWindow.cxx   |   94 
 reportdesign/source/ui/report/dlgedfunc.cxx |   14 +--
 11 files changed, 88 insertions(+), 88 deletions(-)

New commits:
commit 457220bc2c0142c5b6f4135cb688ccfc99fec792
Author: Noel Grandin 
Date:   Wed Feb 14 09:38:40 2018 +0200

loplugin:changetoolsgen in oox,reportdesign

Change-Id: I8112ae6bb92ef96b4229ab53b7002ae3c0ba865c
Reviewed-on: https://gerrit.libreoffice.org/49702
Tested-by: Jenkins 
Reviewed-by: Noel Grandin 

diff --git a/oox/source/export/shapes.cxx b/oox/source/export/shapes.cxx
index e922a3bce934..72f2eac304ba 100644
--- a/oox/source/export/shapes.cxx
+++ b/oox/source/export/shapes.cxx
@@ -386,9 +386,9 @@ awt::Size ShapeExport::MapSize( const awt::Size& rSize ) 
const
 Size aRetSize( OutputDevice::LogicToLogic( Size( rSize.Width, rSize.Height 
), maMapModeSrc, maMapModeDest ) );
 
 if ( !aRetSize.Width() )
-aRetSize.Width()++;
+aRetSize.setWidth( ++aRetSize.Width() );
 if ( !aRetSize.Height() )
-aRetSize.Height()++;
+aRetSize.setHeight( ++aRetSize.Height() );
 return awt::Size( aRetSize.Width(), aRetSize.Height() );
 }
 
diff --git a/reportdesign/source/core/sdr/RptObject.cxx 
b/reportdesign/source/core/sdr/RptObject.cxx
index a63018c1ab9d..37a0f763b51b 100644
--- a/reportdesign/source/core/sdr/RptObject.cxx
+++ b/reportdesign/source/core/sdr/RptObject.cxx
@@ -681,7 +681,7 @@ void OUnoObject::NbcMove( const Size& rSize )
 int nNewY = m_xReportComponent->getPositionY() + rSize.Height();
 if (nNewY < 0 && !bUndoMode)
 {
-aUndoSize.Height() = abs(nNewY);
+aUndoSize.setHeight( abs(nNewY) );
 bPositionFixed = true;
 nNewY = 0;
 }
@@ -961,7 +961,7 @@ void OOle2Obj::NbcMove( const Size& rSize )
 int nNewY = m_xReportComponent->getPositionY() + rSize.Height();
 if (nNewY < 0 && !bUndoMode)
 {
-aUndoSize.Height() = abs(nNewY);
+aUndoSize.setHeight( abs(nNewY) );
 bPositionFixed = true;
 nNewY = 0;
 }
diff --git a/reportdesign/source/ui/report/DesignView.cxx 
b/reportdesign/source/ui/report/DesignView.cxx
index 1170439603ee..b7d5c3fbac60 100644
--- a/reportdesign/source/ui/report/DesignView.cxx
+++ b/reportdesign/source/ui/report/DesignView.cxx
@@ -237,11 +237,11 @@ void ODesignView::resizeDocumentView(tools::Rectangle& 
_rPlayground)
 Point aTaskPanePos(nSplitPos + nSplitterWidth, _rPlayground.Top());
 if (m_pTaskPane && m_pTaskPane->IsVisible() && m_pPropWin)
 {
-aTaskPanePos.X() = aPlaygroundSize.Width() - 
m_pTaskPane->GetSizePixel().Width();
+aTaskPanePos.setX( aPlaygroundSize.Width() - 
m_pTaskPane->GetSizePixel().Width() );
 sal_Int32 nMinWidth = m_pPropWin->getMinimumSize().Width();
 if ( nMinWidth > (aPlaygroundSize.Width() - aTaskPanePos.X()) )
 {
-aTaskPanePos.X() = aPlaygroundSize.Width() - nMinWidth;
+aTaskPanePos.setX( aPlaygroundSize.Width() - nMinWidth );
 }
 nSplitPos = aTaskPanePos.X() - nSplitterWidth;
 getController().setSplitPos(nSplitPos);
diff --git a/reportdesign/source/ui/report/EndMarker.cxx 
b/reportdesign/source/ui/report/EndMarker.cxx
index fba16afca43c..fc1f2703f7f6 100644
--- a/reportdesign/source/ui/report/EndMarker.cxx
+++ b/reportdesign/source/ui/report/EndMarker.cxx
@@ -48,7 +48,7 @@ void OEndMarker::Paint(vcl::RenderContext& rRenderContext, 
const tools::Rectangl
 const long nCornerSpace = long(aCornerSpace);
 
 Size aSize = GetSizePixel();
-aSize.Width() += nCornerSpace;
+aSize.setWidth( aSize.Width() + nCornerSpace );
 tools::Rectangle aWholeRect(Point(-nCornerSpace,0),aSize);
 tools::PolyPolygon aPoly;
 aPoly.Insert( tools::Polygon(aWholeRect,nCornerSpace,nCornerSpace));
diff --git a/reportdesign/source/ui/report/ReportSection.cxx 
b/reportdesign/source/ui/report/ReportSection.cxx
index 99f93cc72455..de5a0e726aca 100644
--- a/reportdesign/source/ui/report/ReportSection.cxx
+++ b/reportdesign/source/ui/report/ReportSection.cxx
@@ -758,12 +758,12 @@ sal_Int8 OReportSection::ExecuteDrop( const 
ExecuteDropEvent& _rEvt )
 m_pView->Unmar

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

2018-02-14 Thread Noel Grandin
 sd/source/core/drawdoc2.cxx|2 
 sd/source/core/sdpage.cxx  |  110 
+-
 sd/source/filter/eppt/epptso.cxx   |4 
 sd/source/filter/eppt/pptx-epptbase.cxx|4 
 sd/source/filter/eppt/pptx-text.cxx|4 
 sd/source/filter/grf/sdgrffilter.cxx   |   16 -
 sd/source/filter/html/buttonset.cxx|8 
 sd/source/filter/html/htmlattr.cxx |2 
 sd/source/filter/html/htmlex.cxx   |   24 +-
 sd/source/ui/animations/CustomAnimationList.cxx|   30 +-
 sd/source/ui/annotations/annotationmanager.cxx |8 
 sd/source/ui/annotations/annotationtag.cxx |4 
 sd/source/ui/controller/displaymodecontroller.cxx  |   12 -
 sd/source/ui/controller/slidelayoutcontroller.cxx  |   12 -
 sd/source/ui/dlg/PhotoAlbumDialog.cxx  |8 
 sd/source/ui/dlg/RemoteDialogClientBox.cxx |   20 -
 sd/source/ui/dlg/animobjs.cxx  |   76 +++---
 sd/source/ui/dlg/headerfooterdlg.cxx   |8 
 sd/source/ui/dlg/vectdlg.cxx   |   12 -
 sd/source/ui/docshell/docshel2.cxx |4 
 sd/source/ui/docshell/sdclient.cxx |8 
 sd/source/ui/func/fudraw.cxx   |8 
 sd/source/ui/func/fuinsert.cxx |   16 -
 sd/source/ui/func/fuinsfil.cxx |8 
 sd/source/ui/func/fusel.cxx|8 
 sd/source/ui/func/fusnapln.cxx |4 
 sd/source/ui/func/futext.cxx   |4 
 sd/source/ui/func/fuzoom.cxx   |   16 -
 sd/source/ui/sidebar/LayoutMenu.cxx|8 
 sd/source/ui/sidebar/MasterPageContainer.cxx   |8 
 sd/source/ui/slideshow/slideshowimpl.cxx   |4 
 sd/source/ui/slideshow/slideshowviewimpl.cxx   |   12 -
 sd/source/ui/slidesorter/cache/SlsBitmapFactory.cxx|4 
 sd/source/ui/slidesorter/controller/SlsScrollBarManager.cxx|   24 +-
 sd/source/ui/slidesorter/controller/SlsVisibleAreaManager.cxx  |8 
 sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx|8 
 sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx|4 
 sd/source/ui/slidesorter/view/SlsInsertionIndicatorOverlay.cxx |4 
 sd/source/ui/slidesorter/view/SlsLayouter.cxx  |   16 -
 sd/source/ui/table/TableDesignPane.cxx |6 
 sd/source/ui/table/tablefunction.cxx   |4 
 sd/source/ui/view/DocumentRenderer.cxx |   30 +-
 sd/source/ui/view/ViewShellBase.cxx|4 
 sd/source/ui/view/drviews1.cxx |4 
 sd/source/ui/view/drviews2.cxx |   10 
 sd/source/ui/view/drviews3.cxx |   18 -
 sd/source/ui/view/drviews4.cxx |8 
 sd/source/ui/view/drviews5.cxx |2 
 sd/source/ui/view/drviews8.cxx |   12 -
 sd/source/ui/view/drviews9.cxx |   12 -
 sd/source/ui/view/drviewsa.cxx |   32 +-
 sd/source/ui/view/drviewse.cxx |   40 +--
 sd/source/ui/view/drviewsh.cxx |   16 -
 sd/source/ui/view/frmview.cxx  |   18 -
 sd/source/ui/view/grviewsh.cxx |4 
 sd/source/ui/view/outlnvsh.cxx |2 
 sd/source/ui/view/outlview.cxx |   24 +-
 sd/source/ui/view/sdview3.cxx  |   64 ++---
 sd/source/ui/view/sdview4.cxx  |8 
 sd/source/ui/view/sdwindow.cxx |   48 ++--
 sd/source/ui/view/viewoverlaymanager.cxx   |4 
 sd/source/ui/view/viewshe2.cxx |4 
 sd/source/ui/view/viewshel.cxx |4 
 63 files changed, 459 insertions(+), 459 deletions(-)

New commits:
commit 0d9f3f7628f88fa66aaeea1f7148db620e17e728
Author: Noel Grandin 
Date:   Wed Feb 14 12:48:06 2018 +0200

loplugin:changetoolsgen in sd

Change-Id: I41c5510f95167fe028f219fb593f12b75709bd65
Reviewed-on: https://gerrit.libreoffice.org/49726
Tested-by: Jenkins 
Reviewed-by: Noel Grandin 

diff --git a/sd/source/

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

2018-02-14 Thread Noel Grandin
 sfx2/source/appl/childwin.cxx |   12 +-
 sfx2/source/appl/newhelp.cxx  |   22 ++--
 sfx2/source/appl/workwin.cxx  |  112 +++---
 sfx2/source/bastyp/frmhtml.cxx|8 -
 sfx2/source/control/charwin.cxx   |   10 -
 sfx2/source/control/emojiviewitem.cxx |4 
 sfx2/source/control/templatelocalview.cxx |4 
 sfx2/source/control/thumbnailviewitem.cxx |8 -
 sfx2/source/dialog/basedlgs.cxx   |   16 +--
 sfx2/source/dialog/dinfdlg.cxx|2 
 sfx2/source/dialog/dockwin.cxx|   64 ++--
 sfx2/source/dialog/recfloat.cxx   |4 
 sfx2/source/dialog/splitwin.cxx   |   12 +-
 sfx2/source/dialog/templdlg.cxx   |6 -
 sfx2/source/dialog/titledockwin.cxx   |4 
 sfx2/source/doc/iframe.cxx|4 
 sfx2/source/doc/printhelper.cxx   |4 
 sfx2/source/doc/sfxbasemodel.cxx  |4 
 sfx2/source/notebookbar/ContextVBox.cxx   |4 
 sfx2/source/notebookbar/NotebookbarTabControl.cxx |4 
 sfx2/source/sidebar/Deck.cxx  |8 -
 sfx2/source/sidebar/DeckLayouter.cxx  |2 
 sfx2/source/sidebar/TitleBar.cxx  |2 
 sfx2/source/view/classificationcontroller.cxx |8 -
 sfx2/source/view/frame.cxx|8 -
 sfx2/source/view/lokcharthelper.cxx   |8 -
 sfx2/source/view/viewfrm.cxx  |   16 +--
 27 files changed, 181 insertions(+), 179 deletions(-)

New commits:
commit c82802a9ee3514d0b98fbb3783abbc17ec02c3b6
Author: Noel Grandin 
Date:   Wed Feb 14 15:20:27 2018 +0200

loplugin:changetoolsgen in sfx2

Change-Id: I34a007711e2ffc70bdee6823ea9b85f60f819e6e
Reviewed-on: https://gerrit.libreoffice.org/49727
Tested-by: Jenkins 
Reviewed-by: Noel Grandin 

diff --git a/sfx2/source/appl/childwin.cxx b/sfx2/source/appl/childwin.cxx
index aec56687d3d7..2b019f2a5a37 100644
--- a/sfx2/source/appl/childwin.cxx
+++ b/sfx2/source/appl/childwin.cxx
@@ -113,10 +113,10 @@ bool GetPosSizeFromString( const OUString& rStr, Point& 
rPos, Size& rSize )
 return false;
 
 sal_Int32 nIdx = 0;
-rPos.X() = rStr.getToken(0, '/', nIdx).toInt32();
-rPos.Y() = rStr.getToken(0, '/', nIdx).toInt32();
-rSize.Width() = rStr.getToken(0, '/', nIdx).toInt32();
-rSize.Height() = rStr.getToken(0, '/', nIdx).toInt32();
+rPos.setX( rStr.getToken(0, '/', nIdx).toInt32() );
+rPos.setY( rStr.getToken(0, '/', nIdx).toInt32() );
+rSize.setWidth( rStr.getToken(0, '/', nIdx).toInt32() );
+rSize.setHeight( rStr.getToken(0, '/', nIdx).toInt32() );
 
 // negative sizes are invalid
 return !(rSize.Width() < 0 || rSize.Height() < 0);
@@ -133,8 +133,8 @@ bool GetSplitSizeFromString( const OUString& rStr, Size& 
rSize )
 if ( nCount != 2 )
 return false;
 
-rSize.Width() = aStr.getToken(0, ';' ).toInt32();
-rSize.Height() = aStr.getToken(1, ';' ).toInt32();
+rSize.setWidth( aStr.getToken(0, ';' ).toInt32() );
+rSize.setHeight( aStr.getToken(1, ';' ).toInt32() );
 
 // negative sizes are invalid
 return !(rSize.Width() < 0 || rSize.Height() < 0);
diff --git a/sfx2/source/appl/newhelp.cxx b/sfx2/source/appl/newhelp.cxx
index e13437461fc9..1afc7258af4a 100644
--- a/sfx2/source/appl/newhelp.cxx
+++ b/sfx2/source/appl/newhelp.cxx
@@ -488,8 +488,8 @@ void IndexBox_Impl::UserDraw( const UserDrawEvent& rUDEvt )
 {
 // indent sub entries
 Point aPos( rUDEvt.GetRect().TopLeft() );
-aPos.X() += 8;
-aPos.Y() += (rUDEvt.GetRect().GetHeight() - 
rUDEvt.GetRenderContext()->GetTextHeight()) / 2;
+aPos.setX( aPos.X() + 8 );
+aPos.setY( aPos.Y() + (rUDEvt.GetRect().GetHeight() - 
rUDEvt.GetRenderContext()->GetTextHeight()) / 2 );
 OUString aEntry( GetEntry( rUDEvt.GetItemId() ) );
 sal_Int32 nPos = aEntry.indexOf( ';' );
 rUDEvt.GetRenderContext()->DrawText(aPos, (nPos !=-1) ? 
aEntry.copy(nPos + 1) : aEntry);
@@ -2063,7 +2063,7 @@ void SfxHelpTextWindow_Impl::InitOnStartupBox()
 sCBText += aOnStartupCB->GetText();
 long nTextWidth = aOnStartupCB->GetTextWidth( sCBText );
 Size aSize = aOnStartupCB->GetSizePixel();
-aSize.Width() = nTextWidth;
+aSize.setWidth( nTextWidth );
 aOnStartupCB->SetSizePixel( aSize );
 SetOnStartupBoxPosition();
 }
@@ -2073,8 +2073,8 @@ void SfxHelpTextWindow_Impl::InitOnStartupBox()
 Size aTBSize = aToolBox->GetSizePixel();
 Size aCBSize = aOnStartupCB->GetSizePixel();
 Point aPnt = aToolBox->GetPosPixel();
-aPnt.X() += aTBSize.Width() + a3Size.Width();
-aPnt.Y() += ( ( aTBSize.H

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

2018-02-14 Thread Pranav Kant
 loleaflet/dist/toolbar/toolbar.js |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit c470116012eaf1ee47c4dc77c92eca125dd70577
Author: Pranav Kant 
Date:   Thu Feb 15 11:55:40 2018 +0530

Fix some buttons doesn't show up in mobile mode

Change-Id: I25ceecc56e2dae9a0b31e038412c7b74447c391f

diff --git a/loleaflet/dist/toolbar/toolbar.js 
b/loleaflet/dist/toolbar/toolbar.js
index 5683c6ed..b504ebc5 100644
--- a/loleaflet/dist/toolbar/toolbar.js
+++ b/loleaflet/dist/toolbar/toolbar.js
@@ -122,6 +122,8 @@ function resizeToolbar() {
_unmobilify();
}
 
+   toolbarUp.refresh();
+   toolbarUpMore.refresh();
// move items from toolbar-up-more -> toolbar-up
while ($('#toolbar-up')[0].scrollWidth <= $(window).width()) {
var item = toolbarUpMore.items[0];
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Andika Triwidada license statement

2018-02-14 Thread Andika Triwidada
All of my past & future contributions to LibreOffice may be
licensed under the MPLv2/LGPLv3+ dual license.
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


[ANN] liborcus updated to 0.13.3 on master

2018-02-14 Thread Kohei Yoshida
FYI, I've just updated the liborcus package to 0.13.3 on the master
branch.  Due to some failing unit tests when using earlier versions of
orcus, I've also upped the baseline to 0.13.3 as well.

The highlight of this release is mostly wrt the improvements in loading
Excel 2003 XML documents.  I haven't done any objective comparison
between the previous XSLT-based Excel 2003 XML import filter and the
orcus-based one, but I believe the orcus-based one now should be pretty
comparable to the old one in general, and in some areas works much
better.

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


[Libreoffice-commits] core.git: configure.ac download.lst external/liborcus

2018-02-14 Thread Kohei Yoshida
 configure.ac  |2 +-
 download.lst  |4 ++--
 external/liborcus/UnpackedTarball_liborcus.mk |4 
 3 files changed, 3 insertions(+), 7 deletions(-)

New commits:
commit 45a4e70484e7d90dab07a677914ada2d948b415c
Author: Kohei Yoshida 
Date:   Wed Feb 14 21:04:28 2018 -0500

Update orcus to 0.13.3.

This will be the new baseline for master, since, though this change
is a fully API-compatible, one bug fix wrt the alpha value handling
unfortunately would break some unit tests when using an earlier
version.

Change-Id: I5a17ce4085d3311a165748154d107d12b95e2c71
Reviewed-on: https://gerrit.libreoffice.org/49784
Reviewed-by: Kohei Yoshida 
Tested-by: Kohei Yoshida 

diff --git a/configure.ac b/configure.ac
index 101050c2ae3c..e0cbf939 100644
--- a/configure.ac
+++ b/configure.ac
@@ -9026,7 +9026,7 @@ AC_SUBST(ENABLE_FUZZERS)
 dnl ===
 dnl Orcus
 dnl ===
-libo_CHECK_SYSTEM_MODULE([orcus],[ORCUS],[liborcus-0.13 >= 0.13.0])
+libo_CHECK_SYSTEM_MODULE([orcus],[ORCUS],[liborcus-0.13 >= 0.13.3])
 if test "$with_system_orcus" != "yes"; then
 if test "$SYSTEM_BOOST" = "TRUE"; then
 # ===
diff --git a/download.lst b/download.lst
index 70b6833e7e63..12a5f1482c7c 100644
--- a/download.lst
+++ b/download.lst
@@ -190,8 +190,8 @@ export OPENLDAP_SHA256SUM := 
cdd6cffdebcd95161a73305ec13fc7a78e9707b46ca9f84fb89
 export OPENLDAP_TARBALL := openldap-2.4.45.tgz
 export OPENSSL_SHA256SUM := 
8c6ff15ec6b319b50788f42c7abc2890c08ba5a1cdcd3810eb9092deada37b0f
 export OPENSSL_TARBALL := openssl-1.0.2m.tar.gz
-export ORCUS_SHA256SUM := 
0f8e85dc163881c358bd175227a970e3c70443109e2bb0d8d422439c31641df2
-export ORCUS_TARBALL := liborcus-0.13.2.tar.gz
+export ORCUS_SHA256SUM := 
62e76de1fd3101e77118732b860354121b40a87bbb1ebfeb8203477fffac16e9
+export ORCUS_TARBALL := liborcus-0.13.3.tar.gz
 export OWNCLOUD_ANDROID_LIB_SHA256SUM := 
b18b3e3ef7fae6a79b62f2bb43cc47a5346b6330f6a383dc4be34439aca5e9fb
 export OWNCLOUD_ANDROID_LIB_TARBALL := 
owncloud-android-library-0.9.4-no-binary-deps.tar.gz
 export PAGEMAKER_SHA256SUM := 
66adacd705a7d19895e08eac46d1e851332adf2e736c566bef1164e7a442519d
diff --git a/external/liborcus/UnpackedTarball_liborcus.mk 
b/external/liborcus/UnpackedTarball_liborcus.mk
index 92e461f95e57..3ab387e734be 100644
--- a/external/liborcus/UnpackedTarball_liborcus.mk
+++ b/external/liborcus/UnpackedTarball_liborcus.mk
@@ -18,10 +18,6 @@ $(eval $(call 
gb_UnpackedTarball_update_autoconf_configs,liborcus))
 $(eval $(call gb_UnpackedTarball_add_patches,liborcus,\
external/liborcus/0001-workaround-a-linking-problem-on-windows.patch \
external/liborcus/rpath.patch.0 \
-   
external/liborcus/0001-Alpha-value-of-0-means-fully-transparent.-I-m-sure-2.patch
 \
-   
external/liborcus/0002-We-are-supposed-to-use-the-foreground-color-for-soli.patch
 \
-   external/liborcus/0001-xls-xml-Pick-up-border-colors.patch \
-   external/liborcus/0001-xls-xml-Import-hidden-row-and-column-flags.patch 
\
 ))
 
 ifeq ($(OS),WNT)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Eike Rathke
 sc/inc/stringutil.hxx  |7 +++
 sc/source/core/data/column3.cxx|   10 +++---
 sc/source/core/tool/stringutil.cxx |3 ++-
 sc/source/filter/rtf/eeimpars.cxx  |1 +
 4 files changed, 17 insertions(+), 4 deletions(-)

New commits:
commit 1a1fc4ad83539b63d4dace3ddd3e24a54bf44791
Author: Eike Rathke 
Date:   Tue Feb 13 17:10:21 2018 +0100

ScSetStringParam::mbCheckLinkFormula for HTML and RTF import

 This is a combination of 3 commits.

Introduce ScSetStringParam::mbCheckLinkFormula

(cherry picked from commit 5a93c51e3b7f455ff5d4cfc9e8b6e510fc126b75)

Handle ScSetStringParam::mbCheckLinkFormula in ScColumn::ParseString()

(cherry picked from commit 271d9ebfe0c4fc57ea6f01a9c048021e5429dd15)

 Conflicts:
sc/source/core/data/column3.cxx

ScSetStringParam::mbCheckLinkFormula for HTML and RTF import

(cherry picked from commit 98c0bd7ffd008015623b2c5eb8630649394d76f6)

d6b0705140baacdb872560f7031efaf0c03f0e00
7cf7cf12142322cbffd5160e9a8dce55efd36be5

Change-Id: I2028fc53f9778606778cd8629611752acd3f1a1c
Reviewed-on: https://gerrit.libreoffice.org/49709
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/sc/inc/stringutil.hxx b/sc/inc/stringutil.hxx
index c208332b48f6..219a80cd452a 100644
--- a/sc/inc/stringutil.hxx
+++ b/sc/inc/stringutil.hxx
@@ -88,6 +88,13 @@ struct SAL_WARN_UNUSED SC_DLLPUBLIC ScSetStringParam
 
 sc::StartListeningType meStartListening;
 
+/** When true and the string results in a compiled formula, check the
+formula tokens for presence of functions that could trigger access to
+external resources. This is to be set to true in import filter code,
+but not for user input.
+ */
+bool mbCheckLinkFormula;
+
 ScSetStringParam();
 
 /**
diff --git a/sc/source/core/data/column3.cxx b/sc/source/core/data/column3.cxx
index 28445f7c469a..8e36534e8461 100644
--- a/sc/source/core/data/column3.cxx
+++ b/sc/source/core/data/column3.cxx
@@ -1721,11 +1721,15 @@ bool ScColumn::ParseString(
 rCell.set(rPool.intern(rString));
 }
 else // = Formula
-rCell.set(
-new ScFormulaCell(
+{
+ScFormulaCell* pFormulaCell = new ScFormulaCell(
 pDocument, ScAddress(nCol, nRow, nTabP), rString,
 
formula::FormulaGrammar::mergeToGrammar(formula::FormulaGrammar::GRAM_DEFAULT, 
eConv),
-ScMatrixMode::NONE));
+ScMatrixMode::NONE);
+if (aParam.mbCheckLinkFormula)
+pDocument->CheckLinkFormulaNeedingCheck( 
*pFormulaCell->GetCode());
+rCell.set( pFormulaCell);
+}
 }
 else if ( cFirstChar == '\'') // 'Text
 {
diff --git a/sc/source/core/tool/stringutil.cxx 
b/sc/source/core/tool/stringutil.cxx
index afcbe7412474..f52646c980af 100644
--- a/sc/source/core/tool/stringutil.cxx
+++ b/sc/source/core/tool/stringutil.cxx
@@ -30,7 +30,8 @@ ScSetStringParam::ScSetStringParam() :
 mbDetectNumberFormat(true),
 meSetTextNumFormat(Never),
 mbHandleApostrophe(true),
-meStartListening(sc::SingleCellListening)
+meStartListening(sc::SingleCellListening),
+mbCheckLinkFormula(false)
 {
 }
 
diff --git a/sc/source/filter/rtf/eeimpars.cxx 
b/sc/source/filter/rtf/eeimpars.cxx
index 0e6eab3bc56c..e0202ce7e6fe 100644
--- a/sc/source/filter/rtf/eeimpars.cxx
+++ b/sc/source/filter/rtf/eeimpars.cxx
@@ -330,6 +330,7 @@ void ScEEImport::WriteToDocument( bool bSizeColsRows, 
double nOutputFactor, SvNu
 aParam.mbDetectNumberFormat = true;
 aParam.meSetTextNumFormat = 
ScSetStringParam::SpecialNumberOnly;
 aParam.mbHandleApostrophe = false;
+aParam.mbCheckLinkFormula = true;
 
 if (!aValStr.isEmpty())
 mpDoc->SetValue( nCol, nRow, nTab, fVal );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Eike Rathke
 sc/inc/stringutil.hxx  |7 +++
 sc/source/core/data/column3.cxx|   10 +++---
 sc/source/core/tool/stringutil.cxx |3 ++-
 sc/source/filter/rtf/eeimpars.cxx  |1 +
 4 files changed, 17 insertions(+), 4 deletions(-)

New commits:
commit df72c65fdaf5f1276d1759ba3e7eec83eaaa2d20
Author: Eike Rathke 
Date:   Tue Feb 13 17:10:21 2018 +0100

ScSetStringParam::mbCheckLinkFormula for HTML and RTF import

 This is a combination of 3 commits.

Introduce ScSetStringParam::mbCheckLinkFormula

(cherry picked from commit 5a93c51e3b7f455ff5d4cfc9e8b6e510fc126b75)

Handle ScSetStringParam::mbCheckLinkFormula in ScColumn::ParseString()

(cherry picked from commit 271d9ebfe0c4fc57ea6f01a9c048021e5429dd15)

 Conflicts:
sc/source/core/data/column3.cxx

ScSetStringParam::mbCheckLinkFormula for HTML and RTF import

(cherry picked from commit 98c0bd7ffd008015623b2c5eb8630649394d76f6)

d6b0705140baacdb872560f7031efaf0c03f0e00
7cf7cf12142322cbffd5160e9a8dce55efd36be5

Change-Id: I2028fc53f9778606778cd8629611752acd3f1a1c
Reviewed-on: https://gerrit.libreoffice.org/49708
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/sc/inc/stringutil.hxx b/sc/inc/stringutil.hxx
index 005a99713f2f..a1ecbdd85c82 100644
--- a/sc/inc/stringutil.hxx
+++ b/sc/inc/stringutil.hxx
@@ -92,6 +92,13 @@ struct SAL_WARN_UNUSED SC_DLLPUBLIC ScSetStringParam
 
 sc::StartListeningType meStartListening;
 
+/** When true and the string results in a compiled formula, check the
+formula tokens for presence of functions that could trigger access to
+external resources. This is to be set to true in import filter code,
+but not for user input.
+ */
+bool mbCheckLinkFormula;
+
 ScSetStringParam();
 
 /**
diff --git a/sc/source/core/data/column3.cxx b/sc/source/core/data/column3.cxx
index 397fe3310087..730003196151 100644
--- a/sc/source/core/data/column3.cxx
+++ b/sc/source/core/data/column3.cxx
@@ -1722,11 +1722,15 @@ bool ScColumn::ParseString(
 rCell.set(rPool.intern(rString));
 }
 else // = Formula
-rCell.set(
-new ScFormulaCell(
+{
+ScFormulaCell* pFormulaCell = new ScFormulaCell(
 pDocument, ScAddress(nCol, nRow, nTabP), rString,
 
formula::FormulaGrammar::mergeToGrammar(formula::FormulaGrammar::GRAM_DEFAULT, 
eConv),
-ScMatrixMode::NONE));
+ScMatrixMode::NONE);
+if (aParam.mbCheckLinkFormula)
+pDocument->CheckLinkFormulaNeedingCheck( 
*pFormulaCell->GetCode());
+rCell.set( pFormulaCell);
+}
 }
 else if ( cFirstChar == '\'') // 'Text
 {
diff --git a/sc/source/core/tool/stringutil.cxx 
b/sc/source/core/tool/stringutil.cxx
index 8ac5a3a6a0d0..8ba3fd0a94ff 100644
--- a/sc/source/core/tool/stringutil.cxx
+++ b/sc/source/core/tool/stringutil.cxx
@@ -30,7 +30,8 @@ ScSetStringParam::ScSetStringParam() :
 mbDetectNumberFormat(true),
 meSetTextNumFormat(Never),
 mbHandleApostrophe(true),
-meStartListening(sc::SingleCellListening)
+meStartListening(sc::SingleCellListening),
+mbCheckLinkFormula(false)
 {
 }
 
diff --git a/sc/source/filter/rtf/eeimpars.cxx 
b/sc/source/filter/rtf/eeimpars.cxx
index 0214a78240d6..a3af0cb868b7 100644
--- a/sc/source/filter/rtf/eeimpars.cxx
+++ b/sc/source/filter/rtf/eeimpars.cxx
@@ -341,6 +341,7 @@ void ScEEImport::WriteToDocument( bool bSizeColsRows, 
double nOutputFactor, SvNu
 aParam.mbDetectNumberFormat = true;
 aParam.meSetTextNumFormat = 
ScSetStringParam::SpecialNumberOnly;
 aParam.mbHandleApostrophe = false;
+aParam.mbCheckLinkFormula = true;
 
 if (!aValStr.isEmpty())
 mpDoc->SetValue( nCol, nRow, nTab, fVal );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-5-4' - sc/source

2018-02-14 Thread Eike Rathke
 sc/source/core/data/documentimport.cxx |   20 ++--
 1 file changed, 18 insertions(+), 2 deletions(-)

New commits:
commit c9cfcd5f56fb2395a281df7466e5a2d9a2cf309e
Author: Eike Rathke 
Date:   Tue Feb 13 18:08:28 2018 +0100

CheckLinkFormulaNeedingCheck() for ScDocumentImport::setFormulaCell()

and ScDocumentImport::setMatrixCells()

 This is a combination of 2 commits.

CheckLinkFormulaNeedingCheck() for ScDocumentImport::setFormulaCell()

(cherry picked from commit bcd62f2050336951ad56892d6e0a42f63c59a674)

 Conflicts:
sc/source/core/data/documentimport.cxx

More CheckLinkFormulaNeedingCheck() for ScDocumentImport::setFormulaCell()

and ScDocumentImport::setMatrixCells()

(cherry picked from commit f41c14706c6bf8aa5c3df220c706669f1ec6e1f6)

 Conflicts:
sc/source/core/data/documentimport.cxx

d3303fb71889c760424459daa79feca0f2510a3c

Change-Id: I1587be914b390b2597185dd5af870d1d785010a4
Reviewed-on: https://gerrit.libreoffice.org/49735
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/sc/source/core/data/documentimport.cxx 
b/sc/source/core/data/documentimport.cxx
index 95d38ee08f51..c0e4d3c9e60f 100644
--- a/sc/source/core/data/documentimport.cxx
+++ b/sc/source/core/data/documentimport.cxx
@@ -25,6 +25,7 @@
 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -276,9 +277,14 @@ void ScDocumentImport::setFormulaCell(
 if (!pBlockPos)
 return;
 
+std::unique_ptr pFC =
+o3tl::make_unique(&mpImpl->mrDoc, rPos, rFormula, 
eGrammar);
+
+mpImpl->mrDoc.CheckLinkFormulaNeedingCheck( *pFC->GetCode());
+
 sc::CellStoreType& rCells = pTab->aCol[rPos.Col()].maCells;
 pBlockPos->miCellPos =
-rCells.set(pBlockPos->miCellPos, rPos.Row(), new 
ScFormulaCell(&mpImpl->mrDoc, rPos, rFormula, eGrammar));
+rCells.set(pBlockPos->miCellPos, rPos.Row(), pFC.release());
 }
 
 void ScDocumentImport::setFormulaCell(const ScAddress& rPos, ScTokenArray* 
pArray)
@@ -292,9 +298,14 @@ void ScDocumentImport::setFormulaCell(const ScAddress& 
rPos, ScTokenArray* pArra
 if (!pBlockPos)
 return;
 
+std::unique_ptr pFC =
+o3tl::make_unique(&mpImpl->mrDoc, rPos, pArray);
+
+mpImpl->mrDoc.CheckLinkFormulaNeedingCheck( *pFC->GetCode());
+
 sc::CellStoreType& rCells = pTab->aCol[rPos.Col()].maCells;
 pBlockPos->miCellPos =
-rCells.set(pBlockPos->miCellPos, rPos.Row(), new 
ScFormulaCell(&mpImpl->mrDoc, rPos, pArray));
+rCells.set(pBlockPos->miCellPos, rPos.Row(), pFC.release());
 }
 
 void ScDocumentImport::setFormulaCell(const ScAddress& rPos, ScFormulaCell* 
pCell)
@@ -308,6 +319,9 @@ void ScDocumentImport::setFormulaCell(const ScAddress& 
rPos, ScFormulaCell* pCel
 if (!pBlockPos)
 return;
 
+if (pCell)
+mpImpl->mrDoc.CheckLinkFormulaNeedingCheck( *pCell->GetCode());
+
 sc::CellStoreType& rCells = pTab->aCol[rPos.Col()].maCells;
 pBlockPos->miCellPos =
 rCells.set(pBlockPos->miCellPos, rPos.Row(), pCell);
@@ -332,6 +346,8 @@ void ScDocumentImport::setMatrixCells(
 // Set the master cell.
 ScFormulaCell* pCell = new ScFormulaCell(&mpImpl->mrDoc, rBasePos, rArray, 
eGram, ScMatrixMode::Formula);
 
+mpImpl->mrDoc.CheckLinkFormulaNeedingCheck( *pCell->GetCode());
+
 pBlockPos->miCellPos =
 rCells.set(pBlockPos->miCellPos, rBasePos.Row(), pCell);
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-6-0' - sc/source

2018-02-14 Thread Eike Rathke
 sc/source/core/data/documentimport.cxx |   20 ++--
 1 file changed, 18 insertions(+), 2 deletions(-)

New commits:
commit f4ba47543baf2b63444752ba08f4712d2806adef
Author: Eike Rathke 
Date:   Tue Feb 13 18:08:28 2018 +0100

CheckLinkFormulaNeedingCheck() for ScDocumentImport::setFormulaCell()

and ScDocumentImport::setMatrixCells()

 This is a combination of 2 commits.

CheckLinkFormulaNeedingCheck() for ScDocumentImport::setFormulaCell()

(cherry picked from commit bcd62f2050336951ad56892d6e0a42f63c59a674)

 Conflicts:
sc/source/core/data/documentimport.cxx

More CheckLinkFormulaNeedingCheck() for ScDocumentImport::setFormulaCell()

and ScDocumentImport::setMatrixCells()

(cherry picked from commit f41c14706c6bf8aa5c3df220c706669f1ec6e1f6)

 Conflicts:
sc/source/core/data/documentimport.cxx

d3303fb71889c760424459daa79feca0f2510a3c

Change-Id: I1587be914b390b2597185dd5af870d1d785010a4
Reviewed-on: https://gerrit.libreoffice.org/49732
Tested-by: Jenkins 
Reviewed-by: Markus Mohrhard 

diff --git a/sc/source/core/data/documentimport.cxx 
b/sc/source/core/data/documentimport.cxx
index 1062cc893cd7..713f72615ded 100644
--- a/sc/source/core/data/documentimport.cxx
+++ b/sc/source/core/data/documentimport.cxx
@@ -25,6 +25,7 @@
 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -278,9 +279,14 @@ void ScDocumentImport::setFormulaCell(
 if (!pBlockPos)
 return;
 
+std::unique_ptr pFC =
+o3tl::make_unique(&mpImpl->mrDoc, rPos, rFormula, 
eGrammar);
+
+mpImpl->mrDoc.CheckLinkFormulaNeedingCheck( *pFC->GetCode());
+
 sc::CellStoreType& rCells = pTab->aCol[rPos.Col()].maCells;
 pBlockPos->miCellPos =
-rCells.set(pBlockPos->miCellPos, rPos.Row(), new 
ScFormulaCell(&mpImpl->mrDoc, rPos, rFormula, eGrammar));
+rCells.set(pBlockPos->miCellPos, rPos.Row(), pFC.release());
 }
 
 void ScDocumentImport::setFormulaCell(const ScAddress& rPos, ScTokenArray* 
pArray)
@@ -294,9 +300,14 @@ void ScDocumentImport::setFormulaCell(const ScAddress& 
rPos, ScTokenArray* pArra
 if (!pBlockPos)
 return;
 
+std::unique_ptr pFC =
+o3tl::make_unique(&mpImpl->mrDoc, rPos, pArray);
+
+mpImpl->mrDoc.CheckLinkFormulaNeedingCheck( *pFC->GetCode());
+
 sc::CellStoreType& rCells = pTab->aCol[rPos.Col()].maCells;
 pBlockPos->miCellPos =
-rCells.set(pBlockPos->miCellPos, rPos.Row(), new 
ScFormulaCell(&mpImpl->mrDoc, rPos, pArray));
+rCells.set(pBlockPos->miCellPos, rPos.Row(), pFC.release());
 }
 
 void ScDocumentImport::setFormulaCell(const ScAddress& rPos, ScFormulaCell* 
pCell)
@@ -310,6 +321,9 @@ void ScDocumentImport::setFormulaCell(const ScAddress& 
rPos, ScFormulaCell* pCel
 if (!pBlockPos)
 return;
 
+if (pCell)
+mpImpl->mrDoc.CheckLinkFormulaNeedingCheck( *pCell->GetCode());
+
 sc::CellStoreType& rCells = pTab->aCol[rPos.Col()].maCells;
 pBlockPos->miCellPos =
 rCells.set(pBlockPos->miCellPos, rPos.Row(), pCell);
@@ -334,6 +348,8 @@ void ScDocumentImport::setMatrixCells(
 // Set the master cell.
 ScFormulaCell* pCell = new ScFormulaCell(&mpImpl->mrDoc, rBasePos, rArray, 
eGram, ScMatrixMode::Formula);
 
+mpImpl->mrDoc.CheckLinkFormulaNeedingCheck( *pCell->GetCode());
+
 pBlockPos->miCellPos =
 rCells.set(pBlockPos->miCellPos, rBasePos.Row(), pCell);
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Yousuf Philips
 officecfg/registry/data/org/openoffice/VCL.xcu |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit d501ff5f866994a86f8c8d34a5a08ee5b739fa7e
Author: Yousuf Philips 
Date:   Thu Feb 8 00:39:22 2018 +0400

tdf#113538 David CLM has higher priority to David Libre

Mistake from my earlier patch a2158c6ca2ba831665019827889f01e98dc93394

Change-Id: Id535ca2243e368fde9482ae9853f7ae6dd10a449
Reviewed-on: https://gerrit.libreoffice.org/49392
Reviewed-by: Lior Kaplan 
Tested-by: Jenkins 
Reviewed-by: Yousuf Philips 
(cherry picked from commit 9cf22b64183a341429aafac82c6562f869bc7383)
Reviewed-on: https://gerrit.libreoffice.org/49779
Reviewed-by: Adolfo Jayme Barrientos 

diff --git a/officecfg/registry/data/org/openoffice/VCL.xcu 
b/officecfg/registry/data/org/openoffice/VCL.xcu
index d759ef68509f..762f35d75c62 100644
--- a/officecfg/registry/data/org/openoffice/VCL.xcu
+++ b/officecfg/registry/data/org/openoffice/VCL.xcu
@@ -189,7 +189,7 @@
 Nachlieli CLM;Alef;Noto Sans Hebrew;Liberation Sans;Arial;Arial 
Hebrew;Lucida Sans Unicode;Lucida Grande;Arial Unicode MS
   
   
-David Libre;David CLM;Frank Ruehl CLM;Liberation 
Serif;David;Raanana;Lucida Sans Unicode;Lucida Grande;Arial Unicode MS
+David CLM;David Libre;Frank Ruehl CLM;Liberation 
Serif;David;Raanana;Lucida Sans Unicode;Lucida Grande;Arial Unicode MS
   
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Infra call on Tue, Feb 20 at 17:30 UTC

2018-02-14 Thread Guilhem Moulin
Hi there,

The next infra call will take place at `date -d 'Tue Feb 20 17:30:00 UTC 2018'`
(18:30:00 Berlin time).

See https://pad.documentfoundation.org/p/infra for details; agenda TBA.

See you there!
Cheers,
-- 
Guilhem.


signature.asc
Description: PGP signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2018-02-14 Thread Stephan Bergmann
 test/source/sheet/xfunctiondescriptions.cxx |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 09fcdbd5e0ae35fb7db8c8784329035edd82573b
Author: Stephan Bergmann 
Date:   Wed Feb 14 22:36:01 2018 +0100

Fix random range for XFunctionDescriptions::testGetById

...regression introduced with eff70347190a6642fd62a9e0b20e4366c39fbc7a
"tdf#45904 Move _XFunctionDescriptions Java test to C++" (where
java.util.Random.nextInt(n) returned a value 0 <= x < n), apparently causing
sporadic failures of CppunitTest_sc_functionlistobj like 

> ##Failure Location unknown## : Error
> Test name: sc_apitest::ScFunctionListObj::testGetById
> An uncaught exception of type com.sun.star.lang.IndexOutOfBoundsException

Also verify that nCount is not negative, so that the requirements of the
std::uniform_int_distribution ctor are guaranteed to be satisfied.

Change-Id: I90a5dc234fdd07f52fea69ae1d406f0818efb007

diff --git a/test/source/sheet/xfunctiondescriptions.cxx 
b/test/source/sheet/xfunctiondescriptions.cxx
index 12da126cb8d3..5a71f532a4be 100644
--- a/test/source/sheet/xfunctiondescriptions.cxx
+++ b/test/source/sheet/xfunctiondescriptions.cxx
@@ -30,12 +30,12 @@ void XFunctionDescriptions::testGetById()
 uno::Reference xFD(init(), UNO_QUERY_THROW);
 
 const sal_Int32 nCount = xFD->getCount();
-CPPUNIT_ASSERT_MESSAGE("No FunctionDescriptions available", 0 != nCount);
+CPPUNIT_ASSERT_MESSAGE("No FunctionDescriptions available", 0 < nCount);
 
 // first grab a random function descriptions
 std::random_device rd;
 std::mt19937 gen(rd());
-std::uniform_int_distribution<> distr(1, nCount);
+std::uniform_int_distribution<> distr(0, nCount - 1);
 int nNumber = distr(gen);
 
 sal_Int32 aId1 = 0;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Design session about listing of fonts

2018-02-14 Thread Caolán McNamara
On Wed, 2018-02-14 at 20:50 +0100, Heiko Tietze wrote:
> I presented first ideas at FOSDEM [3] that can
> be used as a draft.
> 
> [3] https://de.slideshare.net/HeikoTietze/improvements-to-font-
> handling-in-libreoffice

I believe the preview mock up previews the difference from the missing
font to the font its replaced with ? How would that get implemented in
the absence of the missing font ? Just for some small set of known
fonts with known metrics or something ?

As mostly an aside, but maybe worth mentioning to clarify how some of
this works under the hood, is that there is both "font substitution"
and "glyph substitution" going on. Font substitution is what's shown
here, LibreOffice asks for a font and gets a different one back because
the original is not available. IIRC the users overrides are used first
for font substitution, then under Linux fontconfig is asked. On the
other platforms the massive table of fonts listing in the config is
used to try and find something.

Added to the mix is the "Default" font which is listed in VCL.xcu and
is the font to use for various categories as the default document fonts
for a given language. These are lists per language and per category,
under fontconfig systems the first font is taken and if not available
fontconfig is asked for a replacement font based on the first entry,
which other platforms try the whole list until something crops up.

There are other substitution routes too, e.g. there's a specific route
to map known fonts to the closest matching font available in MSOffice,
e.g. when you write using Liberation Sans and save to .doc[x] the
recommended fallback of "Arial" is found on this route and set in those
file formats so the document gets rendered by MSOffice in Arial when
Liberation Sans is missing on the target system.

That's the relatively simple font substitution, in glyph substitution a
range of glyphs are discovered to not exist in the font (perhaps from
initial font substitution) at render time and libreoffice desperately
searches for something, anything, that can render the glyph. On windows
IIRC there's a bunch of hardcoded fonts to make an effort to find the
glyph in, while with fontconfig we throw the original font, missing
glyphs, size, slant, language etc at fontconfig and it does the work of
finding something. In extremis, if enabled, libreoffice will even
prompt via packagekit that a font for the language that the glyphs are
(probably) for get installed.

Which leads to straightforward things such as you can get a different
font for the missing glyphs if the language is Japanese vs Chinese. And
it can lead to awe inspiring things where different fonts are suggested
for the same missing glyphs at different sizes. You can even be asked
to substitute effectively the *same* font that the glyphs are missing
from, e.g. glyphs are missing from a bold font, but exist in the
regular version and fontconfig suggests using the regular version with
artificial emboldening. Glyph substitution is very exciting.
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2018-02-14 Thread Stephan Bergmann
 framework/source/helper/statusindicatorfactory.cxx |3 ++-
 framework/source/helper/wakeupthread.cxx   |1 +
 2 files changed, 3 insertions(+), 1 deletion(-)

New commits:
commit 57574c2bcc60d37620288c403267c34d960f5863
Author: Stephan Bergmann 
Date:   Wed Feb 14 13:21:40 2018 +0100

tdf#108005: Problems with progress bar while saving document

...as StatusIndicatorFactory::m_pWakeUp is still non-null after it has 
already
been used while loading the document.  Regression introduced with
017f250764ec7b4ecb82ac19f5b3f68cadf1bf56 "Ensure WakeUpThread is joined 
before
exit".

(Also, WakeUpThread::stop could take up to 25 msec longer than necessary, 
as it
failed to set condition_, so would always have waited for 
WakeUpThread::execute
to finish its next 25 msec condition_.wait call.)

Change-Id: Ic7fe15f1b90f3b8292cd2ceccdc2719a00743d44
Reviewed-on: https://gerrit.libreoffice.org/49718
Tested-by: Jenkins 
Reviewed-by: Stephan Bergmann 

diff --git a/framework/source/helper/statusindicatorfactory.cxx 
b/framework/source/helper/statusindicatorfactory.cxx
index fc4e04283fdf..1669bfea5068 100644
--- a/framework/source/helper/statusindicatorfactory.cxx
+++ b/framework/source/helper/statusindicatorfactory.cxx
@@ -18,6 +18,7 @@
  */
 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -547,7 +548,7 @@ void StatusIndicatorFactory::impl_stopWakeUpThread()
 rtl::Reference wakeUp;
 {
 osl::MutexGuard g(m_mutex);
-wakeUp = m_pWakeUp;
+std::swap(wakeUp, m_pWakeUp);
 }
 if (wakeUp.is())
 {
diff --git a/framework/source/helper/wakeupthread.cxx 
b/framework/source/helper/wakeupthread.cxx
index b13621225d21..503f6707a010 100644
--- a/framework/source/helper/wakeupthread.cxx
+++ b/framework/source/helper/wakeupthread.cxx
@@ -53,6 +53,7 @@ void framework::WakeUpThread::stop() {
 osl::MutexGuard g(mutex_);
 terminate_ = true;
 }
+condition_.set();
 join();
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Caolán McNamara
 filter/source/graphicfilter/ipsd/ipsd.cxx |7 +++
 1 file changed, 7 insertions(+)

New commits:
commit 65e14b6c5283244e4ba02a269879d82085d793e6
Author: Caolán McNamara 
Date:   Wed Feb 14 15:15:12 2018 +

ofz#6334 Out-of-memory

Change-Id: I714d4b3c767a2e9244e4d5a0b608e3d7fd3002a3
Reviewed-on: https://gerrit.libreoffice.org/49741
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/filter/source/graphicfilter/ipsd/ipsd.cxx 
b/filter/source/graphicfilter/ipsd/ipsd.cxx
index 9a658ed13a40..344dbb6d3e07 100644
--- a/filter/source/graphicfilter/ipsd/ipsd.cxx
+++ b/filter/source/graphicfilter/ipsd/ipsd.cxx
@@ -107,6 +107,13 @@ bool PSDReader::ReadPSD(Graphic & rGraphic )
 if ( !ImplReadHeader() )
 return false;
 
+if (mbStatus)
+{
+sal_uInt32 nResult;
+if (o3tl::checked_multiply(mpFileHeader->nColumns, 
mpFileHeader->nRows, nResult) || nResult > SAL_MAX_INT32/2/3)
+return false;
+}
+
 Size aBitmapSize( mpFileHeader->nColumns, mpFileHeader->nRows );
 mpBitmap.reset( new vcl::bitmap::RawBitmap( aBitmapSize ) );
 if ( mpPalette && mbStatus )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Caolán McNamara
 filter/source/graphicfilter/ieps/ieps.cxx |8 +++-
 filter/source/graphicfilter/itga/itga.cxx |2 +-
 2 files changed, 8 insertions(+), 2 deletions(-)

New commits:
commit 13fd5d44c1d528c23bcade92241016195c37c453
Author: Caolán McNamara 
Date:   Wed Feb 14 15:06:32 2018 +

ofz#6329 Out-of-memory

Change-Id: I42fef1609db1253bcf262ccf3cc86088ea6ca647
Reviewed-on: https://gerrit.libreoffice.org/49739
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/filter/source/graphicfilter/ieps/ieps.cxx 
b/filter/source/graphicfilter/ieps/ieps.cxx
index a2d94c45faac..e2b5b8e383ab 100644
--- a/filter/source/graphicfilter/ieps/ieps.cxx
+++ b/filter/source/graphicfilter/ieps/ieps.cxx
@@ -652,7 +652,13 @@ ipsGraphicImport( SvStream & rStream, Graphic & rGraphic, 
FilterConfigItem* )
 long nBitDepth = ImplGetNumber(pDest, nSecurityCount);
 long nScanLines = ImplGetNumber(pDest, nSecurityCount);
 pDest = ImplSearchEntry(pDest, reinterpret_cast("%"), nSecurityCount, 1);   // go to the first Scanline
-if (pDest && nWidth > 0 && nHeight > 0 && ( ( nBitDepth == 
1 ) || ( nBitDepth == 8 ) ) && nScanLines)
+bOk = pDest && nWidth > 0 && nHeight > 0 && ( ( nBitDepth 
== 1 ) || ( nBitDepth == 8 ) ) && nScanLines;
+if (bOk)
+{
+long nResult;
+bOk = !o3tl::checked_multiply(nWidth, nHeight, 
nResult) && nResult <= SAL_MAX_INT32/2/3;
+}
+if (bOk)
 {
 rStream.Seek( nBufStartPos + ( pDest - pBuf.get() ) );
 
diff --git a/filter/source/graphicfilter/itga/itga.cxx 
b/filter/source/graphicfilter/itga/itga.cxx
index 211537f34e67..28cfb8dd25b8 100644
--- a/filter/source/graphicfilter/itga/itga.cxx
+++ b/filter/source/graphicfilter/itga/itga.cxx
@@ -143,7 +143,7 @@ bool TGAReader::ReadTGA(Graphic & rGraphic)
 {
 sal_Size nSize = mpFileHeader->nImageWidth;
 nSize *= mpFileHeader->nImageHeight;
-if (nSize > SAL_MAX_INT32/2)
+if (nSize > SAL_MAX_INT32/2/3)
 return false;
 
 mpBitmap.reset( new vcl::bitmap::RawBitmap( Size( 
mpFileHeader->nImageWidth, mpFileHeader->nImageHeight ) ) );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Caolán McNamara
 filter/source/graphicfilter/ipcx/ipcx.cxx |8 +++-
 1 file changed, 7 insertions(+), 1 deletion(-)

New commits:
commit 369018cffb6d1c77e2fb4feec6a4df8a27872ec5
Author: Caolán McNamara 
Date:   Wed Feb 14 15:11:06 2018 +

ofz#6330 Out-of-memory

Change-Id: Ie138705e7994915d7824d8cf1ae1a0e17e247256
Reviewed-on: https://gerrit.libreoffice.org/49740
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/filter/source/graphicfilter/ipcx/ipcx.cxx 
b/filter/source/graphicfilter/ipcx/ipcx.cxx
index c06a5159ec5e..51b50be2fa56 100644
--- a/filter/source/graphicfilter/ipcx/ipcx.cxx
+++ b/filter/source/graphicfilter/ipcx/ipcx.cxx
@@ -40,7 +40,7 @@ private:
 sal_uLong   nPlanes;// no of planes
 sal_uLong   nBytesPerPlaneLin;  // bytes per plane line
 
-sal_uLong   nWidth, nHeight;// dimension in pixel
+sal_uInt32  nWidth, nHeight;// dimension in pixel
 sal_uInt16  nResX, nResY;   // resolution in pixel per inch or 
0,0
 sal_uInt16  nDestBitsPerPixel;  // bits per pixel in destination 
bitmap 1,4,8 or 24
 std::unique_ptr
@@ -96,6 +96,12 @@ bool PCXReader::ReadPCX(Graphic & rGraphic)
 bStatus = false;
 }
 
+if (bStatus)
+{
+sal_uInt32 nResult;
+bStatus = !o3tl::checked_multiply(nWidth, nHeight, nResult) && nResult 
<= SAL_MAX_INT32/2/3;
+}
+
 // Write BMP header and conditionally (maybe invalid for now) color 
palette:
 if (bStatus)
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Caolán McNamara
 filter/source/graphicfilter/itga/itga.cxx |4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit c11c1afe58e0b4a25aaf1fdcf7b865f1c85fa727
Author: Caolán McNamara 
Date:   Wed Feb 14 14:55:42 2018 +

ofz#6328 Abrt

Change-Id: I3bb4faa5b1b9361b4f29f55117d4317d5b1a66ec
Reviewed-on: https://gerrit.libreoffice.org/49737
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/filter/source/graphicfilter/itga/itga.cxx 
b/filter/source/graphicfilter/itga/itga.cxx
index f5c8a43b6993..211537f34e67 100644
--- a/filter/source/graphicfilter/itga/itga.cxx
+++ b/filter/source/graphicfilter/itga/itga.cxx
@@ -137,7 +137,9 @@ bool TGAReader::ReadTGA(Graphic & rGraphic)
 if ( !m_rTGA.GetError() )
 {
 mbStatus = ImplReadHeader();
-if ( mbStatus )
+if (mbStatus)
+mbStatus = mpFileHeader->nImageWidth && mpFileHeader->nImageHeight;
+if (mbStatus)
 {
 sal_Size nSize = mpFileHeader->nImageWidth;
 nSize *= mpFileHeader->nImageHeight;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Caolán McNamara
 filter/source/graphicfilter/itga/itga.cxx |5 +
 include/sal/log-areas.dox |1 +
 2 files changed, 6 insertions(+)

New commits:
commit 7f629f51df1f4fa37696c75e9d88b636b08baa0d
Author: Caolán McNamara 
Date:   Wed Feb 14 14:27:47 2018 +

ofz#6324 Out-of-memory

Change-Id: I3dae862da134ef32ec16a230bc40bef06ec2
Reviewed-on: https://gerrit.libreoffice.org/49734
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/filter/source/graphicfilter/itga/itga.cxx 
b/filter/source/graphicfilter/itga/itga.cxx
index e980e3c20925..f5c8a43b6993 100644
--- a/filter/source/graphicfilter/itga/itga.cxx
+++ b/filter/source/graphicfilter/itga/itga.cxx
@@ -139,6 +139,11 @@ bool TGAReader::ReadTGA(Graphic & rGraphic)
 mbStatus = ImplReadHeader();
 if ( mbStatus )
 {
+sal_Size nSize = mpFileHeader->nImageWidth;
+nSize *= mpFileHeader->nImageHeight;
+if (nSize > SAL_MAX_INT32/2)
+return false;
+
 mpBitmap.reset( new vcl::bitmap::RawBitmap( Size( 
mpFileHeader->nImageWidth, mpFileHeader->nImageHeight ) ) );
 if ( mbIndexing )
 mbStatus = ImplReadPalette();
diff --git a/include/sal/log-areas.dox b/include/sal/log-areas.dox
index 5c2ee4774143..f81eb0564c52 100644
--- a/include/sal/log-areas.dox
+++ b/include/sal/log-areas.dox
@@ -231,6 +231,7 @@ certain functionality.
 @li @c filter.pict
 @li @c filter.ras
 @li @c filter.svg
+@li @c filter.tga
 @li @c filter.tiff
 @li @c filter.xmlfa
 @li @c filter.xslt - xslt import/export
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Caolán McNamara
 filter/source/graphicfilter/ipbm/ipbm.cxx |   17 -
 1 file changed, 12 insertions(+), 5 deletions(-)

New commits:
commit b8bb1c259d2c2f493b5cb05dbe234472c0e41ddc
Author: Caolán McNamara 
Date:   Wed Feb 14 14:18:53 2018 +

ofz#6323 Abrt

Change-Id: Ia87b2430508648e6a77d291d4d86924bfc848ecc
Reviewed-on: https://gerrit.libreoffice.org/49729
Tested-by: Jenkins 
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/filter/source/graphicfilter/ipbm/ipbm.cxx 
b/filter/source/graphicfilter/ipbm/ipbm.cxx
index 686f32119a97..06f51d0e9bac 100644
--- a/filter/source/graphicfilter/ipbm/ipbm.cxx
+++ b/filter/source/graphicfilter/ipbm/ipbm.cxx
@@ -79,16 +79,17 @@ bool PBMReader::ReadPBM(Graphic & rGraphic )
 if ( ( mnMaxVal == 0 ) || ( mnWidth <= 0 ) || ( mnHeight <= 0 ) )
 return false;
 
+sal_uInt32 nPixelsRequired;
+if (o3tl::checked_multiply(mnWidth, mnHeight, nPixelsRequired))
+return false;
+const auto nRemainingSize = mrPBM.remainingSize();
+
 // 0->PBM, 1->PGM, 2->PPM
 switch ( mnMode )
 {
 case 0:
 {
-sal_uInt32 nDataRequired;
-if (o3tl::checked_multiply(mnWidth, mnHeight, 
nDataRequired))
-return false;
-const auto nRemainingSize = mrPBM.remainingSize();
-if (nRemainingSize < nDataRequired / 8)
+if (nRemainingSize < nPixelsRequired / 8)
 return false;
 
 mpRawBmp.reset( new vcl::bitmap::RawBitmap( Size( mnWidth, 
mnHeight ) ) );
@@ -98,6 +99,9 @@ bool PBMReader::ReadPBM(Graphic & rGraphic )
 break;
 }
 case 1 :
+if (nRemainingSize < nPixelsRequired)
+return false;
+
 mpRawBmp.reset( new vcl::bitmap::RawBitmap( Size( mnWidth, 
mnHeight ) ) );
 mnCol = static_cast(mnMaxVal) + 1;
 if ( mnCol > 256 )
@@ -111,6 +115,9 @@ bool PBMReader::ReadPBM(Graphic & rGraphic )
 }
 break;
 case 2 :
+if (nRemainingSize / 3 < nPixelsRequired)
+return false;
+
 mpRawBmp.reset( new vcl::bitmap::RawBitmap( Size( mnWidth, 
mnHeight ) ) );
 break;
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Caolán McNamara
 filter/source/graphicfilter/ipsd/ipsd.cxx |   35 --
 1 file changed, 29 insertions(+), 6 deletions(-)

New commits:
commit 625c53a428180092e343e45da8bb1242c8903314
Author: Caolán McNamara 
Date:   Wed Feb 14 14:50:27 2018 +

ofz#6326 Null-dereference

Change-Id: I97a8a06acc782dc6fb0baddf46332b18d19fecc4
Reviewed-on: https://gerrit.libreoffice.org/49736
Tested-by: Jenkins 
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/filter/source/graphicfilter/ipsd/ipsd.cxx 
b/filter/source/graphicfilter/ipsd/ipsd.cxx
index e254b1946be0..9a658ed13a40 100644
--- a/filter/source/graphicfilter/ipsd/ipsd.cxx
+++ b/filter/source/graphicfilter/ipsd/ipsd.cxx
@@ -117,6 +117,13 @@ bool PSDReader::ReadPSD(Graphic & rGraphic )
 mvPalette[i] = Color( mpPalette[ i ], mpPalette[ i + 256 ], 
mpPalette[ i + 512 ] );
 }
 }
+
+if ((mnDestBitDepth == 1 || mnDestBitDepth == 8) && mvPalette.empty())
+{
+mbStatus = false;
+return mbStatus;
+}
+
 // read bitmap data
 if ( mbStatus && ImplReadBody() )
 {
@@ -301,6 +308,22 @@ bool PSDReader::ImplReadHeader()
 return true;
 }
 
+namespace
+{
+const Color& SanitizePaletteIndex(std::vector const & rvPalette, 
sal_uInt8 nIndex)
+{
+if (nIndex >= rvPalette.size())
+{
+auto nSanitizedIndex = nIndex % rvPalette.size();
+SAL_WARN_IF(nIndex != nSanitizedIndex, "filter.tga", "invalid 
colormap index: "
+<< static_cast(nIndex) << ", colormap 
len is: "
+<< rvPalette.size());
+nIndex = nSanitizedIndex;
+}
+return rvPalette[nIndex];
+}
+}
+
 bool PSDReader::ImplReadBody()
 {
 sal_uLong   nX, nY;
@@ -336,7 +359,7 @@ bool PSDReader::ImplReadBody()
 nDat ^= 0xff;
 nBitCount = 7;
 }
-mpBitmap->SetPixel( nY, nX, mvPalette[nDat >> 
nBitCount--] );
+mpBitmap->SetPixel(nY, nX, 
SanitizePaletteIndex(mvPalette, nDat >> nBitCount--));
 if ( ++nX == mpFileHeader->nColumns )
 {
 nX = 0;
@@ -358,7 +381,7 @@ bool PSDReader::ImplReadBody()
 nDat ^= 0xff;
 nBitCount = 7;
 }
-mpBitmap->SetPixel( nY, nX, mvPalette[nDat >> 
nBitCount--] );
+mpBitmap->SetPixel(nY, nX, 
SanitizePaletteIndex(mvPalette, nDat >> nBitCount--));
 if ( ++nX == mpFileHeader->nColumns )
 {
 nX = 0;
@@ -392,7 +415,7 @@ bool PSDReader::ImplReadBody()
 const sal_uInt16 nCount = -nRunCount + 1;
 for (sal_uInt16 i = 0; i < nCount && m_rPSD.good(); ++i)
 {
-mpBitmap->SetPixel( nY, nX, mvPalette[nDat] );
+mpBitmap->SetPixel(nY, nX, 
SanitizePaletteIndex(mvPalette, nDat));
 if ( ++nX == mpFileHeader->nColumns )
 {
 nX = 0;
@@ -410,7 +433,7 @@ bool PSDReader::ImplReadBody()
 m_rPSD.ReadUChar( nDat );
 if ( mpFileHeader->nDepth == 16 )   // 16 bit depth is 
to be skipped
 m_rPSD.ReadUChar( nDummy );
-mpBitmap->SetPixel( nY, nX, mvPalette[nDat] );
+mpBitmap->SetPixel(nY, nX, 
SanitizePaletteIndex(mvPalette, nDat));
 if ( ++nX == mpFileHeader->nColumns )
 {
 nX = 0;
@@ -688,7 +711,7 @@ bool PSDReader::ImplReadBody()
 m_rPSD.ReadUChar( nDummy );
 for ( sal_uInt16 i = 0; i < ( -nRunCount + 1 ); i++ )
 {
-mpBitmap->SetPixel( nY, nX, mvPalette[nDat] );
+mpBitmap->SetPixel(nY, nX, SanitizePaletteIndex(mvPalette, 
nDat));
 if ( ++nX == mpFileHeader->nColumns )
 {
 nX = 0;
@@ -709,7 +732,7 @@ bool PSDReader::ImplReadBody()
 nDat = 1;
 if ( mpFileHeader->nDepth == 16 )   // 16 bit depth is to 
be skipped
 m_rPSD.ReadUChar( nDummy );
-mpBitmap->SetPixel( nY, nX, mvPalette[nDat] );
+mpBitmap->SetPixel(nY, nX, SanitizePaletteIndex(mvPalette, 
nDat));
 if ( ++nX == mpFileHeader->nColumns )
 {
 nX = 0;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Caolán McNamara
 sw/source/core/unocore/unofield.cxx |  150 ++--
 1 file changed, 75 insertions(+), 75 deletions(-)

New commits:
commit e8508d1db58da7cb5901fa7d63c8f04da667f2f0
Author: Caolán McNamara 
Date:   Wed Feb 14 12:58:30 2018 +

ofz#6321 Direct-leak

Change-Id: I27214b1fd293885e33c95ffad854ba491d98c044
Reviewed-on: https://gerrit.libreoffice.org/49724
Reviewed-by: Julien Nabet 
Tested-by: Jenkins 

diff --git a/sw/source/core/unocore/unofield.cxx 
b/sw/source/core/unocore/unofield.cxx
index db1cc9b3e378..9696663301fa 100644
--- a/sw/source/core/unocore/unofield.cxx
+++ b/sw/source/core/unocore/unofield.cxx
@@ -1324,7 +1324,7 @@ void SAL_CALL SwXTextField::attach(
 SwUnoInternalPaM aPam(*pDoc);
 // this now needs to return TRUE
 ::sw::XTextRangeToSwPaM(aPam, xTextRange);
-SwField* pField = nullptr;
+std::unique_ptr xField;
 switch (m_pImpl->m_nServiceId)
 {
 case SwServiceType::FieldTypeAnnotation:
@@ -1348,15 +1348,15 @@ void SAL_CALL SwXTextField::attach(
 pPostItField->SetTextObject( 
m_pImpl->m_xTextObject->CreateText() );
 pPostItField->SetPar2(m_pImpl->m_xTextObject->GetText());
 }
-pField = pPostItField;
+xField.reset(pPostItField);
 }
 break;
 case SwServiceType::FieldTypeScript:
 {
 SwFieldType* pFieldType = 
pDoc->getIDocumentFieldsAccess().GetSysFieldType(SwFieldIds::Script);
-pField = new 
SwScriptField(static_cast(pFieldType),
+xField.reset(new 
SwScriptField(static_cast(pFieldType),
 m_pImpl->m_pProps->sPar1, m_pImpl->m_pProps->sPar2,
-m_pImpl->m_pProps->bBool1);
+m_pImpl->m_pProps->bBool1));
 }
 break;
 case SwServiceType::FieldTypeDateTime:
@@ -1372,7 +1372,7 @@ void SAL_CALL SwXTextField::attach(
 SwDateTimeField *const pDTField = new SwDateTimeField(
 static_cast(pFieldType),
 nSub, m_pImpl->m_pProps->nFormat);
-pField = pDTField;
+xField.reset(pDTField);
 if (m_pImpl->m_pProps->fDouble > 0.)
 {
 pDTField->SetValue(m_pImpl->m_pProps->fDouble);
@@ -1380,7 +1380,7 @@ void SAL_CALL SwXTextField::attach(
 if (m_pImpl->m_pProps->pDateTime)
 {
 uno::Any aVal; aVal <<= *m_pImpl->m_pProps->pDateTime;
-pField->PutValue( aVal, FIELD_PROP_DATE_TIME );
+xField->PutValue( aVal, FIELD_PROP_DATE_TIME );
 }
 pDTField->SetOffset(m_pImpl->m_pProps->nSubType);
 }
@@ -1393,22 +1393,22 @@ void SAL_CALL SwXTextField::attach(
 nFormat |= FF_FIXED;
 SwFileNameField *const pFNField = new SwFileNameField(
 static_cast(pFieldType), nFormat);
-pField = pFNField;
+xField.reset(pFNField);
 if (!m_pImpl->m_pProps->sPar3.isEmpty())
 pFNField->SetExpansion(m_pImpl->m_pProps->sPar3);
 uno::Any aFormat;
 aFormat <<= m_pImpl->m_pProps->nFormat;
-pField->PutValue( aFormat, FIELD_PROP_FORMAT );
+xField->PutValue( aFormat, FIELD_PROP_FORMAT );
 }
 break;
 case SwServiceType::FieldTypeTemplateName:
 {
 SwFieldType* pFieldType = 
pDoc->getIDocumentFieldsAccess().GetSysFieldType(SwFieldIds::TemplateName);
-pField = new 
SwTemplNameField(static_cast(pFieldType),
-m_pImpl->m_pProps->nFormat);
+xField.reset(new 
SwTemplNameField(static_cast(pFieldType),
+m_pImpl->m_pProps->nFormat));
 uno::Any aFormat;
 aFormat <<= m_pImpl->m_pProps->nFormat;
-pField->PutValue(aFormat, FIELD_PROP_FORMAT);
+xField->PutValue(aFormat, FIELD_PROP_FORMAT);
 }
 break;
 case SwServiceType::FieldTypeChapter:
@@ -1417,11 +1417,11 @@ void SAL_CALL SwXTextField::attach(
 SwChapterField *const pChapterField = new SwChapterField(
 static_cast(pFieldType),
 m_pImpl->m_pProps->nUSHORT1);
-pField = pChapterField;
+xField.reset(pChapterField);
 pChapterField->SetLevel(m_pImpl->m_pProps->nByte1);
 uno::Any aVal;
 aVal <<= static_cast(m_pImpl->m_pProps->nUSHORT1);
-pField->PutValue(aVal, FIELD_PROP_USHORT1 );
+xField->PutValue(aVal, FIELD_PROP_USHORT1 );
 }
 break;
 case SwServiceType::FieldTypeAuthor:
@@ -1433,7 +1433,7 @@ void SAL_CALL SwXTextField::attach(
 SwFieldType* pFieldType = 
pDoc->getIDocumentFieldsAccess().GetSysFieldType(SwFieldIds::Author);
 SwAuthorField *const

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

2018-02-14 Thread Yousuf Philips
 officecfg/registry/data/org/openoffice/VCL.xcu |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 9cf22b64183a341429aafac82c6562f869bc7383
Author: Yousuf Philips 
Date:   Thu Feb 8 00:39:22 2018 +0400

tdf#113538 David CLM has higher priority to David Libre

Mistake from my earlier patch a2158c6ca2ba831665019827889f01e98dc93394

Change-Id: Id535ca2243e368fde9482ae9853f7ae6dd10a449
Reviewed-on: https://gerrit.libreoffice.org/49392
Reviewed-by: Lior Kaplan 
Tested-by: Jenkins 
Reviewed-by: Yousuf Philips 

diff --git a/officecfg/registry/data/org/openoffice/VCL.xcu 
b/officecfg/registry/data/org/openoffice/VCL.xcu
index ab30b58d755d..0e6777f47a93 100644
--- a/officecfg/registry/data/org/openoffice/VCL.xcu
+++ b/officecfg/registry/data/org/openoffice/VCL.xcu
@@ -189,7 +189,7 @@
 Nachlieli CLM;Alef;Noto Sans Hebrew;Liberation Sans;Arial;Arial 
Hebrew;Lucida Sans Unicode;Lucida Grande;Arial Unicode MS
   
   
-David Libre;David CLM;Frank Ruehl CLM;Liberation 
Serif;David;Raanana;Lucida Sans Unicode;Lucida Grande;Arial Unicode MS
+David CLM;David Libre;Frank Ruehl CLM;Liberation 
Serif;David;Raanana;Lucida Sans Unicode;Lucida Grande;Arial Unicode MS
   
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Design session about listing of fonts

2018-02-14 Thread Heiko Tietze
Hi all,

font handling is a major nuisance [1]. Users struggle with font substitution, 
listing, and customization. For the first issue, the UX team made a proposal at 
[2] and now we want to discuss solutions for the other two topics. I presented 
first ideas at FOSDEM [3] that can be used as a draft.

Session will be on Friday 2018-Feb-16 at 7pm UTC (20:00 GMT+1) via Jitsi 
https://meet.jit.si/LibreOfficeDesign. 

Everyone is welcome to join. Of course we will blog about the outcome.

Cheers,
Heiko

[1] https://bugs.documentfoundation.org/show_bug.cgi?id=102985
[2] 
https://design.blog.documentfoundation.org/2016/10/21/dealing-with-missing-fonts/
[3] 
https://de.slideshare.net/HeikoTietze/improvements-to-font-handling-in-libreoffice



signature.asc
Description: OpenPGP digital signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2018-02-14 Thread Miklos Vajna
 desktop/source/app/app.cxx |4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit 4322b69dfcce61ff962be42189dff8ad610ef20e
Author: Miklos Vajna 
Date:   Wed Feb 14 10:42:02 2018 +0100

desktop: allow disabling recovery via config key

The documentation suggests this should disable recovery, so read the
config value at the same place where we disable recovery due to the
environment variable.

Change-Id: I342ae58201aa1d731a5913c2f0598ddff2a8d602
Reviewed-on: https://gerrit.libreoffice.org/49706
Tested-by: Jenkins 
Reviewed-by: Miklos Vajna 

diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index d3eadd1d4987..d00adb195ac0 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -2044,7 +2044,9 @@ void Desktop::OpenClients()
 bool bCrashed= false;
 bool bExistsRecoveryData = false;
 bool bExistsSessionData  = false;
-bool const bDisableRecovery = getenv("OOO_DISABLE_RECOVERY") != 
nullptr;
+bool const bDisableRecovery
+= getenv("OOO_DISABLE_RECOVERY") != nullptr
+  || !officecfg::Office::Recovery::RecoveryInfo::Enabled::get();
 
 impl_checkRecoveryState(bCrashed, bExistsRecoveryData, 
bExistsSessionData);
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Minutes from the design meeting 2018-Feb-14

2018-02-14 Thread Heiko Tietze
Present: Jay, Heiko (not enough to make decisions)

 * GSoC project "100 paper cuts"
   + top 10 of UX nitpicks to fix in a gsoc project
   + Initial idea: 
http://nabble.documentfoundation.org/Re-Minutes-of-the-design-meeting-2018-Jan-31-td4232034.html
   + Collection for voting: 
https://nextcloud.documentfoundation.org/s/zraEHZxyCKBTNY7
 => no further ideas so far, meaning no interest? please add your favorite 
UX pet

 * New bitmaps for the Gallery
   + Issue: https://bugs.documentfoundation.org/show_bug.cgi?id=114817
   + Poll: 
https://docs.google.com/spreadsheets/d/1O0-09bhr0dHQ3VQTED2wFM9WBgEY5v-4VM7iMSS4BVY
   + Patch: https://gerrit.libreoffice.org/#/c/49551/
 + decision on l10n pending
 => comments welcome



signature.asc
Description: OpenPGP digital signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2018-02-14 Thread Miklos Vajna
 sw/qa/extras/ooxmlexport/data/tdf115719.docx |binary
 sw/qa/extras/ooxmlexport/ooxmlexport11.cxx   |7 +
 writerfilter/source/dmapper/DomainMapperTableHandler.cxx |   30 --
 writerfilter/source/dmapper/DomainMapper_Impl.cxx|   17 +++
 writerfilter/source/dmapper/DomainMapper_Impl.hxx|   16 +++
 writerfilter/source/dmapper/PropertyMap.cxx  |   68 +++
 writerfilter/source/dmapper/PropertyMap.hxx  |4 
 writerfilter/source/dmapper/SettingsTable.cxx|   27 +
 writerfilter/source/dmapper/SettingsTable.hxx|2 
 9 files changed, 142 insertions(+), 29 deletions(-)

New commits:
commit 8b73bafbc18acb4dd8911d2f2de8158d98eb6144
Author: Miklos Vajna 
Date:   Wed Feb 14 15:31:35 2018 +0100

tdf#115719 DOCX import: increase paragraph spacing for anchored objects

... like Word 2013 does, when the version string indicates that the new
layout is wanted.

An alternative to this change would be to add a new sw layout
compatibility flag and handle this at a layout level (somewhere in
SwAnchoredObject::GetObjRectWithSpaces()). The downside of that approach
is that once a layout flag is added, it's not preferred to tweak its
behavior, while doing the same at import time is not a problem.

Also it's better to have a flag for something which has clear behavior
in some spec / implementer notes, which is not the case for this
problem. (I've mailed dochelp@microsoft, no answer so far.)

Change-Id: Ibad28d27e4bcbe1991a3be1c686064e18e9ffa4d
Reviewed-on: https://gerrit.libreoffice.org/49733
Reviewed-by: Miklos Vajna 
Tested-by: Jenkins 

diff --git a/sw/qa/extras/ooxmlexport/data/tdf115719.docx 
b/sw/qa/extras/ooxmlexport/data/tdf115719.docx
new file mode 100644
index ..9519a2a14524
Binary files /dev/null and b/sw/qa/extras/ooxmlexport/data/tdf115719.docx differ
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx 
b/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx
index 134576b6275c..661a6a7597e0 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx
@@ -101,6 +101,13 @@ DECLARE_OOXMLEXPORT_TEST(testTdf67207_MERGEFIELD, 
"mailmerge.docx")
 
CPPUNIT_ASSERT_EQUAL(OUString("com.sun.star.text.fieldmaster.DataBase.Name"), 
sValue);
 }
 
+DECLARE_OOXMLEXPORT_TEST(testTdf115719, "tdf115719.docx")
+{
+// This was a single page, instead of pushing the textboxes to the second
+// page.
+CPPUNIT_ASSERT_EQUAL(2, getPages());
+}
+
 DECLARE_OOXMLEXPORT_TEST(testParagraphSplitOnSectionBorder, 
"parasplit-on-section-border.odt")
 {
 xmlDocPtr pXmlDoc = parseExport("word/document.xml");
diff --git a/writerfilter/source/dmapper/DomainMapperTableHandler.cxx 
b/writerfilter/source/dmapper/DomainMapperTableHandler.cxx
index 5fd55f41..851dba8e165e 100644
--- a/writerfilter/source/dmapper/DomainMapperTableHandler.cxx
+++ b/writerfilter/source/dmapper/DomainMapperTableHandler.cxx
@@ -312,34 +312,6 @@ void 
lcl_DecrementHoriOrientPosition(std::vector& rFramePr
 }
 }
 
-sal_Int32 lcl_getWordCompatibilityMode( const css::uno::Sequence< 
css::beans::PropertyValue >& rCompatSettings )
-{
-for ( int i = 0; i < rCompatSettings.getLength(); ++i )
-{
-const css::beans::PropertyValue& rProp = rCompatSettings[i];
-if ( rProp.Name == "compatSetting" )
-{
-css::uno::Sequence< css::beans::PropertyValue > 
aCurrentCompatSettings;
-rProp.Value >>= aCurrentCompatSettings;
-
-OUString sName;
-OUString sUri;
-OUString sVal;
-
-aCurrentCompatSettings[0].Value >>= sName;
-aCurrentCompatSettings[1].Value >>= sUri;
-aCurrentCompatSettings[2].Value >>= sVal;
-
-if ( sName == "compatibilityMode" && sUri == 
"http://schemas.microsoft.com/office/word"; )
-{
-return sVal.toInt32();
-}
-}
-}
-
-return -1; // Word compatibility mode not found
-}
-
 TableStyleSheetEntry * 
DomainMapperTableHandler::endTableGetTableStyle(TableInfo & rInfo, 
std::vector& rFrameProperties)
 {
 // will receive the table style if any
@@ -574,7 +546,7 @@ TableStyleSheetEntry * 
DomainMapperTableHandler::endTableGetTableStyle(TableInfo
 
 // tdf#106742: since MS Word 2013 (compatibilityMode >= 15), top-level 
tables are handled the same as nested tables;
 // this is also the default behavior in LO when DOCX doesn't define 
"compatibilityMode" option
-sal_Int32 nMode = lcl_getWordCompatibilityMode( 
m_rDMapper_Impl.GetSettingsTable()->GetCompatSettings() );
+sal_Int32 nMode = 
m_rDMapper_Impl.GetSettingsTable()->GetWordCompatibilityMode();
 
 if ( nMode > 0 && nMode <= 14 && rInfo.nNestLevel == 1 )
 {
diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.cxx 
b/writerfilter/source/dmapper/

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

2018-02-14 Thread Rene Engelhard
 sysui/desktop/apparmor/program.soffice.bin |9 +
 1 file changed, 9 insertions(+)

New commits:
commit b13678b1e1d6f4cac548ae7e088b6030c31cf081
Author: Rene Engelhard 
Date:   Wed Feb 14 20:18:11 2018 +0100

initial apparmor stuff for lo_kde5filepicker

Change-Id: I310f44bb7145449560aa28d5b33272ece0b307c2

diff --git a/sysui/desktop/apparmor/program.soffice.bin 
b/sysui/desktop/apparmor/program.soffice.bin
index 4fafdd9a8b5b..3a18e7e1c13e 100644
--- a/sysui/desktop/apparmor/program.soffice.bin
+++ b/sysui/desktop/apparmor/program.soffice.bin
@@ -188,4 +188,13 @@ profile libreoffice-soffice INSTDIR-program/soffice.bin {
 
 owner @{HOME}/.gnupg/* r,
   }
+
+  # probably should become a subprofile like gpg above, but then it doesn't
+  # work either as it tries to access stuff only allowed above...
+  owner @{HOME}/.config/kdeglobals r,
+  /usr/lib/libreoffice/program/lo_kde5filepicker rPUx,
+  /usr/share/qt5/translations/* r,
+  /usr/lib/*/qt5/plugins/** rm,
+  /usr/share/plasma/look-and-feel/**/contents/defaults r,
+
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: How to disable libexttextcat?

2018-02-14 Thread David Tardon
Hello,

On Wed, 2018-02-14 at 18:19 +0100, Sander Maijers wrote:
> Building fails for me because of this issue 
> https://github.com/LibreOffice/libexttextcat/issues/2 .
> 
> libexttextcat does not seem like a critical component for a slimmed
> down 
> LibreOffice build for development purposes. May I disable this 
> dependency, and if so, how?

No, you can't. LibreOffice does have a bazillion of dependencies.
Adding flags to disable each one of them separately would only make the
situation worse, as most of the combinations would be never or rarely
used and likely broken. We need less configure options, not more.

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


Re: Non-portable configure.ac

2018-02-14 Thread Tor Lillqvist
On what OS is this? If Linux, what distro? Debian has dash as /bin/sh, but
there are plenty of people building LibreOffice on Debian that haven't
reported this issue. What configuration parameters do pass to autogen.sh
(or ./configure)? Is this related to what PRODUCTNAME_WITHOUT_SPACES ends
up containing in config_host.mk? Do you use a
--with-product-name="Something With Spaces" option?

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


[Libreoffice-commits] online.git: 2 commits - kit/ChildSession.cpp loleaflet/src

2018-02-14 Thread Pranav Kant
 kit/ChildSession.cpp   |   12 ++-
 loleaflet/src/control/Control.LokDialog.js |   93 +++--
 loleaflet/src/layer/tile/TileLayer.js  |5 +
 loleaflet/src/map/handler/Map.Keyboard.js  |   33 +-
 4 files changed, 107 insertions(+), 36 deletions(-)

New commits:
commit 199b582e06a3234a1803553bf5be88c4d462ffc6
Author: Pranav Kant 
Date:   Wed Feb 14 18:11:31 2018 +0530

Use real input element for user input instead of canvas

This allows moving the IME candidate window according to where the
cursor in the lok dialog is.

Change-Id: Icf17f1fc1d3f6af619c8e0037c32109d2b4721fc

diff --git a/loleaflet/src/control/Control.LokDialog.js 
b/loleaflet/src/control/Control.LokDialog.js
index e6c92e77..20fe4b74 100644
--- a/loleaflet/src/control/Control.LokDialog.js
+++ b/loleaflet/src/control/Control.LokDialog.js
@@ -2,7 +2,7 @@
  * L.Control.LokDialog used for displaying LOK dialogs
  */
 
-/* global $ map */
+/* global $ map L */
 L.Control.LokDialog = L.Control.extend({
 
dialogIdPrefix: 'lokdialog-',
@@ -145,12 +145,7 @@ L.Control.LokDialog = L.Control.extend({
var y = parseInt(rectangle[1]);
height = parseInt(rectangle[3]);
 
-   var dialogCursor = L.DomUtil.get(strDlgId + 
'-cursor');
-   L.DomUtil.setStyle(dialogCursor, 'height', 
height + 'px');
-   L.DomUtil.setStyle(dialogCursor, 'display', 
this._dialogs[e.id].cursorVisible ? 'block' : 'none');
-   // set the position of the cursor container 
element
-   L.DomUtil.setStyle(this._dialogs[e.id].cursor, 
'left', x + 'px');
-   L.DomUtil.setStyle(this._dialogs[e.id].cursor, 
'top', y + 'px');
+   this._updateDialogCursor(e.id, x, y, height);
}
} else if (e.action === 'title_changed') {
if (e.title && this._dialogs[parseInt(e.id)]) {
@@ -176,7 +171,20 @@ L.Control.LokDialog = L.Control.extend({
this._map.sendUnoCommand(e.uno);
},
 
-   _launchDialogCursor: function(dialogId) {
+   _updateDialogCursor: function(dlgId, x, y, height) {
+   var strDlgId = this._toDlgPrefix(dlgId);
+   var dialogCursor = L.DomUtil.get(strDlgId + '-cursor');
+   L.DomUtil.setStyle(dialogCursor, 'height', height + 'px');
+   L.DomUtil.setStyle(dialogCursor, 'display', 
this._dialogs[dlgId].cursorVisible ? 'block' : 'none');
+   // set the position of the cursor container element
+   L.DomUtil.setStyle(this._dialogs[dlgId].cursor, 'left', x + 
'px');
+   L.DomUtil.setStyle(this._dialogs[dlgId].cursor, 'top', y + 
'px');
+
+   // update the input as well
+   this._updateDialogInput(dlgId);
+   },
+
+   _createDialogCursor: function(dialogId) {
var id = this._toRawDlgId(dialogId);
this._dialogs[id].cursor = L.DomUtil.create('div', 
'leaflet-cursor-container', L.DomUtil.get(dialogId));
var cursor = L.DomUtil.create('div', 'leaflet-cursor 
lokdialog-cursor', this._dialogs[id].cursor);
@@ -184,6 +192,39 @@ L.Control.LokDialog = L.Control.extend({
L.DomUtil.addClass(cursor, 'blinking-cursor');
},
 
+   _createDialogInput: function(dialogId) {
+   var id = this._toRawDlgId(dialogId);
+   var clipDlgContainer = L.DomUtil.create('div', 
'clipboard-container', L.DomUtil.get(dialogId));
+   clipDlgContainer.id = dialogId + '-clipboard-container';
+   var dlgTextArea = L.DomUtil.create('input', 'clipboard', 
clipDlgContainer);
+   dlgTextArea.setAttribute('type', 'text');
+   dlgTextArea.setAttribute('autocorrect', 'off');
+   dlgTextArea.setAttribute('autocapitalize', 'off');
+   dlgTextArea.setAttribute('autocomplete', 'off');
+   dlgTextArea.setAttribute('spellcheck', 'false');
+   this._dialogs[id].input = dlgTextArea;
+
+   return dlgTextArea;
+   },
+
+   _updateDialogInput: function(dlgId) {
+   if (!this._dialogs[dlgId].input)
+   return;
+
+   var strDlgId = this._toDlgPrefix(dlgId);
+   var left = 
parseInt(L.DomUtil.getStyle(this._dialogs[dlgId].cursor, 'left'));
+   var top = 
parseInt(L.DomUtil.getStyle(this._dialogs[dlgId].cursor, 'top'));
+   var dlgContainer = L.DomUtil.get(strDlgId + 
'-clipboard-container');
+   L.DomUtil.setPosition(dlgContainer, new L.Point(left, top));
+   },
+
+   focus: function(dlgId) {
+   if (!this._isOpen(dlgId) || !this._dialogs[dlgId].input)
+   return;
+
+

[Libreoffice-commits] core.git: desktop/source include/LibreOfficeKit include/vcl sc/inc sc/qa sc/source sd/qa sd/source sw/inc sw/qa sw/source vcl/source

2018-02-14 Thread Pranav Kant
 desktop/source/lib/init.cxx|   36 +
 include/LibreOfficeKit/LibreOfficeKit.h|1 
 include/LibreOfficeKit/LibreOfficeKit.hxx  |6 ++--
 include/vcl/ITiledRenderable.hxx   |   12 +++-
 sc/inc/docuno.hxx  |6 ++--
 sc/qa/unit/tiledrendering/tiledrendering.cxx   |6 ++--
 sc/source/ui/unoobj/docuno.cxx |   34 ++-
 sd/qa/unit/tiledrendering/tiledrendering.cxx   |6 ++--
 sd/source/ui/inc/unomodel.hxx  |3 --
 sd/source/ui/unoidl/unomodel.cxx   |   36 ++---
 sw/inc/unotxdoc.hxx|4 +-
 sw/qa/extras/tiledrendering/tiledrendering.cxx |6 ++--
 sw/source/uibase/uno/unotxdoc.cxx  |   30 ++--
 vcl/source/window/window.cxx   |8 -
 14 files changed, 96 insertions(+), 98 deletions(-)

New commits:
commit 712540224d7c5c8cdb4a5214e2d7963a314c1928
Author: Pranav Kant 
Date:   Wed Feb 14 17:33:16 2018 +0530

lok IME: support dialogs as well

Change-Id: Ic78da45dadaa5a4e1ca78e20d04974108581121e
Reviewed-on: https://gerrit.libreoffice.org/49714
Tested-by: Jenkins 
Reviewed-by: pranavk 

diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index bc788d243b9e..8d0611c21d07 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -543,6 +543,7 @@ static void doc_postKeyEvent(LibreOfficeKitDocument* pThis,
  int nCharCode,
  int nKeyCode);
 static void doc_postExtTextInputEvent(LibreOfficeKitDocument* pThis,
+  unsigned nWindowId,
   int nType,
   const char* pText);
 static void doc_postWindowKeyEvent(LibreOfficeKitDocument* pThis,
@@ -2298,18 +2299,43 @@ static void doc_postKeyEvent(LibreOfficeKitDocument* 
pThis, int nType, int nChar
 pDoc->postKeyEvent(nType, nCharCode, nKeyCode);
 }
 
-static void doc_postExtTextInputEvent(LibreOfficeKitDocument* pThis, int 
nType, const char* pText)
+static void doc_postExtTextInputEvent(LibreOfficeKitDocument* pThis, unsigned 
nWindowId, int nType, const char* pText)
 {
 SolarMutexGuard aGuard;
+VclPtr pWindow;
+if (nWindowId == 0)
+{
+ITiledRenderable* pDoc = getTiledRenderable(pThis);
+if (!pDoc)
+{
+gImpl->maLastExceptionMsg = "Document doesn't support tiled 
rendering";
+return;
+}
+pWindow = pDoc->getDocWindow();
+}
+else
+{
+pWindow = vcl::Window::FindLOKWindow(nWindowId);
+}
 
-ITiledRenderable* pDoc = getTiledRenderable(pThis);
-if (!pDoc)
+if (!pWindow)
 {
-gImpl->maLastExceptionMsg = "Document doesn't support tiled rendering";
+gImpl->maLastExceptionMsg = "No window found for window id: " + 
OUString::number(nWindowId);
 return;
 }
 
-pDoc->postExtTextInputEvent(nType, OUString::fromUtf8(OString(pText, 
strlen(pText;
+switch (nType)
+{
+case LOK_EXT_TEXTINPUT:
+pWindow->PostExtTextInputEvent(VclEventId::ExtTextInput,
+   OUString::fromUtf8(OString(pText, 
strlen(pText;
+break;
+case LOK_EXT_TEXTINPUT_END:
+pWindow->PostExtTextInputEvent(VclEventId::EndExtTextInput, "");
+break;
+default:
+assert(false && "Unhandled External Text input event!");
+}
 }
 
 static void doc_postWindowKeyEvent(LibreOfficeKitDocument* /*pThis*/, unsigned 
nLOKWindowId, int nType, int nCharCode, int nKeyCode)
diff --git a/include/LibreOfficeKit/LibreOfficeKit.h 
b/include/LibreOfficeKit/LibreOfficeKit.h
index ebc112fb7bd5..7492fcc7a561 100644
--- a/include/LibreOfficeKit/LibreOfficeKit.h
+++ b/include/LibreOfficeKit/LibreOfficeKit.h
@@ -302,6 +302,7 @@ struct _LibreOfficeKitDocumentClass
 
 /// @see lok::Document::postExtTextInputEvent
 void (*postExtTextInputEvent) (LibreOfficeKitDocument* pThis,
+   unsigned nWindowId,
int nType,
const char* pText);
 
diff --git a/include/LibreOfficeKit/LibreOfficeKit.hxx 
b/include/LibreOfficeKit/LibreOfficeKit.hxx
index 0983560898a4..55e29ebda1c8 100644
--- a/include/LibreOfficeKit/LibreOfficeKit.hxx
+++ b/include/LibreOfficeKit/LibreOfficeKit.hxx
@@ -540,12 +540,14 @@ public:
 /**
  * Post the text input from external input window, like IME
  *
+ * @param nWindowId Specify the window id to post the input event to. If
+ * nWindow is 0, the event is posted into the document
  * @param nType see LibreOfficeKitExtTextInputType
  * @param pText Text for LOK_EXT_TEXTINPUT
  */
-void postExtTextInputEvent(int nType, const char* pText)
+void postExtTextInputEve

[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-5.3' - desktop/source include/LibreOfficeKit include/vcl sc/inc sc/qa sc/source sd/qa sd/source sw/inc sw/qa sw/source vcl/source

2018-02-14 Thread Pranav Kant
 desktop/source/lib/init.cxx|   36 +
 include/LibreOfficeKit/LibreOfficeKit.h|1 
 include/LibreOfficeKit/LibreOfficeKit.hxx  |6 ++--
 include/vcl/ITiledRenderable.hxx   |   12 +++-
 sc/inc/docuno.hxx  |6 ++--
 sc/qa/unit/tiledrendering/tiledrendering.cxx   |6 ++--
 sc/source/ui/unoobj/docuno.cxx |   34 ++-
 sd/qa/unit/tiledrendering/tiledrendering.cxx   |6 ++--
 sd/source/ui/inc/unomodel.hxx  |3 --
 sd/source/ui/unoidl/unomodel.cxx   |   36 ++---
 sw/inc/unotxdoc.hxx|4 +-
 sw/qa/extras/tiledrendering/tiledrendering.cxx |6 ++--
 sw/source/uibase/uno/unotxdoc.cxx  |   30 ++--
 vcl/source/window/window.cxx   |8 -
 14 files changed, 96 insertions(+), 98 deletions(-)

New commits:
commit 5024d7dbb364dec4fc90979251e5f29bc5ed3f5b
Author: Pranav Kant 
Date:   Wed Feb 14 17:33:16 2018 +0530

lok IME: support dialogs as well

Change-Id: Ic78da45dadaa5a4e1ca78e20d04974108581121e
(cherry picked from commit 44fa8ae7d9bb3a28d860b2cc5871d6a6ccfc8411)
Reviewed-on: https://gerrit.libreoffice.org/49728
Reviewed-by: pranavk 
Tested-by: pranavk 

diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index eafdf21f88ce..8c51972b861d 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -569,6 +569,7 @@ static void doc_postKeyEvent(LibreOfficeKitDocument* pThis,
  int nCharCode,
  int nKeyCode);
 static void doc_postExtTextInputEvent(LibreOfficeKitDocument* pThis,
+  unsigned nWindowId,
   int nType,
   const char* pText);
 static void doc_postWindowKeyEvent(LibreOfficeKitDocument* pThis,
@@ -2285,18 +2286,43 @@ static void doc_postKeyEvent(LibreOfficeKitDocument* 
pThis, int nType, int nChar
 pDoc->postKeyEvent(nType, nCharCode, nKeyCode);
 }
 
-static void doc_postExtTextInputEvent(LibreOfficeKitDocument* pThis, int 
nType, const char* pText)
+static void doc_postExtTextInputEvent(LibreOfficeKitDocument* pThis, unsigned 
nWindowId, int nType, const char* pText)
 {
 SolarMutexGuard aGuard;
+VclPtr pWindow;
+if (nWindowId == 0)
+{
+ITiledRenderable* pDoc = getTiledRenderable(pThis);
+if (!pDoc)
+{
+gImpl->maLastExceptionMsg = "Document doesn't support tiled 
rendering";
+return;
+}
+pWindow = pDoc->getDocWindow();
+}
+else
+{
+pWindow = vcl::Window::FindLOKWindow(nWindowId);
+}
 
-ITiledRenderable* pDoc = getTiledRenderable(pThis);
-if (!pDoc)
+if (!pWindow)
 {
-gImpl->maLastExceptionMsg = "Document doesn't support tiled rendering";
+gImpl->maLastExceptionMsg = "No window found for window id: " + 
OUString::number(nWindowId);
 return;
 }
 
-pDoc->postExtTextInputEvent(nType, OUString::fromUtf8(OString(pText, 
strlen(pText;
+switch (nType)
+{
+case LOK_EXT_TEXTINPUT:
+pWindow->PostExtTextInputEvent(VCLEVENT_WINDOW_EXTTEXTINPUT,
+   OUString::fromUtf8(OString(pText, 
strlen(pText;
+break;
+case LOK_EXT_TEXTINPUT_END:
+pWindow->PostExtTextInputEvent(VCLEVENT_WINDOW_ENDEXTTEXTINPUT, "");
+break;
+default:
+assert(false && "Unhandled External Text input event!");
+}
 }
 
 static void doc_postWindowKeyEvent(LibreOfficeKitDocument* /*pThis*/, unsigned 
nLOKWindowId, int nType, int nCharCode, int nKeyCode)
diff --git a/include/LibreOfficeKit/LibreOfficeKit.h 
b/include/LibreOfficeKit/LibreOfficeKit.h
index bb99e04abe17..2af965e4a45d 100644
--- a/include/LibreOfficeKit/LibreOfficeKit.h
+++ b/include/LibreOfficeKit/LibreOfficeKit.h
@@ -291,6 +291,7 @@ struct _LibreOfficeKitDocumentClass
 
 /// @see lok::Document::postExtTextInputEvent
 void (*postExtTextInputEvent) (LibreOfficeKitDocument* pThis,
+   unsigned nWindowId,
int nType,
const char* pText);
 
diff --git a/include/LibreOfficeKit/LibreOfficeKit.hxx 
b/include/LibreOfficeKit/LibreOfficeKit.hxx
index c076c0f0b58f..fabd3b29e687 100644
--- a/include/LibreOfficeKit/LibreOfficeKit.hxx
+++ b/include/LibreOfficeKit/LibreOfficeKit.hxx
@@ -539,12 +539,14 @@ public:
 /**
  * Post the text input from external input window, like IME
  *
+ * @param nWindowId Specify the window id to post the input event to. If
+ * nWindow is 0, the event is posted into the document
  * @param nType see LibreOfficeKitExtTextInputType
  * @param pText Text for LOK_EXT_TEXTINPUT
  */
-void 

Re: Implementing accessibility non-regression check tool

2018-02-14 Thread Eike Rathke
Hi Samuel,

On Monday, 2018-02-12 15:30:59 +0100, Samuel Thibault wrote:

> [... a nice plan ...]

> What do people think about this plan?

Makes perfectly sense to me.

  Eike

-- 
LibreOffice Calc developer. Number formatter stricken i18n transpositionizer.
GPG key 0x6A6CD5B765632D3A - 2265 D7F3 A7B0 95CC 3918  630B 6A6C D5B7 6563 2D3A
Care about Free Software, support the FSFE https://fsfe.org/support/?erack


signature.asc
Description: PGP signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


How to disable libexttextcat?

2018-02-14 Thread Sander Maijers
Building fails for me because of this issue 
https://github.com/LibreOffice/libexttextcat/issues/2 .


libexttextcat does not seem like a critical component for a slimmed down 
LibreOffice build for development purposes. May I disable this 
dependency, and if so, how?

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


Non-portable configure.ac

2018-02-14 Thread Sander Maijers
./configure fails on my system because configure.ac does not work when 
/bin/sh is not Bash but a POSIX shell such as dash.


Please review the attached patch.
diff --git a/tmp/configure.ac b/tmp/portable_configure.ac
index 101050c..f9c5d9f 100644
--- a/tmp/configure.ac
+++ b/tmp/portable_configure.ac
@@ -168,7 +168,7 @@ if test "$enable_release_build" = "" -o "$enable_release_build" = "no"; then
 fi
 AC_MSG_RESULT([$PRODUCTNAME])
 AC_SUBST(PRODUCTNAME)
-PRODUCTNAME_WITHOUT_SPACES=${PRODUCTNAME// /}
+PRODUCTNAME_WITHOUT_SPACES="$(printf '%s' "$PRODUCTNAME" | tr -d '[:space:]')"
 AC_SUBST(PRODUCTNAME_WITHOUT_SPACES)
 
 dnl ===
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2018-02-14 Thread Caolán McNamara
 filter/source/graphicfilter/itiff/itiff.cxx |8 +---
 1 file changed, 5 insertions(+), 3 deletions(-)

New commits:
commit 4e1161c6cbdaf2bf0a92d3a5195ee559f2b77bed
Author: Caolán McNamara 
Date:   Wed Feb 14 12:23:19 2018 +

ofz#6315 Heap-buffer-overflow

Change-Id: Ia611f65b9fb38f125c224473e584580eeff20622
Reviewed-on: https://gerrit.libreoffice.org/49716
Reviewed-by: Noel Grandin 
Tested-by: Jenkins 
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/filter/source/graphicfilter/itiff/itiff.cxx 
b/filter/source/graphicfilter/itiff/itiff.cxx
index d86d2912804d..24b6c7143863 100644
--- a/filter/source/graphicfilter/itiff/itiff.cxx
+++ b/filter/source/graphicfilter/itiff/itiff.cxx
@@ -584,6 +584,7 @@ bool TIFFReader::ReadMap()
 
 aCCIDecom.StartDecompression( *pTIFF );
 
+const bool bHasAlphaChannel = HasAlphaChannel();
 for (sal_Int32 ny = 0; ny < nImageLength; ++ny)
 {
 bool bDifferentToPrev = ny == 0;
@@ -617,9 +618,10 @@ bool TIFFReader::ReadMap()
 //if the buffer for this line didn't change, then just copy the
 //previous scanline instead of painfully decoding and setting
 //each pixel one by one again
-memcpy( mpBitmap.get() + (ny * maBitmapPixelSize.Width()) * 4,
-mpBitmap.get() + ((ny-1) * maBitmapPixelSize.Width()) 
* 4,
-maBitmapPixelSize.Width() * 4);
+const int nColorSize = bHasAlphaChannel ? 4 : 3;
+memcpy( mpBitmap.get() + (ny * maBitmapPixelSize.Width()) * 
nColorSize,
+mpBitmap.get() + ((ny-1) * maBitmapPixelSize.Width()) 
* nColorSize,
+maBitmapPixelSize.Width() * nColorSize);
 }
 else
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Eike Rathke
 sc/source/core/tool/interpr1.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit fe0f548f2f67f85e32be754b553d709fda400d95
Author: Eike Rathke 
Date:   Wed Feb 14 17:57:56 2018 +0100

No stacked code for jump matrix is worth an assert

Change-Id: I0e65cecd9e016a114a7e9d7b60b24e04d8512f40

diff --git a/sc/source/core/tool/interpr1.cxx b/sc/source/core/tool/interpr1.cxx
index 89823f7eb352..632d16c49b32 100644
--- a/sc/source/core/tool/interpr1.cxx
+++ b/sc/source/core/tool/interpr1.cxx
@@ -542,7 +542,7 @@ bool ScInterpreter::JumpMatrix( short nStackLevel )
 aCode.Pop();// pop what Jump() pushed
 else
 {
-OSL_FAIL( "ScInterpreter::JumpMatrix: pop goes the weasel" );
+assert(!"pop goes the weasel");
 }
 
 if ( !bHasResMat )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Jan-Marek Glogowski
 uui/source/iahndl.cxx |8 
 1 file changed, 8 insertions(+)

New commits:
commit 0e04523b040785e2ce552143d20adcbb40b61d42
Author: Jan-Marek Glogowski 
Date:   Wed Feb 14 12:30:47 2018 +0100

tdf#114676 release the SolarMutex, if we own it

This is a follow up on the SolarMutex unification. Quite probably
the updater process, which is now aborting when releasing the
not-owned mutex, should somewhere acquire it.

In the end this functions currently can be called with or without
the SolarMutex being owned by the calling thread.

This conditional release is really a horrible hack / workaround;
but my guess is - like all hacks - it'll stay for longer.

Change-Id: I90e30149c2fef8bdf3dc0396bf8eb7491eedeabd
Reviewed-on: https://gerrit.libreoffice.org/49717
Tested-by: Jenkins 
Reviewed-by: Jan-Marek Glogowski 

diff --git a/uui/source/iahndl.cxx b/uui/source/iahndl.cxx
index f03372de3f54..59f62217c6ac 100644
--- a/uui/source/iahndl.cxx
+++ b/uui/source/iahndl.cxx
@@ -172,7 +172,11 @@ UUIInteractionHelper::handleRequest(
 HandleData aHD(rRequest);
 Link aLink(&aHD,handlerequest);
 Application::PostUserEvent(aLink,this);
+comphelper::SolarMutex& rSolarMutex = Application::GetSolarMutex();
+sal_uInt32 nLockCount = (rSolarMutex.IsCurrentThread()) ? 
rSolarMutex.release(true) : 0;
 aHD.wait();
+if (nLockCount)
+rSolarMutex.acquire(nLockCount);
 return aHD.bHandled;
 }
 else
@@ -223,7 +227,11 @@ UUIInteractionHelper::getStringFromRequest(
 HandleData aHD(rRequest);
 Link aLink(&aHD,getstringfromrequest);
 Application::PostUserEvent(aLink,this);
+comphelper::SolarMutex& rSolarMutex = Application::GetSolarMutex();
+sal_uInt32 nLockCount = (rSolarMutex.IsCurrentThread()) ? 
rSolarMutex.release(true) : 0;
 aHD.wait();
+if (nLockCount)
+rSolarMutex.acquire(nLockCount);
 return aHD.m_aResult;
 }
 else
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Tamás Zolnai
 sfx2/source/control/unoctitm.cxx |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 45c472697821df1022cb8ac4d81a14fcb1f734ef
Author: Tamás Zolnai 
Date:   Wed Feb 14 17:10:47 2018 +0100

Windows build fix

Related to this commit:
83202ea1341c98a216871f14702548ce5aabd94a

Change-Id: Ied2184f27650219d807095838941400590731817
Reviewed-on: https://gerrit.libreoffice.org/49743
Reviewed-by: Henry Castro 
Tested-by: Henry Castro 

diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx
index 39561e09489e..668f5c65b222 100644
--- a/sfx2/source/control/unoctitm.cxx
+++ b/sfx2/source/control/unoctitm.cxx
@@ -1191,7 +1191,7 @@ static void InterceptLOKStateChangeEvent(const 
SfxViewFrame* pViewFrame, const c
 css::uno::Sequence< OUString > aSeq;
 if (aEvent.State >>= aSeq)
 {
-aBuffer.append(u'{');
+aBuffer.append(static_cast('{'));
 for (sal_Int32 itSeq = 0; itSeq < aSeq.getLength(); itSeq++)
 {
 aBuffer.append("\"" + aSeq[itSeq]);
@@ -1200,7 +1200,7 @@ static void InterceptLOKStateChangeEvent(const 
SfxViewFrame* pViewFrame, const c
 else
 aBuffer.append("\":true");
 }
-aBuffer.append(u'}');
+aBuffer.append(static_cast('}'));
 }
 }
 }
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Impress: Stuttering transition under GNU/Linux

2018-02-14 Thread Paul Menzel

Dear LibreOffice,


With LibreOffice 5.2, 5.4 and 6.0.1.1, doing transitions in LibreOffice 
Impress, like wipe, the transition is not smooth but stutters(?) [1].


I first thought it’s HiDPI related, but it’s not.

Is that expected under GNU/Linux, or do I have something incorrectly 
configured? Any suggestions, how to debug this?



Kind regards,

Paul


[1] https://bugs.documentfoundation.org/show_bug.cgi?id=115650
"Stuttering transitions in GNU/Linux"



smime.p7s
Description: S/MIME Cryptographic Signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2018-02-14 Thread Caolán McNamara
 sc/source/filter/qpro/qpro.cxx  |1 -
 sc/source/ui/docshell/docsh.cxx |1 -
 2 files changed, 2 deletions(-)

New commits:
commit 20c881bf89048ad19c1d108f7e89d1b9d94f5aba
Author: Caolán McNamara 
Date:   Wed Feb 14 11:30:24 2018 +

ofz#6316 Direct-leak

Change-Id: I1ae33f849d252e9682b7386909023821cf336b14
Reviewed-on: https://gerrit.libreoffice.org/49711
Tested-by: Jenkins 
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/sc/source/filter/qpro/qpro.cxx b/sc/source/filter/qpro/qpro.cxx
index 71c04172437c..e1b172ea53a4 100644
--- a/sc/source/filter/qpro/qpro.cxx
+++ b/sc/source/filter/qpro/qpro.cxx
@@ -245,7 +245,6 @@ extern "C" SAL_DLLPUBLIC_EXPORT bool TestImportQPW(SvStream 
&rStream)
 aDocument.EnableExecuteLink(false);
 aDocument.SetInsertingFromOtherDoc(true);
 aDocument.SetImportingXML(true);
-aDocument.EnableUndo(false);
 
 ScQProReader aReader(&rStream);
 ErrCode eRet = aReader.parse(&aDocument);
diff --git a/sc/source/ui/docshell/docsh.cxx b/sc/source/ui/docshell/docsh.cxx
index f794bf89e98d..8d1117af8d48 100644
--- a/sc/source/ui/docshell/docsh.cxx
+++ b/sc/source/ui/docshell/docsh.cxx
@@ -3263,7 +3263,6 @@ extern "C" SAL_DLLPUBLIC_EXPORT bool 
TestImportSLK(SvStream &rStream)
 aDocument.EnableExecuteLink(false);
 aDocument.SetInsertingFromOtherDoc(true);
 aDocument.SetImportingXML(true);
-aDocument.EnableUndo(false);
 
 ScImportExport aImpEx(&aDocument);
 return aImpEx.ImportStream(rStream, OUString(), 
SotClipboardFormatId::SYLK);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Eike Rathke
 sc/qa/unit/ucalc.hxx |2 ++
 sc/qa/unit/ucalc_formula.cxx |   30 ++
 2 files changed, 32 insertions(+)

New commits:
commit b05e4eab225a536c3e5bdae2ca991ee9f53ad1a6
Author: Eike Rathke 
Date:   Wed Feb 14 16:32:00 2018 +0100

Unit test tdf#115493 use matrix as result of jump command, tdf#58874 related

Change-Id: Ic36c5c559d6f650e590ac5f84b4acdb5be0843b3

diff --git a/sc/qa/unit/ucalc.hxx b/sc/qa/unit/ucalc.hxx
index 81d100254f93..a130d4ad69c7 100644
--- a/sc/qa/unit/ucalc.hxx
+++ b/sc/qa/unit/ucalc.hxx
@@ -216,6 +216,7 @@ public:
 void testFuncMDETERM();
 void testFuncSUMIFS();
 void testFuncRefListArraySUBTOTAL();
+void testFuncJumpMatrixArrayIF();
 void testMatConcat();
 void testMatConcatReplication();
 void testRefR1C1WholeCol();
@@ -635,6 +636,7 @@ public:
 CPPUNIT_TEST(testFuncMDETERM);
 CPPUNIT_TEST(testFuncSUMIFS);
 CPPUNIT_TEST(testFuncRefListArraySUBTOTAL);
+CPPUNIT_TEST(testFuncJumpMatrixArrayIF);
 CPPUNIT_TEST(testMatConcat);
 CPPUNIT_TEST(testMatConcatReplication);
 CPPUNIT_TEST(testExternalRef);
diff --git a/sc/qa/unit/ucalc_formula.cxx b/sc/qa/unit/ucalc_formula.cxx
index e282b0eb3a60..d6764c498e51 100644
--- a/sc/qa/unit/ucalc_formula.cxx
+++ b/sc/qa/unit/ucalc_formula.cxx
@@ -8360,6 +8360,36 @@ void Test::testFuncRefListArraySUBTOTAL()
 m_pDoc->DeleteTab(0);
 }
 
+// tdf#115493 jump commands return the matrix result instead of the reference
+// list array.
+void Test::testFuncJumpMatrixArrayIF()
+{
+sc::AutoCalcSwitch aACSwitch(*m_pDoc, true); // turn auto calc on.
+m_pDoc->InsertTab(0, "Test");
+
+m_pDoc->SetString(0,0,0, "a");  // A1
+std::vector> aData = {
+{ "a", "1" },
+{ "b", "2" },
+{ "a", "4" }
+};  // A7:B9
+insertRangeData(m_pDoc, ScAddress(0,6,0), aData);
+
+ScMarkData aMark;
+aMark.SelectOneTable(0);
+
+// Matrix in C10, summing B7,B9
+m_pDoc->InsertMatrixFormula( 2,9, 2,9, aMark, 
"=SUM(IF(EXACT(A7:A9;A$1);B7:B9;0))");
+CPPUNIT_ASSERT_EQUAL_MESSAGE("Formula C10 failed", 5.0, 
m_pDoc->GetValue(ScAddress(2,9,0)));
+
+// Matrix in C11, summing B7,B9
+m_pDoc->InsertMatrixFormula( 2,10, 2,10, aMark,
+
"=SUM(IF(EXACT(OFFSET(A7;0;0):OFFSET(A7;2;0);A$1);OFFSET(A7;0;1):OFFSET(A7;2;1);0))");
+CPPUNIT_ASSERT_EQUAL_MESSAGE("Formula C11 failed", 5.0, 
m_pDoc->GetValue(ScAddress(2,10,0)));
+
+m_pDoc->DeleteTab(0);
+}
+
 // Test iterations with circular chain of references.
 void Test::testIterations()
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Caolán McNamara
 sc/inc/tokenarray.hxx   |2 +-
 sc/source/filter/oox/defnamesbuffer.cxx |1 -
 2 files changed, 1 insertion(+), 2 deletions(-)

New commits:
commit fa25c39749e3ed592fdf87eecf21a960fef44b8f
Author: Caolán McNamara 
Date:   Wed Feb 14 12:13:52 2018 +

unused ScTokenArray

Change-Id: I3132cf7f94efed2db68a1715a892424a24aa1638
Reviewed-on: https://gerrit.libreoffice.org/49715
Tested-by: Jenkins 
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/sc/inc/tokenarray.hxx b/sc/inc/tokenarray.hxx
index feedf95475e9..f5f9a3d3c65a 100644
--- a/sc/inc/tokenarray.hxx
+++ b/sc/inc/tokenarray.hxx
@@ -44,7 +44,7 @@ struct ScRawToken;
 struct ScSingleRefData;
 struct ScComplexRefData;
 
-class SC_DLLPUBLIC ScTokenArray : public formula::FormulaTokenArray
+class SAL_WARN_UNUSED SC_DLLPUBLIC ScTokenArray : public 
formula::FormulaTokenArray
 {
 friend class ScCompiler;
 
diff --git a/sc/source/filter/oox/defnamesbuffer.cxx 
b/sc/source/filter/oox/defnamesbuffer.cxx
index 6f761b2c9b7c..5b6adf58801b 100644
--- a/sc/source/filter/oox/defnamesbuffer.cxx
+++ b/sc/source/filter/oox/defnamesbuffer.cxx
@@ -324,7 +324,6 @@ void DefinedName::createNameObject( sal_Int32 nIndex )
 std::unique_ptr DefinedName::getScTokens(
 const css::uno::Sequence& rExternalLinks 
)
 {
-ScTokenArray aTokenArray;
 ScCompiler aCompiler(&getScDocument(), ScAddress(0, 0, mnCalcSheet), 
formula::FormulaGrammar::GRAM_OOXML);
 aCompiler.SetExternalLinks( rExternalLinks);
 std::unique_ptr 
pArray(aCompiler.CompileString(maModel.maFormula));
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Wikihelp ?

2018-02-14 Thread Jay Philips
Hi Olivier,


Yes close the ones that are no longer applicable with the new help.


From: Olivier Hallot 
Sent: Sunday, February 11, 2018 4:56 PM
To: libreoffice@lists.freedesktop.org
Cc: Jan Holesovsky; Xisco Fauli; philip...@hotmail.com
Subject: Wikihelp ?

Hi

With the deployment of the new Help online, I'd like to review the open
bugs specific to the wiki help implmentation, as listed for example in
the metabug

https://bugs.documentfoundation.org/show_bug.cgi?id=94016

Is it safe to close them (after proper review)? Please advise.

Kind regards

--
Olivier Hallot
LibreOffice Documentation Coordinator
Comunidade LibreOffice
Rio de Janeiro - Brasil - Local Time: UTC-02:00
http://tdf.io/joinus
Get Involved | LibreOffice - Free Office Suite - Fun Project - Fantastic 
People
tdf.io
community, LibreOffice, office suite, free office suite, Document Foundation, 
get involved, opportunities, developers, testers, localizers, translators, 
documentation writers, users support, native-lang, designers, marketers, 
marketing, design, administrators, infrastructures, contributors, members, 
project members, project



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


[Libreoffice-commits] core.git: Branch 'libreoffice-6-0' - sc/source

2018-02-14 Thread Markus Mohrhard
 sc/source/ui/view/tabvwsh4.cxx |8 +---
 1 file changed, 5 insertions(+), 3 deletions(-)

New commits:
commit 9e8e6cf5441bbdb09b890e16c14c495bdda4e624
Author: Markus Mohrhard 
Date:   Wed Feb 14 02:25:32 2018 +0100

it does not make sense to check for nullptr and then access anyway

Seems to be related to the crashreports with the signatures:

http://crashreport.libreoffice.org/stats/signature/ScTabViewShell::~ScTabViewShell()

http://crashreport.libreoffice.org/stats/signature/ScInputHandler::EnterHandler(ScEnterMode)

Change-Id: Iff22db3988687a52a7596f01facd5bdd12ce4140
Reviewed-on: https://gerrit.libreoffice.org/49694
Reviewed-by: Markus Mohrhard 
Tested-by: Markus Mohrhard 
(cherry picked from commit 2fd7c18f42710bdaaf3262f4be9f1a706b33d38d)
Reviewed-on: https://gerrit.libreoffice.org/49700
Tested-by: Jenkins 
Reviewed-by: Miklos Vajna 

diff --git a/sc/source/ui/view/tabvwsh4.cxx b/sc/source/ui/view/tabvwsh4.cxx
index 5c0b1e8ab594..55caac70a18f 100644
--- a/sc/source/ui/view/tabvwsh4.cxx
+++ b/sc/source/ui/view/tabvwsh4.cxx
@@ -1774,10 +1774,12 @@ ScTabViewShell::~ScTabViewShell()
 // all to NULL, in case the TabView-dtor tries to access them
 //! (should not really! ??!?!)
 if (mpInputHandler)
+{
 mpInputHandler->SetDocumentDisposing(true);
-// We end edit mode, before destroying the input handler and the edit 
engine
-// and before end listening (in order to call 
ScTabViewShell::KillEditView())
-mpInputHandler->EnterHandler();
+// We end edit mode, before destroying the input handler and the edit 
engine
+// and before end listening (in order to call 
ScTabViewShell::KillEditView())
+mpInputHandler->EnterHandler();
+}
 
 ScDocShell* pDocSh = GetViewData().GetDocShell();
 EndListening(*pDocSh);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: solenv/flatpak-manifest.in

2018-02-14 Thread Stephan Bergmann
 solenv/flatpak-manifest.in |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit d49a0b7391d43b9e4f8e14f9a9bf0bb2223d0025
Author: Stephan Bergmann 
Date:   Wed Feb 14 15:06:21 2018 +0100

Revert "--disable-pdfium for Linux aarch64 Flatpak build"

...which should no longer be needed w/ 
9efd288b31e259b964097d3eeeff7f6c10945cb3
"pdfium: disable custom allocator".  (On Flathub, the original problem had 
been
seen with worker gnome-aarch64-1 using 64K pages, but not with arm-1/arm-3 
using
4K pages.)

This reverts commit ffc134445ef7e935d18d816626f64e65b4cdbca6.
Conflicts:
solenv/flatpak-manifest.in

Change-Id: I7d169ba92cdcd651b1c560aabf0d4559fad8cf9c

diff --git a/solenv/flatpak-manifest.in b/solenv/flatpak-manifest.in
index cbe5b6a226c7..ae78d0823953 100644
--- a/solenv/flatpak-manifest.in
+++ b/solenv/flatpak-manifest.in
@@ -548,7 +548,7 @@
 ],
 "buildsystem": "simple",
 "build-commands": [
-"./autogen.sh --prefix=/run/build/libreoffice/inst 
--with-distro=LibreOfficeFlatpak --disable-symbols $(if test \"$(uname -m)\" = 
aarch64; then printf %s --disable-pdfium; fi)",
+"./autogen.sh --prefix=/run/build/libreoffice/inst 
--with-distro=LibreOfficeFlatpak --disable-symbols",
 "make $(if test \"$(uname -i)\" = i386; then printf 
build-nocheck; fi)",
 "make distro-pack-install",
 "make cmd cmd='$(SRCDIR)/solenv/bin/assemble-flatpak.sh'"
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread jan Iversen
 bridges/Library_cpp_uno.mk|   65 +-
 bridges/source/cpp_uno/gcc3_ios/cpp2uno-simulator.cxx |  520 --
 bridges/source/cpp_uno/gcc3_ios/uno2cpp-simulator.cxx |  444 ---
 3 files changed, 33 insertions(+), 996 deletions(-)

New commits:
commit 54a5b5d7f3e8ebe52783379aa67fad41de32a695
Author: jan Iversen 
Date:   Wed Feb 14 15:01:38 2018 +0100

iOS, add gcc3 helper for ARM64

Change-Id: Iad8cfd72803864bd1c8a5d01c74e1f856c27685d

diff --git a/bridges/Library_cpp_uno.mk b/bridges/Library_cpp_uno.mk
index 26aaf59ff8f1..73744d2d682c 100644
--- a/bridges/Library_cpp_uno.mk
+++ b/bridges/Library_cpp_uno.mk
@@ -21,6 +21,12 @@ $(call gb_LinkTarget_get_target,$(call 
gb_Library_get_linktarget,gcc3_uno)) : \
EXTRAOBJECTLISTS += $(call 
gb_CustomTarget_get_workdir,bridges/source/cpp_uno/gcc3_linux_arm)/armhelper.objectlist
 endif
 
+else ifeq ($(CPUNAME),ARM64)
+
+bridges_SELECTED_BRIDGE := gcc3_ios
+bridge_noopt_objects := abi call callvirtualmethod cpp2uno except uno2cpp
+bridge_asm_objects := ios64_helper
+
 else ifeq ($(CPUNAME),AARCH64)
 
 ifneq ($(filter ANDROID DRAGONFLY FREEBSD LINUX NETBSD OPENBSD,$(OS)),)
diff --git a/bridges/source/cpp_uno/gcc3_ios/cpp2uno-simulator.cxx 
b/bridges/source/cpp_uno/gcc3_ios/cpp2uno-simulator.cxx
deleted file mode 100644
index d350d0c4c3e1..
--- a/bridges/source/cpp_uno/gcc3_ios/cpp2uno-simulator.cxx
+++ /dev/null
@@ -1,520 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-#ifndef __arm64
-
-#include 
-#include 
-
-#include 
-#include 
-
-#include 
-#include "com/sun/star/uno/RuntimeException.hpp"
-#include 
-#include 
-
-#include "bridge.hxx"
-#include "cppinterfaceproxy.hxx"
-#include "types.hxx"
-#include "vtablefactory.hxx"
-
-#include "abi.hxx"
-#include "call.hxx"
-#include "share.hxx"
-
-using namespace ::osl;
-using namespace ::com::sun::star::uno;
-
-
-// Perform the UNO call
-//
-// We must convert the parameters stored in gpreg, fpreg and ovrflw to UNO
-// arguments and call pThis->getUnoI()->pDispatcher.
-//
-// gpreg:  [ret *], this, [gpr params]
-// fpreg:  [fpr params]
-// ovrflw: [gpr or fpr params (properly aligned)]
-//
-// [ret *] is present when we are returning a structure bigger than 16 bytes
-// Simple types are returned in rax, rdx (int), or xmm0, xmm1 (fp).
-// Similarly structures <= 16 bytes are in rax, rdx, xmm0, xmm1 as necessary.
-static typelib_TypeClass cpp2uno_call(
-bridges::cpp_uno::shared::CppInterfaceProxy * pThis,
-const typelib_TypeDescription * pMemberTypeDescr,
-typelib_TypeDescriptionReference * pReturnTypeRef, // 0 indicates void 
return
-sal_Int32 nParams, typelib_MethodParameter * pParams,
-void ** gpreg, void ** fpreg, void ** ovrflw,
-sal_uInt64 * pRegisterReturn /* space for register return */ )
-{
-unsigned int nr_gpr = 0; //number of gpr registers used
-unsigned int nr_fpr = 0; //number of fpr registers used
-
-// return
-typelib_TypeDescription * pReturnTypeDescr = nullptr;
-if (pReturnTypeRef)
-TYPELIB_DANGER_GET( &pReturnTypeDescr, pReturnTypeRef );
-
-void * pUnoReturn = nullptr;
-void * pCppReturn = nullptr; // complex return ptr: if != 0 && != 
pUnoReturn, reconversion need
-
-if ( pReturnTypeDescr )
-{
-if ( x86_64::return_in_hidden_param( pReturnTypeRef ) )
-{
-pCppReturn = *gpreg++;
-nr_gpr++;
-
-pUnoReturn = ( bridges::cpp_uno::shared::relatesToInterfaceType( 
pReturnTypeDescr )
-   ? alloca( pReturnTypeDescr->nSize )
-   : pCppReturn ); // direct way
-}
-else
-pUnoReturn = pRegisterReturn; // direct way for simple types
-}
-
-// pop this
-gpreg++;
-nr_gpr++;
-
-// stack space
-// parameters
-void ** pUnoArgs = static_cast(alloca( 4 * sizeof(void *) * 
nParams ));
-void ** pCppArgs = pUnoArgs + nParams;
-// indices of values this have to be converted (interface conversion 
cpp<=>uno)
-sal_Int32 * pTempIndices = reinterpret_cast(pUnoArgs + (2 * 
n

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

2018-02-14 Thread Noel Grandin
 svx/source/sdr/primitive2d/sdrprimitivetools.cxx |   44 ---
 1 file changed, 16 insertions(+), 28 deletions(-)

New commits:
commit cb0ace39523acb14ced26ff6f349d228884f02b6
Author: Noel Grandin 
Date:   Tue Feb 13 15:40:47 2018 +0200

move Bitmap creation in createDefaultCross_3x3 to vcl

part of making Bitmap an internal detail of vcl/

Change-Id: Id6ac7a2b099dca41cf41bb9f65c7cc22dce1eb8e
Reviewed-on: https://gerrit.libreoffice.org/49654
Reviewed-by: Michael Meeks 
Tested-by: Jenkins 

diff --git a/svx/source/sdr/primitive2d/sdrprimitivetools.cxx 
b/svx/source/sdr/primitive2d/sdrprimitivetools.cxx
index 31758b6d8a7a..6b8a61ea4b01 100644
--- a/svx/source/sdr/primitive2d/sdrprimitivetools.cxx
+++ b/svx/source/sdr/primitive2d/sdrprimitivetools.cxx
@@ -18,9 +18,9 @@
  */
 
 #include 
-#include 
 #include 
 #include 
+#include 
 
 
 // helper methods
@@ -32,43 +32,31 @@ namespace drawinglayer
 BitmapEx createDefaultCross_3x3(const basegfx::BColor& rBColor)
 {
 static vcl::DeleteOnDeinit< BitmapEx > aRetVal(nullptr);
-static basegfx::BColor aColor;
+static basegfx::BColor aBColor;
 static ::osl::Mutex aMutex;
 
 ::osl::MutexGuard aGuard(aMutex);
 
-if(!aRetVal.get() || rBColor != aColor)
+if(!aRetVal.get() || rBColor != aBColor)
 {
 // copy values
-aColor = rBColor;
+aBColor = rBColor;
 
 // create bitmap
-Bitmap aContent(Size(3, 3), 24);
-Bitmap aMask(Size(3, 3), 1);
-BitmapWriteAccess* pWContent = aContent.AcquireWriteAccess();
-BitmapWriteAccess* pWMask = aMask.AcquireWriteAccess();
-OSL_ENSURE(pWContent && pWMask, "No WriteAccess to bitmap 
(!)");
-const Color aVCLColor(aColor);
-const BitmapColor aPixColor(aVCLColor);
-const BitmapColor aMaskColor(0x01);
-
-// Y,X unusual order (!)
-pWContent->SetPixel(0, 1, aPixColor);
-pWContent->SetPixel(1, 0, aPixColor);
-pWContent->SetPixel(1, 1, aPixColor);
-pWContent->SetPixel(1, 2, aPixColor);
-pWContent->SetPixel(2, 1, aPixColor);
-
-pWMask->SetPixel(0, 0, aMaskColor);
-pWMask->SetPixel(0, 2, aMaskColor);
-pWMask->SetPixel(2, 0, aMaskColor);
-pWMask->SetPixel(2, 2, aMaskColor);
-
-Bitmap::ReleaseAccess(pWContent);
-Bitmap::ReleaseAccess(pWMask);
+Color c(aBColor);
+sal_uInt8 r = c.GetRed();
+sal_uInt8 g = c.GetGreen();
+sal_uInt8 b = c.GetBlue();
+sal_uInt8 a = 255;
+const sal_uInt8 cross[] = {
+   0, 0, 0, a,   r, g, b, 0,   0, 0, 0, a,
+   r, g, b, 0,   r, g, b, 0,   r, g, b, 0,
+   0, 0, 0, a,   r, g, b, 0,   0, 0, 0, a
+};
+BitmapEx aBitmap = vcl::bitmap::CreateFromData(cross, 3, 3, 3, 
32);
 
 // create and exchange at aRetVal
-delete aRetVal.set(new BitmapEx(aContent, aMask));
+delete aRetVal.set(new BitmapEx(aBitmap));
 }
 
 return aRetVal.get() ? *aRetVal.get() : BitmapEx();
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Henry Castro
 desktop/source/lib/init.cxx |5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

New commits:
commit 0df89c0fdaaff10272fb74b196ade0bcc9ea1ff6
Author: Henry Castro 
Date:   Tue Feb 13 20:54:05 2018 -0400

lok: check if an element exists in the container

Change-Id: I5987e90d92a2ebff654a993fb77e389bd036a8f8
Reviewed-on: https://gerrit.libreoffice.org/49693
Tested-by: Jenkins 
Reviewed-by: Henry Castro 
Reviewed-on: https://gerrit.libreoffice.org/49712
Reviewed-by: Aron Budea 
Tested-by: Aron Budea 

diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index 2598da695e0a..eafdf21f88ce 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -2819,11 +2819,12 @@ static char* getStyles(LibreOfficeKitDocument* pThis, 
const char* pCommand)
 OUString sName;
 bool bIsPhysical;
 boost::property_tree::ptree aChild;
-uno::Reference xProperty;
 boost::property_tree::ptree aChildren;
+const OUString sPageStyles("PageStyles");
+uno::Reference xProperty;
 uno::Reference xContainer;
 
-if (xStyleFamilies->getByName("PageStyles") >>= xContainer)
+if (xStyleFamilies->hasByName(sPageStyles) && 
(xStyleFamilies->getByName(sPageStyles) >>= xContainer))
 {
 uno::Sequence aSeqNames = xContainer->getElementNames();
 for (sal_Int32 itName = 0; itName < aSeqNames.getLength(); 
itName++)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Why does the GTK3 vcl sal plugin default to SvpSalGraphics / software rendering?

2018-02-14 Thread Caolán McNamara
On Wed, 2018-02-14 at 12:29 +0100, Clemens Eisserer wrote:
> When compiled for GTK3 GtkInstance::CreateVirtualDevice always
> returns a SvpSalVirtualDevice (instead of a CreateX11VirtualDevice),
> which in turn seems to be unconditionally backed by a cairo image
> surface. This is also what I am seeing in my profiles, as soon as I
> switch to GTK3 all time is spent inside some cairo/pixman software
> loops.
> 
> Maybe this was done by accident and nobody noticed 

No, its not by accident that the Svp variant is used for gtk3 even
under X.

It might be worth in GtkInstance::CreateVirtualDevice casting the pG
argument to a GtkSalGraphics (which is what it is I believe) and using
the mpWindow member of that as a path to get the GdkWindow argument for

gdk_window_create_similar_image_surface/gdk_window_create_similar_surface and 
inheriting a GtkSalVirtualDevice from SvpSalVirtualDevice to override 
SetSizeUsingBuffer in order to call those instead of cairo_image_surface_create
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2018-02-14 Thread Noel Grandin
 include/svx/xbitmap.hxx   |4 +-
 include/vcl/dibtools.hxx  |6 +++
 lotuswordpro/source/filter/lwpbackgroundstuff.cxx |8 +---
 sc/source/filter/excel/xiescher.cxx   |2 -
 svx/source/xoutdev/xattrbmp.cxx   |   10 ++---
 vcl/source/bitmap/BitmapTools.cxx |   44 +++---
 vcl/source/gdi/dibtools.cxx   |9 
 7 files changed, 55 insertions(+), 28 deletions(-)

New commits:
commit b90e098a354323b635bab3ee8f9c79deb1e734fe
Author: Noel Grandin 
Date:   Wed Feb 14 11:20:32 2018 +0200

use BitmapEx in LwpBackgroundStuff

part of making Bitmap an implementation detail of vcl/

Change-Id: I847a2371cd630637b11aed0fad7263809143c706
Reviewed-on: https://gerrit.libreoffice.org/49705
Tested-by: Jenkins 
Reviewed-by: Noel Grandin 

diff --git a/include/svx/xbitmap.hxx b/include/svx/xbitmap.hxx
index d5ff0f7eb9e1..e062a0aebc5a 100644
--- a/include/svx/xbitmap.hxx
+++ b/include/svx/xbitmap.hxx
@@ -43,7 +43,7 @@ private:
 
 
 public:
-XOBitmap( const Bitmap& rBitmap );
+XOBitmap( const BitmapEx& rBitmap );
 ~XOBitmap();
 
 void Bitmap2Array();
@@ -52,7 +52,7 @@ public:
 void SetPixelColor( const Color& rColor )   { aPixelColor = 
rColor; bGraphicDirty = true; }
 void SetBackgroundColor( const Color& rColor )  { aBckgrColor = 
rColor; bGraphicDirty = true; }
 
-Bitmap  GetBitmap() const;
+BitmapExGetBitmap() const;
 const Color&GetBackgroundColor() const  { return aBckgrColor; }
 };
 
diff --git a/include/vcl/dibtools.hxx b/include/vcl/dibtools.hxx
index 75618ad609d7..f56ee96bd4e4 100644
--- a/include/vcl/dibtools.hxx
+++ b/include/vcl/dibtools.hxx
@@ -60,6 +60,12 @@ bool VCL_DLLPUBLIC WriteDIB( // WriteDIB(rBitmap, rOStm, 
false, true);
 bool bCompressed,
 bool bFileHeader);
 
+bool VCL_DLLPUBLIC WriteDIB( // WriteDIB(rBitmap, rOStm, false, true);
+const BitmapEx& rSource,
+SvStream& rOStm,
+bool bCompressed,
+bool bFileHeader);
+
 bool VCL_DLLPUBLIC WriteDIBBitmapEx(
 const BitmapEx& rSource,
 SvStream& rOStm);
diff --git a/lotuswordpro/source/filter/lwpbackgroundstuff.cxx 
b/lotuswordpro/source/filter/lwpbackgroundstuff.cxx
index 90a77cb8eb19..7ee17a64fdd8 100644
--- a/lotuswordpro/source/filter/lwpbackgroundstuff.cxx
+++ b/lotuswordpro/source/filter/lwpbackgroundstuff.cxx
@@ -65,7 +65,7 @@
 
 #include 
 #include 
-#include 
+#include 
 #include 
 
 void LwpBackgroundStuff::Read(LwpObjectStream* pStrm)
@@ -114,11 +114,7 @@ XFBGImage* LwpBackgroundStuff::GetFillPattern()
 GetPattern(m_nID, aPttnArray);
 
 // create bitmap object from the pattern array
-Bitmap aBmp( Size(8, 8), 1 );
-BitmapWriteAccess* pWA = aBmp.AcquireWriteAccess();
-sal_uInt8* pBuf = pWA->GetBuffer();
-memcpy(pBuf, aPttnArray, 32);
-Bitmap::ReleaseAccess(pWA);
+BitmapEx aBmp = vcl::bitmap::CreateFromData( aPttnArray, 8, 8, 8, 1 );
 
 // create XOBitmap object from bitmap object
 XOBitmap aXOBitmap( aBmp );
diff --git a/sc/source/filter/excel/xiescher.cxx 
b/sc/source/filter/excel/xiescher.cxx
index 63284f9076d2..5d03a6ecaf62 100644
--- a/sc/source/filter/excel/xiescher.cxx
+++ b/sc/source/filter/excel/xiescher.cxx
@@ -720,7 +720,7 @@ void XclImpDrawObjBase::ConvertFillStyle( SdrObject& 
rSdrObj, const XclObjFillDa
 aXOBitmap.SetPixelColor( aPattColor );
 aXOBitmap.SetBackgroundColor( aBackColor );
 aXOBitmap.Array2Bitmap();
-aBitmap = aXOBitmap.GetBitmap();
+aBitmap = aXOBitmap.GetBitmap().GetBitmapRef();
 
 rSdrObj.SetMergedItem(XFillStyleItem(drawing::FillStyle_BITMAP));
 rSdrObj.SetMergedItem(XFillBitmapItem(EMPTY_OUSTRING, 
Graphic(aBitmap)));
diff --git a/svx/source/xoutdev/xattrbmp.cxx b/svx/source/xoutdev/xattrbmp.cxx
index fad22b1c546d..6bb58e9707bb 100644
--- a/svx/source/xoutdev/xattrbmp.cxx
+++ b/svx/source/xoutdev/xattrbmp.cxx
@@ -44,7 +44,7 @@
 
 using namespace ::com::sun::star;
 
-XOBitmap::XOBitmap( const Bitmap& rBmp ) :
+XOBitmap::XOBitmap( const BitmapEx& rBmp ) :
 xGraphicObject  (new GraphicObject(rBmp)),
 bGraphicDirty   ( false )
 {
@@ -54,9 +54,9 @@ XOBitmap::~XOBitmap()
 {
 }
 
-Bitmap XOBitmap::GetBitmap() const
+BitmapEx XOBitmap::GetBitmap() const
 {
-return GetGraphicObject().GetGraphic().GetBitmap();
+return GetGraphicObject().GetGraphic().GetBitmapEx();
 }
 
 const GraphicObject& XOBitmap::GetGraphicObject() const
@@ -71,14 +71,14 @@ void XOBitmap::Bitmap2Array()
 {
 ScopedVclPtrInstance< VirtualDevice > pVDev;
 boolbPixelColor = false;
-const BitmapaBitmap( GetBitmap() );
+const BitmapEx  aBitmap( GetBitmap() );
 const sal_Int32 nLines = 8; // type dependent
 
 if( !pPixelArray )
 pPixelArray.reset( new sal_uInt16[ nLines * nLines ] );
 

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

2018-02-14 Thread Noel Grandin
 sc/source/core/data/column2.cxx |8 
 sc/source/core/data/documen3.cxx|   42 +--
 sc/source/core/data/documen9.cxx|4 
 sc/source/core/data/drwlayer.cxx|  108 -
 sc/source/core/data/postit.cxx  |   32 +-
 sc/source/core/tool/detfunc.cxx |   28 +-
 sc/source/core/tool/editutil.cxx|6 
 sc/source/filter/excel/xiescher.cxx |   16 -
 sc/source/filter/excel/xiview.cxx   |4 
 sc/source/filter/excel/xlescher.cxx |4 
 sc/source/filter/html/htmlexp.cxx   |4 
 sc/source/filter/html/htmlexp2.cxx  |8 
 sc/source/filter/html/htmlimp.cxx   |4 
 sc/source/filter/html/htmlpars.cxx  |   12 -
 sc/source/filter/rtf/eeimpars.cxx   |   16 -
 sc/source/filter/xml/XMLTableShapeImportHelper.cxx  |4 
 sc/source/ui/Accessibility/AccessibleCsvControl.cxx |6 
 sc/source/ui/app/client.cxx |   20 -
 sc/source/ui/app/inputhdl.cxx   |2 
 sc/source/ui/app/inputwin.cxx   |   28 +-
 sc/source/ui/app/transobj.cxx   |4 
 sc/source/ui/cctrl/cbuttonw.cxx |   36 +--
 sc/source/ui/cctrl/checklistmenu.cxx|   40 +--
 sc/source/ui/cctrl/dpcontrol.cxx|2 
 sc/source/ui/cctrl/tbzoomsliderctrl.cxx |   40 +--
 sc/source/ui/condformat/condformatdlg.cxx   |8 
 sc/source/ui/condformat/condformatdlgentry.cxx  |2 
 sc/source/ui/dbgui/csvgrid.cxx  |8 
 sc/source/ui/dbgui/csvruler.cxx |4 
 sc/source/ui/docshell/docsh4.cxx|4 
 sc/source/ui/docshell/docsh6.cxx|   12 -
 sc/source/ui/drawfunc/fuconstr.cxx  |4 
 sc/source/ui/drawfunc/fuins1.cxx|   26 +-
 sc/source/ui/drawfunc/fuins2.cxx|   10 
 sc/source/ui/miscdlgs/acredlin.cxx  |2 
 sc/source/ui/miscdlgs/anyrefdg.cxx  |8 
 sc/source/ui/miscdlgs/autofmt.cxx   |   14 -
 sc/source/ui/miscdlgs/solveroptions.cxx |2 
 sc/source/ui/namedlg/namemgrtable.cxx   |2 
 sc/source/ui/navipi/content.cxx |2 
 sc/source/ui/navipi/navipi.cxx  |2 
 sc/source/ui/navipi/scenwnd.cxx |4 
 sc/source/ui/pagedlg/tphfedit.cxx   |6 
 sc/source/ui/sidebar/CellLineStyleValueSet.cxx  |6 
 sc/source/ui/unoobj/TablePivotCharts.cxx|8 
 sc/source/ui/unoobj/chartuno.cxx|8 
 sc/source/ui/unoobj/viewuno.cxx |2 
 sc/source/ui/view/drawview.cxx  |8 
 sc/source/ui/view/gridwin.cxx   |  124 +--
 sc/source/ui/view/gridwin2.cxx  |2 
 sc/source/ui/view/gridwin3.cxx  |2 
 sc/source/ui/view/gridwin4.cxx  |   82 +++
 sc/source/ui/view/gridwin5.cxx  |4 
 sc/source/ui/view/hdrcont.cxx   |   38 +--
 sc/source/ui/view/hintwin.cxx   |2 
 sc/source/ui/view/invmerge.cxx  |   14 -
 sc/source/ui/view/notemark.cxx  |8 
 sc/source/ui/view/output.cxx|   70 +++---
 sc/source/ui/view/output2.cxx   |  222 ++--
 sc/source/ui/view/output3.cxx   |   28 +-
 sc/source/ui/view/preview.cxx   |   36 +--
 sc/source/ui/view/prevloc.cxx   |   24 +-
 sc/source/ui/view/prevwsh.cxx   |   72 +++---
 sc/source/ui/view/printfun.cxx  |  124 +--
 sc/source/ui/view/reffact.cxx   |8 
 sc/source/ui/view/select.cxx|4 
 sc/source/ui/view/tabview.cxx   |   94 
 sc/source/ui/view/tabview2.cxx  |   18 -
 sc/source/ui/view/tabview3.cxx  |   50 ++--
 sc/source/ui/view/tabview4.cxx  |6 
 sc/source/ui/view/tabview5.cxx  |8 
 sc/source/ui/view/tabvwsh2.cxx  |4 
 sc/source/ui/view/tabvwsh4.cxx  |   14 -
 sc/source/ui/view/tabvwshb.cxx  |4 
 sc/source/ui/view/tabvwshg.cxx  |2 
 sc/source/ui/view/viewdata.cxx  |   86 +++
 sc/source/ui/view/viewfun5.cxx  |   12 -
 sc/source/ui/view/viewfun7.cxx  |   24 +-
 78 files changed, 910 insertions(+), 906 deletions(-)

New commits:
commit 95fab7cbf2f0576d0f728bed8898b7ff76

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

2018-02-14 Thread Caolán McNamara
 filter/source/msfilter/msdffimp.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 6be2c684effd6732c92df7ef75581772adb6dac3
Author: Caolán McNamara 
Date:   Tue Feb 13 21:16:56 2018 +

ofz#6300 Abrt

Change-Id: I814b0e4255894d909d29a9a301488a23acf418a0
Reviewed-on: https://gerrit.libreoffice.org/49688
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 
Reviewed-by: Michael Stahl 

diff --git a/filter/source/msfilter/msdffimp.cxx 
b/filter/source/msfilter/msdffimp.cxx
index eadbf3afcc9a..b0f715f4bd4d 100644
--- a/filter/source/msfilter/msdffimp.cxx
+++ b/filter/source/msfilter/msdffimp.cxx
@@ -1114,7 +1114,8 @@ void ApplyRectangularGradientAsBitmap( const 
SvxMSDffManager& rManager, SvStream
 {
 Size aBitmapSizePixel( static_cast< sal_Int32 >( ( 
rObjData.aBoundRect.GetWidth() / 2540.0 ) * 90.0 ),  // we will create a 
bitmap with 90 dpi
static_cast< sal_Int32 >( ( 
rObjData.aBoundRect.GetHeight() / 2540.0 ) * 90.0 ) );
-if ( aBitmapSizePixel.Width() && aBitmapSizePixel.Height() && ( 
aBitmapSizePixel.Width() <= 1024 ) && ( aBitmapSizePixel.Height() <= 1024 ) )
+if (aBitmapSizePixel.Width() > 0 && aBitmapSizePixel.Height() > 0 &&
+aBitmapSizePixel.Width() <= 1024 && aBitmapSizePixel.Height() <= 1024)
 {
 double fFocusX = rManager.GetPropertyValue( DFF_Prop_fillToRight, 0 ) 
/ 65536.0;
 double fFocusY = rManager.GetPropertyValue( DFF_Prop_fillToBottom, 0 ) 
/ 65536.0;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Yousuf Philips
 sw/uiconfig/swform/toolbar/moreformcontrols.xml |6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

New commits:
commit 603d1773a2dfea6b347f44ddacef478577098caf
Author: Yousuf Philips 
Date:   Tue Feb 13 19:27:45 2018 +0400

tdf#115447 tdf#81475 Restore form controls used in forms

Change-Id: I41b72aa6e453d15287573c3fb2d0536a132e490d
Reviewed-on: https://gerrit.libreoffice.org/49671
Tested-by: Jenkins 
Reviewed-by: Yousuf Philips 

diff --git a/sw/uiconfig/swform/toolbar/moreformcontrols.xml 
b/sw/uiconfig/swform/toolbar/moreformcontrols.xml
index bb170f6ed9bc..e0e1fbba4085 100644
--- a/sw/uiconfig/swform/toolbar/moreformcontrols.xml
+++ b/sw/uiconfig/swform/toolbar/moreformcontrols.xml
@@ -27,6 +27,8 @@
  
  
  
- 
- 
+ 
+ 
+ 
+ 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Crash test update

2018-02-14 Thread Crashtest VM
New crashtest update available at 
http://dev-builds.libreoffice.org/crashtest/ac97ca547de9593ff5f8e7615f1aa779a5091126/


exportCrashes.csv
Description: Binary data


importCrash.csv
Description: Binary data


validationErrors.csv
Description: Binary data
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2018-02-14 Thread Eike Rathke
 sc/source/core/data/documentimport.cxx |   14 +-
 1 file changed, 13 insertions(+), 1 deletion(-)

New commits:
commit f41c14706c6bf8aa5c3df220c706669f1ec6e1f6
Author: Eike Rathke 
Date:   Wed Feb 14 12:53:19 2018 +0100

More CheckLinkFormulaNeedingCheck() for ScDocumentImport::setFormulaCell()

and ScDocumentImport::setMatrixCells()

Change-Id: Id3303fb71889c760424459daa79feca0f2510a3c

diff --git a/sc/source/core/data/documentimport.cxx 
b/sc/source/core/data/documentimport.cxx
index a4161d9071f1..3db030880f1b 100644
--- a/sc/source/core/data/documentimport.cxx
+++ b/sc/source/core/data/documentimport.cxx
@@ -319,6 +319,8 @@ void ScDocumentImport::setFormulaCell(
 std::unique_ptr pFC =
 o3tl::make_unique(&mpImpl->mrDoc, rPos, rFormula, 
eGrammar);
 
+mpImpl->mrDoc.CheckLinkFormulaNeedingCheck( *pFC->GetCode());
+
 // Set cached result to this formula cell.
 pFC->SetHybridString(mpImpl->mrDoc.GetSharedStringPool().intern(rResult));
 
@@ -338,9 +340,14 @@ void ScDocumentImport::setFormulaCell(const ScAddress& 
rPos, ScTokenArray* pArra
 if (!pBlockPos)
 return;
 
+std::unique_ptr pFC =
+o3tl::make_unique(&mpImpl->mrDoc, rPos, pArray);
+
+mpImpl->mrDoc.CheckLinkFormulaNeedingCheck( *pFC->GetCode());
+
 sc::CellStoreType& rCells = pTab->aCol[rPos.Col()].maCells;
 pBlockPos->miCellPos =
-rCells.set(pBlockPos->miCellPos, rPos.Row(), new 
ScFormulaCell(&mpImpl->mrDoc, rPos, pArray));
+rCells.set(pBlockPos->miCellPos, rPos.Row(), pFC.release());
 }
 
 void ScDocumentImport::setFormulaCell(const ScAddress& rPos, ScFormulaCell* 
pCell)
@@ -354,6 +361,9 @@ void ScDocumentImport::setFormulaCell(const ScAddress& 
rPos, ScFormulaCell* pCel
 if (!pBlockPos)
 return;
 
+if (pCell)
+mpImpl->mrDoc.CheckLinkFormulaNeedingCheck( *pCell->GetCode());
+
 sc::CellStoreType& rCells = pTab->aCol[rPos.Col()].maCells;
 pBlockPos->miCellPos =
 rCells.set(pBlockPos->miCellPos, rPos.Row(), pCell);
@@ -378,6 +388,8 @@ void ScDocumentImport::setMatrixCells(
 // Set the master cell.
 ScFormulaCell* pCell = new ScFormulaCell(&mpImpl->mrDoc, rBasePos, rArray, 
eGram, ScMatrixMode::Formula);
 
+mpImpl->mrDoc.CheckLinkFormulaNeedingCheck( *pCell->GetCode());
+
 pBlockPos->miCellPos =
 rCells.set(pBlockPos->miCellPos, rBasePos.Row(), pCell);
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Noel Grandin
 canvas/source/cairo/cairo_canvashelper_text.cxx |4 -
 canvas/source/vcl/canvashelper_texturefill.cxx  |8 +--
 canvas/source/vcl/impltools.cxx |4 -
 canvas/source/vcl/spritehelper.cxx  |8 +--
 chart2/source/controller/dialogs/DataBrowser.cxx|2 
 chart2/source/controller/dialogs/dlg_CreationWizard.cxx |2 
 chart2/source/controller/main/ChartWindow.cxx   |   20 
 chart2/source/controller/main/DrawCommandDispatch.cxx   |4 -
 cui/source/customize/macropg.cxx|   10 ++--
 cui/source/dialogs/colorpicker.cxx  |   24 -
 cui/source/dialogs/cuicharmap.cxx   |   14 ++---
 cui/source/dialogs/cuigrfflt.cxx|8 +--
 cui/source/dialogs/cuihyperdlg.cxx  |   12 ++--
 cui/source/dialogs/thesdlg.cxx  |6 +-
 cui/source/options/dbregister.cxx   |2 
 cui/source/options/optcolor.cxx |2 
 cui/source/options/optdict.cxx  |4 -
 cui/source/options/optlingu.cxx |8 +--
 cui/source/options/optpath.cxx  |2 
 cui/source/tabpages/autocdlg.cxx|4 -
 cui/source/tabpages/backgrnd.cxx|   22 
 cui/source/tabpages/chardlg.cxx |   16 +++---
 cui/source/tabpages/grfpage.cxx |   12 ++--
 cui/source/tabpages/macroass.cxx|2 
 cui/source/tabpages/numpages.cxx|   18 +++
 cui/source/tabpages/page.cxx|6 +-
 cui/source/tabpages/tabstpge.cxx|4 -
 cui/source/tabpages/tparea.cxx  |4 -
 cui/source/tabpages/tpbitmap.cxx|   40 
 cui/source/tabpages/tpline.cxx  |   12 ++--
 30 files changed, 142 insertions(+), 142 deletions(-)

New commits:
commit f841dada1a5018897cce29ccf972da33ece4738c
Author: Noel Grandin 
Date:   Tue Feb 13 14:21:50 2018 +0200

loplugin:changetoolsgen in canvas..cui

Change-Id: I4e320055a3dbe4159c2aa2714e1ee98182e1e80a
Reviewed-on: https://gerrit.libreoffice.org/49642
Tested-by: Jenkins 
Reviewed-by: Noel Grandin 

diff --git a/canvas/source/cairo/cairo_canvashelper_text.cxx 
b/canvas/source/cairo/cairo_canvashelper_text.cxx
index 806bc415e7b1..b0d07f87cdbe 100644
--- a/canvas/source/cairo/cairo_canvashelper_text.cxx
+++ b/canvas/source/cairo/cairo_canvashelper_text.cxx
@@ -99,8 +99,8 @@ namespace cairocanvas
 io_rVCLFont.SetOrientation( static_cast< short >( 
::basegfx::fround(-fmod(nRotate, 2*M_PI)*(1800.0/M_PI)) ) );
 
 // TODO(F2): Missing functionality in VCL: shearing
-o_rPoint.X() = ::basegfx::fround(aTranslate.getX());
-o_rPoint.Y() = ::basegfx::fround(aTranslate.getY());
+o_rPoint.setX( ::basegfx::fround(aTranslate.getX()) );
+o_rPoint.setY( ::basegfx::fround(aTranslate.getY()) );
 
 return true;
 }
diff --git a/canvas/source/vcl/canvashelper_texturefill.cxx 
b/canvas/source/vcl/canvashelper_texturefill.cxx
index 9d7aaa502a88..892d6d781e8f 100644
--- a/canvas/source/vcl/canvashelper_texturefill.cxx
+++ b/canvas/source/vcl/canvashelper_texturefill.cxx
@@ -78,8 +78,8 @@ namespace vclcanvas
 
 for( nY=0; nY < nTilesY; ++nY )
 {
-aCurrPos.X() = rPosPixel.X() + nY*rNextTileY.Width();
-aCurrPos.Y() = rPosPixel.Y() + nY*rNextTileY.Height();
+aCurrPos.setX( rPosPixel.X() + nY*rNextTileY.Width() );
+aCurrPos.setY( rPosPixel.Y() + nY*rNextTileY.Height() );
 
 for( nX=0; nX < nTilesX; ++nX )
 {
@@ -90,8 +90,8 @@ namespace vclcanvas
rTileSize,
&rAttr );
 
-aCurrPos.X() += rNextTileX.Width();
-aCurrPos.Y() += rNextTileX.Height();
+aCurrPos.setX( aCurrPos.X() + rNextTileX.Width() );
+aCurrPos.setY( aCurrPos.Y() + rNextTileX.Height() );
 }
 }
 
diff --git a/canvas/source/vcl/impltools.cxx b/canvas/source/vcl/impltools.cxx
index 055eb061930e..dd0ca8a0714b 100644
--- a/canvas/source/vcl/impltools.cxx
+++ b/canvas/source/vcl/impltools.cxx
@@ -140,8 +140,8 @@ namespace vclcanvas
 io_rVCLFont.SetOrientation( static_cast< short >( 
::basegfx::fround(-fmod(nRotate, 2*M_PI)*(1800.0/M_PI)) ) );
 
 // TODO(F2): Missing functionality in VCL: shearing
-o_rPoint.X() = ::basegfx::fround(aTranslate.getX());
-o_rPoint.Y() = ::basegfx::fround(aTranslate.getY());
+o_rPoint.setX( ::basegfx::fround(aTranslate.getX()) );

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

2018-02-14 Thread Henry Castro
 desktop/source/lib/init.cxx |5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

New commits:
commit 9763383ebb7e5b10ba9e7557dffa803a8d392c0d
Author: Henry Castro 
Date:   Tue Feb 13 20:54:05 2018 -0400

lok: check if an element exists in the container

Change-Id: I5987e90d92a2ebff654a993fb77e389bd036a8f8
Reviewed-on: https://gerrit.libreoffice.org/49693
Tested-by: Jenkins 
Reviewed-by: Henry Castro 

diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index f5952665d148..bc788d243b9e 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -2850,11 +2850,12 @@ static char* getStyles(LibreOfficeKitDocument* pThis, 
const char* pCommand)
 OUString sName;
 bool bIsPhysical;
 boost::property_tree::ptree aChild;
-uno::Reference xProperty;
 boost::property_tree::ptree aChildren;
+const OUString sPageStyles("PageStyles");
+uno::Reference xProperty;
 uno::Reference xContainer;
 
-if (xStyleFamilies->getByName("PageStyles") >>= xContainer)
+if (xStyleFamilies->hasByName(sPageStyles) && 
(xStyleFamilies->getByName(sPageStyles) >>= xContainer))
 {
 uno::Sequence aSeqNames = xContainer->getElementNames();
 for (sal_Int32 itName = 0; itName < aSeqNames.getLength(); 
itName++)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] online.git: wsd/Storage.cpp

2018-02-14 Thread Andras Timar
 wsd/Storage.cpp |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit baa3e09bdefb49d3aa3c3fddf11cd5a888d8f00b
Author: Andras Timar 
Date:   Wed Feb 14 12:29:50 2018 +0100

Typo: remove -> remote

Change-Id: I6214f569d6a0302c5a5a69a18150122a371e0d03

diff --git a/wsd/Storage.cpp b/wsd/Storage.cpp
index fef0c2b7..c2f3664d 100644
--- a/wsd/Storage.cpp
+++ b/wsd/Storage.cpp
@@ -115,7 +115,7 @@ void StorageBase::initialize()
 // Init client
 Poco::Net::Context::Params sslClientParams;
 
-// TODO: Be more strict and setup SSL key/certs for remove server and us
+// TODO: Be more strict and setup SSL key/certs for remote server and us
 sslClientParams.verificationMode = Poco::Net::Context::VERIFY_NONE;
 
 Poco::SharedPtr 
consoleClientHandler = new Poco::Net::KeyConsoleHandler(false);
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Why does the GTK3 vcl sal plugin default to SvpSalGraphics / software rendering?

2018-02-14 Thread Clemens Eisserer
Hi Tomaz,

Thanks for your time taking a look at this.

> Not sure what you mean software - it is using cairo, which is used for
> canvas in GTK 2/3 for example. Whatever that triggers on cairo's
> backend could be done in software and some code paths could trigger
> code path in X 

This is what I initially assumed too, but it doesn't seem to be the case:

When compiled for GTK3 GtkInstance::CreateVirtualDevice always returns
a SvpSalVirtualDevice (instead of a CreateX11VirtualDevice), which in
turn seems to be unconditionally backed by a cairo image surface.
This is also what I am seeing in my profiles, as soon as I switch to
GTK3 all time is spent inside some cairo/pixman software loops.

Maybe this was done by accident and nobody noticed (except some
performance sensitive users) - but before trying to get X11/Xrender
accelerated rendering working, I thought whether maybe there are
reasons this was implemented this was.


> code path in X which could be performed on the GPU using Glamor (and
> the GPU data upload would kill any performance advantage you would get
> from doing that)

Currently, the X11/GTK2 backend seems to perform a lot better (despite
doing ugly things like XGetImage when extracting the AlphaMap) even
when layered on top of glamor, even with the XServer (and the
additional IPC it causes) in between.

Thanks and best regards, Clemens
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2018-02-14 Thread Andrea Gelmini
 oox/source/core/xmlfilterbase.cxx |1 -
 1 file changed, 1 deletion(-)

New commits:
commit a8af8b792eb653cab807c07b7d9f6ec40b789418
Author: Andrea Gelmini 
Date:   Wed Feb 14 08:09:13 2018 +0100

Removed duplicated include

Change-Id: I53d98e814d9f4760390b9b0a9e826ee91efe6fe8
Reviewed-on: https://gerrit.libreoffice.org/49698
Reviewed-by: Julien Nabet 
Tested-by: Julien Nabet 

diff --git a/oox/source/core/xmlfilterbase.cxx 
b/oox/source/core/xmlfilterbase.cxx
index d268b6f67f45..b4836634ed2a 100644
--- a/oox/source/core/xmlfilterbase.cxx
+++ b/oox/source/core/xmlfilterbase.cxx
@@ -56,7 +56,6 @@
 #include 
 #include 
 #include 
-#include 
 #include 
 #include 
 #include 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Andrea Gelmini
 wizards/source/access2base/Compatible.xba |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 556c62add4ae351e5856786ff362ed722a32246a
Author: Andrea Gelmini 
Date:   Wed Feb 14 11:42:17 2018 +0100

Fix typo

Change-Id: I31e8d775d10d374ef4670a3b8d9a0e9628e8e2c8
Reviewed-on: https://gerrit.libreoffice.org/49710
Reviewed-by: Julien Nabet 
Tested-by: Julien Nabet 

diff --git a/wizards/source/access2base/Compatible.xba 
b/wizards/source/access2base/Compatible.xba
index 77e99bcdc97c..45f3e2eacb9f 100644
--- a/wizards/source/access2base/Compatible.xba
+++ b/wizards/source/access2base/Compatible.xba
@@ -11,7 +11,7 @@ Option Explicit
 REM 
---
 Public Sub DebugPrint(ParamArray pvArgs() As Variant)
 
-'Print arguments unconditionnally in console
+'Print arguments unconditionally in console
 'Arguments are separated by a TAB (simulated by spaces)
 'Some pvArgs might be missing: a TAB is still generated
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


Re: Why does the GTK3 vcl sal plugin default to SvpSalGraphics / software rendering?

2018-02-14 Thread Tomaž Vajngerl
Hi,

On Wed, Feb 14, 2018 at 6:44 PM, Clemens Eisserer  wrote:
> Hi,
>
> While investigaing, I found that with the GTK3 backend all rendering
> is done with SvpSalGraphics in software / on the CPU.
> I wonder what was the relationale behind this decision? And is this
> the right mailing list to ask vcl implementation details?

Not sure what you mean software - it is using cairo, which is used for
canvas in GTK 2/3 for example. Whatever that triggers on cairo's
backend could be done in software and some code paths could trigger
code path in X which could be performed on the GPU using Glamor (and
the GPU data upload would kill any performance advantage you would get
from doing that). Under wayland however there is no such thing -
either you're doing it in software or do it yourself (or a library
that does it) in OpenGL / Vulkan. So the rationale is simple - that's
how rendering is done in GTK3, until GTK4 comes out and its sexy
scenegraph API.

> Best regards, Clemens

Regards, Tomaž
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice-commits] core.git: filter/source forms/source formula/source fpicker/source framework/source

2018-02-14 Thread Noel Grandin
 filter/source/flash/swfwriter1.cxx  |   50 +++---
 filter/source/flash/swfwriter2.cxx  |4 -
 filter/source/graphicfilter/eps/eps.cxx |   12 +--
 filter/source/graphicfilter/idxf/dxf2mtf.cxx|8 +-
 filter/source/graphicfilter/idxf/dxfvec.cxx |4 -
 filter/source/graphicfilter/ios2met/ios2met.cxx |   20 ++---
 filter/source/msfilter/escherex.cxx |   12 +--
 filter/source/msfilter/eschesdo.cxx |   24 +++---
 filter/source/msfilter/msdffimp.cxx |   56 
 filter/source/msfilter/svdfppt.cxx  |   30 
 filter/source/svg/svgwriter.cxx |   37 +-
 filter/source/xsltdialog/xmlfiltersettingsdialog.cxx|6 -
 forms/source/richtext/richtextimplcontrol.cxx   |   16 ++--
 forms/source/solar/control/navtoolbar.cxx   |2 
 formula/source/ui/dlg/structpg.cxx  |2 
 fpicker/source/office/PlacesListBox.cxx |2 
 fpicker/source/office/RemoteFilesDialog.cxx |   10 +-
 fpicker/source/office/iodlg.cxx |   10 +-
 framework/source/layoutmanager/helpers.cxx  |8 +-
 framework/source/layoutmanager/layoutmanager.cxx|2 
 framework/source/layoutmanager/toolbarlayoutmanager.cxx |   24 +++---
 framework/source/uiconfiguration/ImageList.cxx  |4 -
 framework/source/uielement/addonstoolbarwrapper.cxx |2 
 framework/source/uielement/toolbarmanager.cxx   |2 
 framework/source/uielement/toolbarwrapper.cxx   |4 -
 25 files changed, 176 insertions(+), 175 deletions(-)

New commits:
commit bf8a6cacd06d7c1961b5db8cc79ee4bbdb342e43
Author: Noel Grandin 
Date:   Wed Feb 14 09:22:30 2018 +0200

loplugin:changetoolsgen in filter..framework

Change-Id: I622da8a0c096c74efd97326451c4576b230f0483
Reviewed-on: https://gerrit.libreoffice.org/49701
Reviewed-by: Noel Grandin 
Tested-by: Noel Grandin 

diff --git a/filter/source/flash/swfwriter1.cxx 
b/filter/source/flash/swfwriter1.cxx
index 7f82c97e8491..4b627d50e4bc 100644
--- a/filter/source/flash/swfwriter1.cxx
+++ b/filter/source/flash/swfwriter1.cxx
@@ -57,8 +57,8 @@ Point Writer::map( const Point& rPoint ) const
 
 // AS: Produces a 'possible loss of data' warning that we can't fix without
 //  hurting code readability.
-retPoint.X() = static_cast( retPoint.X() * mnDocXScale );
-retPoint.Y() = static_cast( retPoint.Y() * mnDocYScale );
+retPoint.setX( static_cast( retPoint.X() * mnDocXScale ) );
+retPoint.setY( static_cast( retPoint.Y() * mnDocYScale ) );
 
 return retPoint;
 }
@@ -72,8 +72,8 @@ Size Writer::map( const Size& rSize ) const
 
 // AS: Produces a 'possible loss of data' warning that we can't fix without
 //  hurting code readability.
-retSize.Width() = static_cast( retSize.Width() * mnDocXScale );
-retSize.Height() = static_cast( retSize.Height() * mnDocYScale );
+retSize.setWidth( static_cast( retSize.Width() * mnDocXScale ) );
+retSize.setHeight( static_cast( retSize.Height() * mnDocYScale ) );
 
 return retSize;
 }
@@ -521,7 +521,7 @@ void Writer::Impl_writeText( const Point& rPos, const 
OUString& rText, const lon
 
 if( nLen > 1 )
 {
-aNormSize.Width() = pDX[ nLen - 2 ] + mpVDev->GetTextWidth( 
OUString(rText[nLen - 1]) );
+aNormSize.setWidth( pDX[ nLen - 2 ] + mpVDev->GetTextWidth( 
OUString(rText[nLen - 1]) ) );
 
 if( nWidth && aNormSize.Width() && ( nWidth != aNormSize.Width() ) 
)
 {
@@ -550,11 +550,11 @@ void Writer::Impl_writeText( const Point& rPos, const 
OUString& rText, const lon
 switch( aOldFont.GetAlignment() )
 {
 case ALIGN_TOP:
-aBaseLinePos.Y() += aMetric.GetAscent();
+aBaseLinePos.setY( aBaseLinePos.Y() + aMetric.GetAscent() );
 break;
 
 case ALIGN_BOTTOM:
-aBaseLinePos.Y() -= aMetric.GetDescent();
+aBaseLinePos.setY( aBaseLinePos.Y() - aMetric.GetDescent() );
 break;
 
 default:
@@ -664,14 +664,14 @@ void Writer::Impl_writeText( const Point& rPos, const 
OUString& rText, const lon
 
 if( aOldFont.GetStrikeout() != STRIKEOUT_NONE )
 {
-aPoly[ 0 ].X() = aBaseLinePos.X();
-aPoly[ 0 ].Y() = aBaseLinePos.Y() - FRound( 
aMetric.GetAscent() * 0.26 ) - nLineHeight;
-aPoly[ 1 ].X() = aPoly[ 0 ].X() + aNormSize.Width() - 1;
-aPoly[ 1 ].Y() = aPoly[ 0 ].Y();
-aPoly[ 2 ].X() = aPoly[ 1 ].X();
-aPoly[ 2 ].Y() = aPoly[ 1 ].Y() + nLineHeight - 1;
-aPoly[ 3 ].X() = aPoly[ 0 ].X();
-aPoly[ 3 ].Y() = aPoly[ 2 ].Y();
+aPoly[ 0 ].s

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

2018-02-14 Thread Stephan Bergmann
 editeng/source/items/frmitems.cxx   |   24 +++
 include/editeng/sizeitem.hxx|   13 
 sw/inc/fmtfsize.hxx |   18 ++---
 sw/source/core/layout/atrfrm.cxx|   37 
 sw/source/uibase/uiview/viewtab.cxx |4 +--
 5 files changed, 55 insertions(+), 41 deletions(-)

New commits:
commit e2372907c991833a8bbe13f84460783d8d8fdfdb
Author: Stephan Bergmann 
Date:   Tue Feb 13 18:57:46 2018 +0100

Make SwFormatFrameSize derive from SvxSizeItem

...as seen in UBSan builds when, on an image in Writer, selecting context 
menu's
"Properties..." to open the "Image" dialog, there'll be failure

> cui/source/tabpages/grfpage.cxx:206:21: runtime error: downcast of 
address 0x1293f5c0 which does not point to an object of type 'const 
SvxSizeItem'
> 0x1293f5c0: note: object is of type 'SwFormatFrameSize'
 00 00 00 00  68 d5 ea aa 8f 7f 00 00  01 00 00 00 43 27 00 00  81 2e 00 00 
00 00 00 00  c5 41 00 00
>   ^~~
>   vptr for 'SwFormatFrameSize'
> #0 0x7f8f1ec29a34 in SvxGrfCropPage::Reset(SfxItemSet const*) 
cui/source/tabpages/grfpage.cxx:206:21
> #1 0x7f9036000d98 in SfxTabDialog::ActivatePageHdl(TabControl*) 
sfx2/source/dialog/tabdlg.cxx:1115:19

Moved the {Get,Set}{Width,Height} convenience functions down from
SwFormatFrameSize to SvxSizeItem.  And "reverted" the SvxSizeItem
{Has,Scale}Metrics overrides in SwFormatFrameSize, "just in case."  Renamed
SvxSizeItem::aSize to m_aSize to avoid GCC -Werror=shadow in
SwFormatFrameSize::dumpAsXml (sw/source/core/layout/atrfrm.cxx), which has a
local variable named aSize.

Change-Id: I9a2e0b19f21c1468ecba87a5bdafa40c8c424ae4
Reviewed-on: https://gerrit.libreoffice.org/49678
Tested-by: Jenkins 
Reviewed-by: Miklos Vajna 

diff --git a/editeng/source/items/frmitems.cxx 
b/editeng/source/items/frmitems.cxx
index 0ed13e1088af..f39dc856fb3d 100644
--- a/editeng/source/items/frmitems.cxx
+++ b/editeng/source/items/frmitems.cxx
@@ -201,7 +201,7 @@ SvxSizeItem::SvxSizeItem( const sal_uInt16 nId, const Size& 
rSize ) :
 
 SfxPoolItem( nId ),
 
-aSize( rSize )
+m_aSize( rSize )
 {
 }
 
@@ -211,7 +211,7 @@ bool SvxSizeItem::QueryValue( uno::Any& rVal, sal_uInt8 
nMemberId ) const
 bool bConvert = 0!=(nMemberId&CONVERT_TWIPS);
 nMemberId &= ~CONVERT_TWIPS;
 
-awt::Size aTmp(aSize.Width(), aSize.Height());
+awt::Size aTmp(m_aSize.Width(), m_aSize.Height());
 if( bConvert )
 {
 aTmp.Height = convertTwipToMm100(aTmp.Height);
@@ -247,7 +247,7 @@ bool SvxSizeItem::PutValue( const uno::Any& rVal, sal_uInt8 
nMemberId )
 aTmp.Height = convertMm100ToTwip(aTmp.Height);
 aTmp.Width = convertMm100ToTwip(aTmp.Width);
 }
-aSize = Size( aTmp.Width, aTmp.Height );
+m_aSize = Size( aTmp.Width, aTmp.Height );
 }
 else
 {
@@ -261,7 +261,7 @@ bool SvxSizeItem::PutValue( const uno::Any& rVal, sal_uInt8 
nMemberId )
 if(!(rVal >>= nVal ))
 return false;
 
-aSize.setWidth( bConvert ? convertMm100ToTwip(nVal) : nVal );
+m_aSize.setWidth( bConvert ? convertMm100ToTwip(nVal) : nVal );
 }
 break;
 case MID_SIZE_HEIGHT:
@@ -270,7 +270,7 @@ bool SvxSizeItem::PutValue( const uno::Any& rVal, sal_uInt8 
nMemberId )
 if(!(rVal >>= nVal))
 return true;
 
-aSize.setHeight( bConvert ? convertMm100ToTwip(nVal) : nVal );
+m_aSize.setHeight( bConvert ? convertMm100ToTwip(nVal) : nVal );
 }
 break;
 default: OSL_FAIL("Wrong MemberId!");
@@ -291,7 +291,7 @@ bool SvxSizeItem::operator==( const SfxPoolItem& rAttr ) 
const
 {
 assert(SfxPoolItem::operator==(rAttr));
 
-return ( aSize == static_cast( rAttr ).GetSize() );
+return ( m_aSize == static_cast( rAttr ).GetSize() );
 }
 
 
@@ -313,18 +313,18 @@ bool SvxSizeItem::GetPresentation
 switch ( ePres )
 {
 case SfxItemPresentation::Nameless:
-rText = GetMetricText( aSize.Width(), eCoreUnit, ePresUnit, &rIntl 
) +
+rText = GetMetricText( m_aSize.Width(), eCoreUnit, ePresUnit, 
&rIntl ) +
 cpDelimTmp +
-GetMetricText( aSize.Height(), eCoreUnit, ePresUnit, 
&rIntl );
+GetMetricText( m_aSize.Height(), eCoreUnit, ePresUnit, 
&rIntl );
 return true;
 
 case SfxItemPresentation::Complete:
 rText = EditResId(RID_SVXITEMS_SIZE_WIDTH) +
-GetMetricText( aSize.Width(), eCoreUnit, ePresUnit, &rIntl 
) +
+GetMetricText( m_aSize.Width(), eCoreUnit, ePresUnit, 
&rIntl ) +
 " " + EditResId(GetMetricId(ePresUnit)) +
   

Why does the GTK3 vcl sal plugin default to SvpSalGraphics / software rendering?

2018-02-14 Thread Clemens Eisserer
Hi,

I am currently analyzing performance issues when scrolling larger
images in writer on linux, especially when they have an alpha channel:
https://bugs.documentfoundation.org/show_bug.cgi?id=115702
https://bugs.documentfoundation.org/show_bug.cgi?id=80659
https://bugs.documentfoundation.org/show_bug.cgi?id=87485

Some reports indicate that the GTK3 vcl backend seems to be particulary bad.

While investigaing, I found that with the GTK3 backend all rendering
is done with SvpSalGraphics in software / on the CPU.
I wonder what was the relationale behind this decision? And is this
the right mailing list to ask vcl implementation details?

Best regards, Clemens
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


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

2018-02-14 Thread Justin Luth
 sw/source/core/crsr/findtxt.cxx |   16 +---
 1 file changed, 13 insertions(+), 3 deletions(-)

New commits:
commit 5054456a6ed8ef7cd2a05fb09e1954eb02eaf0f7
Author: Justin Luth 
Date:   Wed Feb 7 20:17:31 2018 +0300

tdf#102374: regex allow ReplaceBackReferences for $ search

Since searching for $ spans nodes, and normal searches don't find it
(see bChkParaEnd and bChkEmptyPara), all "replace" items were
being used verbatim instead of being transformed. So, a similar
"just make it work" hack is needed here.

This patch allows proper replacement for \[\&$t] as well as
& and $0.

Change-Id: I59d760e27acacff679decdcb7fcf337f3b4a1fa1
Reviewed-on: https://gerrit.libreoffice.org/49387
Tested-by: Jenkins 
Reviewed-by: Justin Luth 
Reviewed-by: Michael Stahl 
(cherry picked from commit 9bb369edf5471d0b29b5cea86d7203831f93d529)
Reviewed-on: https://gerrit.libreoffice.org/49679

diff --git a/sw/source/core/crsr/findtxt.cxx b/sw/source/core/crsr/findtxt.cxx
index d63d66cbf41d..7d5842b883b4 100644
--- a/sw/source/core/crsr/findtxt.cxx
+++ b/sw/source/core/crsr/findtxt.cxx
@@ -758,15 +758,25 @@ OUString *ReplaceBackReferences( const 
i18nutil::SearchOptions2& rSearchOpt, SwP
 SearchAlgorithms2::REGEXP == rSearchOpt.AlgorithmType2 )
 {
 const SwContentNode* pTextNode = pPam->GetContentNode();
-if( pTextNode && pTextNode->IsTextNode() && pTextNode == 
pPam->GetContentNode( false ) )
+const bool bParaEnd = rSearchOpt.searchString == "$" || 
rSearchOpt.searchString == "^$" || rSearchOpt.searchString == "$^";
+if ( pTextNode && pTextNode->IsTextNode() && (bParaEnd || pTextNode == 
pPam->GetContentNode( false )) )
 {
 utl::TextSearch aSText( utl::TextSearch::UpgradeToSearchOptions2( 
rSearchOpt) );
-const OUString& rStr = pTextNode->GetTextNode()->GetText();
+OUString rStr = pTextNode->GetTextNode()->GetText();
 sal_Int32 nStart = pPam->Start()->nContent.GetIndex();
 sal_Int32 nEnd = pPam->End()->nContent.GetIndex();
 SearchResult aResult;
-if( aSText.SearchForward( rStr, &nStart, &nEnd, &aResult ) )
+if ( bParaEnd || aSText.SearchForward( rStr, &nStart, &nEnd, 
&aResult ) )
 {
+if ( bParaEnd )
+{
+rStr = "\\n";
+aResult.subRegExpressions = 1;
+aResult.startOffset.realloc(1);
+aResult.endOffset.realloc(1);
+aResult.startOffset[0] = 0;
+aResult.endOffset[0] = rStr.getLength();
+}
 OUString aReplaceStr( rSearchOpt.replaceString );
 aSText.ReplaceBackReferences( aReplaceStr, rStr, aResult );
 pRet = new OUString( aReplaceStr );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Yousuf Philips
 officecfg/registry/data/org/openoffice/Office/Accelerators.xcu |8 +++-
 1 file changed, 7 insertions(+), 1 deletion(-)

New commits:
commit 532576461654eaf43120d2f693172c07a41275fa
Author: Yousuf Philips 
Date:   Sun Jan 28 19:52:42 2018 +0400

tdf#114858 Use Ctrl+` for Formula Toggle on Mac

Change-Id: I0685eb0d1f6ea7c8502bbaa22f0e90004947282d
Reviewed-on: https://gerrit.libreoffice.org/48793
Tested-by: Jenkins 
Reviewed-by: Yousuf Philips 

diff --git a/officecfg/registry/data/org/openoffice/Office/Accelerators.xcu 
b/officecfg/registry/data/org/openoffice/Office/Accelerators.xcu
index b3f195413c17..6e9182150a56 100644
--- a/officecfg/registry/data/org/openoffice/Office/Accelerators.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/Accelerators.xcu
@@ -1080,7 +1080,13 @@
 
   
 I10N SHORTCUTS - NO 
TRANSLATE
-.uno:ToggleFormula
+.uno:ToggleFormula
+  
+
+
+  
+I10N SHORTCUTS - NO 
TRANSLATE
+.uno:ToggleFormula
   
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Jim Raykowski
 sw/source/ui/dbui/mmoutputtypepage.cxx |   48 ++---
 sw/source/ui/dbui/mmresultdialogs.cxx  |8 +++--
 sw/source/ui/inc/mmresultdialogs.hxx   |   11 +++
 sw/source/uibase/uiview/viewsrch.cxx   |3 ++
 sw/uiconfig/swriter/ui/mmsendmails.ui  |4 +-
 5 files changed, 42 insertions(+), 32 deletions(-)

New commits:
commit 106f66e921da871c26ce6b642f9f67024417b93d
Author: Jim Raykowski 
Date:   Mon Feb 12 23:43:00 2018 -0900

tdf#115620 Prevent "Find Text" changing "Navigate By"

Change-Id: I46ab436e98f0d24e51277f22b2a707dfd5e2937c
Reviewed-on: https://gerrit.libreoffice.org/49690
Tested-by: Jenkins 
Reviewed-by: Thorsten Behrens 
(cherry picked from commit eb975197b62204062393979e33438a3a4e2d27c1)
Reviewed-on: https://gerrit.libreoffice.org/49696
Reviewed-by: Katarina Behrens 

diff --git a/sw/source/uibase/uiview/viewsrch.cxx 
b/sw/source/uibase/uiview/viewsrch.cxx
index e6fc466dfc9a..463bd92054df 100644
--- a/sw/source/uibase/uiview/viewsrch.cxx
+++ b/sw/source/uibase/uiview/viewsrch.cxx
@@ -198,6 +198,7 @@ void SwView::ExecSearch(SfxRequest& rReq)
 case FN_REPEAT_SEARCH:
 case FID_SEARCH_NOW:
 {
+sal_uInt16 nMoveType = SwView::GetMoveType();
 {
 if(FID_SEARCH_NOW == nSlot && !rReq.IsAPI())
 SwView::SetMoveType(NID_SRCH_REP);
@@ -396,6 +397,7 @@ void SwView::ExecSearch(SfxRequest& rReq)
 }
 #endif
 m_bFound = false;
+SwView::SetMoveType(nMoveType);
 return;
 }
 
@@ -425,6 +427,7 @@ void SwView::ExecSearch(SfxRequest& rReq)
 
 rReq.Done();
 m_eLastSearchCommand = m_pSrchItem->GetCommand();
+SwView::SetMoveType(nMoveType);
 }
 break;
 case FID_SEARCH_SEARCHSET:
commit e0d32e7fc9abd0c5718398f6ed80a75c392e746a
Author: Alex McMurchy1917 
Date:   Thu Aug 24 14:34:13 2017 +0100

tdf#103919 mailmerge: prevent premature end of emailing

...by changing the parent of SwSendMailDialog.

The destruction of the main dialog (SwMMResultEmailDialog) also
closes the progress dlg (SwSendMailDialog), which shuts down the
dispatcher stopping anymore messages from being sent. Have changed
the parent of progress dlg such that it will not close when the
main dialog is closed. This has allowed the main dialog to be
closed immediately after the progress dialog had been created
making for a cleaner ui.

During the development of this patch
there were problems with the timer causing LO to consistently crash
during the dispose of OutputDevice, but I could find no logical
reason for the crashes.
(It didn't crash if smtp authentication failed. It also didn't
crash when run in gdb...)
Moving the exit code from StateChanged to CloseHdl magically
fixed the crashing problem. I think it makes it a bit clearer
to end in closeHdl anyway, and start the timer only in case of
an early cancellation (before all the mail messages
have been queued up). This eliminates MOST of the use of the
timer - since the typical exit occurs after the email process
has finished.

Change-Id: Icd3af372772fab3e78eb0702b120d7a811baa6bd
Reviewed-on: https://gerrit.libreoffice.org/41519
Tested-by: Jenkins 
Reviewed-by: Justin Luth 
Reviewed-by: Thorsten Behrens 
Reviewed-on: https://gerrit.libreoffice.org/49680

diff --git a/sw/source/ui/dbui/mmoutputtypepage.cxx 
b/sw/source/ui/dbui/mmoutputtypepage.cxx
index 0dd9bedcc917..dd9ce480b9f0 100644
--- a/sw/source/ui/dbui/mmoutputtypepage.cxx
+++ b/sw/source/ui/dbui/mmoutputtypepage.cxx
@@ -241,7 +241,7 @@ SwSendWarningBox_Impl::SwSendWarningBox_Impl(vcl::Window* 
pParent, const OUStrin
 #define ITEMID_STATUS   2
 
 SwSendMailDialog::SwSendMailDialog(vcl::Window *pParent, 
SwMailMergeConfigItem& rConfigItem) :
-ModelessDialog /*SfxModalDialog*/(pParent, "SendMailsDialog", 
"modules/swriter/ui/mmsendmails.ui"),
+Dialog(pParent, "SendMailsDialog", "modules/swriter/ui/mmsendmails.ui"),
 m_pTransferStatus(get("transferstatus")),
 m_pPaused(get("paused")),
 m_pProgressBar(get("progress")),
@@ -257,9 +257,10 @@ SwSendMailDialog::SwSendMailDialog(vcl::Window *pParent, 
SwMailMergeConfigItem&
 m_sCompleted(   SwResId(ST_COMPLETED )),
 m_sFailed(  SwResId(ST_FAILED )),
 m_bCancel(false),
-m_bDesctructionEnabled(false),
+m_bDestructionEnabled(false),
 m_pImpl(new SwSendMailDialog_Impl),
 m_pConfigItem(&rConfigItem),
+m_nExpectedCount(0),
 m_nSendCount(0),
 m_nErrorCount(0)
 {
@@ -290,6 +291,7 @@ SwSendMailDialog::SwSendMailDialog(vcl::Window *pParent, 
SwMailMergeConfigItem&
 m_pStatus->SetTabs(&nTabs[0], MapUnit::MapPixel);
 m_pStatus->SetSpaceBetweenEntries(3);
 
+m_pPaused->Show(false);
 UpdateT

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

2018-02-14 Thread Michael Stahl
 sw/source/core/inc/UndoInsert.hxx |2 +-
 sw/source/core/undo/unins.cxx |   24 +---
 2 files changed, 14 insertions(+), 12 deletions(-)

New commits:
commit 0b574c7315b2ea6f1401502e0a8ae4f0c2a41457
Author: Michael Stahl 
Date:   Tue Feb 13 17:46:44 2018 +0100

sw: replace DELETEZ with unique_ptr in SwUndoInsert

Change-Id: I127eba390068ba241ff2b67e2bc99f3b907195db
Reviewed-on: https://gerrit.libreoffice.org/49675
Tested-by: Jenkins 
Reviewed-by: Michael Stahl 

diff --git a/sw/source/core/inc/UndoInsert.hxx 
b/sw/source/core/inc/UndoInsert.hxx
index 35a1a6b62c13..d16b2c07aa91 100644
--- a/sw/source/core/inc/UndoInsert.hxx
+++ b/sw/source/core/inc/UndoInsert.hxx
@@ -41,7 +41,7 @@ class SwUndoInsert: public SwUndo, private SwUndoSaveContent
 {
 /// start of Content in UndoNodes for Redo
 std::unique_ptr m_pUndoNodeIndex;
-OUString *pText;
+std::unique_ptr m_pText;
 std::unique_ptr pUndoText;
 SwRedlineData* pRedlData;
 sal_uLong nNode;
diff --git a/sw/source/core/undo/unins.cxx b/sw/source/core/undo/unins.cxx
index 23723aff8a69..af2f8c718a89 100644
--- a/sw/source/core/undo/unins.cxx
+++ b/sw/source/core/undo/unins.cxx
@@ -111,7 +111,7 @@ SwUndoInsert::SwUndoInsert( const SwNodeIndex& rNd, 
sal_Int32 nCnt,
 sal_Int32 nL,
 const SwInsertFlags nInsertFlags,
 bool bWDelim )
-: SwUndo(SwUndoId::TYPING, rNd.GetNode().GetDoc()), pText( nullptr ), 
pRedlData( nullptr ),
+: SwUndo(SwUndoId::TYPING, rNd.GetNode().GetDoc()), pRedlData( nullptr ),
 nNode( rNd.GetIndex() ), nContent(nCnt), nLen(nL),
 bIsWordDelim( bWDelim ), bIsAppend( false )
 , m_bWithRsid(false)
@@ -121,7 +121,7 @@ SwUndoInsert::SwUndoInsert( const SwNodeIndex& rNd, 
sal_Int32 nCnt,
 }
 
 SwUndoInsert::SwUndoInsert( const SwNodeIndex& rNd )
-: SwUndo(SwUndoId::SPLITNODE, rNd.GetNode().GetDoc()), pText( nullptr ),
+: SwUndo(SwUndoId::SPLITNODE, rNd.GetNode().GetDoc()),
 pRedlData( nullptr ), nNode( rNd.GetIndex() ), nContent(0), nLen(1),
 bIsWordDelim( false ), bIsAppend( true )
 , m_bWithRsid(false)
@@ -202,7 +202,9 @@ SwUndoInsert::~SwUndoInsert()
 m_pUndoNodeIndex.reset();
 }
 else // the inserted text
-delete pText;
+{
+m_pText.reset();
+}
 delete pRedlData;
 }
 
@@ -258,7 +260,7 @@ void SwUndoInsert::UndoImpl(::sw::UndoRedoContext & 
rContext)
 aPaM.GetMark()->nContent.GetIndex());
 }
 RemoveIdxFromRange( aPaM, false );
-pText = new OUString( pTextNode->GetText().copy(nContent-nLen, 
nLen) );
+m_pText.reset(new 
OUString(pTextNode->GetText().copy(nContent-nLen, nLen)));
 pTextNode->EraseText( aPaM.GetPoint()->nContent, nLen );
 }
 else// otherwise Graphics/OLE/Text/...
@@ -272,7 +274,7 @@ void SwUndoInsert::UndoImpl(::sw::UndoRedoContext & 
rContext)
 nNd = aPaM.GetPoint()->nNode.GetIndex();
 nCnt = aPaM.GetPoint()->nContent.GetIndex();
 
-if( !pText )
+if (!m_pText)
 {
 m_pUndoNodeIndex.reset(
 new SwNodeIndex(pDoc->GetNodes().GetEndOfContent()));
@@ -332,15 +334,15 @@ void SwUndoInsert::RedoImpl(::sw::UndoRedoContext & 
rContext)
 {
 const bool bMvBkwrd = MovePtBackward( *pPam );
 
-if( pText )
+if (m_pText)
 {
 SwTextNode *const pTextNode = pCNd->GetTextNode();
 OSL_ENSURE( pTextNode, "where is my textnode ?" );
 OUString const ins(
-pTextNode->InsertText( *pText, pPam->GetMark()->nContent,
+pTextNode->InsertText( *m_pText, pPam->GetMark()->nContent,
 m_nInsertFlags) );
-assert(ins.getLength() == pText->getLength()); // must succeed
-DELETEZ( pText );
+assert(ins.getLength() == m_pText->getLength()); // must 
succeed
+m_pText.reset();
 if (m_bWithRsid) // re-insert RSID
 {
 SwPaM pam(*pPam->GetMark(), nullptr); // mark -> point
@@ -459,8 +461,8 @@ SwRewriter SwUndoInsert::GetRewriter() const
 OUString * pStr = nullptr;
 bool bDone = false;
 
-if (pText)
-pStr = pText;
+if (m_pText)
+pStr = m_pText.get();
 else if (pUndoText)
 pStr = pUndoText.get();
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Michael Stahl
 sw/inc/undobj.hxx  |4 ++--
 sw/source/core/undo/undobj.cxx |   22 +++---
 2 files changed, 13 insertions(+), 13 deletions(-)

New commits:
commit c77429bc28e3baf2f20c5e3fa313abad943f2335
Author: Michael Stahl 
Date:   Tue Feb 13 17:30:47 2018 +0100

sw: replace DELETEZ with unique_ptr in SwUndoSaveSection

Change-Id: Ic57736a6d1349574f779afc26b8785caf575cf06
Reviewed-on: https://gerrit.libreoffice.org/49674
Tested-by: Jenkins 
Reviewed-by: Michael Stahl 

diff --git a/sw/inc/undobj.hxx b/sw/inc/undobj.hxx
index f71f8873e1e1..48a576dca537 100644
--- a/sw/inc/undobj.hxx
+++ b/sw/inc/undobj.hxx
@@ -185,13 +185,13 @@ public:
 // Save a complete section in nodes-array.
 class SwUndoSaveSection : private SwUndoSaveContent
 {
-SwNodeIndex *pMvStt;
+std::unique_ptr m_pMovedStart;
 SwRedlineSaveDatas* pRedlSaveData;
 sal_uLong nMvLen;   // Index into UndoNodes-Array.
 sal_uLong nStartPos;
 
 protected:
-SwNodeIndex* GetMvSttIdx() const { return pMvStt; }
+SwNodeIndex* GetMvSttIdx() const { return m_pMovedStart.get(); }
 sal_uLong GetMvNodeCnt() const { return nMvLen; }
 
 public:
diff --git a/sw/source/core/undo/undobj.cxx b/sw/source/core/undo/undobj.cxx
index bb6e1c50af90..4c624a6018f8 100644
--- a/sw/source/core/undo/undobj.cxx
+++ b/sw/source/core/undo/undobj.cxx
@@ -1181,19 +1181,19 @@ void SwUndoSaveContent::DelContentIndex( const 
SwPosition& rMark,
 
 // save a complete section into UndoNodes array
 SwUndoSaveSection::SwUndoSaveSection()
-: pMvStt( nullptr ), pRedlSaveData( nullptr ), nMvLen( 0 ), nStartPos( 
ULONG_MAX )
+: pRedlSaveData( nullptr ), nMvLen( 0 ), nStartPos( ULONG_MAX )
 {
 }
 
 SwUndoSaveSection::~SwUndoSaveSection()
 {
-if( pMvStt )// delete also the section from UndoNodes array
+if (m_pMovedStart) // delete also the section from UndoNodes array
 {
 // SaveSection saves the content in the PostIt section.
-SwNodes& rUNds = pMvStt->GetNode().GetNodes();
-rUNds.Delete( *pMvStt, nMvLen );
+SwNodes& rUNds = m_pMovedStart->GetNode().GetNodes();
+rUNds.Delete( *m_pMovedStart, nMvLen );
 
-delete pMvStt;
+m_pMovedStart.reset();
 }
 delete pRedlSaveData;
 }
@@ -1239,9 +1239,9 @@ void SwUndoSaveSection::SaveSection(
 
 // Keep positions as SwIndex so that this section can be deleted in DTOR
 sal_uLong nEnd;
-pMvStt = new SwNodeIndex( rRange.aStart );
-MoveToUndoNds(aPam, pMvStt, &nEnd);
-nMvLen = nEnd - pMvStt->GetIndex() + 1;
+m_pMovedStart.reset(new SwNodeIndex(rRange.aStart));
+MoveToUndoNds(aPam, m_pMovedStart.get(), &nEnd);
+nMvLen = nEnd - m_pMovedStart->GetIndex() + 1;
 }
 
 void SwUndoSaveSection::RestoreSection( SwDoc* pDoc, SwNodeIndex* pIdx,
@@ -1268,11 +1268,11 @@ void SwUndoSaveSection::RestoreSection( SwDoc* pDoc, 
const SwNodeIndex& rInsPos
 if( ULONG_MAX != nStartPos )// was there any content?
 {
 SwPosition aInsPos( rInsPos );
-sal_uLong nEnd = pMvStt->GetIndex() + nMvLen - 1;
-MoveFromUndoNds(*pDoc, pMvStt->GetIndex(), aInsPos, &nEnd);
+sal_uLong nEnd = m_pMovedStart->GetIndex() + nMvLen - 1;
+MoveFromUndoNds(*pDoc, m_pMovedStart->GetIndex(), aInsPos, &nEnd);
 
 // destroy indices again, content was deleted from UndoNodes array
-DELETEZ( pMvStt );
+m_pMovedStart.reset();
 nMvLen = 0;
 
 if( pRedlSaveData )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Michael Stahl
 sw/inc/doc.hxx|4 ++--
 sw/source/core/doc/docnew.cxx |   19 ---
 2 files changed, 14 insertions(+), 9 deletions(-)

New commits:
commit f311dc973e70ed38767a857cd201ee4a73d45830
Author: Michael Stahl 
Date:   Tue Feb 13 15:01:02 2018 +0100

sw: convert DELETEZ to unique_ptr in SwDoc

Change-Id: Ice9957fefea98a878281f64ab129a452a31f27bb
Reviewed-on: https://gerrit.libreoffice.org/49668
Tested-by: Jenkins 
Reviewed-by: Michael Stahl 

diff --git a/sw/inc/doc.hxx b/sw/inc/doc.hxx
index 331132911936..440127f743fd 100644
--- a/sw/inc/doc.hxx
+++ b/sw/inc/doc.hxx
@@ -307,7 +307,7 @@ class SW_DLLPUBLIC SwDoc final
 // Hash map to find numrules by name
 mutable std::unordered_map maNumRuleMap;
 
-SwPagePreviewPrtData *mpPgPViewPrtData;//< Indenting / spacing for 
printing of page view.
+std::unique_ptr m_pPgPViewPrtData; //< Indenting / 
spacing for printing of page view.
 SwPaM   *mpExtInputRing;
 
 IStyleAccess*mpStyleAccess;//< handling of automatic 
styles
@@ -1446,7 +1446,7 @@ public:
 void ClearDoc();// Deletes all content!
 
 // Query /set data for PagePreview.
-const SwPagePreviewPrtData* GetPreviewPrtData() const { return 
mpPgPViewPrtData; }
+const SwPagePreviewPrtData* GetPreviewPrtData() const { return 
m_pPgPViewPrtData.get(); }
 
 // If pointer == 0 destroy pointer in document.
 // Else copy object.
diff --git a/sw/source/core/doc/docnew.cxx b/sw/source/core/doc/docnew.cxx
index 5c55de44eb9a..7baf06eb7da1 100644
--- a/sw/source/core/doc/docnew.cxx
+++ b/sw/source/core/doc/docnew.cxx
@@ -252,7 +252,6 @@ SwDoc::SwDoc()
 mpURLStateChgd( nullptr ),
 mpNumberFormatter( nullptr ),
 mpNumRuleTable( new SwNumRuleTable ),
-mpPgPViewPrtData( nullptr ),
 mpExtInputRing( nullptr ),
 mpStyleAccess( nullptr ),
 mpLayoutCache( nullptr ),
@@ -406,7 +405,7 @@ SwDoc::~SwDoc()
 ClrContourCache();
 }
 
-delete mpPgPViewPrtData;
+m_pPgPViewPrtData.reset();
 
 mbDtor = true;
 
@@ -752,13 +751,19 @@ void SwDoc::SetPreviewPrtData( const 
SwPagePreviewPrtData* pNew )
 {
 if( pNew )
 {
-if( mpPgPViewPrtData )
-*mpPgPViewPrtData = *pNew;
+if (m_pPgPViewPrtData)
+{
+*m_pPgPViewPrtData = *pNew;
+}
 else
-mpPgPViewPrtData = new SwPagePreviewPrtData( *pNew );
+{
+m_pPgPViewPrtData.reset(new SwPagePreviewPrtData(*pNew));
+}
+}
+else if (m_pPgPViewPrtData)
+{
+m_pPgPViewPrtData.reset();
 }
-else if( mpPgPViewPrtData )
-DELETEZ( mpPgPViewPrtData );
 getIDocumentState().SetModified();
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Michael Stahl
 svl/source/misc/PasswordHelper.cxx |4 
 1 file changed, 4 insertions(+)

New commits:
commit 306cd912b5b84c02ae9b786f72963506369df649
Author: Michael Stahl 
Date:   Tue Feb 13 15:46:20 2018 +0100

svl: clear temporary copies of passwords in SvlPasswordHelper

This is an obvious place to start, but there might be more copies
elsewhere.

Change-Id: I3c3ea6cb54f40fe5c21c3128b55aeaad1ff74b42
Reviewed-on: https://gerrit.libreoffice.org/49669
Tested-by: Jenkins 
Reviewed-by: Michael Stahl 

diff --git a/svl/source/misc/PasswordHelper.cxx 
b/svl/source/misc/PasswordHelper.cxx
index 48aa165507ee..4f8cbb655b08 100644
--- a/svl/source/misc/PasswordHelper.cxx
+++ b/svl/source/misc/PasswordHelper.cxx
@@ -33,6 +33,7 @@ void 
SvPasswordHelper::GetHashPasswordSHA256(uno::Sequence& rPassHash,
 ::comphelper::HashType::SHA256));
 rPassHash.realloc(hash.size());
 ::std::copy(hash.begin(), hash.end(), rPassHash.begin());
+rtl_secureZeroMemory(const_cast(tmp.getStr()), 
tmp.getLength());
 }
 
 void SvPasswordHelper::GetHashPasswordSHA1UTF8(uno::Sequence& 
rPassHash, OUString const& rPassword)
@@ -43,6 +44,7 @@ void 
SvPasswordHelper::GetHashPasswordSHA1UTF8(uno::Sequence& rPassHas
 ::comphelper::HashType::SHA1));
 rPassHash.realloc(hash.size());
 ::std::copy(hash.begin(), hash.end(), rPassHash.begin());
+rtl_secureZeroMemory(const_cast(tmp.getStr()), 
tmp.getLength());
 }
 
 void SvPasswordHelper::GetHashPassword(uno::Sequence& rPassHash, 
const sal_Char* pPass, sal_uInt32 nLen)
@@ -69,6 +71,7 @@ void 
SvPasswordHelper::GetHashPasswordLittleEndian(uno::Sequence& rPas
 }
 
 GetHashPassword(rPassHash, pCharBuffer.get(), nSize * sizeof(sal_Unicode));
+rtl_secureZeroMemory(pCharBuffer.get(), nSize * sizeof(sal_Unicode));
 }
 
 void SvPasswordHelper::GetHashPasswordBigEndian(uno::Sequence& 
rPassHash, const OUString& sPass)
@@ -84,6 +87,7 @@ void 
SvPasswordHelper::GetHashPasswordBigEndian(uno::Sequence& rPassHa
 }
 
 GetHashPassword(rPassHash, pCharBuffer.get(), nSize * sizeof(sal_Unicode));
+rtl_secureZeroMemory(pCharBuffer.get(), nSize * sizeof(sal_Unicode));
 }
 
 void SvPasswordHelper::GetHashPassword(uno::Sequence& rPassHash, 
const OUString& sPass)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Caolán McNamara
 filter/source/msfilter/msdffimp.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 4f490b86c782f609dabf1355c8db4d654af4c9c4
Author: Caolán McNamara 
Date:   Tue Feb 13 21:16:56 2018 +

ofz: Abrt

Change-Id: I814b0e4255894d909d29a9a301488a23acf418a0
Reviewed-on: https://gerrit.libreoffice.org/49686
Tested-by: Jenkins 
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/filter/source/msfilter/msdffimp.cxx 
b/filter/source/msfilter/msdffimp.cxx
index dc26bc4a6c57..8291b7ccc0d0 100644
--- a/filter/source/msfilter/msdffimp.cxx
+++ b/filter/source/msfilter/msdffimp.cxx
@@ -1107,7 +1107,8 @@ void ApplyRectangularGradientAsBitmap( const 
SvxMSDffManager& rManager, SvStream
 {
 Size aBitmapSizePixel( static_cast< sal_Int32 >( ( 
rObjData.aBoundRect.GetWidth() / 2540.0 ) * 90.0 ),  // we will create a 
bitmap with 90 dpi
static_cast< sal_Int32 >( ( 
rObjData.aBoundRect.GetHeight() / 2540.0 ) * 90.0 ) );
-if ( aBitmapSizePixel.Width() && aBitmapSizePixel.Height() && ( 
aBitmapSizePixel.Width() <= 1024 ) && ( aBitmapSizePixel.Height() <= 1024 ) )
+if (aBitmapSizePixel.Width() > 0 && aBitmapSizePixel.Height() > 0 &&
+aBitmapSizePixel.Width() <= 1024 && aBitmapSizePixel.Height() <= 1024)
 {
 double fFocusX = rManager.GetPropertyValue( DFF_Prop_fillToRight, 0 ) 
/ 65536.0;
 double fFocusY = rManager.GetPropertyValue( DFF_Prop_fillToBottom, 0 ) 
/ 65536.0;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


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

2018-02-14 Thread Szymon Kłos
 oox/source/drawingml/chart/seriesconverter.cxx |   34 -
 sd/qa/unit/data/pptx/tdf114821.pptx|binary
 sd/qa/unit/import-tests.cxx|   49 +
 3 files changed, 73 insertions(+), 10 deletions(-)

New commits:
commit f48053c06cfed8edcbcde08b1c193fd2ad080700
Author: Szymon Kłos 
Date:   Wed Jan 3 13:24:32 2018 +0100

tdf#114821 calculate better label position

Positioning hack was improved. It calculates position
depending on direct chart size factor. Preffered
label positions are: top - vertical, and center - horizontal

Change-Id: Ic25f08cd0bc3105fe34841dbc3f8aacacb694d43
Reviewed-on: https://gerrit.libreoffice.org/48909
Tested-by: Jenkins 
Reviewed-by: Szymon Kłos 
Reviewed-on: https://gerrit.libreoffice.org/48927
Reviewed-by: Andras Timar 

diff --git a/oox/source/drawingml/chart/seriesconverter.cxx 
b/oox/source/drawingml/chart/seriesconverter.cxx
index 6eceb213ea04..19538048e52e 100644
--- a/oox/source/drawingml/chart/seriesconverter.cxx
+++ b/oox/source/drawingml/chart/seriesconverter.cxx
@@ -54,13 +54,30 @@ using namespace ::com::sun::star::uno;
 
 namespace {
 
-/** nested-up sgn function - employs some gratuity around 0 - values
-   smaller than 0.33 are clamped to 0
+/** Function to get vertical position of label from chart height factor.
+Value can be negative, prefer top placement.
  */
-int lclSgn( double nVal )
+int lclGetPositionY( double nVal )
 {
-const int intVal=nVal*3;
-return intVal == 0 ? 0 : (intVal < 0 ? -1 : 1);
+if( nVal <= 0.1 )
+return -1;
+else if( nVal <= 0.6 )
+return 0;
+else
+return 1;
+}
+
+/** Function to get horizontal position of label from chart width factor.
+Value can be negative, prefer center placement.
+*/
+int lclGetPositionX( double nVal )
+{
+if( nVal <= -0.2 )
+return -1;
+else if( nVal <= 0.2 )
+return 0;
+else
+return 1;
 }
 
 Reference< XLabeledDataSequence > lclCreateLabeledDataSequence(
@@ -236,11 +253,8 @@ void DataLabelConverter::convertFromModel( const 
Reference< XDataSeries >& rxDat
 csscd::LEFT,csscd::CENTER, csscd::RIGHT,
 csscd::BOTTOM_LEFT, csscd::BOTTOM, csscd::BOTTOM_RIGHT
 };
-const double nMax=std::max(
-fabs(mrModel.mxLayout->mfX),
-fabs(mrModel.mxLayout->mfY));
-const int simplifiedX=lclSgn(mrModel.mxLayout->mfX/nMax);
-const int simplifiedY=lclSgn(mrModel.mxLayout->mfY/nMax);
+const int simplifiedX = lclGetPositionX(mrModel.mxLayout->mfX);
+const int simplifiedY = lclGetPositionY(mrModel.mxLayout->mfY);
 aPropSet.setProperty( PROP_LabelPlacement,
   aPositionsLookupTable[ simplifiedX+1 + 
3*(simplifiedY+1) ] );
 }
diff --git a/sd/qa/unit/data/pptx/tdf114821.pptx 
b/sd/qa/unit/data/pptx/tdf114821.pptx
new file mode 100644
index ..3813b0607903
Binary files /dev/null and b/sd/qa/unit/data/pptx/tdf114821.pptx differ
diff --git a/sd/qa/unit/import-tests.cxx b/sd/qa/unit/import-tests.cxx
index 00e72e3b533c..255bac40ed28 100644
--- a/sd/qa/unit/import-tests.cxx
+++ b/sd/qa/unit/import-tests.cxx
@@ -56,6 +56,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -165,6 +166,7 @@ public:
 void testTdf109187();
 void testTdf108926();
 void testTdf100065();
+void testTdf114821();
 
 bool checkPattern(sd::DrawDocShellRef const & rDocRef, int nShapeNumber, 
std::vector& rExpected);
 void testPatternImport();
@@ -238,6 +240,7 @@ public:
 CPPUNIT_TEST(testTdf109187);
 CPPUNIT_TEST(testTdf108926);
 CPPUNIT_TEST(testTdf100065);
+CPPUNIT_TEST(testTdf114821);
 
 CPPUNIT_TEST_SUITE_END();
 };
@@ -2285,6 +2288,52 @@ void SdImportTest::testTdf100065()
 xDocShRef->DoClose();
 }
 
+void SdImportTest::testTdf114821()
+{
+css::uno::Any aAny;
+sd::DrawDocShellRef xDocShRef = loadURL( m_directories.getURLFromSrc( 
"/sd/qa/unit/data/pptx/tdf114821.pptx" ), PPTX );
+
+uno::Reference< beans::XPropertySet > xPropSet( getShapeFromPage( 0, 0, 
xDocShRef ) );
+aAny = xPropSet->getPropertyValue( "Model" );
+CPPUNIT_ASSERT_MESSAGE( "The shape doesn't have the property", 
aAny.hasValue() );
+
+uno::Reference< chart::XChartDocument > xChartDoc;
+aAny >>= xChartDoc;
+CPPUNIT_ASSERT_MESSAGE( "failed to load chart", xChartDoc.is() );
+uno::Reference< chart2::XChartDocument > xChart2Doc( xChartDoc, 
uno::UNO_QUERY );
+CPPUNIT_ASSERT_MESSAGE( "failed to load chart", xChart2Doc.is() );
+
+uno::Reference< chart2::XCoordinateSystemContainer > xBCooSysCnt( 
xChart2Doc->getFirstDiagram(), uno::UNO_QUERY );
+uno::Sequence< uno::Reference< chart2::XCoordinateSystem > > aCooSysSeq( 
xBCooSysCnt->getCoordinateSystems() );
+uno::Reference< chart2::XCh

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

2018-02-14 Thread Szymon Kłos
 oox/source/drawingml/chart/seriesconverter.cxx |   34 -
 sd/qa/unit/data/pptx/tdf114821.pptx|binary
 sd/qa/unit/import-tests.cxx|   49 +
 3 files changed, 73 insertions(+), 10 deletions(-)

New commits:
commit 326c9766281e6f80abc042420f1d4be3a27b8aa9
Author: Szymon Kłos 
Date:   Wed Jan 3 13:24:32 2018 +0100

tdf#114821 calculate better label position

Positioning hack was improved. It calculates position
depending on direct chart size factor. Preffered
label positions are: top - vertical, and center - horizontal

Change-Id: Ic25f08cd0bc3105fe34841dbc3f8aacacb694d43
Reviewed-on: https://gerrit.libreoffice.org/48909
Tested-by: Jenkins 
Reviewed-by: Szymon Kłos 
Reviewed-on: https://gerrit.libreoffice.org/48928
Reviewed-by: Andras Timar 

diff --git a/oox/source/drawingml/chart/seriesconverter.cxx 
b/oox/source/drawingml/chart/seriesconverter.cxx
index a1f2cb737c7f..c2a183363a21 100644
--- a/oox/source/drawingml/chart/seriesconverter.cxx
+++ b/oox/source/drawingml/chart/seriesconverter.cxx
@@ -54,13 +54,30 @@ using namespace ::com::sun::star::uno;
 
 namespace {
 
-/** nested-up sgn function - employs some gratuity around 0 - values
-   smaller than 0.33 are clamped to 0
+/** Function to get vertical position of label from chart height factor.
+Value can be negative, prefer top placement.
  */
-int lclSgn( double nVal )
+int lclGetPositionY( double nVal )
 {
-const int intVal=nVal*3;
-return intVal == 0 ? 0 : (intVal < 0 ? -1 : 1);
+if( nVal <= 0.1 )
+return -1;
+else if( nVal <= 0.6 )
+return 0;
+else
+return 1;
+}
+
+/** Function to get horizontal position of label from chart width factor.
+Value can be negative, prefer center placement.
+*/
+int lclGetPositionX( double nVal )
+{
+if( nVal <= -0.2 )
+return -1;
+else if( nVal <= 0.2 )
+return 0;
+else
+return 1;
 }
 
 Reference< XLabeledDataSequence > lclCreateLabeledDataSequence(
@@ -236,11 +253,8 @@ void DataLabelConverter::convertFromModel( const 
Reference< XDataSeries >& rxDat
 csscd::LEFT,csscd::CENTER, csscd::RIGHT,
 csscd::BOTTOM_LEFT, csscd::BOTTOM, csscd::BOTTOM_RIGHT
 };
-const double nMax=std::max(
-fabs(mrModel.mxLayout->mfX),
-fabs(mrModel.mxLayout->mfY));
-const int simplifiedX=lclSgn(mrModel.mxLayout->mfX/nMax);
-const int simplifiedY=lclSgn(mrModel.mxLayout->mfY/nMax);
+const int simplifiedX = lclGetPositionX(mrModel.mxLayout->mfX);
+const int simplifiedY = lclGetPositionY(mrModel.mxLayout->mfY);
 aPropSet.setProperty( PROP_LabelPlacement,
   aPositionsLookupTable[ simplifiedX+1 + 
3*(simplifiedY+1) ] );
 }
diff --git a/sd/qa/unit/data/pptx/tdf114821.pptx 
b/sd/qa/unit/data/pptx/tdf114821.pptx
new file mode 100644
index ..3813b0607903
Binary files /dev/null and b/sd/qa/unit/data/pptx/tdf114821.pptx differ
diff --git a/sd/qa/unit/import-tests.cxx b/sd/qa/unit/import-tests.cxx
index fd3b5721af27..2ab15a7763eb 100644
--- a/sd/qa/unit/import-tests.cxx
+++ b/sd/qa/unit/import-tests.cxx
@@ -56,6 +56,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
@@ -165,6 +166,7 @@ public:
 void testTdf109223();
 void testActiveXCheckbox();
 void testTdf108926();
+void testTdf114821();
 
 bool checkPattern(sd::DrawDocShellRef& rDocRef, int nShapeNumber, 
std::vector& rExpected);
 void testPatternImport();
@@ -237,6 +239,7 @@ public:
 CPPUNIT_TEST(testTdf109223);
 CPPUNIT_TEST(testActiveXCheckbox);
 CPPUNIT_TEST(testTdf108926);
+CPPUNIT_TEST(testTdf114821);
 
 CPPUNIT_TEST_SUITE_END();
 };
@@ -2313,6 +2316,52 @@ void SdImportTest::testTdf108926()
 xDocShRef->DoClose();
 }
 
+void SdImportTest::testTdf114821()
+{
+css::uno::Any aAny;
+sd::DrawDocShellRef xDocShRef = loadURL( m_directories.getURLFromSrc( 
"/sd/qa/unit/data/pptx/tdf114821.pptx" ), PPTX );
+
+uno::Reference< beans::XPropertySet > xPropSet( getShapeFromPage( 0, 0, 
xDocShRef ) );
+aAny = xPropSet->getPropertyValue( "Model" );
+CPPUNIT_ASSERT_MESSAGE( "The shape doesn't have the property", 
aAny.hasValue() );
+
+uno::Reference< chart::XChartDocument > xChartDoc;
+aAny >>= xChartDoc;
+CPPUNIT_ASSERT_MESSAGE( "failed to load chart", xChartDoc.is() );
+uno::Reference< chart2::XChartDocument > xChart2Doc( xChartDoc, 
uno::UNO_QUERY );
+CPPUNIT_ASSERT_MESSAGE( "failed to load chart", xChart2Doc.is() );
+
+uno::Reference< chart2::XCoordinateSystemContainer > xBCooSysCnt( 
xChart2Doc->getFirstDiagram(), uno::UNO_QUERY );
+uno::Sequence< uno::Reference< chart2::XCoordinateSystem > > aCooSysSeq( 
xBCooSysCnt->getCoordinateSystems() );
+uno::Reference< chart2

[Libreoffice-commits] core.git: xmlsecurity/source xmlsecurity/util

2018-02-14 Thread Miklos Vajna
 xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl.cxx |   53 ++-
 xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl.hxx |   80 -
 xmlsecurity/source/xmlsec/nss/xsec_nss.cxx |5 -
 xmlsecurity/util/xsec_xmlsec.component |3 
 4 files changed, 33 insertions(+), 108 deletions(-)

New commits:
commit 48d3ff5c498f8f186d4ee72871af379010403442
Author: Miklos Vajna 
Date:   Tue Feb 13 22:09:40 2018 +0100

xmlsecurity nss: create XMLSignature instances with a constructor

Change-Id: Ic2968a1eda7517ba4cfb67d0cf68fb7de1ac1935
Reviewed-on: https://gerrit.libreoffice.org/49685
Tested-by: Jenkins 
Reviewed-by: Miklos Vajna 

diff --git a/xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl.cxx 
b/xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl.cxx
index 3389fd149086..5eef5e80ae28 100644
--- a/xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl.cxx
+++ b/xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl.cxx
@@ -19,7 +19,6 @@
 
 #include 
 #include 
-#include "xmlsignature_nssimpl.hxx"
 
 #include 
 #include 
@@ -31,7 +30,9 @@
 #include "xmlsecuritycontext_nssimpl.hxx"
 
 #include 
+#include 
 
+using namespace ::com::sun::star;
 using namespace ::com::sun::star::uno ;
 using namespace ::com::sun::star::lang ;
 using ::com::sun::star::lang::XMultiServiceFactory ;
@@ -45,10 +46,30 @@ using ::com::sun::star::xml::crypto::XXMLSignatureTemplate ;
 using ::com::sun::star::xml::crypto::XXMLSecurityContext ;
 using ::com::sun::star::xml::crypto::XUriBinding ;
 
-XMLSignature_NssImpl::XMLSignature_NssImpl() {
-}
+class XMLSignature_NssImpl
+: public ::cppu::WeakImplHelper
+{
+public:
+explicit XMLSignature_NssImpl();
+
+//Methods from XXMLSignature
+virtual uno::Reference SAL_CALL
+generate(const uno::Reference& 
aTemplate,
+ const uno::Reference& 
aEnvironment) override;
+
+virtual uno::Reference SAL_CALL
+validate(const uno::Reference& 
aTemplate,
+ const uno::Reference& aContext) 
override;
+
+//Methods from XServiceInfo
+virtual OUString SAL_CALL getImplementationName() override;
+
+virtual sal_Bool SAL_CALL supportsService(const OUString& ServiceName) 
override;
+
+virtual uno::Sequence SAL_CALL getSupportedServiceNames() 
override;
+};
 
-XMLSignature_NssImpl::~XMLSignature_NssImpl() {
+XMLSignature_NssImpl::XMLSignature_NssImpl() {
 }
 
 /* XXMLSignature */
@@ -267,7 +288,7 @@ SAL_CALL XMLSignature_NssImpl::validate(
 
 /* XServiceInfo */
 OUString SAL_CALL XMLSignature_NssImpl::getImplementationName() {
-return impl_getImplementationName() ;
+return OUString("com.sun.star.xml.crypto.XMLSignature");
 }
 
 /* XServiceInfo */
@@ -283,27 +304,15 @@ sal_Bool SAL_CALL XMLSignature_NssImpl::supportsService( 
const OUString& service
 
 /* XServiceInfo */
 Sequence< OUString > SAL_CALL XMLSignature_NssImpl::getSupportedServiceNames() 
{
-return impl_getSupportedServiceNames() ;
-}
-
-//Helper for XServiceInfo
-Sequence< OUString > XMLSignature_NssImpl::impl_getSupportedServiceNames() {
-::osl::Guard< ::osl::Mutex > aGuard( ::osl::Mutex::getGlobalMutex() ) ;
 Sequence seqServiceNames { 
"com.sun.star.xml.crypto.XMLSignature" };
 return seqServiceNames ;
 }
 
-OUString XMLSignature_NssImpl::impl_getImplementationName() {
-return 
OUString("com.sun.star.xml.security.bridge.xmlsec.XMLSignature_NssImpl") ;
-}
-
-//Helper for registry
-Reference< XInterface > SAL_CALL XMLSignature_NssImpl::impl_createInstance( 
const Reference< XMultiServiceFactory >& ) {
-return Reference< XInterface >( *new XMLSignature_NssImpl ) ;
-}
-
-Reference< XSingleServiceFactory > XMLSignature_NssImpl::impl_createFactory( 
const Reference< XMultiServiceFactory >& aServiceManager ) {
-return ::cppu::createSingleFactory( aServiceManager , 
impl_getImplementationName() , impl_createInstance , 
impl_getSupportedServiceNames() ) ;
+extern "C" SAL_DLLPUBLIC_EXPORT uno::XInterface*
+com_sun_star_xml_crypto_XMLSignature_get_implementation(uno::XComponentContext*
 /*pCtx*/,
+
uno::Sequence const& /*rSeq*/)
+{
+return cppu::acquire(new XMLSignature_NssImpl);
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl.hxx 
b/xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl.hxx
deleted file mode 100644
index 92f50d9acb26..
--- a/xmlsecurity/source/xmlsec/nss/xmlsignature_nssimpl.hxx
+++ /dev/null
@@ -1,80 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the 

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

2018-02-14 Thread Miklos Vajna
 external/pdfium/Library_pdfium.mk |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 9efd288b31e259b964097d3eeeff7f6c10945cb3
Author: Miklos Vajna 
Date:   Tue Feb 13 22:07:38 2018 +0100

pdfium: disable custom allocator

That causes problems on aarch64 (see

)
and provides little benefit to our use-case.

Change-Id: I133d41476ab84cec67abc5b36a1e16c91bc6ac15
Reviewed-on: https://gerrit.libreoffice.org/49684
Tested-by: Jenkins 
Reviewed-by: Miklos Vajna 

diff --git a/external/pdfium/Library_pdfium.mk 
b/external/pdfium/Library_pdfium.mk
index a508d83be107..e3e802d8053c 100644
--- a/external/pdfium/Library_pdfium.mk
+++ b/external/pdfium/Library_pdfium.mk
@@ -24,6 +24,7 @@ $(eval $(call gb_Library_add_defs,pdfium,\
 -DUSE_SYSTEM_LCMS2 \
 -DUSE_SYSTEM_LIBJPEG \
 -DUSE_SYSTEM_ZLIB \
+-DMEMORY_TOOL_REPLACES_ALLOCATOR \
 -DUNICODE \
 ))
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits