summaryrefslogtreecommitdiff
path: root/svx
AgeCommit message (Collapse)AuthorFilesLines
2018-10-21tdf#120703 (PVS): redundant nullptr checkMike Kaganski1-1/+1
V668 There is no sense in testing the 'pDest' pointer against null, as the memory was allocated using the 'new' operator. The exception will be generated in the case of memory allocation error. Change-Id: I17773f92ed73359e925ad779d171ec99727f7905 Reviewed-on: https://gerrit.libreoffice.org/62133 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2018-10-21cppcheck: variableScopeMark Dobo1-2/+1
Change-Id: I6826f1352cff7632dc93cc0067dfe4315dc43823 Reviewed-on: https://gerrit.libreoffice.org/62078 Tested-by: Jenkins Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2018-10-20ensure m_aMutex ctor called before m_aMutex usedCaolán McNamara1-2/+2
Change-Id: I3d05831947b955b63f351180193bcf1585589c25 Reviewed-on: https://gerrit.libreoffice.org/62012 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-20return by unique_ptr from CreateFieldControlNoel Grandin3-12/+12
Change-Id: Ic8bf9829c3320aca452fd1a40e9843fdbdbfa219 Reviewed-on: https://gerrit.libreoffice.org/61906 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-20use equal_range instead of lower_bound+upper_boundNoel Grandin1-3/+2
Change-Id: I7cc1c95b3a55630e3571cac5fe22be6c2f3a1bc9 Reviewed-on: https://gerrit.libreoffice.org/62015 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-20when calling std::lower_boundNoel Grandin1-1/+1
it's not enough to compare != end(), you also need to compare the key against the iterator result Change-Id: Ide5f151ba2297a35e5546f47fbc3c53cbe5ab533 Reviewed-on: https://gerrit.libreoffice.org/62014 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-19copy and paste errorCaolán McNamara1-1/+1
Change-Id: Idfb9772912b52fa6cd33546953def4f65ac75e52 Reviewed-on: https://gerrit.libreoffice.org/61983 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-19copy and paste errorCaolán McNamara2-1/+2
Change-Id: I54a1453b561306dd98cd2193f1a21b80b8b7e1d4 Reviewed-on: https://gerrit.libreoffice.org/61973 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-19clang-tidy readability-container-size-emptyNoel Grandin13-18/+18
Change-Id: I1df70b7dff5ebb6048f7fc618789faa15ca5d422 Reviewed-on: https://gerrit.libreoffice.org/61967 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-19clang-tidy readability-misleading-indentationNoel Grandin1-1/+1
Change-Id: I4673fc7c694924b41d048a1918ddb8b0e0af1f79 Reviewed-on: https://gerrit.libreoffice.org/61935 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-19clang-tidy modernize-redundant-void-argNoel Grandin1-1/+1
Change-Id: Ia25ac2e40f29e5b766a4c5c013fb53274196f656 Reviewed-on: https://gerrit.libreoffice.org/61934 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-18convert SdrLayer::nType to boolNoel Grandin1-4/+4
since it is being used as a bool. Also rename it to something more readable Change-Id: I89acc47251770c94fa321b742b0fb9327024055f Reviewed-on: https://gerrit.libreoffice.org/61909 Reviewed-by: Regina Henschel <rb.henschel@t-online.de> Tested-by: Jenkins
2018-10-18clang-tidy readability-simplify-boolean-exprNoel Grandin3-15/+4
Change-Id: I78fa01a6c803dec782488490b730af3a11814d64 Reviewed-on: https://gerrit.libreoffice.org/61902 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-17loplugin:unusedmethodsNoel Grandin1-46/+0
Change-Id: I73de303f93b3557881dbb84d6d11d89f193da010 Reviewed-on: https://gerrit.libreoffice.org/61868 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-17weld BrokenRecoveryDialogCaolán McNamara3-118/+125
Change-Id: I6bcc067eba0648f0f4c000d1fbb811d9235c8707 Reviewed-on: https://gerrit.libreoffice.org/61870 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-17clang-tidy readability-redundant-smartptr-getNoel Grandin13-109/+101
redundant get() call on smart pointer Change-Id: Icb5a03bbc15e79a30d3d135a507d22914d15c2bd Reviewed-on: https://gerrit.libreoffice.org/61837 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-16Related: tdf#120612 help response missing from other help buttonsCaolán McNamara2-0/+4
Change-Id: I982b4190f5af2715f797ecd9bf798e4b4af0ecda Reviewed-on: https://gerrit.libreoffice.org/61828 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-16loplugin:singlevalfields in vclNoel Grandin4-8/+4
Change-Id: I159f94fba64acc0e0599b64be02c7864b1ed02c3 Reviewed-on: https://gerrit.libreoffice.org/61813 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-15loplugin:staticconstfield improvementsNoel Grandin4-17/+16
And fix ScXMLCachedRowAttrAccess::Cache which was never setting its mnTab field, and hence would never be hit. And fix oox::xls::CellBlockBuffer, which was never setting mnCurrRow. Change-Id: I2c46aa050b9ebe3c2dc2e52579555f97945dd61c Reviewed-on: https://gerrit.libreoffice.org/61772 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-15loplugin:constantparamNoel Grandin2-3/+3
Change-Id: I895ceffa468d84d22e4a81b7a6b06eaed0bd839d Reviewed-on: https://gerrit.libreoffice.org/61776 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-15loplugin:unusedmethodsNoel Grandin1-5/+0
Change-Id: I0226d33cbe224519cf2ed9ea5143ffe68fdbc884 Reviewed-on: https://gerrit.libreoffice.org/61775 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-15tdf#120429 - Functions Insert Columns Exist Two Timesheiko tietze1-2/+2
Legacy UNO commands InsertRows and InsertCols hidden from customization Commands are still accessible via macro Also fixed terminology in Draw/Impress for Insert Columns from Left/Right to Before/After Change-Id: I29a6b2fdb7481db43ad1a8ad25be5e9107558bd6 Reviewed-on: https://gerrit.libreoffice.org/61579 Tested-by: Jenkins Reviewed-by: Heiko Tietze <tietze.heiko@gmail.com>
2018-10-15tdf#42949 Fix IWYU warnings in include/basegfx/*Gabor Kelemen5-0/+5
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Ifd59a5d93cfe7dc232891a681002014cd825035a Reviewed-on: https://gerrit.libreoffice.org/61546 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-10-15add SvStream::TellEndNoel Grandin5-17/+8
and simplify callsites to use it instead of the current "seek to end, find pos, seek back to original pos" pattern Change-Id: Ib5828868f73c341891efc759af8bd4695ae2f33c Reviewed-on: https://gerrit.libreoffice.org/61738 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-15use range based loops over B2DPolyPolygon in svxJochen Nitschke8-36/+25
avoid copy when adapting polygon in SdrPathObj::ImpForceKind() Change-Id: Ifd830ecd181563102ee269c6a609ef8ebeab670c Reviewed-on: https://gerrit.libreoffice.org/61767 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-15tdf#120593: properly handle tab pos identical to right indentMike Kaganski1-1/+9
... otherwise it's counted without taking into account current column, as well as TabsRelativeToIndent mode. Change-Id: I7442f63d9d5c51c5a4d82094b49b8028f2b42b41 Reviewed-on: https://gerrit.libreoffice.org/61768 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2018-10-14MoreButton is solely used by toolkitCaolán McNamara1-1/+0
Change-Id: Ieb436b49be3598e316d59a6d89cb211879d061c1 Reviewed-on: https://gerrit.libreoffice.org/61766 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-14drop unnecessary vcl/group.hxx includesCaolán McNamara2-2/+0
Change-Id: I09d86ee7e156ac71d7c1f9fd58d43751037d2629 Reviewed-on: https://gerrit.libreoffice.org/61761 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-14weld SwFrameAddPageCaolán McNamara1-48/+4
Change-Id: Ia63e22d01c6bcc08f50d3e1b12943094660c7fd0 Reviewed-on: https://gerrit.libreoffice.org/61758 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-14drop now unused orienthelperCaolán McNamara2-150/+0
Change-Id: I6a33104002ecb304a65e930320595a082049faa9 Reviewed-on: https://gerrit.libreoffice.org/61750 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-14svxlo-DialControl gone from .uis nowCaolán McNamara1-2/+0
Change-Id: I70c83a0c87b49048d0bb7c85a287f23d2c45b868 Reviewed-on: https://gerrit.libreoffice.org/61749 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-14weld SchAxisLabelTabPageCaolán McNamara1-0/+5
Change-Id: I499162c6c2327a6c0d635382defea7e0bae068cd Reviewed-on: https://gerrit.libreoffice.org/61747 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-12tdf#119739 split ConfigManager::getLocale(), getUILocale(), getWorkLocale()Eike Rathke1-1/+1
To prevent further confusion which is which, dbaccess UserInformation already got that wrong since ever. /org.openoffice.Setup/L10N/ooLocale is the UI locale. /org.openoffice.Setup/L10N/ooSetupSystemLocale is the work locale. Confusingly due to legacy when the setup program was a separate binary that picked the UI ooLocale and later set up the default (system) work locale as well. Change-Id: I9a05ad39f5fb65c54076ff5789ba7a2cc06ad23a Reviewed-on: https://gerrit.libreoffice.org/61725 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Jenkins
2018-10-12clang-tidy misc-throw-by-value-catch-by-referenceNoel Grandin1-2/+2
Change-Id: I04750771b63551fd3df522753a4ed21b8d5c42f3 Reviewed-on: https://gerrit.libreoffice.org/61680 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-12tdf#117721 draw ui: modify Optimize/Distribute RowHeightJustin Luth1-6/+18
Optimize row height: Adjust the height of the selected rows to match the height of the tallest row in the selection (fit to content), without shrinking the table. (Optimize rows is a new feature for Draw. My initial implementation was replaced by setMinimalRowHeight. This option is now the same as minimizing row height and then distributing rows evenly except that it adds the benefit of preventing the table from shrinking.) Distribute rows evenly: Adjusts the height of the selected rows to match the height of the tallest row in the selection (regardless of the content), causing the table to grow. (Previously, Distribute rows worked like Optimize now does, but the documentation indicates that it should work this way.) Change-Id: I49b9f9b5d1f9d3e8d2267ba0d49a9901585b4095 Reviewed-on: https://gerrit.libreoffice.org/61473 Tested-by: Jenkins Reviewed-by: Justin Luth <justin_luth@sil.org>
2018-10-11tdf#117721 draw ui: add .uno::SetMinimal[RowHeight|ColumnWidth]Justin Luth4-36/+88
Minimize column width: Adjusts the width of the selected columns to fit the selected content. The table can shrink if necessary, but will not grow. (Previously no way to minimize columns. Since minimizing really can mess up merged cells, enhance my new calcPreferredColumnWidth function.) Minimize row height: Adjusts the height of the selected rows to fit the content, causing the table to shrink. (The new optimize action functioned as minimize. So this change tweaks optimize so that it does not reduce the table size. A followup commit will make it distribute based on largest minimized row (still without reducing table size), and change distributed rows to work the way the document states - based on the largest row. Change-Id: I807a9cc9e9441a1215539e817b87158afe5a0604 Reviewed-on: https://gerrit.libreoffice.org/61472 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-10-10weld FmShowColsDialogCaolán McNamara1-1/+1
Change-Id: I31f3a787e6f835f576c02b5831508fa78340bf22 Reviewed-on: https://gerrit.libreoffice.org/61629 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-10Resolves: tdf#120407 support popover getting replacedCaolán McNamara1-0/+1
Change-Id: I56f51a5effccd8854361790c68fa11a2cc067aa9 Reviewed-on: https://gerrit.libreoffice.org/61623 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-10optimize adding a block of entries at one timeCaolán McNamara2-19/+38
Change-Id: I9a59154fa445cf3c44ede3ceb1d09f408d906530 Reviewed-on: https://gerrit.libreoffice.org/61618 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-10clean up column pos vs column idLionel Elie Mamane1-1/+1
everywhere GetColumnAtXPosPixel is used; see also tdf#119564 fix Change-Id: Ibab57c7305bf4dce9ea9f3df66e6214b0d1585b2 Reviewed-on: https://gerrit.libreoffice.org/61390 Tested-by: Jenkins Reviewed-by: Lionel Elie Mamane <lionel@mamane.lu>
2018-10-10tdf#119564 column id is not always the same as positionLionel Elie Mamane1-2/+2
GetColumnAtXPosPixel returns the column position (index in mvCols vector), _not_ the column id! These differ in particular when some columns are hidden. Change-Id: Ifc068bd3cc090969278f10e48d9d7d3f8a682e13 Reviewed-on: https://gerrit.libreoffice.org/60975 Tested-by: Jenkins Reviewed-by: Lionel Elie Mamane <lionel@mamane.lu>
2018-10-09filling the language list just to replace it entirelyCaolán McNamara1-19/+0
Change-Id: I1f79038f2a5cc455a50a532870c4042588c3e446 Reviewed-on: https://gerrit.libreoffice.org/61595 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-09use freeze/thawCaolán McNamara1-0/+2
Change-Id: I14f808864ec99258731e12879acffdd130ab0613 Reviewed-on: https://gerrit.libreoffice.org/61586 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-09Extend loplugin:redundantinline to catch inline functions w/o external linkageStephan Bergmann7-11/+11
...where "inline" (in its meaning of "this function can be defined in multiple translation units") thus doesn't make much sense. (As discussed in compilerplugins/clang/redundantinline.cxx, exempt such "static inline" functions in include files for now.) All the rewriting has been done automatically by the plugin, except for one instance in sw/source/ui/frmdlg/column.cxx that used to involve an #if), plus some subsequent solenv/clang-format/reformat-formatted-files. Change-Id: Ib8b996b651aeafc03bbdc8890faa05ed50517224 Reviewed-on: https://gerrit.libreoffice.org/61573 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-10-09loplugin:unusedmethodsNoel Grandin1-25/+0
Change-Id: Icd7a0f9909f36363b307b4fe7ee920183881afbb Reviewed-on: https://gerrit.libreoffice.org/61576 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-09cppcheck: redundantAssignmentRéka Csékei1-2/+1
Change-Id: I1efdffb92e09f83be7052b8a28ddbfb22f17defa Reviewed-on: https://gerrit.libreoffice.org/61581 Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2018-10-09use unique_ptr in SfxUndoManager::AddUndoActionNoel Grandin22-149/+117
Change-Id: I11483e3cece12a7373f4276972b4c899edf1ce15 Reviewed-on: https://gerrit.libreoffice.org/61566 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-09use unique_ptr in SdrUndoGroupNoel Grandin2-22/+11
Change-Id: I569c56b6114e07b2a227ad0f906c1a5188a94af4 Reviewed-on: https://gerrit.libreoffice.org/61528 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-08tdf#42949 Fix IWYU warnings in include/comphelper/[m-z]*Gabor Kelemen9-0/+9
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: I04c5ba277d5b3398c07de6ae66713d977636088d Reviewed-on: https://gerrit.libreoffice.org/61347 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-10-08loplugin:constfields in svxNoel Grandin101-386/+367
Change-Id: I643e8686e015ca85dd96221f1c93038f4fddf27b Reviewed-on: https://gerrit.libreoffice.org/61182 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>