summaryrefslogtreecommitdiff
path: root/hwpfilter
AgeCommit message (Collapse)AuthorFilesLines
2016-07-20Replace fallthrough comments with new SAL_FALLTHROUGH macroStephan Bergmann1-2/+2
...which (in LIBO_INTERNAL_ONLY) for Clang expands to [[clang::fallthrough]] in preparation of enabling -Wimplicit-fallthrough. (This is only relevant for C++11, as neither C nor old C++ has a way to annotate intended fallthroughs.) Could use BOOST_FALLTHROUGH instead of introducing our own SAL_FALLTHROUGH, but that would require adding back in dependencies on boost_headers to many libraries where we carefully removed any remaining Boost dependencies only recently. (At least make SAL_FALLTHROUGH strictly LIBO_INTERNAL_ONLY, so its future evolution will not have any impact on the stable URE interface.) C++17 will have a proper [[fallthroug]], eventually removing the need for a macro altogether. (cherry picked from commit 14cd5182c5f64c43581c82db8c958369152226ac) Change-Id: I342a7610a107db7d7a344ea9cbddfd9714d7e9ca
2016-07-20Fix typosAndrea Gelmini1-12/+12
Reviewed-on: https://gerrit.libreoffice.org/21209 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> (cherry picked from commit 64d624b65124ac02d8ee59b135593fd9d8eb9067) Change-Id: I9a5940027423ff0791fa7da0b79b617412ce6b86
2016-07-20loplugin:nullptr: More NULL -> nullptr automatic rewriteStephan Bergmann1-6/+6
Change-Id: Ie83819e2bcdc5fa160b39296b005ca9a5ff74b1d (cherry picked from commit fb8a3fac5d448451794804a7470be45fa14da453)
2016-07-12Remove excess newlinesChris Sherlock6-11/+0
A ridiculously fast way of doing this is: for i in $(pcregrep -l -M -r --include='.*[hc]xx$' \ --exclude-dir=workdir --exclude-dir=instdir '^ {3,}' .) do perl -0777 -i -pe 's/^ {3,}/ /gm' $i done Reviewed-on: https://gerrit.libreoffice.org/22224 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> (cherry picked from commit a238b1f8d304bf1e2ffb357937f3ec888ee8ac89) Change-Id: Iebb93eccbee9e4fc5c4380474ba595858a27ac2c
2016-07-12update unusedmethods plugin to deal with constructorsNoel Grandin1-1/+0
and fix the operator< implementations in some of the other plugins too. Reviewed-on: https://gerrit.libreoffice.org/25057 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com> (cherry picked from commit 2c8fe2e737b84ecd3dbac36a4fe6bd061bbd3bae) Change-Id: Ie5631e0cdc8d2a994ad2af2533cdb558a6cfc035
2016-07-12update loplugin stylepolice to check local pointers varsNoel Grandin1-52/+52
are actually pointer vars. Also convert from regex to normal code, so we can enable this plugin all the time. Reviewed-on: https://gerrit.libreoffice.org/24391 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com> (cherry picked from commit e8fd5a07eca70912ddee45aaa34d434809b59fb7) Change-Id: Ie36a25ecba61c18f99c77c77646d6459a443cbd1
2015-11-24'#pragma setlocale("C")' is probably no longer necessaryStephan Bergmann2-10/+0
...as in both files the direct use of non-ASCII characters in ordinary string literals has since been changed to use \xXX escapes instead Change-Id: Ic3e17a9849288a02dc69d7702782fefccb7026ee Reviewed-on: https://gerrit.libreoffice.org/20148 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>
2015-11-24Translate Korean commentsStephan Bergmann1-3/+3
...via translate.google.com, to make file plain ASCII Change-Id: Icbf25074bd92eb1f0fb453f9887b1f1f1ca82b57
2015-11-24Remove non-ASCII U+0086 PARAGRAPH SIGN from commentStephan Bergmann1-1/+1
Change-Id: Ifcbb2a61c662f135badc01b7beaef10fa3d75515
2015-11-24Replace non-ASCII content in ordinary string literals with UTF-8 bytesStephan Bergmann1-4/+25
Change-Id: Ib92221527550beb35e2263b150a509b3ef68545f
2015-11-24cppcheck: noExplicitConstructorCaolán McNamara6-10/+10
Change-Id: I1934441858baeeb41a46f694dbcef2d846b308b7
2015-11-18use unique_ptr for pImpl in extensions,hwpfilter/Noel Grandin2-12/+6
Change-Id: I476ba7ec2ebee8c61bf9bb6ff0309cc40affb275
2015-11-17Don't assume sal_Unicode is unsigned shortStephan Bergmann2-59/+59
Change-Id: I72b0f9956e866afd22f7335a57d7dca0297e3b8a
2015-11-15Fast PCH generator and optimized PCH filesAshod Nakashian1-14/+43
Ported update_pch.sh to Python with improved performance and features. The new script is invoked from the same update_pch.sh which calls it for each library in parallel, although it can be invoked directly. The ported script (update_pch) updates all PCH files in ~15 seconds where the old script took ~4500 seconds. In addition, the new script supports 3-tiered headers (system, module, and local) and is very flexible to support other improvement. It has a per-library optimal configuration settings that can be updated using another new scripts (update_pch_autotune.sh) which finds optimal per-PCH settings. PCH files have been generated using the new scripts which builds significantly faster (2-3x, depending on module and configuration) and the intermediate binaries are noticably smaller (by several GBs). The new script stamps each generated PCH file with the command that generated it to make it trivial for users to update them, and also adds the command to invoke another script (update_pch_bisect) that helps find missing headers or conflicting headers that may break the build after updating the PCH. Finally update_pch has built-in unit-tests for makefile parsing and other core functionality. Change-Id: Ib933b50e50374d7e2e7e3e95ba8799b0cc8a27fa Reviewed-on: https://gerrit.libreoffice.org/19965 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2015-11-15use initialiser syntax for Sequence<OUString>Noel Grandin1-2/+1
replaced using the script: git grep -lP 'Sequence.*OUString.*\(1\)' | xargs perl -0777 -pi -e "s/Sequence< OUString > (\w+)\(1\); .*\[0\] = (\S+);/Sequence< OUString > \1 { \2 };/g" Change-Id: I23688a91562051a8eed11fc2a85599545c285c34 Reviewed-on: https://gerrit.libreoffice.org/19967 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-11-11new loplugin: memoryvarNoel Grandin1-15/+8
detect when we can convert a new/delete sequence on a local variable to use std::unique_ptr Change-Id: Iecae4e4197eccdfacfce2eed39aa4a69e4a660bc Reviewed-on: https://gerrit.libreoffice.org/19884 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-11-10loplugin:nullptr (automatic rewrite)Stephan Bergmann21-418/+418
Change-Id: Idec97093ca48c14b825c7b87ec050cc99aadc526
2015-11-04yyyyyNoel Grandin2-19/+19
Change-Id: I9a947beefd2dfe21da8239e841ea3fb416bd1548
2015-11-01no need to be so verbose in constructing uno::ReferenceNoel Grandin1-4/+3
Change-Id: I187a26e200e9ecaff2adaf53a2ba3f6e87346030 Reviewed-on: https://gerrit.libreoffice.org/19724 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-11-01no need to use OUString constructor in call to createInstanceNoel Grandin1-4/+2
Change-Id: Iaf3d83ba1490cb1d97a5bd4d1f7cd6943d4a7296 Reviewed-on: https://gerrit.libreoffice.org/19704 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-10-19com::sun::star->css in hwpfilter/Noel Grandin2-9/+9
Change-Id: I2ec12da777d04855d34233d5781f2304e181bbbd
2015-10-12Replace "SAL_OVERRIDE" with "override" in LIBO_INTERNAL_ONLY codeStephan Bergmann5-69/+69
Change-Id: I2ea407acd763ef2d7dae2d3b8f32525523ac8274
2015-10-07Reduce variable scopeStephan Bergmann1-2/+1
Change-Id: I5d2d7e7991c3727ed6367fe22ebddd5c2e2e9265
2015-10-07clang-analyzer-deadcode.DeadStoresStephan Bergmann1-2/+1
The code had been like this ever since 16cba77220efab8204eeecb49ccd3ec033efca38 "#112673# initial checkin of HWP filter." Assuming that the second line should rather read angle = 1800 - angle * 10; instead of angle = 1800 - prop->angle * 10; does not look too plausible: It would keep mapping -1 -> 181 0 -> 180 1 -> 179 : 179 -> 1 but then would discontinuously map 180 -> 180 181 -> 179 : instead of continuously mapping 180 -> 0 181 -> -1 : Change-Id: I8cf97eeb53409b18bda6777b09a20331f3c8132a
2015-10-01loplugin:unusedmethodsNoel Grandin4-165/+0
- improvements to the plugin to find more method calls - improvements to python script to remove more false+ - fix the FORCE_COMPILE_ALL build flag to include code in the $WORKDIR Change-Id: I4d6015dcb9b9d60c26f0bcee8abad807177a7836 Reviewed-on: https://gerrit.libreoffice.org/19064 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-09-30Fix typosAndrea Gelmini4-4/+4
Change-Id: Iab78219aff60a7a45a319a96f326e27a6e8e25b8 Reviewed-on: https://gerrit.libreoffice.org/18953 Reviewed-by: Oliver Specht <oliver.specht@cib.de> Tested-by: Oliver Specht <oliver.specht@cib.de>
2015-09-29loplugin:removeunusedmethods, remove unused stuffNoel Grandin1-35/+0
Change-Id: I35456b2a3ad2a84a1d045f09cdfb29e4c19b8350
2015-09-18boost->stdCaolán McNamara1-2/+2
Change-Id: Ie490bf2c6921f393bdeed96b1a8815996b701bf0 Reviewed-on: https://gerrit.libreoffice.org/18670 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2015-09-14boost->stdCaolán McNamara2-6/+3
Change-Id: I3fd9e1599c5ad812879a58cf1dabbcd393105e1c Reviewed-on: https://gerrit.libreoffice.org/18564 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2015-09-03clang-tidy clang-analyzer-deadcode.DeadStoresStephan Bergmann1-1/+1
...ever since its inception in 16cba77220efab8204eeecb49ccd3ec033efca38 "#112673# initial checkin of HWP filter" (but curr is needed as a local scratch pad in the STARTT macro) Change-Id: I7233bf99b7d6f9ac0d3d3384ba4508f84ba8fa38
2015-08-22tdf#39440 reduce scope of local variablesMichael Weghorn2-4/+3
This addresses some cppcheck warnings. Change-Id: I6ab170c4426494ab9fc53017f88e47fbfdbd9aad Reviewed-on: https://gerrit.libreoffice.org/17920 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2015-08-21add hwp to fftesterCaolán McNamara2-0/+22
Change-Id: Ibf819307905295580cb6a813f6d003a7dabc86b5
2015-08-18hwpfilter: tdf#88206 replace cppu::WeakImplHelper*Takeshi Abe3-8/+6
with the variadic variants. Change-Id: Ibfe59dc7631cf499f42ff998066ed73d1eb257b3 Reviewed-on: https://gerrit.libreoffice.org/17767 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2015-08-05loplugin:unusedmethodsNoel Grandin1-11/+0
Change-Id: I6801618efb5a66d24156fa429e026acb6ca03aba Reviewed-on: https://gerrit.libreoffice.org/17506 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-07-30loplugin:unusedmethodsNoel Grandin1-8/+0
Change-Id: Ib4d77ee01e7362f5951f81fceeca3c489872d971 Reviewed-on: https://gerrit.libreoffice.org/17378 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-07-17formatting of public/private/protected section qualifiersNoel Grandin1-1/+1
make it consistent across the codebase, no space between keyword and the colon Change-Id: Idca61ddfc74ad2460fb05fe417499324b05e5de5 Reviewed-on: https://gerrit.libreoffice.org/17148 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2015-07-16tdf#91067: Translate Korean commentsJihui Choi13-309/+308
Change-Id: Idbee9cb5a1745bb2cc3c4cb1238773da7ff2a0a3 Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net>
2015-07-06loplugin:unusedmethods hwpfilter,i18npoolNoel Grandin7-44/+0
Change-Id: Ied85d93019d0f6c01c14045758b405f2ac316676 Reviewed-on: https://gerrit.libreoffice.org/16783 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2015-07-03Fix typosAndrea Gelmini2-2/+2
Change-Id: Ie2bbe020fc6e3a4a4f913208c245f395849bb9ee Reviewed-on: https://gerrit.libreoffice.org/16708 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2015-06-15remove unnecessary check for null when calling deleteNoel Grandin1-2/+1
Idea originally from caolan. Found using the following command: find . -name *.cxx | xargs /opt/local/bin/grep -zlP '(?m)if\s*\(\s*\w+\s*\)\s*delete\s+\w+\;' Change-Id: I3338f4e22193a6dfd6219c8c75835224a3392763
2015-06-08loplugin:cstylecast: deal with remaining pointer castsStephan Bergmann5-12/+12
Change-Id: I8a8ba86dd78e30146f7b9dd7071f5641d496a67a
2015-06-02loplugin:cstylecast: deal with those that are (technically) const_castStephan Bergmann1-1/+1
Change-Id: Ia48650597a4854cbb92ef203b3c1338b4f47becc
2015-05-11loplugin:cstylecast: nop between pointer types of exactly same spellingStephan Bergmann1-2/+2
Change-Id: I10dfaab18f39df8766718370d0bee6c9e41d1a42
2015-05-04cppcheck: memleakOnReallocCaolán McNamara2-18/+9
Change-Id: Ibdf762b0d397f798372d9bf882aa82a6e5fd0229
2015-05-04hstream.h->hstream.hxxCaolán McNamara6-5/+5
Change-Id: Icc4a3d3661c3d40f9e71215bdc875c6a25f40ac1
2015-04-29sequence operator twaddle + silly castCaolán McNamara1-1/+2
Change-Id: I8804bfb39d8306762cbe39ac4b6df9128a8e0069
2015-04-29redundant castCaolán McNamara1-4/+4
Change-Id: Ib812a7cafabc4820946da67fb3f8896b6aad1461
2015-04-27More loplugin:simplifyboolStephan Bergmann3-6/+6
Change-Id: I64ec8a0525b935d12455f7ed236ffd367f47c070
2015-04-24loplugin:simplifyboolStephan Bergmann3-9/+9
Change-Id: Ic42cf05f9eddb0cd7724d16cc73a8d6495c193f2
2015-04-23cppcheck: silence assertWithSideEffectCaolán McNamara1-1/+1
Change-Id: Iaaf69ea5e8d5eeaa3a61660c3abe04ff3e83d061