summaryrefslogtreecommitdiff
path: root/xmloff
AgeCommit message (Collapse)AuthorFilesLines
2018-06-08tdf#115007: add import/export to NatNum12 (spell out numbers,László Németh4-18/+53
dates and money amounts, supporting all the XNumberText/libnumbertext formatting codes, for example "ordinal", "ordinal-number", "ordinal-feminine", etc., and ISO 4217 currency codes, also their possible combinations. NatNum12 formatting codes are stored by using the newly introduced (yet, loext:)transliteration-spellout attribute. creator-initials also added to token list Change-Id: I20f93c9d16778f142067a56d53b336d0acbe2d92 Reviewed-on: https://gerrit.libreoffice.org/54673 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2018-06-08look for unnecessary calls to Reference::is() after an UNO_QUERY_THROWNoel Grandin3-27/+14
Since the previous call would throw if there was nothing to be assigned to the value. Idea from tml. Used the following script to find places: git grep -A3 -n UNO_QUERY_THROW | grep -B3 -F 'is()' Change-Id: I36ba7b00bcd014bdf16c0455ab91056f82194969 Reviewed-on: https://gerrit.libreoffice.org/55417 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tor Lillqvist <tml@collabora.com> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2018-06-05tdf#42949 remove unused compheler includes ..Jochen Nitschke3-5/+1
and fix the fallout Change-Id: I15bc5d626f4d157cbc69a87392078b41e621d14e Reviewed-on: https://gerrit.libreoffice.org/54882 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-05-30Load ODF signature line signed imagesSamuel Mehrbrodt1-0/+65
Change-Id: I7684d4747c4977103fcc3dca62f5d1c28a0836bf Reviewed-on: https://gerrit.libreoffice.org/55056 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-05-29loplugin:unusedfields-in-constructor in xmloffNoel Grandin23-81/+39
fields that are only referenced in the constructor Change-Id: I44bddb2dce2f30c21ea0f1ada4c1615c854d3334 Reviewed-on: https://gerrit.libreoffice.org/54823 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-27Fix typosAndrea Gelmini1-1/+1
Change-Id: I907e5dbcd7c62344c2c76fe2fdaf1b18ecfecee1 Reviewed-on: https://gerrit.libreoffice.org/54838 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2018-05-25Improve re-throwing of UNO exceptionsNoel Grandin1-4/+7
(*) if we are already throwing a Wrapped*Exception, get the exception using cppu::getCaughtexception. (*) when catching and then immediately throwing UNO exceptions, use cppu::getCaughtException to prevent exception slicing (*) if we are going to catch an exception and then immediately throw a RuntimeException, rather throw a WrappedTargetRuntimeException and preserve the original exception information. Change-Id: Ia7a501a50ae0e6f4d05186333c8517fdcb17d558 Reviewed-on: https://gerrit.libreoffice.org/54692 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-22vbahelper, xmloff: Ask current datetime only onceTakeshi Abe1-4/+4
Change-Id: I930983fab11d30f0887965fe30b07c5ac6eef8ef Reviewed-on: https://gerrit.libreoffice.org/54651 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-20Fix typosAndrea Gelmini1-6/+6
Change-Id: Ia2c768f519a4131b26f38243a64179a39771eb00 Reviewed-on: https://gerrit.libreoffice.org/54576 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-05-17crashtesting: assert on fdo62508-1.odtCaolán McNamara2-4/+12
document, with meta:generator of "opxml2odf - Version KO 0.1" has a styles.xml xmlns of... xmlns:ofo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" instead of the usual xmlns:fo=... use the importer namespace map to get the importers namespace prefix for the fastparser namespace uri for the token Change-Id: Ib633009f6c2b7dae5a3ceb1c921adfff84e21150 Reviewed-on: https://gerrit.libreoffice.org/52720 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-05-17New o3tl::temporary to simplify calls of std::modfStephan Bergmann1-3/+2
...that ignore the out-parameter integral part Change-Id: I05f07c1a8909023232f8aecf75ea5541d4eb81ca Reviewed-on: https://gerrit.libreoffice.org/54474 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>
2018-05-17Avoid warning C4101 with some over-eager MSVCStephan Bergmann1-0/+1
<https://ci.libreoffice.org/job/lo_tb_master_win/17664/console>: > C:/cygwin/home/tdf/lode/jenkins/workspace/lo_tb_master_win/xmloff/source/forms/propertyimport.cxx(189): error C2220: warning treated as error - no 'object' file generated > C:/cygwin/home/tdf/lode/jenkins/workspace/lo_tb_master_win/xmloff/source/forms/propertyimport.cxx(189): warning C4101: 'dummy': unreferenced local variable Change-Id: Ic80aee5b9c7af44bf87081492008a6ec30fcfe1c
2018-05-17loplugin:redundantcast improvements for floating-integer conversionsStephan Bergmann1-1/+6
Change-Id: I63dbf18f144a792ae775fe6706da81657f790016 Reviewed-on: https://gerrit.libreoffice.org/54416 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>
2018-05-16loplugin:constantparamNoel Grandin1-9/+8
Change-Id: I0110e0c662004456e4bc8f8082e2e2fea59e0148 Reviewed-on: https://gerrit.libreoffice.org/54385 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-11Only write mime-type attribute if ODF version > 1.2Samuel Mehrbrodt1-1/+1
Change-Id: I88ae821e969a2c45161f59eb2e667f645f1afdac Reviewed-on: https://gerrit.libreoffice.org/54075 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-05-10Only write signatureline element if ODF version > 1.2Samuel Mehrbrodt1-1/+2
Change-Id: I28769e8e3f4d5a0daa54fa188a9aec56c31120ca Reviewed-on: https://gerrit.libreoffice.org/54074 Reviewed-by: Tomaž Vajngerl <quikee@gmail.com> Tested-by: Jenkins <ci@libreoffice.org>
2018-05-08OFFICE-3776 xmloff: adapt ODF import to renamed text:sender-initialsMichael Stahl6-6/+15
ODF TC decided to rename the element to meta:creator-initials, so adapt the import so it can read this in addition to the 2 element names produced by current and past LO versions. Also add a test. Unfortunately it turned out that the ODF validator had a bug in checking character data in foreign elements, which is triggered by the test document, see https://issues.apache.org/jira/browse/ODFTOOLKIT-475 ... so update the validator jar as well. Change-Id: I1de1e8772b41f8937f043d9a0d150e169f25ffd4 Reviewed-on: https://gerrit.libreoffice.org/53979 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
2018-05-05Fix typosAndrea Gelmini1-1/+1
Change-Id: I92078fdece135754744d85424956dbb071f3899e Reviewed-on: https://gerrit.libreoffice.org/53638 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-04-30loplugin:useuniqueptr in XMLTextParagraphExportNoel Grandin2-8/+7
Change-Id: I753bbfc60172a36e1f3ba08398dc17ee14e0c551 Reviewed-on: https://gerrit.libreoffice.org/53604 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-27Fix typosAndrea Gelmini2-2/+2
Change-Id: I32c0966f8489d58f02b32bf205aedbb8303a217d Reviewed-on: https://gerrit.libreoffice.org/53432 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2018-04-26[API CHANGE] deprecate XGraphicObjectResolverTomaž Vajngerl2-51/+35
XGraphicObjectResolver was used to get the GraphicObject URL from an storage (package) URL. This isn't possible anymore in LO 6.1 since creating GraphicObject from uniqueID was removed for its lifecycle issues. XGraphicObjectResolver is now deprecated and when the "resolveGraphicObjectURL" is called, it throws a RuntimeExeption. In places where XGraphicObjectResolver was used, we now use the XGraphicStorageHandler as the alternative. Both share a common implementation so previously we could cast one to the other at any time. Now only XGraphicStorageHandler is used. GraphicObjectResolver was removed and replaced by the alternative GraphicStorageHandler for instance creation - where needed. Change-Id: I5d3f759c6f95b7dbe2d93688d99c8aa4899ffa84 Reviewed-on: https://gerrit.libreoffice.org/53279 Reviewed-by: Tomaž Vajngerl <quikee@gmail.com> Tested-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-21cppcheck: identicalInnerConditionJochen Nitschke1-13/+11
renamed temporary list in EnhancedCustomShape2d.cxx to avoid shadow of a local variable Change-Id: I17a2261dafd2067480fcc5314af4f48765d6b690 Reviewed-on: https://gerrit.libreoffice.org/53244 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Jochen Nitschke <j.nitschke+logerrit@ok.de>
2018-04-19tdf#117075 TOC numberings have incorrect right indentNoel Grandin9-3/+27
This reverts parts of commit 867a22fd199e732803c9050fe9f84ad630ec27fb Date: Wed Mar 28 10:00:30 2018 +0200 loplugin:virtualdown in xmloff/xmlsecurity and commit 73e6a7975b3508c5cfccb3df7c35b0303f87d9bb Date: Thu Mar 29 09:35:22 2018 +0200 loplugin:unusedmethods Change-Id: Id4230fafc10bbfe5822f7011a1b1d3d9dff30735 Reviewed-on: https://gerrit.libreoffice.org/53149 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-16Make linked graphic register into LinkedManager againTomaž Vajngerl1-12/+4
Change-Id: I16b162f86d6221d120f6355f9a52c1abfcd0ac73 Reviewed-on: https://gerrit.libreoffice.org/52911 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-15remove some unused comphelper includesJochen Nitschke9-9/+0
and fix the fallout Change-Id: I5d0c2040f57a3ac354a7e277592da31d09a5f359 Reviewed-on: https://gerrit.libreoffice.org/52894 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Jochen Nitschke <j.nitschke+logerrit@ok.de>
2018-04-11new loplugin:unusedvariablemoreNoel Grandin1-3/+0
collection of heuristics to look for local variables that are never read from i.e. do not contribute to the surrounding logic This is an expensive plugin, since it walks up the parent tree, so it is off by default. Change-Id: Ib8ba292241bd16adf299e8bba4502cb473513a06 Reviewed-on: https://gerrit.libreoffice.org/52450 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-10xmloff: fix leak in XMLPropertySetMapperEntry_ImplMichael Stahl1-3/+7
The XMLNamedBoolPropertyHdl should be owned by OControlPropertyHandlerFactory like all the other handlers created in that function. Thanks to Julien Nabet for pointing out the problem. Change-Id: Id474b2fdb84ca74f686d0c888fbedbee623c31bb Reviewed-on: https://gerrit.libreoffice.org/52666 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
2018-04-09use more DBG_UNHANDLED_EXCEPTIONNoel Grandin7-24/+31
so we get nice logs of the exception dynamic type for UNO exceptions. Change-Id: Ic0b10dc14d354a2c9a0591b3a51d2f1640d54bdb Reviewed-on: https://gerrit.libreoffice.org/52465 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-08tdf#112384 sw: Allow New line as a label followed by chapter numberingNithin Kumar Padavu4-2/+19
reference-language also added to token list Change-Id: I32713508d3611dc2bce10b2c5abb1e1a4167bdaf Reviewed-on: https://gerrit.libreoffice.org/52561 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-04-07SOSAW080: Added first bunch of basic changes to helpersArmin Le Grand1-36/+3
SOSAW080: Make SdrModel& prerequisite to SdrObjects Added need for SdrModel& in constructors of SdrModel, SdrPage, SdrView and SdrObjList. Builds, not finished. SOSAW080: removed and replaced old SdrModel Removed and replaced GetModel()/SetModel() in all using classes (SdrObject, SdrPage, SdrView), added accessors to new referenced SdrModel, adapted all accessing places. Refactored/Extended ::Clone and ::operator== for these classes to allow cloning objects to a target SdrModel. Adapted places where this is done AFAP. Added quite some comments (tagged with 'TTTT') where possible further work is needed. Builds completely, thus checking in. This does not mean that this change is done yet. SOSAW080: Adapted SdrPage/SdrModel relationship Also needed to work on copy-construction of SdrPage and hierarchy, quite some stuff removed, no copy-constructor anymore, no MigrateItemPool stuff. Builds well, test stuck, will need some cleanup/finetunung SOSAW080: Smaller corrections/includes adapted SOSAW080: Smaller corrections/includes adapted SOSAW080: Debugging/Stabilizing/MakeUnitTestWork SOSAW080: Stabilized for UnitTests, cleanups SOSAW080: Adapted GetObjGraphic to just take a const SdrObject& SOSAW080: Removed ChangeModel from classes Classes SvxTextEditSource and SvxDrawPage (including TextEditSource stuff) do not need change of SdrModel anymore. SOSAW080: Adapted some comments to make more readable SOSAW080: Corrected constructor SOSAW080: getSdrModelFromUnoModel added override marks SOSAW080: Added missing includes SOSAW080: Corrected SdrPage constructor SOSAW080: Corrected some SdrObject::Clone scenarios Especially when cloning to another SdrModel and taking the sdr::properties into account. SOSAW080: Added include for Mac-Build SOSAW080: Added Scale to DefaultProperties If a SdrModel change happens in DefaultProperties copy constructor (used from Clone()), potentially a Scale for the SfxItems has to be done. SOSAW080: Added missing include for MacBuild SOSAW080: Corrected CppunitTest_sc_anchor_test An adaption of a SdrPathObj instantiation was missing, added that. Seems as if that test is no tpart of the usual 'make' scenario, but used/executed in gerrit builds SOSAW080: Reworked SvxShape to use SdrObject's SdrModel SOSAW080: Reworked SvxShape to use SdrObject's SdrModel SOSAW080: Free SdrObjects when SdrModel goes down In an UNO API test problem is that SvxShapes reference SdrShapes, but these are not added to a SdrPage and not 'owned' by the SvxShape. Thus these do not get deleted at all (same in master, memory leak). I extended SvxShape::Notify the case for ModelCleared to also Free the SdrObject when not owner and it's not added to a SdrPage (in that case it gets deleted with deleting the SdrModel) SOSAW080: Solve UNO API calls that move SvxShapes to other Model Due to UNO API tests I got a call to insert an xShape to a xDrawPage which was constructed in another Model, this has now to be done by Cloning the SdrObject to the new SdrModel, getting rid of the old one and getting all the UNO implementation stuff right (referemces SdrObject <-> xShape). 1cb7d573d323e98a89761fe662c10c4a654fdec0 24617494a0ef79f6e33dfcb02782a833a81c6434 763f39094b6a48b529a6952d01468f8776c97679 242b9e228a9a042c3a5bdd38b1ea6600144276d5 242b9e228a9a042c3a5bdd38b1ea6600144276d5 33a6f3f306b70c223171aef796dd5ee041ad14df 6878b33f8b05738a44c0910e40a60a0f0d1d58ed 0a636caf3cb36c2f9c6cd11aa22cb9bc435dc8f2 8c4626274a5cc531dad27f27c0c45d4c528fb2fb 446685a49a6d67aedd01cfbbd5e87b07f97a4d7b c1b5ed3c99bc7219a0061e4ece24ea42afd2889a 22de9a1c8af7c25be5c108671ddc548ba323ed47 4caf6b6fbbe6e8130741d793dffb560fd01d4ed5 488b9601735ec1822433f82f633990063951fe08 c366d60299f239e3df856ddffedb19e743e4be0c c5137ba8c597c7b5f90318df50e87b93a39a28dc f9e646242cf89f6fde1315046952252a2c429779 f830fbc5fadd89d04be5edd2a5abf9b0d4bf0410 1694b54903df784385abaa8452e1201e12344238 17bcb44d2e29920c0c74430c2d9c703b36cfa0ad 17bcb44d2e29920c0c74430c2d9c703b36cfa0ad 7b5c241faec7488924e5935ae8b19f785846b5e4 bf097ee7467895823fbd158a2a9543da3b5a5078 Change-Id: Iaf53535de0502a481466be74a1768bbb39f0e78c Reviewed-on: https://gerrit.libreoffice.org/52526 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Armin Le Grand <Armin.Le.Grand@cib.de>
2018-04-06Revert "SOSAW080: Added first bunch of basic changes to helpers"Armin Le Grand1-3/+36
This reverts commit 6c14c27c75a03e2363f2b363ddf0a6f2f46cfa91.
2018-04-06SOSAW080: Added first bunch of basic changes to helpersArmin Le Grand1-36/+3
SOSAW080: Make SdrModel& prerequisite to SdrObjects Added need for SdrModel& in constructors of SdrModel, SdrPage, SdrView and SdrObjList. Builds, not finished. SOSAW080: removed and replaced old SdrModel Removed and replaced GetModel()/SetModel() in all using classes (SdrObject, SdrPage, SdrView), added accessors to new referenced SdrModel, adapted all accessing places. Refactored/Extended ::Clone and ::operator== for these classes to allow cloning objects to a target SdrModel. Adapted places where this is done AFAP. Added quite some comments (tagged with 'TTTT') where possible further work is needed. Builds completely, thus checking in. This does not mean that this change is done yet. SOSAW080: Adapted SdrPage/SdrModel relationship Also needed to work on copy-construction of SdrPage and hierarchy, quite some stuff removed, no copy-constructor anymore, no MigrateItemPool stuff. Builds well, test stuck, will need some cleanup/finetunung SOSAW080: Smaller corrections/includes adapted SOSAW080: Smaller corrections/includes adapted SOSAW080: Debugging/Stabilizing/MakeUnitTestWork SOSAW080: Stabilized for UnitTests, cleanups SOSAW080: Adapted GetObjGraphic to just take a const SdrObject& SOSAW080: Removed ChangeModel from classes Classes SvxTextEditSource and SvxDrawPage (including TextEditSource stuff) do not need change of SdrModel anymore. SOSAW080: Adapted some comments to make more readable SOSAW080: Corrected constructor SOSAW080: getSdrModelFromUnoModel added override marks SOSAW080: Added missing includes SOSAW080: Corrected SdrPage constructor SOSAW080: Corrected some SdrObject::Clone scenarios Especially when cloning to another SdrModel and taking the sdr::properties into account. SOSAW080: Added include for Mac-Build SOSAW080: Added Scale to DefaultProperties If a SdrModel change happens in DefaultProperties copy constructor (used from Clone()), potentially a Scale for the SfxItems has to be done. SOSAW080: Added missing include for MacBuild SOSAW080: Corrected CppunitTest_sc_anchor_test An adaption of a SdrPathObj instantiation was missing, added that. Seems as if that test is no tpart of the usual 'make' scenario, but used/executed in gerrit builds SOSAW080: Reworked SvxShape to use SdrObject's SdrModel SOSAW080: Reworked SvxShape to use SdrObject's SdrModel SOSAW080: Free SdrObjects when SdrModel goes down In an UNO API test problem is that SvxShapes reference SdrShapes, but these are not added to a SdrPage and not 'owned' by the SvxShape. Thus these do not get deleted at all (same in master, memory leak). I extended SvxShape::Notify the case for ModelCleared to also Free the SdrObject when not owner and it's not added to a SdrPage (in that case it gets deleted with deleting the SdrModel) SOSAW080: Solve UNO API calls that move SvxShapes to other Model Due to UNO API tests I got a call to insert an xShape to a xDrawPage which was constructed in another Model, this has now to be done by Cloning the SdrObject to the new SdrModel, getting rid of the old one and getting all the UNO implementation stuff right (referemces SdrObject <-> xShape). Change-Id: Iaf53535de0502a481466be74a1768bbb39f0e78c 1cb7d573d323e98a89761fe662c10c4a654fdec0 24617494a0ef79f6e33dfcb02782a833a81c6434 763f39094b6a48b529a6952d01468f8776c97679 242b9e228a9a042c3a5bdd38b1ea6600144276d5 242b9e228a9a042c3a5bdd38b1ea6600144276d5 33a6f3f306b70c223171aef796dd5ee041ad14df 6878b33f8b05738a44c0910e40a60a0f0d1d58ed 0a636caf3cb36c2f9c6cd11aa22cb9bc435dc8f2 8c4626274a5cc531dad27f27c0c45d4c528fb2fb 446685a49a6d67aedd01cfbbd5e87b07f97a4d7b c1b5ed3c99bc7219a0061e4ece24ea42afd2889a 22de9a1c8af7c25be5c108671ddc548ba323ed47 4caf6b6fbbe6e8130741d793dffb560fd01d4ed5 488b9601735ec1822433f82f633990063951fe08 c366d60299f239e3df856ddffedb19e743e4be0c c5137ba8c597c7b5f90318df50e87b93a39a28dc f9e646242cf89f6fde1315046952252a2c429779 f830fbc5fadd89d04be5edd2a5abf9b0d4bf0410 1694b54903df784385abaa8452e1201e12344238 17bcb44d2e29920c0c74430c2d9c703b36cfa0ad 17bcb44d2e29920c0c74430c2d9c703b36cfa0ad 7b5c241faec7488924e5935ae8b19f785846b5e4 bf097ee7467895823fbd158a2a9543da3b5a5078
2018-04-03new loplugin:dbgunhandledexceptionNoel Grandin2-4/+4
enforce that DBG_UNHANDLED_EXCEPTION is called first in a catch block, otherwise it cannot do it's job properly Change-Id: I906436c6861212c44f8f21552ccbceb54f15c6e1 Reviewed-on: https://gerrit.libreoffice.org/52303 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-03pass area param to DBG_UNHANDLED_EXCEPTIONNoel Grandin10-34/+29
and update sallogareas plugin to enforce this Change-Id: Id0782c8a1f619372e10d931aec3c6a4743a4c86a Reviewed-on: https://gerrit.libreoffice.org/52249 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-02give DBG_UNHANDLED_EXCEPTION_WHEN an area parameterNoel Grandin2-18/+18
and rename it to DBG_UNHANDLED_EXCEPTION, to make it more like the SAL_WARN-type macros. Use some macro magic to deal with different numbers of arguments. Update the sallogareas plugin to check the area parameter of DBG_UNHANDLED_EXCEPTION. Change-Id: Ie790223244c3484f41acb3679c043fb9b438e7c4 Reviewed-on: https://gerrit.libreoffice.org/52073 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-01remove unused processfactory.hxx includesJochen Nitschke6-6/+0
and fix fallout Change-Id: Id06bf31f2075111e426ba40c84c885ae70697bee Reviewed-on: https://gerrit.libreoffice.org/52206 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Jochen Nitschke <j.nitschke+logerrit@ok.de>
2018-03-29loplugin:unusedmethodsNoel Grandin4-16/+0
Change-Id: I7805ac9bc6f8c0aa5ba4804777e7d7c2c29a78f3 Reviewed-on: https://gerrit.libreoffice.org/52066 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-03-28loplugin:virtualdown in xmloff/xmlsecurityNoel Grandin7-13/+5
Change-Id: I884fe180be98fe29ddb7d2daf4c61f733236e8bd Reviewed-on: https://gerrit.libreoffice.org/51987 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-03-28tdf#115005: New option to prevent adding fallback imagesSerge Krot2-1/+6
A new option AddReplacementImages was added to prevent addition of fallback images that could increase the file size of the package in several times. Added unit test. Change-Id: I50eebba51072d3c93bfe6bed59e9f007568810c0 Reviewed-on: https://gerrit.libreoffice.org/51939 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-03-26forcepoint #35 handle odd number of dimension fragmentsCaolán McNamara1-1/+1
Change-Id: I97e4e1b38d80276077b3427c90ae33023afb5e59 Reviewed-on: https://gerrit.libreoffice.org/51899 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-03-25xmloff: export ruby-position in a more compatible way.Mark Hung2-10/+5
Export both style:ruby-position and loext:ruby-position. The later one only allows "above" and "below", obeying ODF standard while the former one allows "inter-character", which is added lately. Also use ODFVER_012_EXT_COMPAT so that loext:ruby-position isn't exported only in extended mode. Change-Id: I7b9208f289f8253a835b2f7751549206361274e0 Reviewed-on: https://gerrit.libreoffice.org/51007 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mark Hung <marklh9@gmail.com>
2018-03-20tdf#115005 Do not remove original vector images from slidesSerge Krot1-0/+4
During calculation of the quality index of the image, we should take into account also SVM vector image type. Its mime type is image/x-vclgraphic. Change-Id: I7c723e99995f73258bb59d976a6c7670c51f7a25 Reviewed-on: https://gerrit.libreoffice.org/51599 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-03-20tdf#83877 ODF: Load signature linesSamuel Mehrbrodt5-0/+93
Change-Id: I6a92246161be34bc6ecea8f1c04229a5dd593deb Reviewed-on: https://gerrit.libreoffice.org/51535 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-03-20Signatureline ODF export: Use tokens instead of plain stringsSamuel Mehrbrodt3-10/+24
Change-Id: I80eca35b03be2a7f288705295a355f08fbc757be Reviewed-on: https://gerrit.libreoffice.org/51542 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-03-19Improve error message on token inconsistencySamuel Mehrbrodt1-1/+2
Change-Id: Ib8f4d0d008b495139defb162b1b5105e5e271c67 Reviewed-on: https://gerrit.libreoffice.org/51536 Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-03-19Write signatureline element after imagesSamuel Mehrbrodt1-2/+2
The importer expects an image to exist when parsing the signatureline element Change-Id: I30c0ffad294229e0d2b09b5d7c31a692e714a3d5 Reviewed-on: https://gerrit.libreoffice.org/51534 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-03-15Fix typosAndrea Gelmini2-3/+3
Change-Id: Icb2d5f8bb9eb781d6a59384e1aac75abf6145774 Reviewed-on: https://gerrit.libreoffice.org/51337 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins <ci@libreoffice.org>
2018-03-14loplugin:constantparamNoel Grandin1-3/+2
Change-Id: I3ce653c0d9e517229dbbe32cc8d3ec3c206e364d Reviewed-on: https://gerrit.libreoffice.org/51273 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-03-14Moving XSAXDocumentBuilder2 to use XFastDocumentHandler:Mohammed Abdul Azeem10-174/+262
This is used in parsing of meta Contexts across different modules. This also involved moving to XFastParser for parsing xml filters in sw, sd, starmath. Change-Id: Ic663aaac6cb20ee8ce5b97cae87c93220f5a2929 Reviewed-on: https://gerrit.libreoffice.org/42989 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Jenkins <ci@libreoffice.org>
2018-03-14xmloff: ODF import: improve meta:generator checksMichael Stahl3-9/+148
Instead of a hard-coded check for (effectively) one project name "LibreOffice" (which is build-time configurable), check for the string "LibreOffice_project", which has been produced hard-coded ever since LO 3.3.0. This now recognises additional downstreams "LibreOffice_Vanilla" and "Collabora_Office", and also historic "BrOffice". An important point here is that the build-time configurable version numbers of any downstream that retains the hard-coded "LibreOffice_project" *MUST* be the same as the upstream's at least in their major and minor versions (micro and further digits are currently not used), and that such downstreams don't backport changes with ODF export compatibility impact further than upstream. Add a unit test too, with a representative sample of 4372 distinct generators in bugzilla attachments. This revealed that StarOffice 6 and AOO 4.0.1 were falling through the cracks and not recognised, so fix that too. Change-Id: I8105222d3428e7b20cc4a6b8e76732c697812594 Reviewed-on: https://gerrit.libreoffice.org/51171 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>