summaryrefslogtreecommitdiff
path: root/sfx2
AgeCommit message (Collapse)Author
2021-10-08remove unwanted xpad/ypad properties and replace with a margin-endCaolán McNamara
the xpad didn't do anything in vcl, and is deprecated for gtk. There was additional padding shown in gen anyway because a yalign of 0.5 wrongly horizontally centering, which is now fixed. Change-Id: I546ec72b0449185217213ee1ba061dd051122880 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123270 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-10-08remove (presumably) unwanted 'Widget name' propertyCaolán McNamara
Change-Id: Icf296074e21e02c2aeb63bc6a9d8ff0702cc4c14 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123268 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-10-08resave with glade to tidy this upCaolán McNamara
Change-Id: I7b3499cc1044cb976415d3db6855283bf928c4b5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123266 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-10-08add mappings for emphasis propertyCaolán McNamara
Change-Id: I1406d57a47075bfad3973c6bbb825a7754e8f279 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123264 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-10-08fix "GtkBox does not have a child property called left-attach"Caolán McNamara
on launching development tools probably since... commit 81d6ed89d1e5268c2ea4ff527f3e6087dc1d8ccd Date: Mon May 17 13:59:25 2021 +0300 tdf#142276 Use vertical GtkBox insted of horizontal GtkGrid for the left side. Change-Id: I6d4e4a056fb25c6ffb44e0ed734eb7a553a78ba3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123263 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-10-08add 'destructive-action' style to the close button of save changesCaolán McNamara
which gives a red "Don't Save" close button in the default Adwaita gtk theme for that undoable action Change-Id: I62b50c90ca53c8f05e656c9beaecbfb160ce5f67 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123249 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-10-08loplugin:moveparam in vclNoel Grandin
Change-Id: Ic43e02576454e3ee174304db350659dd113a1d5f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123186 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-10-06avoid repeated calls to SfxNotebookBar::IsActive()Luboš Luňák
The call reads configuration, and so is a bit expensive when called in a loop. Change-Id: I62398bcfdc856f02f6e2d928bac2f144bc47424d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123103 Tested-by: Jenkins Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
2021-10-04drop 'using namespace std' in sax/sc/scaddins/sfx2/shellJulien Nabet
Change-Id: I422a6d5b0151115203fd2d7c0fc5597903d3ec8b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123064 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-10-03A more lightweight O[U]StringConcatenationStephan Bergmann
...compared to a full-blown O[U]String, for temporary objects holding an O[U]StringConcat result that can then be used as a std::[u16]string_view. It's instructive to see how some invocations of operator ==, operator !=, and O[U]StringBuffer::insert with an O[U]StringConcat argument required implicit materialization of an O[U]String temporary, and how that expensive operation has now been made explicit with the explicit O[U]StringConcatenation ctor. (The additional operator == and operator != overloads are necessary because the overloads taking two std::[u16]string_view parameters wouldn't even be found here with ADL. And the OUString-related ones would cause ambiguities in at least sal/qa/rtl/strings/test_oustring_stringliterals.cxx built with RTL_STRING_UNITTEST, so have simply been disabled for that special test-code case.) Change-Id: Id29799fa8da21a09ff9794cbc7cc9b366e6803b8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122890 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-10-03cid#1492221 silence bogus Dereference after null checkCaolán McNamara
Change-Id: I4e0554d16cac67bd8d829ed5e65fd4b17f4cf1b5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123008 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-10-01loplugin:constmethodNoel Grandin
Change-Id: I3ed657c5c5e6840e38e3c8505505b4b372125df0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122910 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-30loplugin:constmethod handle more casesNoel Grandin
remove some of the naming limitations, and handle pointer parameters better. I only let the plugin run up till vcl/ Change-Id: Ice916e0157031ab531c47f10778f406b07966251 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122892 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-30loplugin:constparams improve handling of pointer paramsNoel Grandin
Change-Id: I4c0002e72703eded435bfe4985f5b0121bf8524b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122843 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-28fix deadlock on exit (attempt2)Noel Grandin
regression from commit 8122c82d90117fc0c4c8ea87aa7f771d5e92bf36 osl::Mutex->std::mutex in SfxGlobalEvents_Imp Change-Id: Ia7416520a3538dcb77d7a4573045122581730264 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122779 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-28gives names to all the Idles and TasksNoel Grandin
enforce it by making the constructor parameter non-default. Change-Id: I321543e4dcf15ea0a43ad8cce91d2f8dc22df6ec Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122766 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-28fix deadlock on exitNoel Grandin
regression from commit 8122c82d90117fc0c4c8ea87aa7f771d5e92bf36 osl::Mutex->std::mutex in SfxGlobalEvents_Imp Change-Id: Ifdde340a4cb6a84b5b396d04694e856f6bdd5c03 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122769 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-28vcl: rename OutDevState to StackChris Sherlock
I have moved the header file to include/vcl/rendercontext as this will eventually be part of the RenderContext split from OutputDevice. State and associated enums have also been moved to the vcl namespace. I have also moved ComplexTextLayoutFlags into the vcl::text namespace. Change-Id: I0abbf560e75b45a272854b267e948c240cd69091 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121524 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2021-09-26use SfxItemSetFixed in variousNoel Grandin
Change-Id: Ie2472959dbab93ead20948245fca9644de834422 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122653 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-24make it possible to build required database stuff for fuzzingCaolán McNamara
The dbase filter requires dbaccess and connectivity but I don't want to pull in the rest of the stuff that --disable-database-connectivity currently disables that we still don't need for fuzzing if --disable-database-connectivity is removed Change-Id: Ia48d42295f9724b4dd2d3beb8e46ed23fc789f5c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122579 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-23tdf#144132 Crash when insert formula object in WriterNoel Grandin
regression from commit ec01d43e0a8fa560d7cd8c76c0d609b18a60cddb Date: Wed Jul 21 14:24:28 2021 +0200 pass SfxChildWinFactory around by value Change-Id: I88bc6c8bfd35d0a653512b064c9ee0d59b1e8b38 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122520 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-22Extend loplugin:stringviewparam to starts/endsWith: sfx2Stephan Bergmann
Change-Id: Icac2c5877059208ed348aa824071803e415f374f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122482 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-09-20clean up ambiguous confusing rectangle APIs like IsInside()Luboš Luňák
Reading 'rectA.IsInside( rectB )' kind of suggests that the code checks whether 'rectA is inside rectB', but it's actually the other way around. Rename IsInside() -> Contains(), IsOver() -> Overlaps(), which should make it clear which way the logic goes. Change-Id: I9347450fe7dc34c96df6d636a4e3e660de1801ac Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122271 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Luboš Luňák <l.lunak@collabora.com> Tested-by: Jenkins
2021-09-16occasionally the bg color of the deck grip is wrongCaolán McNamara
Change-Id: I318e817a8e99b9f01aee90f042bfac39a1c4b5d9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122176 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-15loplugin:finalclassesNoel Grandin
Change-Id: I88831f290e1923db6fb5a733746bfa3bc7fbc7e8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122148 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-15loplugin:constvarsNoel Grandin
Change-Id: I9b35d6333afa6b305bf73fc55a7e60c8365674e9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122134 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-15Use <comphelper/servicehelper.hxx> implementing XUnoTunnel part 5Mike Kaganski
- Revise uses of getSomething to use getFromUnoTunnel Where that is impossible, use getSomething_cast to unify casting, and minimize number of places doing low-level transformations. The change keeps the existing tunnel references that last for the duration of the pointers' life, because sometimes destroying such reference may destroy the pointed object, and result in use after free. Change-Id: I291c33223582c34cd2c763aa8aacf0ae899ca4c0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122101 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-09-15Use <comphelper/servicehelper.hxx> implementing XUnoTunnel part 4Mike Kaganski
- Change implementations of getSomething to use getSomethingImpl Or where that's impossible, use getSomething_cast to unify this and reduce number of places where we reinterpret_cast. All static methods getting tunnel ids were renamed to getUnoTunnelId, to comply with the convention used in <comphelper/servicehelper.hxx>. TODO (in separate commits): - Revise uses of getSomething to use getFromUnoTunnel Change-Id: Ifde9e214b52e5df678de71fcc32d2199c82e85cf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122100 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-09-15Use <comphelper/servicehelper.hxx> implementing XUnoTunnel part 1Mike Kaganski
The header got some changes: 1. Move UnoTunnelIdInit and isUnoTunnelId into 'comphelper' namespace 2. Rename UnoTunnelIdInit to UnoIdInit, as a precondition to replace of uses of OImplementationId with it, including in XTypeProvider 3. Introduce convenience functions 'getSomething_cast' to cast between sal_Int64 and object pointers uniformly. 4. Rename getUnoTunnelImplementation to getFromUnoTunnel, both to make it a bit shorter, and to reflect its function better. Templatize it to take also css::uno::Any for convenience. 5. Introduce getSomethingImpl, inspired by sw::UnoTunnelImpl; allow it handle cases both with and without fallback to parent. 6. Adjust UNO3_GETIMPLEMENTATION_* macros TODO (in separate commits): - Drop sw::UnoTunnelImpl and sw::UnoTunnelGetImplementation - Replace all uses of OImplementationId in core with UnoIdInit - Deprecate OImplementationId in <cppuhelper/typeprovider.hxx> - Change implementations of getSomething to use getSomethingImpl - Revise uses of getSomething to use getFromUnoTunnel Change-Id: If4a3cb024130f1f552f988f0479589da1cd066e7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122022 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-09-12Typo: SAVE_SUCCESSFULL->SAVE_SUCCESSFULJulien Nabet
Change-Id: I4b50e1f5ca55e756f1fd0028287eeb0c9b96439a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121962 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-09-11clang:optin.performance.Padding in sfx2Noel Grandin
Excessive padding in 'class SfxControllerItem' (10 padding bytes, where 2 is optimal). Excessive padding in 'struct SfxChildWinInfo' (11 padding bytes, where 3 is optimal). Excessive padding in 'struct SfxChildWinFactory' (12 padding bytes, where 4 is optimal). Excessive padding in 'class SfxChildWindow' (10 padding bytes, where 2 is optimal). Change-Id: I435cfcf8a199bcab4612d671e1900ba659b8e383 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121941 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-11Drop unused multiple selection from UI filesJan-Marek Glogowski
The code must call set_selection_mode(SelectionMode::Multiple) instead. Change-Id: I2d51dd3d3182ccec25f2ec1093a3866880354371 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121915 Tested-by: Jenkins Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
2021-09-10gtk4: cannot focus to toolbutton if can-focus is falseCaolán McNamara
which seems reasonable Change-Id: I0cc5fecaace99f612d637c39065982ad12b23b89 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121895 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-10drop stray fprintfCaolán McNamara
Change-Id: Ide4df588f8642b3eaad6dab4c819ba1914f3e2ba Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121896 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-09Resolves: tdf#144389 get_accessible_parent should only be called on vcl implsCaolán McNamara
Change-Id: If5d8718fcd9bcccee37e162a99cc68ff4a77de8f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121847 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-09merge ThumbnailView and ThumbnailViewBaseCaolán McNamara
only ThumbnailView inherits directly from ThumbnailViewBase and it will simplify a11y if ThumbnailView instead of ThumbnailViewBase is available Change-Id: I715faa3f9b2cec68c1de07479b7d1dbbd9ddbcc2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121846 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-08convert some OSL_ENSURE -> assertNoel Grandin
where we are just provide checking for a following static_cast. I'd rather have an explicit assert failure than a random crash Change-Id: Iab6c6b056341018deaa74b78b075e564f72c58d9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121814 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-07vcl: rename PrinterOptions to vcl::printer::OptionsChris Sherlock
Move Options to own source and header files. Options moved to own source and header files, however also put Options into vcl::printer namespace. I have renamed and moved PrinterOptions into the vcl::printer namespace because the word "Printer" is redundant, and we want to organize the vcl namespace better. Change-Id: I2ef188af381dd65907d48f7b190e4ab69417606d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121389 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Jenkins
2021-09-07loplugin:unusedmethodsNoel Grandin
Change-Id: I6295d6ff6fb7410852351801c324244308c5c472 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121751 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-05tdf#105689: fix path management to retrieve Emoji toolbar buttonJulien Nabet
On Windows console logs show: warn:sfx:7060:6444:sfx2/source/control/emojiview.cxx:105: Emoji config data is empty Change-Id: I85baf2fedc20ff855183147e9a178bb048ac75ce Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121653 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-09-02clang-tidy:readability-redundant-member-initNoel Grandin
Change-Id: I396b83c089fef3aeb7789c17a3013ce61691504e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121489 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-01tdf#118938 XLSX import/export: fix permission for editingTünde Tóth
The password for editing wasn't asked, also wasn't exported in XLSX documents. Now it's exported in Calc using the following steps, also verified before editing: - In File->Save As, choose Excel 2007–365 (.xlsx) format; - enable checkbox "Save with password" and click Save; - in the dialog "Set password", click on "Options" and enable checkbox "Open file read-only", and enter a password for editing (i.e. skip the password for opening). Note: Excel 2016 doesn't ask password for editing, but Office 365 does. Passwords created in Excel haven't been supported, yet. Also passwords with diacritics aren't interoperable. Note: saving the file under a different path is still allowed both in Calc and Excel without asking the password for editing. Change-Id: Ic00d7c5a785e04d270a182a4087ea922d7d92979 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121371 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2021-09-01tdf#142458 minimal width not including extra width needed by scrolledwindowCaolán McNamara
its only including the width of the panels and not the extra space possibly required by the container window. Which is 2x the m_nBorderWidth of 1pixel of VclScrolledWindow in this case. Change-Id: I56775c7183d7a8b87af263ddc8bb17373779e9ad Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121390 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-01sfx2: allow storeAsURL() on the main threadMiklos Vajna
This is similar to commit b030e83fccbff8d82a4c84462075baa8442cde54 (sfx2: allow storeToURL() on the main thread, 2019-02-05), just this handles the 'export' case, not the 'save as' one. Note that this already worked in some cases when impl_store() decided to call storeSelf(), but vcl::solarthread::syncExecute() already avoids dispatch when called on a non-main thread, so that is not a problem. Change-Id: Ief09ba6c60923c7f16d86f61625c0faa9a5f829b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121385 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2021-08-31flatten SfxAppData_ImplNoel Grandin
no need to allocate things separately that are always allocated with this object Change-Id: I6acc215fa1f86625f300cd7717ee5d40a6bc986b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121341 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-31no need to allocate SfxFilterMatcher separatelyNoel Grandin
it only contains a single pointer Change-Id: If988f03d693d4912ce3b7a6fa5fab7cd52ab05cd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121340 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-31no need to allocate SfxPickList separatelyNoel Grandin
it only contains a pointer Change-Id: I593665314eae2c0ad02b4555c2fda0d8719f2edf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121339 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-31no need to allocate SfxDocumentTemplates separatelyNoel Grandin
it only contains a single pointer Change-Id: If6fc4924b7980317500a5c02e62c671f8f97aafd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121338 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-31flatten SfxObjectShellArr_ImplNoel Grandin
Change-Id: I97e3ea18ce17c63ae95d7755a32c602b88373370 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121337 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-31flatten SfxViewShellArr_ImplNoel Grandin
Change-Id: I781f877b0c94fdd667b4fd00342e68b35b127867 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121336 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>