Commit graph

469434 commits

Author SHA1 Message Date
Noel Grandin
23886b0e02 tdf#133835 speedup calc autofilter (2)
Tweak ImpEditEngine::SetRotation to avoid doing work when
nothing has changed, saves 10%

Change-Id: I10db2415278908e9e36491950a5f4826e01f42fd
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125564
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-20 06:40:35 +01:00
Noel Grandin
66317d3aa5 tdf#133835 speedup calc autofilter (1)
avoid a copy in INetURLHistory::QueryUrl, saves 10%

Change-Id: I662a4e48f198e61f1cef52b1e920613bce9c9766
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125563
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-20 06:40:11 +01:00
Noel Grandin
b692c8a280 small optimisation
avoid malloc in the common case

Change-Id: I3820065c2b070eddf7cfcba117ec1be73735957f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125562
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-20 06:39:53 +01:00
Rene Engelhard
214fa23333 add with-system-abseil/with-system-openjpeg for pdfium
Change-Id: I270cbb75cde2a44416b61978b8eefdf267720031
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125559
Tested-by: Jenkins
Reviewed-by: René Engelhard <rene@debian.org>
2021-11-19 22:23:42 +01:00
Caolán McNamara
04c5aef876 add placement to Popover popup_at_rect
Change-Id: Iaa12a48f62037dd985d526993a07762b10bd0cee
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125474
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-11-19 21:47:54 +01:00
Rene Engelhard
2ed0c2f7ce fix gtk4 build
res is only defined if NDEBUG is *not* defined. So it doesn't exist in a
"standard" build using -DNDEBUG and shouldn't be used.

Change-Id: Iebae9898d50030f994a7289e2bc3fe3052172dee
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125582
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-11-19 21:47:15 +01:00
Mike Kaganski
13ff493f1d Use toRadians on Degree10
Change-Id: Ib0a53f1dd9c7dd2011041c1c8a6923a64ff6d0f8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125581
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-11-19 21:46:06 +01:00
Xisco Fauli
2a605bdd15 uitest: sc: Add UItest for the Save to CSV dialog
Change-Id: Iddf617a02697c30e195d1de94fa064adf5b2d7f4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125560
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-11-19 19:46:29 +01:00
Mike Kaganski
7ff2c9cfc5 Use more basegfx::deg2rad<N> and basegfx::rad2deg<N>
Change-Id: I9dc57628b98f67994d546f6887e96389be1efe62
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125568
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-11-19 19:33:53 +01:00
Xisco Fauli
f8790b1d58 uitest: better use execute_dialog_through_action in these cases
Change-Id: Ic2317db908afc12973624034f29c1de6f4efd60c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125561
Tested-by: Xisco Fauli <xiscofauli@libreoffice.org>
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-11-19 18:25:28 +01:00
Mike Kaganski
e3c8de29dd Use more precise value for M_PI in OpenCL
No idea if that would make actual difference, but it simply looks
odd that we use such a value, in view of all other efforts to improve
accuracy of rad<->deg conversions.

The value is used that is already present elsewhere in the code, e.g.
in sc/source/core/opencl/op_statistical.cxx.
Change-Id: I098f2bf748670e3250035d74d1bf7d1e224dd66b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125557
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-11-19 17:40:41 +01:00
Heiko Tietze
1833cb7aa9 Resolves tdf#130895 - Edit Bookmark Entry dialog too tall
Introduced a scrollwindow behind the fields

Change-Id: Ic32d85d196a73594868f4268a76f783e3d0bea07
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125551
Tested-by: Jenkins
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2021-11-19 17:27:07 +01:00
Caolán McNamara
50affeebd9 gtk3: treat standalone GtkPopover similarly to the GtkMenuButton managed one
so do the same replacement with GtkWindow under X11 for gtk3 that we do
in MenuButtons for the popover with direct popovers when the constraint
is GTK_POPOVER_CONSTRAINT_NONE

