summaryrefslogtreecommitdiff
path: root/sw
AgeCommit message (Collapse)Author
2020-01-28gtk silence warning about parentless widgetCaolán McNamara
Change-Id: I9aa4b9ba63c5a83e7e27e786e38761721977b33a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87644 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-01-28tdf#130122 Make content navigation view collapse uniformJim Raykowski
...for root node of all content types This patch makes content navigation view root collapse to it's immediate child entries. This fixes the current behavior of outline root collapse not collapsing and all other content types collapsing to root. Change-Id: If48b4c9f5f92e7a1843557eec51c516fa42f228f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87316 Tested-by: Jenkins Reviewed-by: Jim Raykowski <raykowj@gmail.com>
2020-01-28tdf#88205: Adapt uses of css::uno::Sequence to use initializer_list ctorMehmet Emin Başoğlu
Change-Id: I13e5c59aa673100655f38328b4b6515a1946fb76 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87524 Tested-by: Jenkins Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com>
2020-01-28tdf#130214: workaround invalid state resulting from error on importMike Kaganski
Obviously the real error is somewhere else, which results in tdf#126435, and produces unexpected state with missing text append context on stack. This is just a hack to avoid crash. Change-Id: I420ac3b74f5efb9688dc764ac2ad0dcc974ba0e1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87595 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Mike Kaganski <mike.kaganski@collabora.com>
2020-01-28fix unit test testCharacterBorderNoel Grandin
ever since commit ea358f5d5b04a2a8e11a73d35643cd0afc5cb63b Date: Tue Aug 13 18:04:14 2013 +0200 CharBrd 8.2: Tests for UNO API and ODF filter found by my new loplugin:unusedvariableplus Change-Id: I2508192ae2eb0c3e5051b3090d767956752124dc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87574 Tested-by: Jenkins Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-01-28SwAutoCompleteClient: SwClient no moreBjoern Michaelsen
- also: lets at least use atomic<> in debug code, when not caring about mutexes Change-Id: I0a32caea46a559607ff973a6f4b8e45f955e4015 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87564 Tested-by: Jenkins Reviewed-by: Björn Michaelsen <bjoern.michaelsen@libreoffice.org>
2020-01-28tdf#130031 Chart OOXML import: fix area chart data label positionTünde Tóth
Default data label positioning of area charts in Excel is vertically centered between the X axes and the data point. In LibreOffice the data labels positioning was above the data point. Change-Id: Icff3e2554dee7b5ee264bc6f9579a84852da6f7b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86927 Reviewed-by: László Németh <nemeth@numbertext.org> Tested-by: László Németh <nemeth@numbertext.org>
2020-01-28remove some unused local varsNoel Grandin
found by my new loplugin:unusedvariableplus Change-Id: Ic3f55f492d43a53d8850a97d44059ff127fd69a2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87573 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-01-28tdf#103964 DOCX import: ignore rotation when setting position of group shapesMiklos Vajna
Regression from commit 36ac7749523e0c6f40a77beac278bd9e7a667a9b (DOCX import: make sure rotation does not affect shape position, 2014-09-24), the motivation for tweaking the rotation when setting the position of a shape was for images. By accident, this also happened for group shapes. But the bugdoc shows it's not a good idea to read the rotation of group shapes: the group shape is just a container, it does not have rotation in itself. (The test120551 intention was probably just to verify that the position is not entirely off, so the small required change to the expected value should be OK.) Change-Id: I8e12c28e65c5f64168c3f802546fddf472fcc6eb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87551 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-01-28UItest: Check list of changes is updated accordinglyXisco Fauli
Change-Id: I8a68abc928fd2bedf3d5580a6f45bdb6993560c1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87545 Tested-by: Jenkins Reviewed-by: Xisco Faulí <xiscofauli@libreoffice.org>
2020-01-28New loplugin:unsignedcompareStephan Bergmann
"Find explicit casts from signed to unsigned integer in comparison against unsigned integer, where the cast is presumably used to avoid warnings about signed vs. unsigned comparisons, and could thus be replaced with o3tl::make_unsigned for clairty." (compilerplugins/clang/unsignedcompare.cxx) o3tl::make_unsigned requires its argument to be non-negative, and there is a chance that some original code like static_cast<sal_uInt32>(n) >= c used the explicit cast to actually force a (potentially negative) value of sal_Int32 to be interpreted as an unsigned sal_uInt32, rather than using the cast to avoid a false "signed vs. unsigned comparison" warning in a case where n is known to be non-negative. It appears that restricting this plugin to non- equality comparisons (<, >, <=, >=) and excluding equality comparisons (==, !=) is a useful heuristic to avoid such false positives. The only remainging false positive I found was 0288c8ffecff4956a52b9147d441979941e8b87f "Rephrase cast from sal_Int32 to sal_uInt32". But which of course does not mean that there were no further false positivies that I missed. So this commit may accidentally introduce some false hits of the assert in o3tl::make_unsigned. At least, it passed a full (Linux ASan+UBSan --enable-dbgutil) `make check && make screenshot`. It is by design that o3tl::make_unsigned only accepts signed integer parameter types (and is not defined as a nop for unsigned ones), to avoid unnecessary uses which would in general be suspicious. But the STATIC_ARRAY_SELECT macro in include/oox/helper/helper.hxx is used with both signed and unsigned types, so needs a little oox::detail::make_unsigned helper function for now. (The ultimate fix being to get rid of the macro in the first place.) Change-Id: Ia4adc9f44c70ad1dfd608784cac39ee922c32175 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87556 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-01-28remove some unused local varsNoel Grandin
found by my new aggressive unused var plugin. these are unused return values from function calls Change-Id: I3359c583f535828f192cb833762dfedc008d82f0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87439 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-01-27tdf#130179 sw comments on frames: limit insert UI for at-char and ...Miklos Vajna
... as-char anchor types SwWrtShell::InsertPostIt() only sets the comment anchor for those types, and we would crash without an anchor. Change-Id: I7d2f5d3d8f8e11c46db060c17587e97ecb786ad2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87542 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2020-01-27fix bug in testTdf128304Noel Grandin
Assuming the test actually meant to use these vars Comes from commit b203b9c83d0000c8465dcd92fb6b029a2f28c724 Date: Fri Dec 13 07:23:35 2019 +0800 tdf#128304 export TB_RL writing mode as eaVirt Change-Id: I0649f189019ea764e7ed554dac43932b717eed2c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87535 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-01-27tdf#95033 DOCX import: apply tblPrEx table borderLászló Németh
exceptions of table rows, fixing for example missing cell borders. Change-Id: Id66af2706f564f46a1afd04bad65d1bf086a3232 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87514 Tested-by: Jenkins Reviewed-by: László Németh <nemeth@numbertext.org>
2020-01-27tdf#129671 add tooltips to Assign Styles dialog boxSeth Chaiklin
There are two radio buttons with arrow images. The labels explain the meaning of their action. The dialog box is used in two different contexts (Table of Contents and User-Defined Indexes) so the tooltips must be generic. Change-Id: I83761d5bd5511060ca9ee28fbf18d5d9ec8d4807 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87311 Tested-by: Jenkins Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2020-01-27sw: prefix members of StgReader, SwAuthEntry, ...Miklos Vajna
... SwChartLockController_Helper and SwInterHyphInfo See tdf#94879 for motivation. Change-Id: I76b5380eefef63c2c02635ac31eca171906125b8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87486 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2020-01-27tdf#114090 Create a new paragraph style with name "Appendix"Seth Chaiklin
followed recommendation in bug report: 16pt, bold, centered - inheritance from Heading - when tdf#128858 is resolved then Appendix will inherit outline level 1 One attempt at filter modifications, but maybe there are others? Change-Id: I0f91327cfe5578cd888528b2c6fac5065951eec0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/85657 Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org> Tested-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2020-01-27tdf#124176: Use pragma once instead of include guardsSarper Akdemir
Change-Id: Ib83c5cf44537bc1c4552f97c9114357c410a6ddb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87473 Tested-by: Jenkins Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com>
2020-01-27tdf#124176: Use pragma once instead of include guardsSarper Akdemir
Change-Id: Ieeed31e81d47c01eda2edc792cb2ecf271eac58d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87472 Tested-by: Jenkins Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com>
2020-01-27tdf#130197 give paragraph and table panels column widths of 5 toolbutton widthsCaolán McNamara
Change-Id: Iae4f10eef6b293731d22eec8dcbb85a07d3e6c11 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87462 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-01-26tdf#124176: Use pragma once instead of include guardsBurak Bala
Change-Id: Ib2465f040f12413560b2cec1c742cf3558461309 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87404 Tested-by: Jenkins Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com>
2020-01-26Avoid explicit cast to smaller sal_uInt16 from larger longStephan Bergmann
...in what might be an attempt to avoid warnings about signed vs. unsigned comparisons. Change-Id: I43f3efdbd93d1bc9a51ea89ac4a728fc68205379 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87449 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-01-26Avoid explicit cast to smaller sal_uInt16 from larger longStephan Bergmann
...in what might be an attempt to avoid warnings about signed vs. unsigned comparisons. Change-Id: I19be3cc0510b8628e961d840f51b0c9480aee746 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87450 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-01-26Avoid explicit cast to smaller sal_uInt16 from larger longStephan Bergmann
...in what might be an attempt to avoid warnings about signed vs. unsigned comparisons. Change-Id: Ie3aa77f099df19fc150271b17d06194005bfeec5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87448 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-01-26Avoid explicit cast to smaller sal_uInt16 from larger intStephan Bergmann
...in what might be an attempt to avoid warnings about signed vs. unsigned comparisons. Change-Id: I21381a7df7e0902d3b6ab4de064d6470a9c4a2db Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87447 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-01-26move "remove duplicates" for a vector to o3tl/vector_utils.hxxTomaž Vajngerl
Change-Id: I9ecf95a2bf975912b7029cdfb459a9ebc159c75d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87429 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-01-26acc. check: implement goto for a range of text range in a para.Tomaž Vajngerl
Change-Id: I847bc67f886b5dcfe8ec30d7c0bdd3aa61ba2d36 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87421 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-01-26acc. check: check if text format conveys additional meaningTomaž Vajngerl
Change-Id: I8f51248e453018c33ddc64b00cdbc1708309e577 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87420 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-01-26remove some unused local varsNoel Grandin
found by a more aggressive variant of loplugin:unusedvariables. This is my first pass, committing the simplest and most obviously unnecessary vars Change-Id: I9676a6e39a101937097788548764506c93811c57 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87414 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-01-26rename some local variablesNoel Grandin
mostly to make the job of my very aggressive unused local vars plugin easier Change-Id: Ifc21a920841f8589f8b7e10de39dba6622a5d501 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87399 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-01-25Resolves: tdf#130159 hide writedirection unless CTL is enabledCaolán McNamara
rework as ToolboxControllers registered in Controller.xcu Change-Id: I3e7fea09fe83d1ed6400218c41384f82b38b07a2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87419 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-01-25Resolves: tdf#130174 explicitly call SelectHdlCaolán McNamara
Change-Id: Ibda5c3595f8e02bba9faa027f4c90762aa817b42 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87418 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-01-25tdf#130137 Replace remaining uses of WNT define checks with _WIN32A_GAN
Change-Id: If95f1ea5a81de62eb4f725e5fcb30ccb8530062a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87372 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2020-01-25Related: tdf#128942 remove the scrolledwindow frames from all the dialcontrolsCaolán McNamara
Change-Id: I445753ad1eb4d441e5a5e909ae450bda6013a6b3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87352 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-01-25Change some #define to constexprStephan Bergmann
...plus loplugin:unnecessaryparen fallout in sw/source/uibase/docvw/edtwin.cxx. Each of the files contained at least one #define that would have caused warnings with upcoming loplugin:unsignedcompare. For consistency, I changed all #defines in those files (using a variable of a specific type if the original #define used a cast to that type, otherwise using 'auto'). Change-Id: I66f71b2d83394c9dc6952ae19df774cdd4d0b76a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87374 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-01-25tdf#129423: Make export tests export-only where applicableShivam Kumar Singh
Change-Id: Iff36608e3f1d643175e47a96333df4cb80a88064 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87209 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2020-01-25tdf#130155 Writer Navigator crash fix: Check entry to expand has childrenJim Raykowski
Fixes crash/freeze when an entry without children is sent is to SwContentTree::Expand. It forwards to SvTreeListBox::Expand deal with it. Change-Id: Icd3cd1b2d0a949e01a3e02a6fa4cdc08610c8ffb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87307 Tested-by: Jenkins Reviewed-by: Jim Raykowski <raykowj@gmail.com>
2020-01-24tdf#130096 Wrap Sidebar update use common .uno commands and layoutandreas kainz
Change-Id: Ie8185169582616179fd96850283836f4e3d60ad1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87309 Tested-by: Jenkins Reviewed-by: andreas_kainz <kainz.a@gmail.com>
2020-01-24loplugin:makeshared in swNoel Grandin
Change-Id: I6b297b84edda441c4ec6ea9f89ed553a50783bf5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87356 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-01-24DOCX export: fix line spacing when spacing is 0Miklos Vajna
When the input was: <w:pPr> <w:spacing w:line="0" w:lineRule="atLeast"/> </w:pPr> Then we used to write: <w:pPr> <w:spacing w:lineRule="auto"/> </w:pPr> which is clarly wrong. The comment at the end of AttributeOutputBase::ParaLineSpacing() documents the intention reasonably clearly (and is in sync with what's in the DOC and DOCX spec), adapt DocxAttributeOutput::ParaLineSpacing_Impl() accordingly. Change-Id: I60cbc3392a6460ba2760b2c02ae0755726478ec1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87351 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2020-01-24Revert "lok: ui: more files to increase the 'step-increment'"Miklos Vajna
This reverts commit 0a64b33617299ece871a947828855b16e2482706. Let's revert this till it's clear how to fix UITest_writer_tests2 to not hang with these changes. Change-Id: I9b40b101ecdad0ccac9a0b52b6a2ef19bd47a38c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87333 Reviewed-by: Henry Castro <hcastro@collabora.com> Tested-by: Henry Castro <hcastro@collabora.com>
2020-01-23sw DoNotCaptureDrawObjsOnPage: don't capture wrap-through Writer images, eitherMiklos Vajna
This compat flag was originally added in commit 7961b14c4f9f00696b241e5ad9bf9ba18041fe22 (INTEGRATION: CWS swdrawobjpos203 (1.12.54); FILE MERGED, 2006-03-22) for compatibility with OOo 1.x. Later commit af313fc149f80adb0f1680ca20e19745ccb7fede (tdf#105143 DOCX import: enable DoNotCaptureDrawObjsOnPage layout compat option, 2017-01-06) also turned it on for DOCX documents. One overlooked difference was that the compat flag disables "capturing" of draw objects only, but not wrap-through Writer images. The DOCX case wants the same for wrap-through Writer images as well, since Word does no capturing in either case. Fix the problem by disabling capturing for wrap-through Writer images as well; if this turns out to be too problematic, we can have a dedicated compat flag just for OOo 1.x documents, but that comes at some cost as well. (Need to write the new compat flag to each & every new ODT.) TextBoxes are handled separately (see testTDF91260 in CppunitTest_sw_ooxmlexport8), so leave their handling unchanged. Change-Id: I74f434ed7518d7784c7cba085deb6ff8baf1770a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87289 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2020-01-23tdf#128782: Add UItestXisco Fauli
Change-Id: I389d05fa9b1e79af2c01abd920fb4454b96543fb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87282 Tested-by: Jenkins Reviewed-by: Xisco Faulí <xiscofauli@libreoffice.org>
2020-01-23lok: ui: more files to increase the 'step-increment'Henry Castro
property to 5. In mobile view, touch spin button should increment by 5 Change-Id: Ib3c8966443d053ab0588fa0c124f0daae31b7ed8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86844 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Henry Castro <hcastro@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86854 Tested-by: Henry Castro <hcastro@collabora.com>
2020-01-23weld SvxFontWorkDialogCaolán McNamara
Change-Id: If9da7ad6a834d22f1bcab8d41ce7fe1f80168946 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/84774 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-01-23sw_redlinehide: fix SwScriptInfo hidden textMichael Stahl
A missing update of nOffset in SwScriptInfo::InitScriptInfo(); it must be updated for every extent but it's not for the last one in a node. test case: ab cd Delete "bc", hide "d", but "a" disappears. (regression from 0e26d48ad7f18deac8447a306215f79d5c62be27) Change-Id: I99fb88409e184a61866f908722b4430a53914153 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87201 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de>
2020-01-23no need for repetitive GetShell()->GetWin() callsCaolán McNamara
Change-Id: I2c0a136db685e67b5981a0162619521d7f2070cb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87216 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-01-23tdf#42949 Fix IWYU warnings in sw/source/ui/[c-u]*/*cxxGabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Icf4e6f8ea7c751c8d068dbde50ea1b4726d565d5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87004 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-01-22flush out unused MapModesCaolán McNamara
Change-Id: I691143162bf9a26171f3ede3bded34c7fb985244 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87207 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>