summaryrefslogtreecommitdiff
path: root/unotools/source
AgeCommit message (Collapse)Author
2021-07-16Output proper language tag instead of Language+Country concatenationEike Rathke
Change-Id: I83d7f94cf304a58f2ff68b2a667ba66de262f4f3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119070 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Jenkins
2021-07-12add Japanese font fallback.Jun NOGATA
Change-Id: Ic15413a13a4d6989362c1a96b11cba4c7406b80c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116724 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-07-12update Japanese font order listJun NOGATA
* Fix tdf#137393 changed Noto CJK font order (Noto Sans/Serif CJK JP has priority) * Add Adobe Genno Kaku Gothic(Source han sans JP) and Genno minecho(Source han serif JP). * Add macOS version Yu Gothic and Yu Mincho fonts. * Add IPAex Gothic, IPAex Mincho and IPAmj Mincho. Japanese fonts are compiled in a TDF wiki. * https://wiki.documentfoundation.org/JA/Fonts Change-Id: I6dec9b5deba19d3272e53a4c73031acd231635f5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116712 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-07-10tdf#142702 Handle STARTMODULE in SvtModuleOptions::GetFactoryShortNameSergey Fukanchik
Change-Id: I06064eb3ff3e77cd0fcc6e211c6baf07adcc3096 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116794 Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org> Tested-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
2021-07-06Related: tdf#125035 Introduce LongDateOrder and handle YDM in DateFormatterEike Rathke
This fixes also unotools/source/i18n/localedatawrapper.cxx:1473: LocaleDataWrapper::scanDateOrder: no magic applicable lv-LV requested lv-LV loaded that is the only locale with a YDM long date order. Change-Id: I776b8706bf5bd3ec11cc46d38fd3613c8df7519f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118482 Tested-by: Jenkins Reviewed-by: Eike Rathke <erack@redhat.com>
2021-07-06Remove now unused LocaleDataWrapper::getLongDate()Eike Rathke
Change-Id: I8e9614a4d77aa8b0c0e68a248ea57f921e3ed424 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118476 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Jenkins
2021-06-30fix failure in JunitTest_unotools_complexNoel Grandin
Temp files created from OTempFileService are always opened with StreamMode::SHARE_DENYALL. So normally you can't open them twice. But the JunitTest_unotools_complex unit test used to work because it exploited a pessimisation in OTempFileService, where that code would close the file when we read to the end. Which meant that the unit test could open it again and read it. However, in commit 218f36dd614cf828e949f605faaf6a6fd615da26 Date: Sun Jun 20 18:51:12 2021 +0200 tdf#135316 remove OTempFileService pessimisation I removed that pessimisation. So make the share mode a little more permissive. Change-Id: I297a5c9c0505816b399fad29414077d03231ec72 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118146 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-06-29constructing SaveOptions just to read default versionNoel Grandin
can be a little expensive sometimes, since it loads a bunch of other stuff at the same time. So create a custom method that just loads the version Change-Id: Ic480d95c4d64c68e57faf1b52f1d102141b7e246 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118047 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-06-29use std::optional in OTempFileServiceNoel Grandin
since we are always needing this, no need to allocate it separately Change-Id: Ic81aa485807dd1705fd0af2065044b4169c9cf5b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118044 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-06-28loplugin:indentation improve checks for brace alignmentNoel Grandin
Change-Id: I333100fda7e181f68f36b03279b3fbb8cb768310 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117615 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-06-23tdf#135316 add SvFileStream::SetDontFlushOnCloseNoel Grandin
if we're going to be deleting a temporary file, there is no point flushing it on close, which has a measureable cost This takes my load time from 17s to 16s Change-Id: I2fce7eeaf0ce9fef826b4ce9a1a4d4c8114cac76 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117607 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-06-21tdf#135316 remove OTempFileService pessimisationNoel Grandin
Closing the temp file when we read to the end, and then opening it again later actually is quite expensive, just leave it open. This takes my load time from 22s to 19s Also clean up the unit-test that failed, so that I can get a useful stack trace out of it when something fails, specifically (*) throw an exception when something goes wrong, instead of just writing a message to stdout (*) don't catch exceptions and write useless messages - just let the exception flow up to the JUnit handler, which will log a nice stacktrace with line numbers. Change-Id: If55c997f91eea4e703e92c632961d68b3453076d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117517 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-06-17use string_view in the Translate APINoel Grandin
Change-Id: I0bb0ea9d39ed623928060ffd3f2e2bc36ba33209 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117272 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-06-17tdf#90401 xmloff: remove personal info of comments and changesLászló Németh
If Options → LibreOffice → Security → Security Options and Warnings → Options... → Security Options → Remove personal information on saving" is enabled. Use the same time (1970-01-01T00:00:00) for mandatory time stamps, and replace authors and creator-initials with "1", "2", "3" etc., also to avoid of joining adjacent redline ranges. Note: to see the work of the unit test in Linux command line: (cd sw && make UITest_writer_tests7 UITEST_TEST_NAME="tdf90401.tdf90401.test_tdf90401_remove_personal_info" SAL_USE_VCLPLUGIN=gen) Change-Id: I3b4d710dbeeee12177aff378597cd2b683ca6c25 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117319 Tested-by: Jenkins Reviewed-by: László Németh <nemeth@numbertext.org>
2021-06-16Adapt implicit OString return value construction to C++23 P2266R1Stephan Bergmann
With the recent implementation of <http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2021/p2266r1.html> "P2266R1: Simpler implicit move" in Clang 13 trunk as <https://github.com/llvm/llvm-project/commit/bf20631782183cd19e0bb7219e908c2bbb01a75f> "[clang] Implement P2266 Simpler implicit move", a --with-latest-c++ build started to fail with > comphelper/source/xml/xmltools.cxx:103:20: error: no viable conversion from returned value of type 'char [39]' to function return type 'rtl::OString' > return str; > ^~~ [...] > include/rtl/string.hxx:277:5: note: candidate constructor [with T = char [39]] not viable: expects an lvalue for 1st argument > OString( T& value, typename libreoffice_internal::NonConstCharArrayDetector< T, libreoffice_internal::Dummy >::Type = libreoffice_internal::Dummy() ) > ^ [...] etc. Change-Id: If34f143a1855fdd7cd22ea3d7594f9381d50a7ec Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117336 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-06-13tdf#142242 Forename imported with trailing spaceNoel Grandin
Fix the case where there is only a name, and no surname. Change-Id: If11078364924c8332b113e5650e7ea2b262a357a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117080 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-06-11Simplify Sequences initializations (unotools)Julien Nabet
Change-Id: Ibc5deee4b69213310a75c2a74a800d99bc451424 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117047 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-05-10reduce cost of locking in SvtModuleOptionsNoel Grandin
Change-Id: If9e0c275822b733d339845d16edfbc5942b4aa6f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115354 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-06loplugin:unusedmethodsNoel Grandin
plugin code needed some updating because it was interacting badly with PCH code in pluginhandler::ignoreLocation Change-Id: I228f94a4e285747bd1d5b8536010f8617118cafa Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115212 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-05loplugin:constmethodNoel Grandin
Change-Id: I7913fd8144d521b8293ac43036d0fad82e457cd1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115145 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-02sal_uLong->sal_uInt32 in ImplFontAttrsNoel Grandin
Change-Id: If0f9304eee98b442a5d3b4cdbf71230461e830bd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114994 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-02throw() -> noexcept, part 2/3: Automatic loplugin:noexcept rewriteStephan Bergmann
Change-Id: I076f16d0536b534abf0ced4d76051eadb4c0e033 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114949 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-05-02tdf#79049 speed up OOXML workbook load (4)Noel Grandin
Optimise LocaleDataWrapper for reads by initialising the data we in the constructor, so we don't need any kind of locking Reduces load time from 34s to 28s. Change-Id: I4bd3bddb30b70ba015fe5b1372534f9507762b74 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114960 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-04-27loplugin:stringadd convert chained append to +Noel Grandin
which can use the more efficient *StringConcat Also fix a crash in stringview plugin which started happening while I working on this. Change-Id: I91a5b9b7707d1594d27d80b73930f5afac8ae608 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114568 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-03-23tdf#124176 Use pragma once in u*Vincent LE GARREC
ucb, uno*, uui Change-Id: Ic4b6d541eb0df8bf7bceddf178ebb5177ad2b87b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112046 Tested-by: Jenkins Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
2021-03-23use single-use attribute for ServiceDocumenterNoel Grandin
instead of rtl::Instance, which means it will get cleaned up when UNO shuts down Change-Id: I90f23e9439a7478e28cd466545ed498dfaf6e4de Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112928 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-03-10Drop 'static_cast<cppu::OWeakObject*>' syntactic noiseMike Kaganski
... where the object is created in-place, and its type is known Change-Id: Ifabfcf2f3ad0d60152f14e8d970c1faa42115288 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112256 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-03-01At least warn about the missing osl::Thread::join with a TODO commentStephan Bergmann
(as is already done in other such cases, too). This apparently randomly hit e.g. <https://ci.libreoffice.org/job/gerrit_linux_clang_dbgutil/81371/> now, > Program terminated with signal 11, Segmentation fault. > > Thread 2 (Thread 0x2b2d9ec16600 (LWP 23008)): [...] > #72 0x00002b2d9edff4d2 in configmgr::Components::~Components() (this=0x2b2d9ef26e58 <configmgr::Components::getSingleton(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&)::singleton>) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/configmgr/source/components.cxx:641 > #73 0x00002b2d854cdce9 in __run_exit_handlers () at /lib64/libc.so.6 > #74 0x00002b2d854cdd37 in () at /lib64/libc.so.6 > #75 0x00002b2d854b655c in __libc_start_main () at /lib64/libc.so.6 > #76 0x00000000004007a9 in _start () > > Thread 1 (Thread 0x2b2db04a5700 (LWP 24092)): > #0 0x00002b2d8672a36b in pthread_rwlock_wrlock () at /lib64/libpthread.so.0 > #1 0x00002b2db00d97d5 in CRYPTO_THREAD_write_lock (lock=0x0) at crypto/threads_pthread.c:78 > #2 0x00002b2db00a9b69 in RAND_get_rand_method () at crypto/rand/rand_lib.c:847 > #3 0x00002b2db00aa30d in RAND_status () at crypto/rand/rand_lib.c:956 > #4 0x00002b2daff92b9d in seed_ssl_prng () at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/workdir/UnpackedTarball/neon/src/ne_socket.c:265 > #5 0x00002b2daff929c9 in ne_sock_connect_ssl (sock=0x29845a0, ctx=0x34e6150, userdata=0x1e224e0) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/workdir/UnpackedTarball/neon/src/ne_socket.c:1800 > #6 0x00002b2daff9ac02 in ne__negotiate_ssl (sess=0x1e224e0) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/workdir/UnpackedTarball/neon/src/ne_openssl.c:717 > #7 0x00002b2daff8de68 in open_connection (sess=0x1e224e0) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/workdir/UnpackedTarball/neon/src/ne_request.c:1716 > #8 0x00002b2daff8cfd6 in send_request (req=0x351d930, request=0x2ea4460) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/workdir/UnpackedTarball/neon/src/ne_request.c:1021 > #9 0x00002b2daff8c698 in ne_begin_request (req=0x351d930) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/workdir/UnpackedTarball/neon/src/ne_request.c:1255 > #10 0x00002b2daff8db25 in ne_request_dispatch (req=0x351d930) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/workdir/UnpackedTarball/neon/src/ne_request.c:1466 > #11 0x00002b2dafe4921b in webdav_ucp::NeonSession::OPTIONS(rtl::OUString const&, webdav_ucp::DAVOptions&, webdav_ucp::DAVRequestEnvironment const&) (this=0x34e6390, inPath="/api/Icons.json", rOptions=..., rEnv=...) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/ucb/source/ucp/webdav-neon/NeonSession.cxx:879 > #12 0x00002b2dafe11bbc in webdav_ucp::DAVResourceAccess::OPTIONS(webdav_ucp::DAVOptions&, com::sun::star::uno::Reference<com::sun::star::ucb::XCommandEnvironment> const&) (this=0x34e7880, rOptions=..., xEnv=uno::Reference to (utl::(anonymous namespace)::UcbTaskEnvironment *) 0x34e8908) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/ucb/source/ucp/webdav-neon/DAVResourceAccess.cxx:187 > #13 0x00002b2dafe9fc28 in webdav_ucp::Content::getResourceOptions(com::sun::star::uno::Reference<com::sun::star::ucb::XCommandEnvironment> const&, webdav_ucp::DAVOptions&, std::unique_ptr<webdav_ucp::DAVResourceAccess, std::default_delete<webdav_ucp::DAVResourceAccess> > const&, bool*) (this=0x34e8970, xEnv=uno::Reference to (utl::(anonymous namespace)::UcbTaskEnvironment *) 0x34e8908, rDAVOptions=..., rResAccess=..., networkAccessAllowed=0x0) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/ucb/source/ucp/webdav-neon/webdavcontent.cxx:3928 > #14 0x00002b2dafe90664 in webdav_ucp::Content::open(com::sun::star::ucb::OpenCommandArgument3 const&, com::sun::star::uno::Reference<com::sun::star::ucb::XCommandEnvironment> const&) (this=0x34e8970, rArg=..., xEnv=uno::Reference to (utl::(anonymous namespace)::UcbTaskEnvironment *) 0x34e8908) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/ucb/source/ucp/webdav-neon/webdavcontent.cxx:2225 > #15 0x00002b2dafe87e0d in webdav_ucp::Content::execute(com::sun::star::ucb::Command const&, int, com::sun::star::uno::Reference<com::sun::star::ucb::XCommandEnvironment> const&) (this=0x34e8970, aCommand=..., Environment=uno::Reference to (utl::(anonymous namespace)::UcbTaskEnvironment *) 0x34e8908) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/ucb/source/ucp/webdav-neon/webdavcontent.cxx:553 > #16 0x00002b2dafe997c1 in non-virtual thunk to webdav_ucp::Content::execute(com::sun::star::ucb::Command const&, int, com::sun::star::uno::Reference<com::sun::star::ucb::XCommandEnvironment> const&) () at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/instdir/program/../program/libucpdav1.so > #17 0x00002b2d8d5436aa in ucbhelper::Content_Impl::executeCommand(com::sun::star::ucb::Command const&) (this=0x34cbbd0, rCommand=...) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/ucbhelper/source/client/content.cxx:1255 > #18 0x00002b2d8d5447b6 in ucbhelper::Content::executeCommand(rtl::OUString const&, com::sun::star::uno::Any const&) (this=0x34e8858, rCommandName="open", rCommandArgument=uno::Any("com.sun.star.ucb.OpenCommandArgument2": {<com::sun::star::ucb::OpenCommandArgument> = {Mode = 2, Priority = 0, Sink = uno::Reference to (utl::(anonymous namespace)::ModeratorsActiveDataSink *) 0x34e7100, Properties = empty uno::Sequence}, SortingInfo = empty uno::Sequence})) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/ucbhelper/source/client/content.cxx:558 > #19 0x00002b2d8d8257a6 in utl::(anonymous namespace)::Moderator::run() (this=0x34e87b0) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/unotools/source/ucbhelper/ucblockbytes.cxx:580 > #20 0x00002b2d8d82cd9e in threadFunc(void*) (param=0x34e87b0) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/include/osl/thread.hxx:189 > #21 0x00002b2d850b3f3a in osl_thread_start_Impl(void*) (pData=0x34e7200) at /home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/sal/osl/unx/thread.cxx:264 > #22 0x00002b2d86726ea5 in start_thread () at /lib64/libpthread.so.0 > #23 0x00002b2d8559296d in clone () at /lib64/libc.so.6 during UITest_sw_options Change-Id: I739bca5c27fba12efb9ed0e902e8d9d1a06c49af Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111742 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-02-23loplugin:refcounting in unotoolsNoel
Change-Id: I7c4540a6b2975c590b36332f23d15882a79491a2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111376 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-02-16loplugin:referencecasting in UnoControls..unoxmlNoel
Change-Id: I42f216b6115be693a4e57d70f6cbbf11b62ec185 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110998 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-01-29Replace rtl::Static with function-local static hereMike Kaganski
Change-Id: Iaba5c16c9f80431a5a9c03b94087e3f0b14fd9d5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110132 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-01-29loplugin:stringviewparam extend to new..Noel
O[U]StringBuffer methods Change-Id: I0ffbc33d54ae7c98b5652434f3370ee4f819f6f4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110090 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-01-28simplify code, use more subView()Noel
Change-Id: I569c7f34acbdf8451cd5c9acf1abd334637072d1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110051 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-01-09fix coverity parse errorsCaolán McNamara
Change-Id: I3a1179947704452e3ffec02be59d0f7bf0b75ab0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109017 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-04loplugin:stringviewparam: operator +=Stephan Bergmann
Change-Id: I30ce1b5bd8fb168da7067c1967c5af2569df2653 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108512 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-01-01tdf#119367: use Unicode paths on Windows in unotoolsMike Kaganski
Change-Id: I671c42c5dfe5acc8a6dd670694c07ff04f08c3e8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108477 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2020-12-29loplugin:stringviewparam: operator +Stephan Bergmann
Change-Id: I044dd21b63d7eb03224675584fa143009c6b6008 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108418 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-26New loplugin:stringliteralvarStephan Bergmann
See the comment at the top of compilerplugins/clang/stringliteralvar.cxx for details. (Turned some affected variables in included files into inline variables, to avoid GCC warnings about unused variables.) Change-Id: Ie77219e6adfdaaceaa8b4e590b08971f2f04c83a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108239 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-11Adapt the remaining OUString functions to std string_viewStephan Bergmann
...for LIBO_INTERNAL_ONLY. These had been missed by 1b43cceaea2084a0489db68cd0113508f34b6643 "Make many OUString functions take std::u16string_view parameters" because they did not match the multi-overload pattern that was addressed there, but they nevertheless benefit from being changed just as well (witness e.g. the various resulting changes from copy() to subView()). This showed a conversion from OStringChar to std::string_view to be missing (while the corresponding conversion form OUStringChar to std::u16string_view was already present). The improvement to loplugin:stringadd became necessary to fix > [CPT] compilerplugins/clang/test/stringadd.cxx > error: 'error' diagnostics expected but not seen: > File ~/lo/core/compilerplugins/clang/test/stringadd.cxx Line 43 (directive at ~/lo/core/compilerplugins/clang/test/stringadd.cxx:42): simplify by merging with the preceding assignment [loplugin:stringadd] > File ~/lo/core/compilerplugins/clang/test/stringadd.cxx Line 61 (directive at ~/lo/core/compilerplugins/clang/test/stringadd.cxx:60): simplify by merging with the preceding assignment [loplugin:stringadd] > 2 errors generated. Change-Id: Ie40de0616a66e60e289c1af0ca60aed6f9ecc279 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107602 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-08use proper struct for trusted authorsNoel
instead of passing around a Sequence<String>, there is no need to use UNO types here. Change-Id: I1b9a1b6919f830d8ce29139b4362b979a669d505 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107396 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-08remove rest of 'xmlsec05' stuffNoel
which has never been used since creation in commit fd069bee7e57ad529c3c0974559fd2d84ec3151a Author: Jens-Heiner Rechtien <hr@openoffice.org> Date: Mon Sep 18 16:07:07 2000 +0000 initial import Change-Id: I1ead1bee759eb09eb72517d90b42813ad66ea1e5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107373 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-07remove SID_BASIC_ENABLED and BasicEnabled optionNoel
which has never been used since creation in commit fd069bee7e57ad529c3c0974559fd2d84ec3151a Author: Jens-Heiner Rechtien <hr@openoffice.org> Date: Mon Sep 18 16:07:07 2000 +0000 initial import Change-Id: I018b1f734c8263167dab3d5c6f98a400666f01d6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107047 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-03convert EHistoryType to scoped enumNoel
Change-Id: I115fc0ed81d6392d3649757727c4d9468213619d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107046 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-03convert SvtPathOptions::Paths to scoped enumNoel
Change-Id: I2e6cab798309a1bc2ade00661bc95dd5ae20f748 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107045 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-02simplify SvtDynamicMenuOptionsNoel Grandin
just use the struct instead of passing around sequence of sequence of PropertyValue Change-Id: Ic03c066962a10daac6f83f30413a5ab09e1bfd5f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106915 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-01OSL_FAIL.*exception -> TOOLS_WARN_EXCEPTIONNoel
Change-Id: I6800e23ead2767d245d5da71d2d40e0f8a6d7e1f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106859 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-11-30loplugin:stringviewparam include comparisons with string literalsNoel
Change-Id: I8ba1214500dddaf413c506a4b82f43d63cda804b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106559 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-11-24loplugin:stringviewparam extend to comparison operatorsNoel
which means that some call sites have to change to use unicode string literals i.e. u"foo" instead of "foo" Change-Id: Ie51c3adf56d343dd1d1710777f9d2a43ee66221c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106125 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-11-17loplugin:stringviewparam check methods tooNoel
not just functions Change-Id: Icca295dd159002b428b73f2c95d40725434f04d9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105789 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-11-11loplugin:stringviewNoel
Add new methods "subView" to O(U)String to return substring views of the underlying data. Add a clang plugin to warn when replacing existing calls to copy() would be better to use subView(). Change-Id: I03a5732431ce60808946f2ce2c923b22845689ca Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105420 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>