Change-Id: Ia903b24c54e6d3acc18df1ab912600e07b7f844d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125543
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-11-19 16:10:28 +01:00
Mike Kaganski
bc0ab08634 Drop F_PI1800/F_PI18000, and unify deg2rad/rad2deg conversions
Change-Id: Ib89b00c3dc8cd440e8a88906eea133becd1cef64
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125509
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Tested-by: Jenkins
2021-11-19 15:42:03 +01:00
Stephan Bergmann
168ae4c00a Fix --enable-online-update
...after 4bc44490f5
"loplugin:stringliteraldefine in tools"

Change-Id: I0ec1e07b151e853be8a795c7135aecf5c6957eac
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125556
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-11-19 15:33:10 +01:00
Michael Stahl
a8beb8c088 sw: DOCX export: use list's indent if paragraph is not counted
Writer/ODF has a feature to have paragraphs in a list without having a
list label, but they do take the indent of the list level into account.

Word doesn't appear to have this feature, so the export forces such
paragraphs to refer to a non-existent numId 0, so they are not part of a
list.

Take the left indent from the list level and write it into the pPr.

Change-Id: I8ad56e51e2d4dfd691e3c38532f1a824f5276fd7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125555
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2021-11-19 15:31:49 +01:00
Miklos Vajna
32ae1ed750 PPTX import: handle <a:clrScheme name="...">
We had doc model for this, but the UNO API and the PPTX import was
missing.

Change-Id: I199e9cc235a783d91700ce74f17d442f41d3c3f8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125532
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
2021-11-19 15:28:42 +01:00
Noel Grandin
13aa508179 remove unused defines
Change-Id: I1140d7dc2f40dafcba6a314c7a641c3b2d886af4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125554
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-19 15:25:45 +01:00
Caolán McNamara
52d199b364 gtk4: GtkPopover parent must be set before its shown
Change-Id: I6184422b92d3629f31141215bed588400b30289c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125542
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-11-19 14:58:40 +01:00
Caolán McNamara
a59b5f9e80 gtk3: use GtkPopover default for selected cases that are within a document
and where inability to escape window under X11 hasn't been a problem to date

Change-Id: I14aa5fe2cf443b6214aed48266d5bd32b8b9c700
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125541
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-11-19 14:58:10 +01:00
Caolán McNamara
fae7fd3d19 gtk3: default to an explicit constrain-to for Popovers
with the intent to do the same replacement with GtkWindow under X11 for
gtk3 that we do in MenuButtons for the popover with direct popovers when
the constraint is GTK_POPOVER_CONSTRAINT_NONE

Change-Id: I629c30b44a9e362ba0d924bb229930b5f0dc7ed3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125540
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-11-19 14:57:46 +01:00
Xisco Fauli
2337bd5f0d tdf#136551: sc_subsequent_filters: Add unittest
we can use the file from tdf#134867 to test tdf#136551
although one bug is in calc and the other is in writer
In the end, the problem is in the sax parser when dealing
with files bigger than 10Mbs so the problem is not
specific to one component

