summaryrefslogtreecommitdiffstats
path: root/unotools
Commit message (Collapse)AuthorAgeFilesLines
* convert LocationType to scoped enumNoel Grandin2017-02-101-19/+9
| | | | | | and drop unused ltAnyInstance enumerator Change-Id: Ic471470973542ebcd3c9d0123870e70b3de6b8bb
* convert ConfigNameFormat to scoped enumNoel Grandin2017-02-103-52/+5
| | | | | | | | and drop unused constants CONFIG_NAME_PLAINTEXT_NAME CONFIG_NAME_FULL_PATH Change-Id: Ibf7e88da0ae54516cb863b8efa995201f2a95268
* convert EItem to scoped enumNoel Grandin2017-02-1020-56/+48
| | | | | | | | | | | and drop read-only enumerators: enum EItem E_APEARCFG enum EItem E_FLTRCFG enum EItem E_FONTSUBSTCONFIG enum EItem E_LANGUAGEOPTIONS enum EItem E_SEARCHOPT Change-Id: Ie3baaecec3d1c30404b4fb0d948e25d4bb2f3f93
* convert SvtSaveOptions::EOption to scoped enumNoel Grandin2017-02-101-24/+15
| | | | | | | | and remove unused E_SAVEUNPACKED, E_USESHA1INODF12, E_USEBLOWFISHINODF12 enumerators Change-Id: I7c384e0c30af5091a22beeda1c77e4b71fdde55e
* convert SvtSecurityOptions::EOption to scoped enumNoel Grandin2017-02-101-27/+24
| | | | | | | | | and drop unused E_MACRO_DISABLE enumerator Change-Id: I0bd706d4d4e1d8b9004e68c9e77c11410c62a64a Reviewed-on: https://gerrit.libreoffice.org/34067 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* convert SvtSysLocaleOptions::EOption to scoped enumNoel Grandin2017-02-101-8/+3
| | | | | | | | | and drop unused E_UILOCALE enumerator Change-Id: Ic9bdac91fab15af45e7dbd613e6e44b73b5cf9de Reviewed-on: https://gerrit.libreoffice.org/34066 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* convert SearchParam::SearchType to scoped enumNoel Grandin2017-02-101-13/+3
| | | | | | | | | and drop unused SRCH_LEVDIST enumerator Change-Id: Ic5118757060656562e04dd7da24a3f143abec3fb Reviewed-on: https://gerrit.libreoffice.org/34065 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* convert ResultType to scoped enumNoel Grandin2017-02-091-42/+23
| | | | | | | | | and drop unused enumerators Change-Id: I429e586967ef46e2657e296a369cdeb3b75bfc02 Reviewed-on: https://gerrit.libreoffice.org/34064 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* Add missing #includesStephan Bergmann2017-02-068-0/+18
| | | | | | | | | ...and remove some unncessary using directives/declarations, in preparation of removing now-unnecessary #includes from cppumaker-generated files, post e57ca02849c3d87142ff5ff9099a212e72b8139c "Remove dynamic exception specifications". Change-Id: Iaf1f268871e2ee1d1c76cf90f03557527ebc9067
* Fix some typosSamuel Mehrbrodt2017-02-027-25/+25
| | | | | | | Change-Id: Ide3786aad5589e2d430a4e3890d51117b145e51d Reviewed-on: https://gerrit.libreoffice.org/33842 Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
* convert method names in tools::SvRef to be more like our other..Noel Grandin2017-02-022-10/+10
| | | | | | | | | | | reference classes, uno::Reference and rtl::Reference. Specifically rename Is()->is() and Clear()->clear(). Change-Id: Icb7e05e2d09cb9977121508b837ba0961dabb4ae Reviewed-on: https://gerrit.libreoffice.org/33576 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* Compatibility options refactoring. Part 1 small fixVitaliy Anderson2017-02-011-1/+1
| | | | | | | | | | Add missing recommended formatting options in Compatibility.xcs Correct ConfigItem rootnode path for SvtCompatibilityOptions_Impl Change-Id: I1e56b276bf4a0801ab724baaecda53168783b27f Reviewed-on: https://gerrit.libreoffice.org/33786 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
* Compatibility options refactoring. Part 1 small fixVitaliy Anderson2017-01-311-22/+11
| | | | | | | | | SvtCompatibilityOptions_Impl::impl_GetPropertyNames() solve problem with wrong lProperties names Change-Id: I0b71a80d542d8175c3f6e6cdf5fe857143714acb Reviewed-on: https://gerrit.libreoffice.org/33752 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
* teach lolugin:stringconstant about calling constructorsNoel Grandin2017-01-3114-17/+17
| | | | | | | | | | | so we can remove unnecessary calls to the OUString(literal) constructor when calling constructors like this: Foo(OUString("xxx"), 1) Change-Id: I1de60ef561437c86b27dc9cb095a5deb2e103b36 Reviewed-on: https://gerrit.libreoffice.org/33698 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* Compatibility options refactoring. Part 1Vitaliy Anderson2017-01-271-533/+164
| | | | | | | | | | | | It relate to reduce the nubmer of copy-paste the same code and simplify adding compability options. Also using enum class instead enum can eliminate to occurrence an error relate to access to out of range an array. Change-Id: I07b862aac5f88da4a98e2273cb14daa09e70eacb Reviewed-on: https://gerrit.libreoffice.org/33543 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* Remove dynamic exception specificationsStephan Bergmann2017-01-2621-253/+129
| | | | | | | | | | | | | | | | | | | | | | | | | ...(for now, from LIBO_INTERNAL_CODE only). See the mail thread starting at <https://lists.freedesktop.org/archives/libreoffice/2017-January/076665.html> "Dynamic Exception Specifications" for details. Most changes have been done automatically by the rewriting loplugin:dynexcspec (after enabling the rewriting mode, to be committed shortly). The way it only removes exception specs from declarations if it also sees a definition, it identified some dead declarations-w/o-definitions (that have been removed manually) and some cases where a definition appeared in multiple include files (which have also been cleaned up manually). There's also been cases of macro paramters (that were used to abstract over exception specs) that have become unused now (and been removed). Furthermore, some code needed to be cleaned up manually (avmedia/source/quicktime/ and connectivity/source/drivers/kab/), as I had no configurations available that would actually build that code. Missing @throws documentation has not been applied in such manual clean-up. Change-Id: I3408691256c9b0c12bc5332de976743626e13960 Reviewed-on: https://gerrit.libreoffice.org/33574 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
* loplugin: unnecessary destructor test..unotoolsNoel Grandin2017-01-263-15/+0
| | | | | | | Change-Id: I1fd8a3f39b875d1920759f42e37f4c9d6785d62e Reviewed-on: https://gerrit.libreoffice.org/33573 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* New loplugin:dynexcspec: Add @throws documentation, unotoolsStephan Bergmann2017-01-194-0/+24
| | | | Change-Id: Ie1adfe09bf5b63adecc0a5a67a042e6e678b58dd
* new loplugin: useuniqueptr: unotools..xmlscriptNoel Grandin2017-01-191-2/+1
| | | | | | | Change-Id: I6966d44cff644112dd837adfe7d9c4f459457271 Reviewed-on: https://gerrit.libreoffice.org/33298 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* tdf#104349, tdf#104668 MS Word compatibility trailing blanks option part 2Vitaliy Anderson2017-01-181-7/+36
| | | | | | | | | Create the option in Tools->Options->LibreOffice Writer->Compatibility Change-Id: I7c766138db9210d3e7a97eea48b9265ee9762199 Reviewed-on: https://gerrit.libreoffice.org/33148 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
* New loplugin:externvar: unotoolsStephan Bergmann2017-01-098-16/+43
| | | | Change-Id: I117f5166dffa1514cfc774105b4c94009183fe90
* teach sallogareas plugin to catch inconsistenciesNoel Grandin2016-12-152-2/+2
| | | | | | | Change-Id: I8bcea5ffc74d48148bea78da8c17744e288c069a Reviewed-on: https://gerrit.libreoffice.org/32004 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* tdf#88206 replace cppu::WeakImplHelper* in unotoolsJochen Nitschke2016-12-082-2/+2
| | | | | | | | | | [needs 288386f6986622461f28276ff7ff3e7172143159 "Another 'Do not export whole class to avoid MS C++ implicitly exporting...'" to build with MSVC] Change-Id: I8de7c4a1947ce91f9a629536e481c012e7c5c7ec Reviewed-on: https://gerrit.libreoffice.org/31679 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
* Non-inline virtual dtors of exported classesStephan Bergmann2016-12-081-0/+4
| | | | Change-Id: I7b3597d48bf7b0196b98c869329d2fb1a46fa8f2
* OSL_TRACE->SAL in unotools..uuiNoel Grandin2016-12-063-5/+5
| | | | Change-Id: I7f391604401b8a10f5d451673ed6223c031c56ab
* convert DecodeMechanism to scoped enumNoel Grandin2016-12-052-15/+15
| | | | Change-Id: I5c56634b1bca8e37fa73d02d2428645301b6c547
* remove now unused SvtSysLocaleOptions::GetLocaleConfigString()Eike Rathke2016-12-021-7/+2
| | | | | | Which just lead to confusion as could be seen in two earlier commits.. Change-Id: I172127cf08bcd45c3c53e0cf00cf11a41e0dd3a6
* Simplify FontManager a bitKhaled Hosny2016-12-022-88/+0
| | | | | | | | | | | | | | There does not seem to be any need for that atom thing as we are perfectly happy using plain OUStrings in the same struct, not to mention that font names are supposed to be unique so I don’t see what we are saving here. As this was the only use for unotools/atom, it goes with it. Change-Id: If9d58d84fff0403f9b2c41fe594b99028b30c2f4 Reviewed-on: https://gerrit.libreoffice.org/31520 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
* Rewrite some (trivial) assignments inside if/while conditions: unotoolsStephan Bergmann2016-11-291-3/+2
| | | | Change-Id: Iee52f5a3a815a782692a8ee962425ff2ab9173a8
* Allow extensions to provide color palettesStephan Bergmann2016-11-291-0/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Until now, .oxt extensions cannot provide additional color palettes (.soc files, see e.g. Draw's "Format - Area... - Area - Color - Colors - Palette:" drop-down list). There are two ways how this feature could be added: Either add a new file-entry media-type to extensions' META-INF/manifest.xml and add support for that in the code. Or leverage the existing code, which reads the configuration set /org.openoffice.Office.Paths/Paths/Palette/InternalPaths, where each set element denotes a directory, and scans those directories for .soc files. So an extension would include an .xcu file adding such a path (using %origin% to denote a directory within the .oxt file itself) and a directory with one or more .soc files. For simplicity, this commit uses the second way. The only problem with the existing code is that extension configuration data using %origin% is rewritten to vnd.sun.star.expand URIs which the palette-scanning code does not support. So extend SvtPathOptions_Impl::GetPath's PATH_PALETTE case to expand such URIs. (The choice of doing it in SvtPathOptions is somewhat arbitrary; there would be other, more generic places where it might make sense to do such expansion, but which would also carry a higher risk of regressions.) <https://github.com/stbergmann/palette-extension> contains an example of such an extension (with a LibreOffice-minimal-version of "LibreOffice 5.3", assuming this commit will be backported to upcoming LO 5.3). Some drawbacks of going this way are: * No control over where extension palettes appear in the palette drop-down lists. (But those lists appear to be sorted in some random order, anyway?) * Commit on future support of the .soc file format (which, however, is XML) and the /org.openoffice.Office.Paths/Paths/Palette/InternalPaths configuration set in a backward-compatible way. (But any other way of implementing this feature would also need a similar commitment.) * Somewhat odd, indirect approach where an extension specifies a directory filled with .soc files, instead of specifying the .soc files diretly. * With the current palette-management code, live extension addition/removal is not immediately reflected in all places that offer palette drop-down lists. (But this should be fixable, and would be an issue with other approaches, too.) Change-Id: I68b30127d61764d1b5349f1f2af9c712828bee3e
* convert FILTERCFG constants to o3tl::typed_flagsNoel Grandin2016-11-251-121/+128
| | | | Change-Id: I01a4df6bb9b90177ce72c61fd0d611a63559166e
* loplugin:unnecessaryoverride (dtors) in unotoolsStephan Bergmann2016-11-244-44/+0
| | | | Change-Id: I14f10addc701be143b0482dc62d2e90a0862062d
* use o3tl::typed_flags in ConfigurationListener::ConfigurationChangedNoel Grandin2016-11-245-28/+28
| | | | Change-Id: I0ad7c02953aa53168dc242f1f374ab871728c84e
* Make this look less wiredKhaled Hosny2016-11-181-2/+8
| | | | Change-Id: I20b6a5e6ecdf48e1ca8df2e7e86248eae666c9f1
* Correct minute mapping from Adobe Symbol encodingKhaled Hosny2016-11-181-1/+1
| | | | | | | It should be mapped to U+2032 PRIME not U+0384 GREEK TONOS, based on: http://www.unicode.org/Public/MAPPINGS/VENDORS/ADOBE/symbol.txt Change-Id: I554fe307955ac166d5c4e96813be71c03234eb4f
* loplugin:unusedfieldsNoel Grandin2016-11-171-4/+0
| | | | | | | Change-Id: Id2dbbf384637223db3d334d95332251832918003 Reviewed-on: https://gerrit.libreoffice.org/30927 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
* Copycat SvtSysLocale_Impl for SvtSysLocaleOptions_ImplJulien Nabet2016-11-121-29/+25
| | | | | | | | | | | | | | and so avoid warn:unotools.config:6728:1:unotools/source/config/configmgr.cxx:167: ConfigManager not empty when exiting LO See http://nabble.documentfoundation.org/OSL-ASSERT-items-empty-because-of-Setup-L10N-td4199284.html Thank you Eike for the hint! Change-Id: I4b374a075ad8f1ef10a71f3a9424986154613aef Reviewed-on: https://gerrit.libreoffice.org/30787 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* loplugin:unnecessaryvirtual in test..vbahelperNoel Grandin2016-11-071-2/+2
| | | | | | | Change-Id: I0e110af6eab798e11f96d0f7d282d59440d91965 Reviewed-on: https://gerrit.libreoffice.org/30649 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
* Replace some OSL_ASSERT (unotools/configmgr)Julien Nabet2016-11-051-3/+2
| | | | | | | Change-Id: Ifacee39c43c1171ce673f16a9069e1f72dffae78 Reviewed-on: https://gerrit.libreoffice.org/30596 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
* Add helper for creating zip filesSamuel Mehrbrodt2016-11-032-0/+200
| | | | | | | Change-Id: I8b49b74622bf4d671d640e4cd06dc2da348ee222 Reviewed-on: https://gerrit.libreoffice.org/30478 Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
* coverity#1371313 Missing move assignment operatorCaolán McNamara2016-11-031-7/+39
| | | | Change-Id: I07a9d7fe837c18e66b4a2a57186f1f9b0d44daee
* loplugin:oncevar in unoxml..toolkitNoel Grandin2016-10-314-31/+17
| | | | | | | Change-Id: I3b97665908be0a44d24192433bdc9c2bd9008736 Reviewed-on: https://gerrit.libreoffice.org/30431 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
* loplugin:expandablemethods in UnoControls..vbahelperNoel Grandin2016-10-252-14/+3
| | | | | | | Change-Id: I7e607df2a1f6d4eb207ee0d3eb30f41fac44a0c6 Reviewed-on: https://gerrit.libreoffice.org/30262 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* loplugin:expandablemethodds in include/tools..unotoolsNoel Grandin2016-10-212-7/+2
| | | | | | | Change-Id: I5607d4a2a81de1a3ae329acd1e90280a21522f06 Reviewed-on: https://gerrit.libreoffice.org/30097 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
* tdf#103274 (11): Add default XCommandEnvironment referenceGiuseppe Castagno2016-10-201-1/+4
| | | | | | | Change-Id: I8145e167ef58d83666c2f18adf869a30c859ee8f Reviewed-on: https://gerrit.libreoffice.org/30036 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Giuseppe Castagno <giuseppe.castagno@acca-esse.eu>
* '>>=' with rhs Any is a copy assignmentJochen Nitschke2016-10-191-4/+4
| | | | | | | | | | replace '>>=' operator with '=' where return value is not checked and simplify. (note: switches lhs with rhs) Change-Id: I0d283e8786ea996ed80d7aa9d8a4ea930a3d52f8 Reviewed-on: https://gerrit.libreoffice.org/30004 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
* tdf#103274 (3): Add default XCommandEnvironment referenceGiuseppe Castagno2016-10-171-1/+1
| | | | | | | Change-Id: I0a3d8fbea1143c3f7fee6f9f3cbdfc24399090ed Reviewed-on: https://gerrit.libreoffice.org/29980 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Giuseppe Castagno <giuseppe.castagno@acca-esse.eu>
* tdf#103274: Add default XCommandEnvironment referenceGiuseppe Castagno2016-10-171-1/+1
| | | | | | | Change-Id: I4c9e4945e9fd4bb4fc2fe29e5a2a800cc5f298ae Reviewed-on: https://gerrit.libreoffice.org/29966 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Giuseppe Castagno <giuseppe.castagno@acca-esse.eu>
* tdf#103274: Add helper for a default XCommandEnvironment reference.Giuseppe Castagno2016-10-171-0/+18
| | | | | | | | | | | | | | | | | | | | This helper should be used where the empty XCommandEnvironment e.g. something like: css::uno::Reference< css::ucb::XCommandEnvironment >() is currently used. See comment in the committed code (include/unotools/ucbhelper.hxx) for details. A case use is presented in this commit, please see: sfx2/source/doc/docfile.cxx for details. Change-Id: Ieb97c0ed61f31ef8df532c8be0e7ff1035327915 Reviewed-on: https://gerrit.libreoffice.org/29927 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Giuseppe Castagno <giuseppe.castagno@acca-esse.eu>
* clang-cl loplugin: unotoolsStephan Bergmann2016-10-151-12/+16
| | | | | | | Change-Id: I1bbdae6b27a04321b232851f5f45ac2248b55835 Reviewed-on: https://gerrit.libreoffice.org/29843 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>