summaryrefslogtreecommitdiff
path: root/xmloff
AgeCommit message (Collapse)Author
2017-02-02fix linux buildNoel Grandin
after commit 1461ebb "expand out ::sax::Converter::convertNumber to OUString::number" Change-Id: I9bf0d36f9623491a8f760e88029b5d9a04369eba
2017-02-02expand out ::sax::Converter::convertNumber to OUString::numberNoel Grandin
which results in much simpler code overall, there is no need to go via an OUStringBuffer all the time Change-Id: I69eba92c93f471fa9a45f97c29c56dcf3cd1ebf8 Reviewed-on: https://gerrit.libreoffice.org/33773 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-02-01loplugin:stringconstant handle calls to constructors with one argNoel Grandin
Change-Id: Ide9148a908bef46ba14640dfa6f556beaf6e3f60 Reviewed-on: https://gerrit.libreoffice.org/33772 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-01-31teach lolugin:stringconstant about calling constructorsNoel Grandin
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>
2017-01-30GetWasUsed can return by value, no need to be a special snowflakeNoel Grandin
Change-Id: I4ef22fa49ee883ff0bddb49d1711e8521905502f Reviewed-on: https://gerrit.libreoffice.org/33658 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-01-28coverity#1399595 Uninitialized scalar fieldCaolán McNamara
Change-Id: I6e6a1e114ee9abf8826dda19e0b7bc3b573e2edf
2017-01-28Resolves: coverity#1399594 Unchecked dynamic_castCaolán McNamara
Change-Id: I6aae2d451db218a53931df1982a5412923dd42c1
2017-01-28loplugin:stringconstant check for unnecessary OUString constructor..Noel Grandin
..calls when creating exceptions Change-Id: I3bc58a5aa4dc6f0508ecb88b3a843b96b8c7ebfe Reviewed-on: https://gerrit.libreoffice.org/33617 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-01-27loplugin: unnecessary destructor writerfilter..xmloffNoel Grandin
Change-Id: I511822dc874101ed3b9850b015b746a86d26c3b5 Reviewed-on: https://gerrit.libreoffice.org/33578 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-01-26Remove dynamic exception specificationsStephan Bergmann
...(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>
2017-01-25ScXMLTableRowCellContext implements fast interfaces:Mohammed Abdul Azeem
Implementation of fast interfaces for contexts in path from ScXMLImport::CreateFastContext to ScXMLTableRowCellContext. FastParser is enabled and duplicates are avoided at all possible places. OOoXML filters still need those legacy paths we removed, so I had to temporarily map them to fast elements, which would increase their load time, but hopefully it should help us in the long run. Change-Id: Ie997a9a8b72787da2356abc99ea2cd57c2e5b670 Reviewed-on: https://gerrit.libreoffice.org/28648 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2017-01-23just for non exported thingsCaolán McNamara
Change-Id: I448d0009d7c8ffec64fdab76897e8684afe7fcd7
2017-01-23ditch some empty dtors which match the default dtorCaolán McNamara
Change-Id: Id2450b03e6c8c5461e92d995ea8c33d5dfd55a45
2017-01-20can use truncate instead of a new OUStringBufferCaolán McNamara
Change-Id: I6efd48af1e00c21675ef0697b38185008a794d7a
2017-01-19New loplugin:dynexcspec: Add @throws documentation, xmloffStephan Bergmann
Change-Id: Idf9db7108514e91fb4fe3abeca55fbab844c770a
2017-01-19new loplugin: useuniqueptr: unotools..xmlscriptNoel Grandin
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>
2017-01-17use rtl::Reference in SvXMLExportNoel Grandin
instead of storing both a raw pointer and an uno::Reference Change-Id: I83774937d3556b9fed550a7f3e757dc975b4098a
2017-01-11Some loplugin:conststringvar/stringconstant improvements: xmloffStephan Bergmann
Change-Id: I05e03936d9e5518fa7ba4d9c72d5b8e241e32526
2017-01-10New loplugin:conststringvar: xmloffStephan Bergmann
Change-Id: I337de74f48fa973a937bde3e4eb97e255c2f915f
2017-01-09use (new) -mlong-jump-table-offsets on m68k for libxoRene Engelhard
Change-Id: I6e2886e2de4f3502c74f1e367216066352994865
2017-01-09New loplugin:externvar: xmloffStephan Bergmann
Change-Id: I3fe731a535fe67b4cf260f9c6a36e32732695a7c
2017-01-07coverity#705098 Explicit null dereferencedCaolán McNamara
Change-Id: Icf32bbe9ce259048219ba88aa7e4dc51592f7cb5
2017-01-07coverity#705097 Explicit null dereferencedCaolán McNamara
Change-Id: I0c2163f91b86d2b48b7bc58b173438d2aa11377d
2017-01-06writerperfect, xmloff: fix loplugin:cppunitassertequals warningsMiklos Vajna
Change-Id: Ie8246433a7cea0886f00d8c76cf6f7d023545417 Reviewed-on: https://gerrit.libreoffice.org/32770 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2016-12-17More blind fix attempt for MSVCStephan Bergmann
Change-Id: I023d79c0d8928d8b43df67996ca4eb9dc6bfb25e
2016-12-17More blind fix attempt for MSVCStephan Bergmann
"warning C4822: 'XMLEmbeddedObjectImportContext::{ctor}::Entry::Entry' : local class member function does not have a body" Change-Id: Ieeb11aaf3f204532a77ce80d47e0e6996697003c
2016-12-17More blind fix attempt for MSVCStephan Bergmann
Change-Id: Ic1c8fe2994d8094581b7c22a50edb6267122b8ea
2016-12-17Blind fix for MSVCStephan Bergmann
"warning C4510: 'XMLEmbeddedObjectImportContext::{ctor}::<unnamed-tag>' : default constructor could not be generated" Change-Id: I3c81bf4c0fd20795e20f5c0f2e790bf4118c0e2d
2016-12-17Minor simplificationStephan Bergmann
(the explicit OUStringLiteral ctors in aServiceMap are needed at least by GCC 4.8 used by <http://ci.libreoffice.org/job/lo_gerrit/Config=linux_gcc_release_64/>) Change-Id: I16721317ef4fd47ca6f2905a9387a77fbf54086a Reviewed-on: https://gerrit.libreoffice.org/32100 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>
2016-12-17Adapt to no-longer explicit OUStringLiteral ctorStephan Bergmann
...from previous commit Change-Id: I062b7cd212c17e7eb5274476e6859228d0477c7f Reviewed-on: https://gerrit.libreoffice.org/32098 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>
2016-12-15teach sallogareas plugin to catch inconsistenciesNoel Grandin
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>
2016-12-14remove local macroJochen Nitschke
don't store string length, construct string with createFromAscii and inline SERVICE_MAP_ENTRY macro Change-Id: Ib25da99f3ad24f58179a0231a42b29e177967bfc Reviewed-on: https://gerrit.libreoffice.org/32006 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-12-13tdf#95416 Fix includes for xmloffAdam Kasztenny
Move a header file into inc/ Change-Id: If337720fbd5af43fc7ec32518058a1c7d43b8d18 Reviewed-on: https://gerrit.libreoffice.org/31879 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2016-12-12coverity#1397053 Logically dead code (golden)Caolán McNamara
and coverity#1397055 Inferred misuse of enum copy and paste error from the other converted call site I bet Change-Id: I63701db153c5fd424374a95dd757d9fd7a8bc216
2016-12-12coverity#704109 Unchecked return valueCaolán McNamara
and coverity#1397040 Unchecked return value coverity#1397047 Unchecked return value coverity#1397049 Unchecked return value coverity#1397050 Unchecked return value coverity#1397051 Unchecked return value Change-Id: Idf7dd7818b74c661a1f7a757f0bdc16e2d1d5c72
2016-12-12coverity#704108 Unchecked return valueCaolán McNamara
Change-Id: I5bd58f94fbea3d59849f60f2096e5191dbb0d810
2016-12-09xmloff: XMLChangeImportContext: replace boolean pair with proper enumMichael Stahl
Change-Id: I82ec75058a2309b8bcf0f8e78d8ef0db367014b0
2016-12-09xmloff: convert some DBG_ASSERT in txtparae.cxxMichael Stahl
Change-Id: I7b53726e3bb16ff1d9a6cdb05ce4cf4273eb5ac4
2016-12-05convert DecodeMechanism to scoped enumNoel Grandin
Change-Id: I5c56634b1bca8e37fa73d02d2428645301b6c547
2016-12-02Remove dup line in aGroupShapeElemTokenMap (xmloff)Julien Nabet
Change-Id: Iac0194046a9a2aae25f7976df6f845f6f909425f Reviewed-on: https://gerrit.libreoffice.org/31507 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-12-02inline some constant strings in xmloff (part1)Noel Grandin
Change-Id: I7971f210ffb30bdd80a1adde2c286b4d092bd053 Reviewed-on: https://gerrit.libreoffice.org/31433 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-12-01crashtesting: a gadzillion failures on export to odpCaolán McNamara
e.g. fdo35235-1.odp Change-Id: I259cdc9ed073be2ad7d5208cd943d4f193f09c16
2016-12-01loplugin:unnecessaryoverride (dtors) in xmloffStephan Bergmann
Change-Id: I351ff5955d766118e3a6b2234181774af0d1f522
2016-11-29tdf#102479 ODF export: ignore exceptions when checking shape textMichael Stahl
The bugdoc contains a SwXShape-SwXTextFrame aggregate which contains only a table, no top-level paragraph. Because of that, SwXTextFrame::createTextCursor() throws a RuntimeException. Assuming that the exception itself is intentional, work around it in XMLShapeExport::collectShapeAutoStyles() and assume that the getString() check that was added there in commit 73fcb052edf1a21d785583bc53e8b4323b577bb1 is just a performance optimization; the actual export of auto styles and content uses XEnumerationAccess anyway. Change-Id: I7c23164b1e692ce16e5b4e03dd945e46768677de Reviewed-on: https://gerrit.libreoffice.org/31218 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2016-11-25add exception context to error log messageEike Rathke
Change-Id: Iae8a0c8e7ed4c8bec6497f1636a943bd6f79d5c8
2016-11-25replace useless OSL_FAIL with DBG_UNHANDLED_EXCEPTION_WHENEike Rathke
Change-Id: I7eebb09d1725eff4793330362e5bfba84a237195
2016-11-25replace meaningless OSL_FAIL with DBG_UNHANDLED_EXCEPTION_WHENEike Rathke
Change-Id: I8aceb106339d879455bd96b2f84b54306f13d062
2016-11-23loplugin field-can-be-private in include/vcl..xmlscriptNoel Grandin
Change-Id: Ia03f7cccb256d825daa4dc6f4c0598448e46e6cf Reviewed-on: https://gerrit.libreoffice.org/31069 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-11-18includes should be at the top of the fileNoel Grandin
not randomly scattered through the code found with something like: git ls-files *.cpp | xargs grep -Pzl "(?s){.*#include" Change-Id: I9c242fa4ef99e8677f2800d7ec9f16d16e488351 Reviewed-on: https://gerrit.libreoffice.org/30952 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-11-17ODF: do not write an empty style:text-position="" attribute for CharEscapementEike Rathke
... and CharEscapementHeight if the Any is void. This was a real error complained about in the officeotron validation https://bugs.documentfoundation.org/attachment.cgi?id=128411 https://bugs.documentfoundation.org/show_bug.cgi?id=103493 Also showed up as console warning warn:legacy.osl:3269:1:xmloff/source/core/xmlerror.cxx:178: An error or a warning has occurred during XML import/export! Error-Id: 0x20040003 Flags: 2 ERROR Class: 4 API Number: 3 Parameters: 0: CharEscapement Exception-Message: UNKNOWN_PROPERTY Position: Public Identifier: System Identifier: file:///.../103493-LotroPlan%203.8.ods Row, Column: 2,1850164 Change-Id: Ifc634cc6b3d5d6dfa43741005ef0c9a1f7ff71fe