summaryrefslogtreecommitdiff
path: root/sw/source/filter/ww8/wrtw8esh.cxx
AgeCommit message (Collapse)Author
2017-04-25tools: svstream.hxx needs only errcode.hxx & not errinf.hxxChris Sherlock
Change-Id: Ia28e35ae5af4f601e9a586a3deffbcd61702b0ca Reviewed-on: https://gerrit.libreoffice.org/36896 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2017-04-19SwBreakIt::m_xBreak is always availableCaolán McNamara
this all is a hold over from the initial tentitive changeover to using it in the first place Change-Id: I70e28023798d8ea637c61f9fac252bc698e8100d Reviewed-on: https://gerrit.libreoffice.org/36683 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-04-12enum spelling: throught -> throughJustin Luth
git grep -l "[ _\.]THROUGHT" | xargs sed -i 's/THROUGHT/THROUGH/g' git grep -l -i "[ _\.]THROUGHT" | xargs sed -i 's/throught/through/g' In ENUMs: THROUGHT = THROUGH (preserved as valid alternate spelling) In ooxmlexport8 - unit test confirms THROUGH = THROUGHT Change-Id: Iae0fef9a8adcb96761989f38903a24ffb1b91e77 Reviewed-on: https://gerrit.libreoffice.org/35998 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-04-05loplugin:constantparam part2Noel Grandin
Change-Id: I7ec4c946be52a6b56aee908426f95ecacc7b0746 Reviewed-on: https://gerrit.libreoffice.org/36072 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-03-31tdf#82580 tools: rename Rectangle to tools::RectangleMiklos Vajna
Mostly generated using make check COMPILER_EXTERNAL_TOOL=1 CCACHE_PREFIX=clang-rename-wrapper RENAME_ARGS="-qualified-name=Rectangle -new-name=tools::Rectangle" Except some modules have their own foo::tools namespace, so there have to use ::tools::Rectangle. This commit just moves the class from the global namespace, it does not update pre/postwin.h yet. Change-Id: I42b2de3c6f769fcf28cfe086f98eb31e42a305f2 Reviewed-on: https://gerrit.libreoffice.org/35923 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2017-03-20convert RndStdIds to scoped enumNoel Grandin
Change-Id: I029ad67dfcbc40f3953adf485957efcbd97f23d0 Reviewed-on: https://gerrit.libreoffice.org/35328 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-03-17convert SvxBorderStyle to scoped enumNoel Grandin
and rename to SvxBorderLineStyle Change-Id: I19e530f162e4ca6290a0ad076e7fe3d5775ae6bc Reviewed-on: https://gerrit.libreoffice.org/35265 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-03-15convert SvxFrameDirection to scoped enumNoel Grandin
Based on the casts in chart2/source/view/main/ChartView.cxx and the similarity of naming of values, I conclude that this enum was intended to abstract over css::text::WritingMode2. Added a comment to that effect. Change-Id: I3af8bbe8b6ac8c4a9375f6ccde145b98b9c69a57 Reviewed-on: https://gerrit.libreoffice.org/35164 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-03-15convert MirrorGraph to scoped enumNoel Grandin
Change-Id: I2eae815a10e23a7904e1aa54577a959cb8579172 Reviewed-on: https://gerrit.libreoffice.org/35179 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-03-13convert GraphicDrawMode to scoped enumNoel Grandin
Change-Id: I18eec89c4e1ebb86d64297e7cef4b36bf12df59f Reviewed-on: https://gerrit.libreoffice.org/35004 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-03-08convert SvxShadowLocation to scoped enumNoel Grandin
Change-Id: Ie51995579312328538263172cd3173641df89bca Reviewed-on: https://gerrit.libreoffice.org/34965 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-03-03convert SfxEnumItem to type-safe template classNoel Grandin
and drop the SvxChartTextOrientItem class, unused. Change-Id: I99100837d1beb953450f57b2cda47d165df1620c Reviewed-on: https://gerrit.libreoffice.org/34747 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-03-02Fix typosAndrea Gelmini
Change-Id: Ib725427225fe95fb39a72f96bbd60d5464c9351a Reviewed-on: https://gerrit.libreoffice.org/34782 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2017-03-02elide the SwSurround enumNoel Grandin
no point in redeclaring an existing enum exactly Change-Id: I4fb367e4b27e36601f1f36b629097a87b5f00096 Reviewed-on: https://gerrit.libreoffice.org/34773 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-02-02convert method names in tools::SvRef to be more like our other..Noel Grandin
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>
2017-02-01loplugin:useuniqueptr extend to check local varsNoel Grandin
just the simple and obvious case for now, of a local var being allocated and deleted inside a single local block, and the delete happening at the end of the block Change-Id: I3a7a094da543debdcd2374737c2ecff91d644625 Reviewed-on: https://gerrit.libreoffice.org/33749 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-12-16crashtesting: 10 squillion .doc export assertsCaolán McNamara
since... commit 880e622d2e324a85a7b2b6ddc60e06cc423195b4 Author: Bjoern Michaelsen <bjoern.michaelsen@canonical.com> Date: Sun Dec 11 14:30:44 2016 +0100 refactor out lcl_GetWW8Pos IIUC the old code only changes the X/Y if its not NO_CONV for that direction, so lets reintroduce that and then drop the assert Change-Id: Ia5b0e668fff83466dc2ab59aa163cb9a87984b0e
2016-12-15decloak some string literalsJochen Nitschke
and remove explicit OUString ctor calls, now criticised by [loplugin:stringconstant] Change-Id: I778df2f410108e1386431a0035101444ec44c951 Reviewed-on: https://gerrit.libreoffice.org/32014 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-12-12reintroduce CONV2CHAR/CONV2LINE splitBjoern Michaelsen
Change-Id: I02a3a46d2222b8bfe955eb17ca655d36d9155b48 Reviewed-on: https://gerrit.libreoffice.org/31867 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2016-12-12refactor out lcl_SetRelationOrientBjoern Michaelsen
Change-Id: I9759a0f21641b6f5ba5e456e5c45ac28238ca672 Reviewed-on: https://gerrit.libreoffice.org/31866 Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com> Tested-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2016-12-12add relative to tablecell as stateBjoern Michaelsen
Change-Id: I76e9d317dabeefcdf53468a89f3a6130279993f3 Reviewed-on: https://gerrit.libreoffice.org/31865 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2016-12-12use message passingBjoern Michaelsen
Change-Id: I49c448c454f9bb820c3b9afa3825c58cb2dab978 Reviewed-on: https://gerrit.libreoffice.org/31863 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2016-12-12move enums up so core specific functionality can followBjoern Michaelsen
Change-Id: Iad8b5ff731c9d53f0f015a95387a00993a4a31f8 Reviewed-on: https://gerrit.libreoffice.org/31862 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2016-12-05convert FSysStyle to o3tl::typed_flagsNoel Grandin
Change-Id: I58a63a0e6f619442f21827064644ecd8ca57b8ff
2016-12-05convert DecodeMechanism to scoped enumNoel Grandin
Change-Id: I5c56634b1bca8e37fa73d02d2428645301b6c547
2016-12-05convert INetURLObject::EncodeMechanism to scoped enumNoel Grandin
Change-Id: I50ea17c7779c7b5cacddf548f1773fd7d6c8bade
2016-11-30convert WRITEFIELD constants to o3tl::typed_flagsNoel Grandin
Change-Id: I6412faee844e19195d57415874022bcf8547f4d7 Reviewed-on: https://gerrit.libreoffice.org/31360 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-11-29convert ND constants to o3tl::typed_flagsNoel Grandin
Change-Id: I5fe3df5515017ec24db1184e8aca823714fcfdb3 Reviewed-on: https://gerrit.libreoffice.org/31343 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-11-23tdf#42949 Remove unnecessary headers from sw/source/filtersBartosz Kosiorek
Change-Id: I5f4d3fed6e8fd484ba5da835e2954f3c2042f33b Reviewed-on: https://gerrit.libreoffice.org/31087 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-11-21convert inventorId to scoped enumNoel Grandin
SW_DRAWLAYER had the same value as SC_DRAWLAYER, so I merged it into the ScOrSwDraw enum constant Change-Id: I5c45d378c00364d11cc960c9e48a6e3f10928724 Reviewed-on: https://gerrit.libreoffice.org/31037 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-11-07tdf#41542 MSWordExport: accommodate image's borderless paddingJustin Luth
Honor the padding value even if the border is not visible. Previously the padding information was just thrown out, and the image scaled to fill the entire image size. The unit test for tdf#77454 needed to be tweaked because surprisingly it has border padding of 1 - which this patch turns into a negative crop. Change-Id: I866d26e00f27221239d3291404f70fb57ac0896d Reviewed-on: https://gerrit.libreoffice.org/30578 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Justin Luth <justin_luth@sil.org>
2016-10-31MS formats allow padding without borders, regardless of display.Justin Luth
AllowPaddingWithoutBorders is about display / UI settings. Whether LO displays them or not, the border distance should be saved for proper round-tripping, so no need to test for compat setting (and which is always true anyway in this code segment). related to tdf#41542 and commit 52b29c60801cf75364fd8275a22e812797cb184d Change-Id: I3822d9ea50376b50b89dff37b7394286cab76fff Reviewed-on: https://gerrit.libreoffice.org/30426 Reviewed-by: Justin Luth <justin_luth@sil.org> Tested-by: Justin Luth <justin_luth@sil.org>
2016-10-31fix logic error - still set zero padding if no border setJustin Luth
caused by commit 52b29c60801cf75364fd8275a22e812797cb184d originally, if there were no visible lines (bFirstLine), then any line distance was reset to zero, but with AllowPaddingWithoutBorders that should not be done. However, the case were there is no boxItem at all was missed - padding should still be initialized to zero in that case. Change-Id: I0a95ee1de6781089196a1ba40d2c0365d15926e2 Reviewed-on: https://gerrit.libreoffice.org/30412 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Justin Luth <justin_luth@sil.org>
2016-10-29tdf#41542 rename variable to match LO5.4 terminologyJustin Luth
Changing /Allow_*Spacing_*Without_*Borders/I to AllowPaddingWithoutBorders related to tdf#103275 where "spacing to contents" is to be changed to Padding. Rename this already in LO53 to simplify potential backports and laying other groundwork for fixing this bug. Also, I can easily see setting AllowPaddingWithoutBorders globally in 5.3 for the purpose of being able to share documents when the UI in LO5.4 permits creation of padding without borders. Otherwise older versions will display significantly different formatting. Change-Id: I253173274f824a019ebc09a039c471d170c1be73 Reviewed-on: https://gerrit.libreoffice.org/30372 Reviewed-by: Justin Luth <justin_luth@sil.org> Tested-by: Justin Luth <justin_luth@sil.org>
2016-10-20loplugin:expandablemethodds in sw(part3)Noel Grandin
Change-Id: I7db01985a35407e4169709ede5324656c6629047 Reviewed-on: https://gerrit.libreoffice.org/30095 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-10-05convert MapUnit to scoped enumNoel Grandin
I left a prefix on the names "Map" so that I would not have to re-arrange each name too much, since I can't start identifiers with digits like "100thMM" And remove RSC_EXTRAMAPUNIT, which doesn't seem to be doing anything anymore. Change-Id: I5187824aa87e30caf5357b51b5384b5ab919d224 Reviewed-on: https://gerrit.libreoffice.org/29096 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-10-03sw: prefix members of WW8FibMiklos Vajna
Change-Id: I69f8b6dda03b9a8cc19fc1dbe5e8031cfb7329d2 Reviewed-on: https://gerrit.libreoffice.org/29470 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2016-09-02tdf#76349 SpacingWithoutBorders: enable .doc RTJustin Luth
Microsoft allows spacing in textboxes even if the borders are not shown, but LO does not. Added a compatible setting, used an existing setting to allow the spacing, and changed .doc export not to zero out the spacing if the border was zero-width. Using the compatible setting in the export code is almost redundant, but it does require that the document was LOADED as .doc, and not "save as" from another format. This patch simply allows round-tripping - any user attempt to modify the border settings will enforce normal LO border rules. Change-Id: I60ac036e1bfac381eea15e33c21495ad3800277a Reviewed-on: https://gerrit.libreoffice.org/28601 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Justin Luth <justin_luth@sil.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2016-08-29Convert SwFrameFormats to boost::multi_indexJan-Marek Glogowski
This is almost the same situation as SwPageDescs. What makes this more complicated is the fact, that actually duplicated draw objects are allowed, in regard to the key values "type" and "name". And actually for some types, duplicate names are not allowed, e.g. SwDoc::FindFlyByName( const OUString& rName, sal_Int8 nNdTyp ) expects a single result! Change-Id: I6e0ea1099c1c1e6cfe90926170e27179722e88b8
2016-08-17convert SvxBreak to scoped enumNoel Grandin
Change-Id: If8b79ed617e5662550bd73bd1506d047217f2313
2016-07-07loplugin:passstuffbyref also for {css::uno,rtl}::ReferenceStephan Bergmann
Change-Id: I7e7cdfa5efaf18bb47d40947d4e1d91a2c9b5a57
2016-06-10Clean up uses of Any::getValue() in swStephan Bergmann
Change-Id: Ifaa239ab3e285e8cf998339456ece5ce99008af9
2016-06-08tdf#96099 Remove various smart pointer typedefsMark Page
Change-Id: I76843139e43ca1c158a977e24d210d5af93e4d0f Reviewed-on: https://gerrit.libreoffice.org/26014 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-06-06tools: rename SvStream::Read/Write to ReadBytes/WriteBytesMichael Stahl
Change-Id: Ib788a30d413436aa03f813aa2fddcbc4d6cd2f9a Reviewed-on: https://gerrit.libreoffice.org/25972 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2016-05-12clang-tidy modernize-loop-convert in swNoel Grandin
Change-Id: I1f4a0ad6658bd3154c48940296aa8edc1ea1612c Reviewed-on: https://gerrit.libreoffice.org/24876 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-10Replace fallthrough comments with new SAL_FALLTHROUGH macroStephan Bergmann
...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. Change-Id: I342a7610a107db7d7a344ea9cbddfd9714d7e9ca
2016-04-21new plugin stylepoliceNoel Grandin
check for local variables which follow our member field naming convention, which is highly confusing Change-Id: Idacedf7145d09843e96a584237b385f7662eea10
2016-04-18clang-tidy performance-unnecessary-copy-initializationNoel Grandin
probably not much performance benefit, but it sure is good at identifying leftover intermediate variables from previous refactorings. Change-Id: I3ce16fe496ac2733c1cb0a35f74c0fc9193cc657 Reviewed-on: https://gerrit.libreoffice.org/24026 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-12cleanup: remove unused com/sun/star/uno includesJochen Nitschke
Sequence.h(xx), Any.h(xx) and Type.h(xx) and remove unused using-declarations from these files. Add a few missing includes provided by them. Change-Id: I6b91b6d1fdf9d0496dd546c0aab9bdcc6831a5d4 Reviewed-on: https://gerrit.libreoffice.org/23805 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-01tdf#97966 Drop 'static' keywordsWastack
Including no keywords from extern "C" blocks Change-Id: Ie3160af9decf04ceeda02dc20a6518afaa80f972 Reviewed-on: https://gerrit.libreoffice.org/23677 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>