summaryrefslogtreecommitdiff
path: root/xmloff
AgeCommit message (Collapse)Author
2017-02-28new loplugin unoanyNoel Grandin
Change-Id: I5d6c4a67cb2a09e7cd5bd620c6b262d188701b89 Reviewed-on: https://gerrit.libreoffice.org/34714 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-02-26loplugin:loopvartoosmallStephan Bergmann
Change-Id: If080ee083a7531cc744ac35fc4ebd24d037003dc
2017-02-21loplugin:unusedmethodsNoel Grandin
Change-Id: I52a9f16f3ed543a3c83ca111df70e3f7ae1ef33c Reviewed-on: https://gerrit.libreoffice.org/34508 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-02-21loplugin:subtlezeroinit: xmloffStephan Bergmann
Change-Id: I1308f4ad4584ac7c657ab9fc2b747c4e3715337d
2017-02-21Use symbolic AUTOLAYOUT_* namesTor Lillqvist
Change-Id: I76a23c99bf92f33ebea1e138ccb3e948dee5ab84
2017-02-21AutoLayout value 33 is "AUTOLAYOUT_4CLIPART" according to commentsTor Lillqvist
Change-Id: I082dd08c1caf6f1585e3e16b441ba3b5a0d137f1
2017-02-21s/AUTOLAYOUT_6CLIPART/AUTOLAYOUT_TITLE_6CONTENT/, and sortTor Lillqvist
Need to sort in this commit so that the AUTOLAYOUT_END keeps being one more than the highest-valued enumerator. Change-Id: I0db7c8ba069808e92589d5c4688632440007163b
2017-02-20s/AUTOLAYOUT_TITLE_VERTICAL_OUTLINE_CLIPART/AUTOLAYOUT_TITLE_2VTEXTTor Lillqvist
Change-Id: Ie20c4539b8b66b1e9b40015e6bc611d5bc12ddb4
2017-02-20s/AUTOLAYOUT_TITLE_VERTICAL_OUTLINE/AUTOLAYOUT_TITLE_VCONTENTTor Lillqvist
Change-Id: I6186a2583dff2b142ceee1c4f2c7f0c972ec6c57
2017-02-20s/AUTOLAYOUT_VERTICAL_TITLE_VERTICAL_OUTLINE/AUTOLAYOUT_VTITLE_VCONTENTTor Lillqvist
Change-Id: Ic423c5a84c887222e38ab411ed218987075f7ced
2017-02-20s/(AUTOLAYOUT)_VERTICAL_TITLE_TEXT_CHART/\1_VTITLE_VCONTENT_OVER_VCONTENTTor Lillqvist
Change-Id: I996d4a0b01ce9cb78119cba3165b2716f09fd048
2017-02-20s/AUTOLAYOUT_4OBJ/AUTOLAYOUT_TITLE_4CONTENTTor Lillqvist
Change-Id: I8acd349ec7d9424f817981719320f51ac58b9861
2017-02-20s/AUTOLAYOUT_OBJOVERTEXT/AUTOLAYOUT_TITLE_CONTENT_OVER_CONTENTTor Lillqvist
Change-Id: Idf9771d3d58520a1a31cea45a6acca89347237f6
2017-02-20s/AUTOLAYOUT_2OBJOVERTEXT/AUTOLAYOUT_TITLE_2CONTENT_OVER_CONTENTTor Lillqvist
Change-Id: I9f421104773c8c84828cb0908f0f5e182538eead
2017-02-20s/AUTOLAYOUT_2OBJTEXT/AUTOLAYOUT_TITLE_2CONTENT_CONTENTTor Lillqvist
Change-Id: I8ed1361b2103b35e277107bfda4c174f07d9de08
2017-02-20s/AUTOLAYOUT_TEXT2OBJ/AUTOLAYOUT_TITLE_CONTENT_2CONTENTTor Lillqvist
Change-Id: I514cf647863e51848ff51c26938e682ffeca7685
2017-02-20Use AUTOLAYOUT_TITLE_ONLY instead of "deprecated" AUTOLAYOUT_ONLY_TITLETor Lillqvist
Change-Id: Ib3c2b5f0feb70fea195f022f322c682ecd4f1918
2017-02-20Use AUTOLAYOUT_TITLE_2CONTENT instead of "deprecated" AUTOLAYOUT_2TEXTTor Lillqvist
Change-Id: I8897e31065f69b7fb62f0770e62025f35ecb5eec
2017-02-20Probably better to set xEntry->nKey = XML_NAMESPACE_UNKNOWN hereStephan Bergmann
...to match the local var nKey, than to rely on xEntry->nKey being initialized to zero (which doesn't even match XML_NAMESPACE_UNKNOWN = USHRT_MAX) by new NameSpaceEntry() Change-Id: I415418b7a1446172a5dfb910df0ce747ebc0da04
2017-02-16Move AutoLayout enum definition to its own file, and start de-duplicating itTor Lillqvist
The mysteriously named AUTOLAYOUT_ENUM had the same value as AUTOLAYOUT_TITLE_CONTENT, and was marked as "deprecated", so just use the latter instead. Use it also in xmloff instead of the magic number 1 in places where comments indicated that AUTOLAYOYT_ENUM was what the 1 meant. Will continue with the other "deprecated" and duplicated enumerators later. (Or you feel free.) Change-Id: Id5d70e07d30b3bf0d62e5d8719edb784bd23f99d
2017-02-15Some simplifications, using UNO_QUERY_THROWStephan Bergmann
Change-Id: Ie82c1f243717eb42218040a9b4d59f8cf10de387 Reviewed-on: https://gerrit.libreoffice.org/34251 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-02-12Various typos about propertyJulien Nabet
Change-Id: I7585a1346fb19a886240db8dd393554efee862cc Reviewed-on: https://gerrit.libreoffice.org/34174 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2017-02-10Further modifications to FastAttributeIter:Mohammed Abdul Azeem
attempt to further reduce unnecessary allocation and freeing of OUString. Change-Id: I85169cfcd2311a5e6a96dc0292ce0686d1b0e43d Reviewed-on: https://gerrit.libreoffice.org/34092 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Jenkins <ci@libreoffice.org>
2017-02-09xmloff: remove onDemandRescueUsefulDataFromTemporaryMichael Stahl
This workaround, which is both complex and quite incomplete, should no longer be necessary because the fixes for tdf#103567 should also fix i#124143, see unit test in previous commit. Change-Id: I038f238d5e3cf5cadfc666196380b7b351543982
2017-02-09tdf#103567 xmloff: ODF import: fix more lossage on Writer framesMichael Stahl
There's another context that reads draw:frame, and it has the same problem as the one used for Impress shapes. This causes SVG images in Writer to lose contour polygons and image maps. Fix this the same way as the other context. (likely regression from 44cfc7cb6533d827fd2d6e586d92c61d7d7f7a70) Change-Id: I16cf55e68829b4e1b0841f2015d0729be0ce3725
2017-02-09xmloff: fix this CreateChildContext to be properly ignorantMichael Stahl
Change-Id: I0b5cc271768ba29d039abb05408ccbd686c18544
2017-02-08tdf#103567 xmloff: ODF import: fix loss of events on SVG multi-imageMichael Stahl
For SVG there are 2 draw:image children in the draw:frame, and the SdXMLEventContext::EndElement() applies the content of office:event-listeners to the shape created from the last draw:image and then MultiImageImportHelper::solveMultipleImages() throws it away because it's the bitmap fallback of the SVG. Avoid that problem by calling solveMultipleImages earlier: The ODF schema ensures that all the draw:image elements occur before the optional property-bearing child elements of draw:frame, so we just call solveMultipleImages on the first such optional element, so that all subsequent properties get applied to the one surviving shape. (likely regression from 44cfc7cb6533d827fd2d6e586d92c61d7d7f7a70) Change-Id: I2be5f6f424dbfd90ca2179ce6f9057929540e762
2017-02-08-Werror,-Wunused-private-fieldStephan Bergmann
Change-Id: Ibba8f9d1823471cc548220d4de62041151898f12
2017-02-08loplugin:unusedenumconstants read-only constants in xmloffNoel Grandin
Change-Id: I88afb3b4b3aa7d823c46062ead894561a66ac275 Reviewed-on: https://gerrit.libreoffice.org/33995 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-02-06Add missing #includesStephan Bergmann
...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
2017-02-03loplugin:unusedenumconstants in xmloffNoel Grandin
Change-Id: Ie9e6d4aa9dba97d45bf7b8afa2347d34e1651a60 Reviewed-on: https://gerrit.libreoffice.org/33871 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-02-03new loplugin:unusedenumconstantsNoel Grandin
These are the simple removals, where it is obviously safe, the more complex ones will come in separate commits Change-Id: I7211945a6a5576354b60d9c709940ce9b674f308 Reviewed-on: https://gerrit.libreoffice.org/33828 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-02-02xmloff: fix loplugin:stringconstantMiklos Vajna
Change-Id: I3a1758982ae8ede32e5a25bb702b6d9f37e1a0a3
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