summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2021-07-30tdf#143580 Qt5 don't use Qt::Popup for FLOAT winsJan-Marek Glogowski
Main problem is, that Qt::Popup grabs the focus and therefore generates a focus-out event for the combobox, which then closes the just shown popup window. The grab happens inside QWidget private code and there is no way around it. But instead of "faking" Qt::Tooltip, this uses Qt::Widget with additional flags. Regression from commit 7e6fee830116823b9cd8e46d6962df4ea2bc1ea6 ("Qt5 fix Qt::Popup window handling"). Change-Id: Ia1f8e33d98f7ec36cf1ebc350886121dfaadd658 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119691 Tested-by: Jenkins Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de> (cherry picked from commit 9dcf5816c90e9819861332f11e014ef7b78e2fe7) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119621 Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2021-07-28bump product version to 7.2.1.0.0+Christian Lohmaier
Change-Id: I21fa71f47313f4edf38b2abc6e56617b519c2610
2021-07-28Revert "tdf#58521 DOCX import: enable ContinuousEndnotes compat flag"Gabor Kelemen
This reverts commit e35fc16969c0d0a55538733d76fc4bb03bf137b0. Reason for revert: tdf#143456 shows there are layout problems with this compatibility option Change-Id: I4f03b9a0cbc6de1d3dbf79681f7caa203a1ce59c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119451 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2021-07-28ODFF: eliminate spaces between function name and initial opening parenthesisEike Rathke
Same as for OOXML, they are disallowed in ODFF as well. Change-Id: Iff78a901838092a3ee32221fdaadd28ee50f7646 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119577 Tested-by: Jenkins Reviewed-by: Eike Rathke <erack@redhat.com> (cherry picked from commit 6eb9fde88af245a00247fca8a592ed08ee4b8bbe) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119449 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2021-07-28Update git submodulesStanislav Horacek
* Update dictionaries from branch 'libreoffice-7-2' to 447a883184eaa8643fd6ae9a85ca64ef1d912d35 - Czech Hunspell: add several word forms Change-Id: I227d4fe75539691c75323ffcc822545081ced9ae Reviewed-on: https://gerrit.libreoffice.org/c/dictionaries/+/119643 Tested-by: Stanislav Horáček <stanislav.horacek@gmail.com> Reviewed-by: Stanislav Horáček <stanislav.horacek@gmail.com>
2021-07-28Update git submodulesXisco Fauli
* Update dictionaries from branch 'libreoffice-7-2' to b6f494a9946de2899acf22c843ef7386d09a5cf4 - tdf#143489: Update Galician dictionaries to version 20.08 Change-Id: I95b0064894a10a47e638568f85ddf5eb97ac345e Reviewed-on: https://gerrit.libreoffice.org/c/dictionaries/+/119372 Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com> Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com> (cherry picked from commit c292071ca8f8dece2bf5655038cdfd4899a09fa3) Reviewed-on: https://gerrit.libreoffice.org/c/dictionaries/+/119614 Tested-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2021-07-28Update git submodulesChristian Lohmaier
* Update translations from branch 'libreoffice-7-2' to 325c25d7264976f4272460ae6852f2743e62bf02 - update translations for 7.2.0 rc2/master and force-fix errors using pocheck Change-Id: I7b7bd01e640b88e6e81140686a68f72592e5a25d (cherry picked from commit a2b54ae27fac12ee3aee478872632c377e1843f9)
2021-07-28tdf#139426 Supress AssertFlyPages in Tabe re-layoutArmin Le Grand (Allotropia)
The current code tries to on-demand create content in form of a SwBodyFrame at a SwPageFrame. That unexpectedly and unfortunately leads - when done during a Table re-layout action - to an endless layout loop. I tried quite some solutions, but the simplest and safest is to just supress AssertFlyPages in that specialized TableLayout. Other solutons may break MailMergse, so CppunitTest_sw_mailmerge needs to be checked with any fix in this area. For more details, see tdf#task comnments. Change-Id: I02de9ee72848061497678936aa1d0c492694bfc2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119324 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com> (cherry picked from commit 0bac5c7e7d71658c5056c4bf0b71fbfb51b92ca0) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119266 Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2021-07-28Revert "tdf#58521 Enable ContinuousEndnotes compat option for RTF too"Gabor Kelemen
This reverts commit 59c5732875c1bea619ed461a378906a2dce12b48. Reason for revert: tdf#143456 shows there are layout problems with this compatibility option Change-Id: I73cbbb73f3110bc93840b8f0de0f2fab69250ebc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119443 Reviewed-by: László Németh <nemeth@numbertext.org> Tested-by: Jenkins
2021-07-28tdf#101630 - gdrive support w/oAuth and Drive API v3Christian Lohmaier
LibreOffice is only using drive.file scope, so can only see files it owns/that were created by LibreOffice. In addition, also store the refresh token in LO's password-store if the user enabled persistent storage, removing the need to to the copy'n'paste dance to grant access each time LO is launched. related tdf#115643 also store the refresh token for onedrive consolidate the fallback-auth provides for onedrive/gdrive into one, they are all the same login in browser, then copy code method that ultimately should be changed to having LO listen on local port for the code Change-Id: I97e3843682c302d2884e35ece6e72bc3a07e2539 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119572 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> (cherry picked from commit 73041de9563c9a973d1b5394c6e5520a7d799980) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119446 Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2021-07-27tdf#143424: support for "Chapter number without separator"Vasily Melenchuk
If LO is using list format strings (this is default behavior since aa5c6d12) it was not able to show just numbering without all formatting, as it used in some fields. Change-Id: Ib4695b8e1c2d7a451522c7e04af2216d16aceefe Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119309 Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de> Tested-by: Jenkins (cherry picked from commit d44730148a95933f4a45a70241cb6d1d0546f626) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119440
2021-07-27tdf#142693 DOCX import: fix zeroing huge page sizesAttila Szűcs
which bigger than 2^15 twips (> ~57.8 cm). Regression from commit 4d1621136c464b462a598571ecdcfe2ae119d8c7 "Fix ignoring large twips values like MSO does (cp#1000087)". Note: Writer could export page size up to 600 cm × 600 cm, and now it can import it back as well. It can even import page sizes in kilometers, and display that, but there will be other issues about its display. MS Word couldn't save page size over 2^15, but can import, and display them till up to 2^16 (that is about 116 cm). Co-authored-by: Tibor Nagy (NISZ) Change-Id: Icc1bd708d53036768a7be94cb1ebe18c1c4c8487 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118940 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org> (cherry picked from commit d5d9795968771651c57c661d95b6992c3c778eca) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119441 Tested-by: Jenkins
2021-07-26sw: layout: fix red triangle problem with text frame in sectionsMichael Stahl
First, a document is loaded, then about 4 pages of content are pasted into it, in about 6 paste operations. In an idle layout action, a page's worth of content moves forward; the text frame at the bottom was split previously, and is joined. The follow has the same upper as the master text frame, so this causes the upper section frame to shrink: SwRect::operator=(const SwRect & rRect) Zeile 256 SwFrameAreaDefinition::FrameAreaWriteAccess::~FrameAreaWriteAccess() Zeile 112 SwSectionFrame::Shrink_(__int64 nDist, bool bTst) Zeile 2327 SwFrame::Shrink(__int64 nDist, bool bTst, bool bInfo) Zeile 1562 SwContentFrame::Cut() Zeile 1339 SwTextFrame::JoinFrame() Zeile 677 SwContentFrame::MakeAll(OutputDevice * __formal) Zeile 1310 The ToMaximize(false) check doesn't help because the section frame doesn't have a follow (or footnotes). Then the text frame is formatted, resulting in one line but no height for it, and a split after the one line. The split causes a follow section frame to be created, calling SwSectionFrame::SimpleFormat() on the master's upper: SwFrameAreaDefinition::FramePrintAreaWriteAccess::~FramePrintAreaWriteAccess() Zeile 120 SwFrame::SetTopBottomMargins(__int64 nTop, __int64 nBot) Zeile 175 SwRectFnSet::SetYMargins(SwFrame & rFrame, __int64 nTop, __int64 nBottom) Zeile 1405 SwSectionFrame::SimpleFormat() Zeile 1192 SwSectionFrame::SwSectionFrame(SwSectionFrame & rSect, bool bMaster) Zeile 110 SwFrame::GetNextSctLeaf(MakePageType eMakePage) Zeile 1781 SwFrame::GetLeaf(MakePageType eMakePage, bool bFwd) Zeile 879 SwFlowFrame::MoveFwd(bool bMakePage, bool bPageBreak, bool bMoveAlways) Zeile 1977 SwContentFrame::MakeAll(OutputDevice * __formal) Zeile 1349 SwFrame::PrepareMake(OutputDevice * pRenderContext) Zeile 286 SwFrame::Calc(OutputDevice * pRenderContext) Zeile 1794 SwTextFrame::CalcFollow(o3tl::strong_int<long,Tag_TextFrameIndex> nTextOfst) Zeile 281 SwTextFrame::AdjustFollow_(SwTextFormatter & rLine, o3tl::strong_int<long,Tag_TextFrameIndex> nOffset, o3tl::strong_int<long,Tag_TextFrameIndex> nEnd, const unsigned char nMode) Zeile 608 Now the upper has space but at this point the master text frame is valid and not invalidated, so it never grows into the available space. There is a check to format again in case additional space is available in SwTextFrame::CalcFollow() but peculiarly it's disabled if the upper is a section frame since initial CVS import. Removing this check appears to fix the problem. Change-Id: Ifad545f7e79675af6e33d68c7fcdbc82bd4f8f57 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119419 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de> (cherry picked from commit 44cc59db6f4f4f8b2ce5c993a31b5a019a8d7e97) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119434 Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de>
2021-07-26tdf#143510 DOCX import: fix tracked table drag & dropLászló Németh
Accept or reject of tracked drag & drop table (row) move weren't handled, resulting an extra empty table (rows) instead of removing the deleted or inserted table (rows). Note: tables moved by drag & drop with track changes use w:moveFromRangeStart/End and w:moveToRangeStart/End bookmark-like elements to sign the boundary of the moved text. Now moveFrom/moveTo import is handled by tracked table (row) deletion and insertion. Change-Id: Ie382645fef28f57b30d3504fb28ac08489f705c0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119406 Tested-by: Jenkins Reviewed-by: László Németh <nemeth@numbertext.org> (cherry picked from commit 7f3c0bbc174b9b0316991c174ca3b407c0e3d141) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119436
2021-07-25Related: tdf#135762 Suppress cout if not command lineEike Rathke
Change-Id: I9431221aadf97739bb197871f25fa151ef4c391c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119294 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Jenkins (cherry picked from commit 0cda081c9aa3b3dcb363f97bac60c845ce9a13e0) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119255 Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-07-23curl: upgrade to release 7.78.0Michael Stahl
* Fixes CVE-2020-8284 CVE-2021-22924 * Also fixes these which don't look relevant to LO: CVE-2020-8231 CVE-2020-8285 CVE-2020-8286 CVE-2021-22876 CVE-2021-22890 CVE-2021-22897 CVE-2021-22898 CVE-2021-22901 CVE-2021-22922 CVE-2021-22923 CVE-2021-22925 CVE-2021-22926 * disable some new protocols and dependencies * remove curl-ios.patch.1 as the code no longer exists upstream Change-Id: I12d5f87f4d503a5f9859226a05cfe2a07e46d993 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119313 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de> (cherry picked from commit 946f457c885bd10ff1a7281c351f3981f035f5a7) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119261 Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de>
2021-07-23sdext.pdfimport: Restore to read font file for the determination...Kevin Suo
of font attributes, as suggested by Mike Kaganski in https://gerrit.libreoffice.org/c/core/+/118977. This partially reverts da59686672fd2bc98f8cb28d5f04dc978b50ac13 but did some modification of the previous code with some explanationary comments. Change-Id: I224d9e717bf374a90f4834cbd9e11bf1138b41ff (cherry picked from commit a91d373837550fbde9c6ba8ca0f43aa8603d86f2) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119118 Tested-by: Jenkins Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2021-07-23Resolves tdf#143066 - Language set to None for indicesHeiko Tietze
Disables spell-checking on ToC Change-Id: I6601d8c54974fcc70564292176a71a80d91020e9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119222 Tested-by: Jenkins Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org> (cherry picked from commit 137a1d5380e310a43d36932c643e1331a94fd70d) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119265 Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2021-07-22tdf#143493 Qt5 key modifier events don't have textJan-Marek Glogowski
Regression from commit 862fdb98ca271b60a831cd5420fd16d5f9c1c747 ("tdf#143298 Qt5 send SalEvent::KeyModChange events"). Change-Id: I6981af06e3a73dee45ed10416f5d3b17b860a73b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119375 Tested-by: Jenkins Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de> (cherry picked from commit 22997c4777eeb424493d1259b72db9a15ff37069) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119267 Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2021-07-22tdf#143464: fix SmartTag managementJulien Nabet
by putting back missing information in lcl_FillRecognizerData Regression from e98711c14db9348f4d3f7d0f5bbde9276a3e73bc loplugin:unusedfields in sw (2018-12-12) Change-Id: I2e99df1a712915851c30c018a1f7279756da72de Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119346 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> (cherry picked from commit 717ec99667f5a9ab570f1c8581e2d7a0241c32f6) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119263 Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2021-07-22Dereferencing uninitialized pointerMike Kaganski
SfxItemSet::GetItemState returns SfxItemState::DEFAULT without resetting the passed pointer. Regression after commit dd5bf12193471f064bf7f581dd1b21783390e735. Change-Id: I1e427a05f8e5b375f50d81b51d32e78fca83eb42 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119348 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> (cherry picked from commit 0d4cbdbc9cd4ab06056cec66cffd292b41615b6e) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119259 Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2021-07-22tdf#143412 CRASH: converting imagesNoel Grandin
Revert "use unique_ptr in SdrEditView::ImpConvertOneObj" This reverts commit 2ec1dab4693cd45b475f02452114dd96ec0bda1b. I was wrong, we are no returning ownership here. Change-Id: Ib3b3b32248d4b56f0a48c658db5d6431b26fc352 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119335 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> (cherry picked from commit 58c6fad213024ef8f162984a66af565ac9ad4b97) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119260
2021-07-21tdf#142854 XLSX import: fix grid visibility in headless modeAttila Szűcs
Fix regression from commit 759103fd65f82fc131679eba0de05f2ddc7294c8 (tdf#126541 XLSX import: fix View grid lines). Sheet based grid visibility shouldn't overwrite the global grid visibility, except for headless mode (i.e. for command line batch mode, see --convert-to in ./soffice --help, otherwise we could get a regression here: The sheet based grid visibility (bShowGrid) is stored in view settings. Headless mode means not to export view setting, including sheet based grid visibility. As the old workaround, use global visibility to keep the losing sheet visibility. FIXME: headless mode only works correctly if all sheets have the same grid visibility. The sheet based bShowGrid should be moved to another location, which is supported by the headless mode, too. Note: now the modified tdf#126541 unit test checks the fix for the regression of the headless mode, and the new Python UI test checks the (now improved) fix for tdf#126541 on the desktop. Co-authored-by: Tibor Nagy (NISZ) Change-Id: I93551d22cc5d858dc64f93a46cd8aa202b4b2df5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118599 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org> Signed-off-by: Xisco Fauli <xiscofauli@libreoffice.org> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119314 Tested-by: Jenkins
2021-07-21tdf#143452: make 2 buttons in the date form control translatableJulien Nabet
Regression from: https://cgit.freedesktop.org/libreoffice/core/commit/?id=bafd50ee06d982e19d54fae0f9d8f968a2dedbd4 weld DateField Calendar floating window Change-Id: I43c108908c6e802f3a8014ccf3fa243bebcae0ac Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119293 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> (cherry picked from commit 73503ce975ce0923bfe2cfd075ac8b91de20f29e) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119257 Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2021-07-21sdremote: avoid infinite loop if client disconnects during handshakeAndrzej Hunt
The following loop can turn into an infinite loop if the client disconnects at the wrong point in time, because pSocket->readLine() returns 0 (indicating disconnection), aLine remains empty (no data was read), and we just keep looping because we never bothered to check the return value: do { pSocket->readLine( aLine ); } while ( aLine.getLength() > 0 ); Aside from spinning unnecessarily, this infinite loop also stops the server from being able to accept any new incoming connections - in effect this causes a DOS of the server. Hence we need to start checking readLine's return value, and break out of this loop - and in fact break of the surrounding outer loop too (because we discard this connection and want to wait for another connection to arrive). Because of the nested looping it's hard to come up with a clean solution that only involves changing this loop - we'd probably need to introduce a temporary to remember that the client has disconnected, and check that temporary after the do...while - letting us 'continue' the outer loop. Therefore we first extract the code that handles newly accepted clients into a separate method, which then lets us simplify the implementation by returning at those points that we know a client has disappeared. That unfortunately makes this bug-fix patch a little more noisy than expected, but it is a refactoring that we'd want to make anyway. (There are further improvement we can make here, but I'll put those in a separate commit to simplify cherry-picking of just this fix. Examples include moving to smart pointers instead of new/delete, introducing an early return instead of the really long if statement, etc.) Change-Id: I13c6efa622a1b1de10b72757ea07e5f4660749fb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119083 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> (cherry picked from commit fcc4d8e01360baa9ba0bf20eb5e7a1c9af793a02) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119184
2021-07-21Qt5 fix Qt::Popup window handlingJan-Marek Glogowski
I guess to get popup windows somehow working, they were matched to Qt::ToolTip. Fixing that by removing SalFrameStyleFlags::FLOAT from the tooltip check, resulted in rather bizarre bahviour. The Qt::Popup window is modal, as documented, but wouldn't close when clicked outside, like normal popups. And I neither got any mouse button or focus events, just some leave or enter. The only way to interact with anything again, was by clicking somewhere on the popup where it can't take focus... and it has nothing to do with the transition setting either. In the end it turned out that Qt::StrongFocus prevented the mouse events to happen. Even without it the widget accepts mouse and keyboard focus, so nothing seems lost by omitting that for the Qt::Popup case; hopefully... Change-Id: Icda7bbe87268293a400fe0da551d2804675d4c2d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119236 Tested-by: Jenkins Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de> (cherry picked from commit 63f92f185b78db5a575da58efac3f94a8cb5a5f6) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119252 Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2021-07-21tdf#143298 Qt5 send SalEvent::KeyModChange eventsJan-Marek Glogowski
I originally omitted this in the Qt implementation, as I couldn't find any non-working use case. The implementation got a bit hacky, because Qt doesn't have a non- native way to identify different L/R modifier keys, so we must process the X11/xkb keycode ourself, which obviously won't work on Wayland... but most times this is not relevant, so the default modifier notification may be good enough. P.S. it's basically the same code then X11 and Gtk... Change-Id: I37fbfde4a33a966b6017f3e0c280e2c7ea91e4db Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119235 Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de> Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de> (cherry picked from commit 862fdb98ca271b60a831cd5420fd16d5f9c1c747) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119191
2021-07-21tdf#143334 Qt5 don't reset buffer on style changeJan-Marek Glogowski
This bug was "unveiled" by commit 963f252cd1ea9c268a6ced68a3454b10cbee1a89 ("Qt5/KF5 get rid of unneeded own grahics handling"). I'm not sure why I ever came up with that code. Eventually we would need a paint event, but at least changing the theme correctly updated LO UI, so that seems to be handled correctly. Change-Id: I528b551180be184427eeeeeb2977e2b7da073ce6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119237 Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de> (cherry picked from commit ec77a2ed0283cb3446f6e352fc329afd3dfb785c) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119190
2021-07-20framework: fix multiple-free in VclToolBarManager::Destroy()Michael Stahl
Multiple ImplToolItem with mnId 1000 are inserted in the same ToolBox and the problem is that only the first one gets its mpUserData set, because setting and getting that is based on the assumption that mnId is unique per container. So in Destroy() for every item with mnId 1000 the same AddonsParams object is deleted. The problem is that in ToolBarManager::FillToolbar() the local nItemId is copied, so its value never changes when iterating the loop because only its copy is incremented. (regression from ac1aefd5174258d9bcb41465ce566ed1a0819f3d) Change-Id: Ica47051f9447c2b9d1981f8373d754874f0f31b0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119228 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de> (cherry picked from commit 7d1175c46588c246c455cd7c8874136bf61197fd) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119186 Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de>
2021-07-20tdf#46184 sc AutoFilter: reset filter options to default valuesTünde Tóth
when the old filter entries are removed in auto-filter rules, because these options are not visible from the AutoFilter. E.g. now using AutoFilter doesn't apply copying of the previous standard filtering, changing also the active sheet etc. This fixes regression from LibreOffice 3.5 or more. Change-Id: I26b272dc738f3918ff5b2ca7e8fee3481d21460a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118603 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org> Signed-off-by: Xisco Fauli <xiscofauli@libreoffice.org> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119272 Tested-by: Jenkins
2021-07-20tdf#123598 sc UI: don't show autofilter dropdown arrowsTünde Tóth
on the result area when the "Copy results to:" option is true. Change-Id: I3da4a1098d8c7c0be6604451b7485312043c5ede Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118484 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org> (cherry picked from commit 15684e5d595289e0a94efd80bbe203ca133845f2) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119188 Tested-by: Jenkins
2021-07-20tdf#143399 DOCX import: fix lost endnotes or footnotesLászló Németh
in a document containing both of them. Regression from commit 7dd8f8aace536a8e60e87e61ee1d90d61fba15eb "tdf#120351 DOCX import: fix slow endnote import". Change-Id: I0fe764f3b48dd2688afa4b7cf0ee6658737ef9fe Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119239 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org> (cherry picked from commit 732b08b22eee2682351a9295be29188852fb0489) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119187 Tested-by: Jenkins
2021-07-20tdf#123321 Fix DOC/DOCX export bug which made some lines disappearHossein
* Fix the wrong calculation of SdrPathObj (line) extent while exporting to .doc and .docx formats. This resolves tdf#123321 which cause some lines to disappear after save and reload. This fix does not break tdf#91687 * added tests to make sure this does not happen again, based on the .doc file provided in Bugzilla * Loading the bad exported file in MS Word is OK, but it does not work in LibreOffice, and some of the lines will be hidden. This needs additional work. The regression came from d72e0cadceb0b43928a9b4f18d75c9d5d30afdda Change-Id: Ic5a7af4d29df741204c50590728542e674ee9f91 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119116 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com> (cherry picked from commit bda4d7a7c3fcc259e023f568606be5dcba818db9) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119185 Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-07-20sdremote: fix race condition in Transmitter shutdown to plug leakAndrzej Hunt
We need to acquire the mutex in notifyFinished() to avoid a race between notifyFinished() and the loop in run(). And we also need to check mFinishRequested) while holding the mutex to avoid the same race condition. While we're here, rename the mutex to make it more obvious that it's not only protecting the queues. The race can happen because the loop in run() blocks until mQueuesNotEmpty is set. It also resets mQueuesNotEmpty at the end of each iteration if the queues are empty. So if someone sets mQueuesNotEmpty in the middle of an iteration, and the loop later resets it, the loop won't continue iterating. But we're actually using mQueuesNotEmpty to indicate either that the queues have data OR that we might want to finish transmission. And the problem is that notifyFinished() sets mFinishRequested, followed by setting mQueuesNotEmpty in an attempt to get the loop to process mFinishRequested (at which point the loop should finish and return). But as described above, we can easily get into a situation where the loop resets mQueuesNotEmpty again (at least if there's no more pending data in the queues). In this scenario, the loop blocks forever (we won't receive any new messages after notifyFinished()), causing a leak of both Transmitter and any resources it's using - e.g. the StreamSocket. The easiest way to fix this is to make it clear that the mutex protects all internal state, followed by using it to protect all internal state. This issue is not a big deal in normal usage - it's a tiny leak, and users won't connect enough clients for accumulated leaks to pose any issues. But it's ugly, and potentially problematic for long-running tests which could run out of filedescriptors because of the socket leak. I will rename mQueuesNotEmpty to something more obvious (possibly mProcessingRequired) in a separate commit. Change-Id: I2e22087054f3f6a02e05c568b1832ccc5a8b47a3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118751 Reviewed-by: Andrzej Hunt <andrzej@ahunt.org> Tested-by: Jenkins (cherry picked from commit 8e6cdb02450a876b5c684eb621e1c9383fb1c428) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118917 Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2021-07-20vcl: check mpWindowImpl for nullptr.Michael Meeks
Crash in calc's mouse capture / end tracking. Change-Id: If5b4cded8ebfc04d1fcf645a7b74184532ab2338 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119034 Tested-by: Jenkins Reviewed-by: Michael Meeks <michael.meeks@collabora.com> (cherry picked from commit c7b9f477f69c317e0482aeee79b1c2f070a1b981) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119037 Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2021-07-19tdf#143332 - Use utl::TextSearch to implement the InStrRev functionAndreas Heinisch
Change-Id: I2dae038d061f036b3b7c0fbbcb6a821305d4839e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119094 Tested-by: Jenkins Reviewed-by: Andreas Heinisch <andreas.heinisch@yahoo.de> (cherry picked from commit f5e030a343bec9f0f2c7b30e2dfb21ba5c94e5e8) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119177 Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-07-19tdf#139840 - Use utl::TextSearch to implement the InStr functionAndreas Heinisch
In addtion, fixed a crash if the start position is greater than the length of the string being searched. Change-Id: I9bcda1131324bdfac6957018e91b3a36dd2dc3d6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118996 Tested-by: Jenkins Reviewed-by: Andreas Heinisch <andreas.heinisch@yahoo.de> Signed-off-by: Xisco Fauli <xiscofauli@libreoffice.org> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119165
2021-07-19tdf#143125 sd: fix crash when closing Custom Slide Shows dialogTibor Nagy
regression from commit I6e97a69c546870199d5a45d9a6ad102e30d820c2 Change-Id: I760dabeb024413f1a2aeb57434f63adedb4246f2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118231 Tested-by: Jenkins Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org> (cherry picked from commit d7dff57384126e50b75c95e84fd3081db2f326a1) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119172 Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-07-19sw: xDictionary may be an empty reference in SID_SPELLCHECK_IGNORE_ALLMiklos Vajna
Seen in a crashreport: handleFatalSignal ./common/SigUtil.cpp:255 /lib/x86_64-linux-gnu/libpthread.so.0 __restore_rt ??:? program/../program/libswlo.so SwTextShell::Execute(SfxRequest&) sw/source/uibase/shells/textsh1.cxx:1496 Change-Id: I709f361a1396abbb07cea06509afc41bb5f5c9a3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119067 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins (cherry picked from commit 801b607fc6b3890eb36d310074f1a68db9ae1f5e) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119173 Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2021-07-19tdf#142923 Deleting comment in Writer leaves visual artifact behindNoel Grandin
Change-Id: Ia2e55886513e81847dd0ac6c697e7cea34e01bdc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119075 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> (cherry picked from commit 3ec78de2322f781a98802acc77cfb3e71a08eb3d) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119174
2021-07-19tdf#92796 ODF import: remove unused bitmap fillsMichael Stahl
With CWS impress64 a partial fix for this was implemented to drop unreferenced named items including all non-color fills after ODF import, but this is only done in sd so move the code that does that to svx and call it from sc and sw as well. Implement some UNO interface for this, it's at least better than a magic string, and not obvious how a better solution would look like since it's known only at the end of the import if a bitmap is used or not. Another problem: when the Area tab is used to change to a different kind of fill, the items with the details for the previous fill aren't cleared, and so they are written to ODF files. Hence bitmaps in the file can be referenced even if they aren't actually used, and bloat up the files. Fix this by dropping all unused draw:fill-image-name attributes in ODF import. Also do the same for Gradient and Hatch fills; Transparency gradients can be combined with anything so leave them as they are. Change-Id: I0b591fd9f963d974d0c3e7208b99621ad61dd93c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118950 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de> (cherry picked from commit 86c0f58b6f9f392865196606173d1b98a6897f32) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119036 Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de>
2021-07-18make calendar button small-button style so it fits in limited heightCaolán McNamara
Change-Id: I1997ae2a3916372ded3d4120e4510144c6700777 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119035 Tested-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com> Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2021-07-17tdf#143355: fix crash with .uno:FontWorkJulien Nabet
with gen rendering part of bt: 2 0x00007fbfb39f440f in __assert_fail_base (fmt=0x7fbfb3b5d128 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x7fbfac2531b0 "!w || dynamic_cast<T*>(w)", file=0x7fbfac2531ca "/home/julien/lo/libreoffice/include/vcl/builder.hxx", line=438, function=<optimized out>) at assert.c:92 3 0x00007fbfb3a03662 in __GI___assert_fail (assertion=0x7fbfac2531b0 "!w || dynamic_cast<T*>(w)", file=0x7fbfac2531ca "/home/julien/lo/libreoffice/include/vcl/builder.hxx", line=438, function=0x7fbfac3ad73e "T *VclBuilder::get(const rtl::OString &) [T = VclBox]") at assert.c:101 4 0x00007fbfabb27ace in VclBuilder::get<VclBox>(rtl::OString const&) (this=0x6e07e70, sID="DockingFontwork") at include/vcl/builder.hxx:438 5 0x00007fbfabb065e5 in SalInstanceBuilder::weld_box(rtl::OString const&) (this=0x6ce97c0, id="DockingFontwork") at vcl/source/app/salvtables.cxx:6811 6 0x00007fbfb07d3fe9 in SfxDockingWindow::SfxDockingWindow(SfxBindings*, SfxChildWindow*, vcl::Window*, rtl::OString const&, rtl::OUString const&) (this= 0x6e37c90, vtt=0x7fbfafd55730 <VTT for SvxFontWorkDialog+8>, pBindinx=0x34f62b0, pCW=0x6e39c00, pParent=0x34f6f40, rID="DockingFontwork", rUIXMLDescription="svx/ui/dockingfontwork.ui") at sfx2/source/dialog/dockwin.cxx:774 7 0x00007fbfaf7c3be8 in SvxFontWorkDialog::SvxFontWorkDialog(SfxBindings*, SfxChildWindow*, vcl::Window*) (this=0x6e37c90, pBindinx=0x34f62b0, pCW=0x6e39c00, _pParent=0x34f6f40) at svx/source/dialog/fontwork.cxx:179 8 0x00007fbfaf7c728c in VclPtrInstance<SvxFontWorkDialog>::VclPtrInstance<SfxBindings*&, SvxFontWorkChildWindow*, vcl::Window*&>(SfxBindings*&, SvxFontWorkChildWindow*&&, vcl::Window*&) (this=0x7ffc6e31bf70, arg=@0x7ffc6e31bf78: 0x34f62b0, arg=@0x7ffc6e31bf68: 0x6e39c00, arg=@0x7ffc6e31bf80: 0x34f6f40) at include/vcl/vclptr.hxx:279 9 0x00007fbfaf7c1dcc in SvxFontWorkChildWindow::SvxFontWorkChildWindow(vcl::Window*, unsigned short, SfxBindings*, SfxChildWinInfo*) (this=0x6e39c00, _pParent=0x34f6f40, nId=10256, pBindings=0x34f62b0, pInfo=0x7ffc6e31c230) at svx/source/dialog/fontwork.cxx:169 See full bt here: https://bugs.documentfoundation.org/attachment.cgi?id=173585 with gtk3 rendering, no crash but: (soffice:33916): GLib-GObject-WARNING **: 20:40:33.018: invalid cast from 'GtkGrid' to 'GtkBox' put grid into a toplevel box (git show -w to see minimal diff) Change-Id: I05f9a295cd839f782467b85d6bafd652a405b14d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118919 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-07-17tdf#143400: fix query with most functions could not be created in GUIJulien Nabet
Regression from: https://cgit.freedesktop.org/libreoffice/core/commit/?id=04aafba860f613c20e7078d038cc83eb02de0b54 loplugin:stringadd simplify some *StringBuffer operations pulled from a larger patch which I created with a more permissive variant of this plugin Specifically here: -------------- dbaccess/source/ui/querydesign/QueryDesignView.cxx -------------- index 22408bbc58aa..63c5d07998ec 100644 @@ -658,11 +658,10 @@ namespace if ( field->isAggregateFunction() ) { OSL_ENSURE(!field->GetFunction().isEmpty(),"Function name must not be empty! ;-("); - OUStringBuffer aTmpStr2( field->GetFunction()); - aTmpStr2.append("("); - aTmpStr2.append(aTmpStr.makeStringAndClear()); - aTmpStr2.append(")"); - aTmpStr = aTmpStr2; + aTmpStr = field->GetFunction() + + "(" + + aTmpStr + + ")"; } if (!rFieldAlias.isEmpty() && Change-Id: Ib0b57e6c44a58a6a5f9c98aebc6a1213b35108d1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119088 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr> (cherry picked from commit 4a096b9c787fa2079ef1c8f00fed91d432d46fae) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119039 Tested-by: Jenkins
2021-07-16update creditsChristian Lohmaier
Change-Id: I1a09193e888318084a7d9b3c76c049e373db545b (cherry picked from commit 113d308155e4b6a67a8510098a7db5f4a6632bdc)
2021-07-16tdf#143257 like graphics defer creating transfer data for drawings until neededCaolán McNamara
don't create when a drawing is selected, wait until its actually dropped into something (I experimented with dropping into gimp) Change-Id: I3edaf79537d5723565adf8c45d6f7408026a93e3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118725 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2021-07-16tdf#143327 keep selection bounds on replacing colorCaolán McNamara
so select-all and type 'a' will retain cursor at position 1 and delete/backspace keep cursor position in a semi-rational way Change-Id: I802f132e58cea9f111deb1c6d157706d08cb5b81 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118921 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2021-07-16Resolves: tdf#143398 mouse event processed twiceCaolán McNamara
this is a problem since: commit 67b157e994d9bef01f6117b53fc29e1fee538715 Author: Caolán McNamara <caolanm@redhat.com> Date: Tue Jun 29 13:00:45 2021 +0100 tdf#143088 multiple Application::EventListeners is expensive turns out that AddChildEventListener is sufficient to get events for the widget and its children so the widget-only AddEventListener isn't needed or wanted Change-Id: I635419df10fce1d4441b2d85627a6cbe99adb6aa Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118930 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2021-07-16Fix lang::Locale.Language usage, tdf#128191 follow-upEike Rathke
Using plain lang::Locale.Language is always wrong, it may even be 'qlt' for a more complex language tag. As the InfoBar message is "Please install the hyphenation package for locale “%1”." actually use the BCP 47 language tag of that character/paragraph attribution. Spotted in https://ask.libreoffice.org/en/question/280102/install-the-hyphenation-package-for-locale-ka/ https://ask.libreoffice.org/en/question/238764/error-message-reads-install-the-hyphenation-package-for-locale-zh/ Change-Id: I5805d4d711989a9d0260940666d3eb33eae830af Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119020 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Jenkins (cherry picked from commit 64f885a6c9d51999b737c0f61bc3a7fa311a5a94) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118931 Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2021-07-16Resolves: tdf#143372 Exclude {qtz} KeyID from SvxLanguageBox listEike Rathke
Change-Id: I3e52407a33f79713635063ff4ba374267eb98005 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119002 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Jenkins (cherry picked from commit da13b76e07231131cb951868a314ee6f51c0f254) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118927 Reviewed-by: Caolán McNamara <caolanm@redhat.com>