summaryrefslogtreecommitdiff
path: root/include
AgeCommit message (Collapse)Author
2022-05-24reduce space needed for NameSpaceMapNoel Grandin
no need to store the key twice. Also rename related fields and typedefs to make the code easier to read. Change-Id: Ib76dea7fd683d024e8c9d8091d85cfec14829359 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134871 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-24modernize and improve PropertySetInfoNoel Grandin
(*) use o3tl::span for the array param, which means we don't need a null entry to terminate the array (*) use std::unordered_map to speed things up (*) mark the array as static at a few more call sites Change-Id: I05b6cae7552f44459e183ec05cb94e60edb3bfe0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134832 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-24flatten the maps in SvXMLNamespaceMapNoel Grandin
to reduce pointer chasing Change-Id: I8d581c03f80fa279a93ed23b7116c6f950405b7a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134857 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-23sw content controls, picture: add LOK APIMiklos Vajna
- send a LOK_CALLBACK_CONTENT_CONTROL callback with action=change-picture when a file picker should be shown - extend lok::Document::sendContentControlEvent() to be able to replace the placeholder with the selected URL - update gtktiledviewer to work with these Change-Id: Ifb3750803885fc09fc82905b0cf85b2b8ca06e77 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134750 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-05-23clang-tidy modernize-pass-by-value in jvmaccessNoel Grandin
Change-Id: I9a2ef4370136b0f26ae3590f358025e7d89f30d2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134757 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-22cid#1504541 Uninitialized scalar fieldCaolán McNamara
Change-Id: I1fa061f9713c808bd06933ae9c574e70a1ec0915 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134721 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-05-22tdf#84502 related: Show keyboard shortcut in sidebar tab bar tab buttonJim Raykowski
tooltip Change-Id: Ia0d48ac437c6a18c4e1624dd9b154ee7a8514f1c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134594 Tested-by: Jenkins Reviewed-by: Jim Raykowski <raykowj@gmail.com>
2022-05-21clang-tidy modernize-pass-by-value in canvasNoel Grandin
Change-Id: Ib6e1b6182d83b09dbf5e2aeb9cf3e4ca11d9f48b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134712 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-21lok-calc: new callback for print rangesDennis Francis
With this callback the lok clients can read and draw the print ranges on each sheet of the Calc document. Conflicts: include/LibreOfficeKit/LibreOfficeKitEnums.h libreofficekit/source/gtk/lokdocview.cxx Change-Id: Ie19351d4420e0f3d4191f6a354ce99ab830aede2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134375 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Pranam Lashkari <lpranam@collabora.com> (cherry picked from commit 172bc7a8f4eeab907adac077407186fbbd046a77) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134527 Reviewed-by: Gökay ŞATIR <gokaysatir@collabora.com> (cherry picked from commit 29b7b25d454e0a6cd07c00e13fdb83cc8a381583) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134614 Tested-by: Jenkins Reviewed-by: Dennis Francis <dennis.francis@collabora.com>
2022-05-20elide temporary OUStringBuffer in INetURLObjectNoel Grandin
which requires a version of replaceAt for OUStringBuffer, which I'll put in comphelper::string:: for now Change-Id: I70b319b018e29a7dac26965dd92f6c4f9ea470ec Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134679 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-20optimise Any::operator=(&&) a littleNoel Grandin
uno_any_destruct will get called by the other Any anyway, so no need to do it ourselves. And inline the helper now, since it is only used in the one spot. Change-Id: If4227ce7e9d8ef83e3440ac1d9fe2579ed3583e2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134597 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-20sfx2: use natural string sort for sorting in object inspectorTomaž Vajngerl
Use a natural string sort for all strings in the object inspector tree view. This is more useful for properties as those can have indices, which are shown as numbers, so having them in natural order makes the tree view easier to digest. Change-Id: I7d036cd755f6595fa302c7a28a005684897f2963 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134541 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2022-05-19Simplify SmElementsControlMike Kaganski
Change-Id: Idcb075a474b440447b8566cc92a8f65bbc77127c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134643 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2022-05-19add ByteWriter to reduce memory copying when writing dataNoel Grandin
similarly to ByteReader move both of them down to comphelper, since we want to use it from comphelper, and comphelper is "below" unotools in the module dependency graph Change-Id: Ic98fa2268e125fd8e4378fb899ad5f97de721713 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134645 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-19sw: fix assert in SwModule::Notify()Michael Stahl
Apparently it happens when loading a 0-byte file that the SfxObjectShell is still in IsLoading() stage when close() is called. This then causes the SfxEventHintId::LoadFinished event to be emitted during close(), which is not a situation the assert was intended for. Change-Id: I60a260ca1c1e6cbf9502832ba6622de2628763e7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134610 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2022-05-19sw content controls, picture: add ODT filterMiklos Vajna
Map Picture UNO property on content controls to: <loext:content-control loext:picture="..."> And do the opposite on import. Change-Id: I47c3d04c505ba94da958d5d6b6b2c883236afc3d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134595 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2022-05-19fix location of #includeNoel Grandin
after commit 343eed477ee7b55aa450bbc2aee6786dc0d9a071 clang-tidy modernize-pass-by-value in o3tl Change-Id: I1800c0ba63abb0862b8c9aef185ebdf416245f3e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134602 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-19Simplify an "ImportGraphic" method by removing useless pExtHeader (WmfExternal)Julien Nabet
Change-Id: I2916610e08c3157e0438ec90592fb5b8f921cc24 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134574 Reviewed-by: Bartosz Kosiorek <gang65@poczta.onet.pl> Tested-by: Jenkins
2022-05-19tdf#148923 PPTX import: fix incorrect image in media fileTünde Tóth
Linked media file was imported with incorrect image, if the Impress couldn't play the media file. Regression from commit 9564747d2fd5d2c859a359dd7fa6242c6859c0d7 (tdf#53970 PPTX: fix import of linked media files). Change-Id: Ib277a61e83c3794376d2c090b7f742707e779832 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134394 Tested-by: Jenkins Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2022-05-19tdf#50400 show an explanatory label if ascii-only password is requiredCaolán McNamara
Change-Id: Ib0e3d07e29d56e9782b4b9d215eab4d743158a71 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134526 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-05-19clang-tidy modernize-pass-by-value in i18nutilNoel Grandin
Change-Id: Ia0457c81ee1da2a88a8238a1a1d65354c1b639bf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134533 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-19add utl::ByteReader pure classNoel Grandin
which lets us skip the inefficiency of needing an extra buffer when reading via XInputStream Change-Id: Ic5334b7d11ea6a57bc1800f508fc69611a053af1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134348 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-19registry: fix some documentationChris Sherlock
Change-Id: I8fb21bf57a238fef2b87a124a9e43ff64873d797 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128169 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2022-05-18tdf#105972: pdf form: export date fields as date typeXisco Fauli
using AFDate_FormatEx which allows to set a custom format Change-Id: I38839965423794a0278b783c39c612c361a90eea Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134543 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2022-05-18Remove 1 ImportGraphic methodJulien Nabet
and replace its only use in Shape::renderDiagramToGraphic (oox/source/drawingml/shape.cxx) by an existing one. It became quite useless since 2876a0f79f94cdd139cc8fa40669acde9674bf8c (2020/03/03) graphic: remove preview when importing with GraphicFilter Change-Id: Iec3b13d85297bbe7cbfefe91a2a88e33e53d506b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134503 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2022-05-18clang-tidy modernize-pass-by-value in linguisticNoel Grandin
Change-Id: Ia5fc81ed6e6e060d62e5ff42dccb06e36774a65c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134534 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-18tdf#105972: pdf form: export time fields as time typeXisco Fauli
using AFTime_FormatEx which allows to set a custom format Change-Id: I2d30d9d8340782ed9ad53eb43e1f65728f926b23 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134510 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2022-05-18clang-tidy modernize-pass-by-value in unoidlNoel Grandin
Change-Id: Ibeb6aa656d6ed8b8ba78e800c9e28ba63ec0ec40 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134521 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-18clang-tidy modernize-pass-by-value in o3tlNoel Grandin
Change-Id: I420e023aa6bad3c960a9ec4c52f09b51cdd5ff6d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134520 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-18clang-tidy modernize-pass-by-value in codemakerNoel Grandin
Change-Id: I2bd9c4c8ced5f0edb9dbf560fe0ed126b9233c26 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134519 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-18Avoid uninitialized vcl::EditWidget::PrependCurrencySymbolStephan Bergmann
...causing UBSan > /vcl/source/gdi/pdfwriter_impl.cxx:11017:53: runtime error: load of value 190, which is not a valid value for type 'bool' > #0 0x7efed21c891b in vcl::PDFWriterImpl::createControl(vcl::PDFWriter::AnyWidget const&, int) /vcl/source/gdi/pdfwriter_impl.cxx:11017:53 > #1 0x7efed205c76b in vcl::PDFWriter::CreateControl(vcl::PDFWriter::AnyWidget const&) /vcl/source/gdi/pdfwriter.cxx:438:29 > #2 0x7efed1f5dc60 in vcl::PageSyncData::PlaySyncPageAct(vcl::PDFWriter&, unsigned int&, GDIMetaFile const&, vcl::PDFExtOutDevData const&) /vcl/source/gdi/pdfextoutdevdata.cxx:394:29 > #3 0x7efed1f64eac in vcl::PDFExtOutDevData::PlaySyncPageAct(vcl::PDFWriter&, unsigned int&, GDIMetaFile const&) /vcl/source/gdi/pdfextoutdevdata.cxx:612:28 > #4 0x7efed206486e in vcl::PDFWriterImpl::playMetafile(GDIMetaFile const&, vcl::PDFExtOutDevData*, vcl::PDFWriter::PlayMetafileContext const&, VirtualDevice*) /vcl/source/gdi/pdfwriter_impl2.cxx:288:48 [...] during CppunitTest_vcl_pdfexport (<https://ci.libreoffice.org/job/lo_ubsan/2402/>) Change-Id: I95c6e58e1a4204ba828db29e3c1429285bae27ec Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134505 Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Jenkins
2022-05-17tdf#105972: pdf form: export numeric and currency fields as number typeXisco Fauli
Initial support for AFNumber_Format and AFNumber_Keystroke More info in https://experienceleague.adobe.com/docs/experience-manager-learn/assets/FormsAPIReference.pdf?lang=en This patch adds support for CurrencySymbol, DecimalAccuracy and PrependCurrencySymbol for now Change-Id: I8d6ffac51d576a8c243b9c6d5be2c3517bc0125a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134471 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2022-05-17osl::Mutex->std::mutex in framework::TransactionManagerNoel Grandin
Change-Id: I8a1c8e8ccec8ca64cc4f615ea8e9e415a343996d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134396 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-16use FontMetric as SalLayoutGlyphsCache key rather than vcl::FontLuboš Luňák
Apparently even calling OutputDevice::GetFontMetric() rather than GetFont() makes a difference with e.g. tdf#65046-1, when only vcl::Font is used it triggers the assert in checkGlyphsEqual() because of the fonts actually being different. Change-Id: I2a2aba6bf6d4bf78b7449ccdb16be0746663ee87 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134401 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-05-16remove unnecessary copying in OInterfaceContainerHelper4Noel Grandin
caused by triggering make_unique in cow_wrappe when calling through non-const operator* Change-Id: I3191466f464d0f741a628afbe45b60f66f6af2c3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134395 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-16basegfx: move ImplB2DPolyPolygon inside basegfx namespaceTomaž Vajngerl
also remove unneeded typedef Change-Id: I24fd31ff9da579260f1889ed87065f95dcfd1e23 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134377 Tested-by: Tomaž Vajngerl <quikee@gmail.com> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2022-05-16make SharedString move operator= inline (tdf#126109)Luboš Luňák
Calc uses SharedString in mdds::multi_type_vector, which may move contents of its blocks on some operations, and making this inline makes such operations faster. Change-Id: I67d14639cf253c56b8cca5b2837bb06bc9afd7d9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134339 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-05-14tdf#121740 cache hashcode in SequenceAsHashMapNoel Grandin
shaves 2% off load time Change-Id: I5bd4eabf61205df21a27d2822acd2676a7732a3d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134315 Tested-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-14bypass some unnecessary wrapping in Any in SfxEvents_ImplNoel Grandin
Change-Id: I96d1194253207642e7abe83b0b18c82eb3782824 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134316 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-14osl::Mutex->std::mutex in framework::GateNoel Grandin
Change-Id: I72f0ed62a65dbd487a29f409d1941a50cecb894f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134301 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-14simplify constructionNoel Grandin
Change-Id: Ib8a28575fe813a909ce5429732a60ae77f92b6ac Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134269 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-13officecfg,stoc: allow running JVM UNO components out-of-processMichael Stahl
The problem is that 32-bit Win32 applications have very little VM, and soffice.bin can run out, so try to move the JVM to a separate process (uno.bin) and connect to it via pipe. Add a new config to enable this: "org.openoffice.Office.Java/VirtualMachine/RunUnoComponentsOutOfProcess" If enabled, ServiceManager instantiates *all* JVM components out-of-process, by instantiating "com.sun.star.java.theJavaVirtualMachine" out-of-process. To ensure that the remote connection is disconnected at shutdown (and thereby prevent crashes with remote calls during late shutdown), JavaComponentLoader is now a "single-instance" service; this change should be harmless for the default in-process configuration case. Tested with these extensions: Wiki Publisher smoketest TestExtension.oxt odk CalcAddins.oxt Inspector.oxt ToDo.oxt Also passed "make check" on Linux when enabled, if the variable URE_BIN_DIR is set properly for CppunitTest_services. Change-Id: I76bf17a9512414b67dbd20daee25a6d29c05f9d9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133218 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2022-05-13tdf#121740 cheaper to clear namespacemap rather than allocatingNoel Grandin
a new one Change-Id: I413de3a61744400f5582f7e090c161ea21bf0b0f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134267 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-13add SvStream::ReadLine(OStringBuffer... to reduce OString allocationNoel Grandin
and use it where possible Change-Id: I3efc7a642f73661ce606c917c0323ba9948521c6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134265 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-13Remove need for two typedefsStephan Bergmann
Change-Id: I8e576f0b2b417ed78e6f38b745e51cbf8b666c68 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134262 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2022-05-13sw content controls, dropdown: add LOK APIMiklos Vajna
- expose the available list items in a new "items" key of the LOK_CALLBACK_CONTENT_CONTROL callback - add a new lok::Document::sendContentControlEvent() function to be able to select a list item from the current drop-down - add a new listbox to the gtktiledviewer toolbar to select a content control list item when the cursor is inside a dropdown - add tests for the array API of tools::JsonWriter Change-Id: I47f1333a7815d67952f7c20a9cba1b248886f6dd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134256 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2022-05-12speed up simple use of NamedValueCollectionNoel Grandin
where instantiating and allocating a whole map just to extract a single key is way inefficient Change-Id: I55248bc71a9e8826cab9b76fa6916bfa888efa0b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134226 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-05-12tdf#143612: map SecondaryRefValue in form pdf exportXisco Fauli
Change-Id: I590784eb94fb6f4f3a20c4f6d8e3fb618f60d0fc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134227 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2022-05-12these members can be privateCaolán McNamara
Change-Id: Icab045ac04f3e556672191b8df454f8f29ecc6d5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134221 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-05-12merge SetNodeBitmaps and SetNodeDefaultImagesCaolán McNamara
Change-Id: I31a9cc0fc9f97d564f9c8eac0c483892ae3c774f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134210 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>