Change-Id: If366626b386c592a0b780692a951b27a3e5cdbe5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125538
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-11-19 14:55:34 +01:00
Armin Le Grand (Allotropia)
8c715d513e Qt set QPainter AntiAlias hint from SalGraphics
Change-Id: I1a9e6014ead24b6edff1dbb41b70c809204d01cc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125549
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
2021-11-19 14:07:52 +01:00
Justin Luth
894a01640a tdf#137438 drawingml: separate outline from text import
By ignoring the a:ln group, the contents in that group
(like transparency) were being applied to the text.
Well, it should only apply to a line around the text,
which LO isn't doing.
[Well, LO can do this as Fontwork, but perhaps that
doesn't match so well with text in shapes generally?]

At any rate, don't allow one group's settings
to override the others. Keep them separate and then apply
a bit of merging logic to try to achieve the best look.

So emulate a little bit. If the outline is not very
transparent (less transparent than the main text)
then it may (if thick or opaque enough) dominate
the text.

For simplicity (and because there is no right answer overall)
I just compared transparency and used the more opaque colour.

Unit tests potentially affected:
-export-tests-ooxml1.cxx: tdf100348_FontworkBitmapFill.odp -> PPTX
   -now imports black instead of yellow (MSO sees gradient colors)
   -so previously completely wrong, and now perhaps even more wrong?
-export-tests-ooxml3.cxx: tdf114848.pptx
   -shows blue text regardless - defined by area.
   -can't see where this is set in MSO2016. Perhaps illegal?
-  : tdf125573_FontWorkScaleX.pptx
   -no visual difference. Same as tdf100348, but with black outline.
-  : tdf119087.pptx
   -should be green, not purple. [Added test for that.]
-  : tdf143315-WordartWithoutBullet.ppt
   -no visual difference (COL_AUTO outline?)
-import-tests2.cxx: tdf129686.pptx
   -poor test usage (but also weird transparent default).
   -no visual change.
-ooxmlimport2.cx: tdf143476_lockedCanvas_position.docx
   -no visual difference. Irrelevant since we can't RT

Change-Id: Iff0d95506dd64825444a99e62a6c2bd5e1dc122f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125300
Tested-by: Jenkins
Reviewed-by: Justin Luth <jluth@mail.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2021-11-19 13:49:01 +01:00
Noel Grandin
31ed4c70b0 loplugin:stringliteraldefine in vcl
Change-Id: Id14cc8613fdfb67790efd6c33ee243f6bdb522f3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125546
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-19 13:34:45 +01:00
Noel Grandin
5078e83d88 loplugin:stringliteraldefine in svl
Change-Id: I49a8062c30bdce5b0d9bd27e421d85ba61d5592e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125544
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-19 13:27:00 +01:00
Jan-Marek Glogowski
7e21785380 Change About LO dialog to run async
Change-Id: I7255a8510e4cf983ebab477cbdb7cdcf00dabc98
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125512
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
2021-11-19 13:14:06 +01:00
Jan-Marek Glogowski
de5bf7f880 Reuse macros for AbstractDialogFactory_Impl
Now that all the abstract dialogs are welded, update and rename
the existing boilerplate macros, to cut down the C'n'P code size.

Change-Id: Iff8f452ca3dfce9a63c4fb73ab3a5025566810e2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125511
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
2021-11-19 13:08:16 +01:00
Noel Grandin
2fe77d0ed8 rtl::Static->thread-safe static in unoxml
Change-Id: Icb458f9ba38225aef17a2421533be79c6d9445d3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125496
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-19 12:58:53 +01:00
Noel Grandin
4bc44490f5 loplugin:stringliteraldefine in tools
Change-Id: I348b9a844c009f9c19301baa76d31b12f67c6130
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125535
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-19 12:56:36 +01:00
Caolán McNamara
d7dbc5fd42 gtk3: take default modality from the popover it replaces
Change-Id: I0404dc17bd816a7dd403c50692f4f5325aacaf31
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125503
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-11-19 12:52:40 +01:00
Tor Lillqvist
c5a72ac64f Upgrade to un-deprecated API and fix a crash in the pasteboard.mm helper tool
Change-Id: Ic0b839df686fb93c64ef844848028ded39225ced
2021-11-19 13:46:08 +02:00
Caolán McNamara
c705a5a65c gtk4: remove constrain-to property
Change-Id: I18f0b72fff31f555873a0808f171e4c1746a4411
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125539
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-11-19 12:26:34 +01:00
Noel Grandin
addf580c28 loplugin:stringliteraldefine in linguistc
Change-Id: Id347daab7aa21ce8756dbc2d139ac022fc22be3f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125536
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-19 11:36:34 +01:00
Noel Grandin
bcf601f53c rtl::Static->thread-safe static in vcl
Change-Id: I748c3b5608b76b4b847273856f6b1c66b53aced1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125497
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-19 11:35:29 +01:00
Noel Grandin
38ef2cb092 loplugin:stringliteraldefine in i18npool
Change-Id: I8a56d5d6d201ac5ae65dc46ef4838a0e41af587e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125530
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-19 11:35:16 +01:00
Hossein
9cad66da64 Cleanup locally used variables in Calendar_hijri
* Some variables that were only used in the calendar_hijri.cxx
  are now moved out of the header file, and they are no loner
  member variables of the the class Calendar_hijri. They are now
  placed in the the i18npool namespace.
* Removed unused variables SynMonth, EveningPeriod and LeapYear
* Moved a global variable definition to the member function that was
  the only place it was used. It is now a local variable.

Change-Id: I8a8b25765bd8ed5640b1a0cfa46ec9903b460a53
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125433
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Tested-by: Jenkins
2021-11-19 11:26:09 +01:00
Caolán McNamara
96d19777ab refactor for potential reuse outside MenuButton
Change-Id: I36729364550dc7c505fdc396442f51809fc58073
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125489
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-11-19 11:01:37 +01:00
Caolán McNamara
d9c6fa0c31 crashes seen in WriterInspectorTextPanel ctor
null DocSh is likely

Change-Id: I5aeb81ef01795b896ad594d7eb7f0cd657f5a690
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125483
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-11-19 10:57:49 +01:00
Noel Grandin
10d172747b loplugin:stringliteraldefine in accessibility
Change-Id: Ie27c32ea51ebcc9ad0d0d5a1d160d55c23727cd5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125274
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-19 10:05:10 +01:00
Mike Kaganski
1cc6fca492 Drop F_2PI
Change-Id: Ie98606607b2ce262e4eed76bb8cd86fbfe846f76
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125506
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-11-19 10:00:02 +01:00
Mike Kaganski
37429f2690 Use M_PI* instead of F_PI*
Change-Id: Ie2b7a1c74fc516781a17a20157b8217bc41e383d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125504
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-11-19 09:59:43 +01:00
Justin Luth
0afd2d3bfa tdf#135906 docxexport: set serializer before writing
This fixes a 6.3 regresssion from
commit aafaf1f55f.

Change-Id: Ia2d3d26fe2cfa2b213326021f6b97f8d40c6e98c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125441
Tested-by: Jenkins
Reviewed-by: Justin Luth <jluth@mail.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2021-11-19 09:12:44 +01:00
Michael Weghorn
dc0016bc8d tdf#137924 qt (>=5.14): Use proper DPI without requiring window handle
For Qt >= 5.14, don't require a window handle to retrieve
the screen and then the associated DPI value from that one,
but directly use 'QWidget::screen' (introduced in QT 5.14)
to retrieve the screen.

Previously, no DPI values would be set in case there was
no window handle.

This makes UI scaling work without having to manually set
'SAL_FORCEDPI' on Wayland.

While various UI elements (like e.g. the "Help" -> "About LibreOffice"
still look quite broken with the qt5 and kf5 VCL plugins
in a Plasma Wayland session (at least on my Debian testing with
Qt 5.15.2 and Plasma 5.23), they look OK
when using the qt6 VCL plugin with a custom build of qtbase
and qtwayland from Qt's "dev" git branches.

Change-Id: I5feae46ed86a8b7d3cf92d4a973f7a0f9a9f95de
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125507
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2021-11-19 09:12:34 +01:00
Noel Grandin
f3a0e8ba28 rtl::Static->thread-safe static in xmloff
Change-Id: I5fa1f0a2b5336508841ef841bb56e2edb25e4ef7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125498
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-19 09:00:01 +01:00
Noel Grandin
8b1399cbb7 rtl::Static->thread-safe static in sw
Change-Id: Ic69883c66a08654b9c86ca87a640f5070312fa83
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125499
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-19 08:50:02 +01:00
Miklos Vajna
339405818c sw: enable warning in XMLRedlineImportHelper::InsertIntoDocument()
This one looks useful, so why hide it behind dbglevel=2.

Change-Id: I424808ae8ccd2ab7edcd1a75cd7c4479a0ec3b13
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125501
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2021-11-19 08:05:18 +01:00
Noel Grandin
f7a8c3cc4d rtl::Static->thread-safe static in unotools
Change-Id: I2a8c9ca7c45a8e20f3d114722a0677b856a13d8c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125495
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-19 07:33:34 +01:00
Noel Grandin
4d3e4c1cf3 rtl::Static->thread-safe static in tools
Change-Id: I6c45fc533ec6281d011282bf2e8d49f23e2c29e6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125494
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-19 07:33:15 +01:00
Noel Grandin
6f3c6b12ea rtl::Static->thread-safe static in svx
Change-Id: I743d252befd948580a1b3619f51d3f0343cb469d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125493
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-11-19 07:33:00 +01:00