Commit graph

1146 commits

Author SHA1 Message Date
Michael Weghorn
57d532057b weld: Rename weld::Treeview selection signal/connect
Rename weld::TreeView member + methods to clarify
that these are about selection changes:

* m_aChangeHdl to m_aSelectionChangedHdl,
* signal_changed to signal_selection_changed
* connect_changed to connect_selection_changed

In GtkInstanceTreeview, also rename the
related methods calling signal_selection_changed
accordingly for consistency.

Change-Id: I299d7930484677395a0bdd0ff105df18688f2e04
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/178023
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2024-12-07 11:15:03 +01:00
Noel Grandin
ce8816ff95 loplugin:reftotemp in drawinglayer..framework
Change-Id: I31618b4ae7ea4e37834bffc89e352b4c33eda14d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/176372
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Jenkins
2024-11-11 18:28:57 +01:00
Regina Henschel
c377e21178 tdf#162177 Adapt function EASTERSUNDAY to ODF 1.4
This includes writing ORG.OPENOFFICE.EASTERSUNDAY for ODF 1.3 and
ODF 1.2.

Change-Id: Ifa19021060f0d0223234c1ca1109300908e2dda1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/175736
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Reviewed-by: Regina Henschel <rb.henschel@t-online.de>
2024-11-06 00:55:37 +01:00
AhmedHamed
d05e0be5f4 tdf#161543 Enhance the searching functionality in FD & FW
Change-Id: I1a21595228f886c942ae46d90e41705443d31550
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170073
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
Reviewed-by: Andreas Heinisch <andreas.heinisch@yahoo.de>
Tested-by: Jenkins
2024-09-03 09:59:16 +02:00
Eike Rathke
044980edc4 Resolves: tdf#161599 Write Add-In CompatibilityName (if any) to OOXML
First "en-US" (preferred) or "en" or any first if no "en-US" nor "en".

Change-Id: Ifdb60547b588f224ee9ddca39af2352a87385bd0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172604
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Jenkins
2024-08-30 03:04:44 +02:00
Eike Rathke
59d2745d4a Related: tdf#161599 Accept Add-In CompatibilityName when reading OOXML
Must be first "en-US" (preferred) or "en" or any first if no "en-US" nor "en".

Change-Id: I1549d6650b19fbb37952bd093692bbbcba1420c2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172603
Tested-by: Jenkins
Reviewed-by: Eike Rathke <erack@redhat.com>
2024-08-29 20:30:28 +02:00
AhmedHamed
e1183fb68e Make help button in FW has a fixed width
Change-Id: I79122e8ae1c05d1ad647dc990b641971c8bbca50
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171929
Tested-by: Jenkins
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2024-08-20 08:35:13 +02:00
Caolán McNamara
a4dfd23e44 cid#1557694 COPY_INSTEAD_OF_MOVE
and

cid#1557162 COPY_INSTEAD_OF_MOVE
cid#1556896 COPY_INSTEAD_OF_MOVE
cid#1556893 COPY_INSTEAD_OF_MOVE
cid#1556873 COPY_INSTEAD_OF_MOVE
cid#1556872 COPY_INSTEAD_OF_MOVE
cid#1556789 COPY_INSTEAD_OF_MOVE
cid#1556570 COPY_INSTEAD_OF_MOVE
cid#1556519 COPY_INSTEAD_OF_MOVE
cid#1556516 COPY_INSTEAD_OF_MOVE
cid#1556451 COPY_INSTEAD_OF_MOVE
cid#1556396 COPY_INSTEAD_OF_MOVE
cid#1556237 COPY_INSTEAD_OF_MOVE
cid#1556113 COPY_INSTEAD_OF_MOVE
cid#1556094 COPY_INSTEAD_OF_MOVE
cid#1555991 COPY_INSTEAD_OF_MOVE
cid#1555982 COPY_INSTEAD_OF_MOVE
cid#1555885 COPY_INSTEAD_OF_MOVE
cid#1555702 COPY_INSTEAD_OF_MOVE
cid#1555610 COPY_INSTEAD_OF_MOVE
cid#1555450 COPY_INSTEAD_OF_MOVE
cid#1555327 COPY_INSTEAD_OF_MOVE
cid#1555145 COPY_INSTEAD_OF_MOVE

Change-Id: I38cc1a38e8cb2c33f33e0fc3afd34a0fb39e5ec1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172028
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-08-19 15:15:54 +02:00
Eike Rathke
4c3f65ea3b Resolves: tdf#159343 Implement TableRef API token conversion
Change-Id: I1b0d9e002d267e62dc7cbbbfc9f5c5c728374345
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171165
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Jenkins
2024-07-29 16:29:19 +02:00
Eike Rathke
0b683547bb Related: tdf#159343 Handle TableRef separator in brackets for Function Wizard
... not breaking to next argument of a function parameter.

Change-Id: Ibc7a64c4ea64c415098a213f0ff3d96b8a9dd73c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171085
Tested-by: Jenkins
Reviewed-by: Eike Rathke <erack@redhat.com>
2024-07-27 00:19:57 +02:00
Eike Rathke
dc9486f244 Resolves: tdf#162087 FormulaCompiler::OpCodeMap::maHashMap must be uppercase
which is the case for all English function names, but not the
TableRef item specifiers like #All, #Data, ...

Change-Id: I7f675e05b0d52eac9596b96b4d2cf299351fb82a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171022
Tested-by: Jenkins
Reviewed-by: Eike Rathke <erack@redhat.com>
2024-07-25 23:27:21 +02:00
AhmedHamed
5bd284583f tdf#161296 Convert functions list in FD & FW into collapsible sections
Change-Id: I9211c0cf02be8d21e343d57f53d14e50d7b5fd0d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169639
Reviewed-by: Andreas Heinisch <andreas.heinisch@yahoo.de>
Tested-by: Jenkins
2024-07-19 07:50:55 +02:00
AhmedHamed
f5685bdfff tdf#161534 Add a Help button in FD & FW to open respective Help documentation
Change-Id: I35f5965401e970e02fa196f767bbd08d00de424f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170181
Reviewed-by: Andreas Heinisch <andreas.heinisch@yahoo.de>
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
Tested-by: Jenkins
2024-07-12 10:51:50 +02:00
Bayram Çiçek
9bbb02bcd7 tdf#161502: change Structure label of Function Wizard dialog
- label "Structure:" changed to "Content:"
- this change also removes the duplicated "Structure" text from the dialog which makes the UX better

Signed-off-by: Bayram Çiçek <bayram.cicek@collabora.com>
Change-Id: I6d70e019b80d4ef0d7207b62e1d0aa6d1f0a3b73
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168161
Tested-by: Pedro Silva <pedro.silva@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Pedro Silva <pedro.silva@collabora.com>
(cherry picked from commit dc3e624b52e43bb197417b5d9339890afe7c5379)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168612
Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
Tested-by: Jenkins
2024-06-11 19:52:30 +02:00
Balazs Varga
e52b555a1d Related: tdf#137543 - fix LET function jump count number
Clean-up and fix wrong jump count.

Change-Id: Ie64ff95f63c17d2726b3a522af981bcaea2a9a32
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168590
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Tested-by: Jenkins
2024-06-09 22:13:24 +02:00
Balazs Varga
521a56d8d1 tdf#137543 - Add new LET function to Calc
Add new LET function to Calc which assigns names to calculation results.

TODO: oasis proposal

Change-Id: Ia0d56a30751a44a72e364a28b64fd8f617e997dc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168349
Tested-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
Tested-by: Jenkins
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
2024-06-06 09:09:47 +02:00
Eike Rathke
62e88a17fd Resolves: tdf#160371 Relax significant whitespace intersection pre-check
Change-Id: I3bef7c70571ee6ce8c98d60e6f6f017f3760530f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168070
Tested-by: Jenkins
Reviewed-by: Eike Rathke <erack@redhat.com>
2024-05-26 19:44:50 +02:00
Andrea Gelmini
5529ada78f Fix typo in code
Change-Id: Ic416b58498274cbd49cbb0a5fea934bfbe356722
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167901
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Tested-by: Julien Nabet <serval2412@yahoo.fr>
2024-05-21 22:14:06 +02:00
Jaume Pujantell
c94a870f22 lok: translate formula bar functions to each locale
On calc the native formula symbols were loaded once on start-up and
assumed to not change.

This adds a map language to symbols when LOK is active and chooses
the correct set of symbols on each call.

Change-Id: I821fb3ad4a06d764399e3fdf4a2ec628909312db
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167870
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Jaume Pujantell <jaume.pujantell@collabora.com>
(cherry picked from commit 421ef056cf)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167825
Tested-by: Jenkins
2024-05-21 11:24:07 +02:00
Balazs Varga
c1565b8b94 tdf#126573 Add Excel2021 array function UNIQUE to Calc
Add new function called UNIQUE to the function list.

(TODO: dynamic array in separate patch, oasis proposal)

Change-Id: Ie138aee545995d4af1e66be5a4cf4e99e6e2f581
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167484
Tested-by: Jenkins
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
2024-05-15 18:10:54 +02:00
Balazs Varga
d68f2394af tdf#126573 Add Excel2021 array function RANDARRAY to Calc
Add new function called RANDARRAY to the function list.

(TODO: dynamic array in separate patch, oasis proposal)

Change-Id: I34bad3b7e8d631d649a0350d7c1170b26161331d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167003
Tested-by: Jenkins
Tested-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
2024-05-08 17:45:36 +02:00
Noel Grandin
1221592520 loplugin:ostr in formula
Change-Id: Iac66906636e64c0547122ac413bee494631c7c06
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167304
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Jenkins
2024-05-08 11:15:34 +02:00
Balazs Varga
35772a003b tdf#126573 Add Excel2021 array function SEQUENCE to Calc
Add new function called SEQUENCE to the function list.

(TODO: dynamic array in separate patch, oasis proposal)

Change-Id: I9fa6f2c83536536987542cc00a9eec5c196ada8d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166245
Tested-by: Jenkins
Tested-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
2024-04-26 09:33:23 +02:00
Caolán McNamara
1d63489ae7 Related: tdf#160056 rename/rework GetDoubleAsReference to SetDouble
Change-Id: I7e79e8d422fe7f426bb7c7360b11f836a5484574
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166053
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-04-13 21:28:16 +02:00
Caolán McNamara
791a2489ee Related: tdf#160056 elide ref counting for initial tokens
The initial tokens provided to interpreting will be restored
to their original ref count when interpreting is complete. So we
could elide expensive ref counting for them for the duration
of the the threaded group calculation.

Possibly "temp" tokens that are created just during interpreting could
additionally use thread-unsafe ref counts presuming they only appear in
a thread specific context.

Change-Id: I1f5b0198e83027781be15812680079f28b6a4e27
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165259
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-04-13 11:54:50 +02:00
Balazs Varga
bfb4c58ae7 tdf#126573 Add Excel2021 array function SORTBY to Calc
TODO/WIP: oasis proposal
More information about how this new function works:
https://support.microsoft.com/en-au/office/sortby-function-cd2d7a62-1b93-435c-b561-d6a35134f28f
https://exceljet.net/functions/sortby-function

Change-Id: I4538a32f7f75056d3055369fc5f4483d24fd1089
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165069
Tested-by: Jenkins
Tested-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
2024-03-26 10:20:38 +01:00
Balazs Varga
45435a680b tdf#126573 Add Excel2021 array function SORT to Calc
TODO/WIP: oasis proposal
More information about how this new function works:
https://support.microsoft.com/en-au/office/sort-function-22f63bd0-ccc8-492f-953d-c20e8e44b86c
https://exceljet.net/functions/sort-function

Note: Move ScSortInfoArray class to sortparam.hxx, which is a more
logical place.

Change-Id: I70e720e93ba0414d54cb3437de0bfa066508fe30
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164778
Tested-by: Jenkins
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
2024-03-25 15:54:01 +01:00
Balazs Varga
e5361d0ef0 Related: tdf#126573 Add Excel2021 array function FILTER to Calc
Add ocFilter to matrix (array) functions.
Some follow-up cosmetic clean.

Follow up commit of b0791dd921

Change-Id: I4c3c786fe14ab870be8c43211ca6a76c5ff6ac6c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164847
Tested-by: Jenkins
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
2024-03-15 12:38:13 +01:00
Balazs Varga
b0791dd921 tdf#126573 Add Excel2021 array function FILTER to Calc
https://issues.oasis-open.org/browse/OFFICE-4156

TODO: add dynamic arrays would be useful: Older array formulas,
known as legacy array formulas, always return a fixed-size result
- they always spill into the same number of cells. The spilling behavior
described in this topic does not apply to legacy array formulas.

More info about it:
https://support.microsoft.com/en-gb/office/dynamic-array-formulas-and-spilled-array-behavior-205c6b06-03ba-4151-89a1-87a7eb36e531

Related Bug: https://bugs.documentfoundation.org/show_bug.cgi?id=127808

Change-Id: I1c3769ef33fa0207f55e1c96083717c2d90402e5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163955
Tested-by: Jenkins
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
2024-03-01 18:31:35 +01:00
Balazs Varga
b36ecef07a tdf#128425 Add Excel2021 function XMATCH to Calc
https://issues.oasis-open.org/browse/OFFICE-4155

Change-Id: I7791ab873cf62ce882feba75dc0d722bc5990f9a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163260
Tested-by: Jenkins
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
2024-02-18 23:13:01 +01:00
Winfried Donkers
f7039822c7 tdf#127293 Add Excel2021 function XLOOKUP to Calc
https://issues.oasis-open.org/browse/OFFICE-4154

What is working already: xlookup with normal forward,
backward search in columns/rows. Binary search in rows with
real binary search algorithm, in columns only works with linear search yet.
Linear forward backward wildcard/regex search in columns/rows.
Looking for the first smaller or greater value with linear and binary search
ALso all the combination of all these options. Except XLOOKUP
not supperted wildcard/regex search with binary search.

TODO in next patches:
- add the binary search option for searching in columns.
- Evaluate Formula calculation not working in general.

Co-authored-by: Balazs Varga <balazs.varga.extern@allotropia.de>

Change-Id: I15fd4479b63ec13b093d269760d1bbb5957553e8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131905
Tested-by: Jenkins
Tested-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
2024-01-31 09:14:19 +01:00
Julien Nabet
7ad6ae594f Use emplace_back instead of push_back (Formula)
Change-Id: I6596e9d002016e5b501900fe9da26b5910cf7653
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161307
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2023-12-27 12:19:27 +01:00
Stephan Bergmann
bd6fb0cd3e Extended loplugin:ostr: Rewrite some O[U]StringLiteral -> O[U]String
...in include files.  This is a mix of automatic rewriting in include files and
manual fixups (mostly addressing loplugin:redundantfcast) in source files that
include those.

Change-Id: I1f3cc1e67b9cabd2e9d61a4d9e9a01e587ea35cc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158337
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2023-10-23 11:04:42 +02:00
Stephan Bergmann
dcea29c283 Make NC_ constexpr-friendly
...by moving the char8_t -> char reinterpret_cast out of any potential constexpr
paths into a new TranslateId::getId.  And demonstrate constexpr'ability by
making the aCategories var in OApplicationIconControl::Fill
(dbaccess/source/ui/app/AppIconControl.cxx) constexpr.  (And there might be more
such cases that could now be made constexpr.)

Change-Id: I0b4e3292faf8f6b901f9b9e934e1aa6bf0f583ff
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157862
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2023-10-12 18:17:49 +02:00
Adam Seskunas
b1b002c293 tdf#147021 use std::size instead of SAL_N_ELEMENTS
Change-Id: Ibc6c83f950890ac9b7a754cc49973736fa81dcb8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156364
Tested-by: Jenkins
Reviewed-by: Hossein <hossein@libreoffice.org>
2023-09-04 15:50:51 +02:00
Andreas Heinisch
421d4fc533 tdf#104487 - Function wizard: remember last used function category
Change-Id: I978dd63553e3528e7b9b853dbb438304f1f680cc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151565
Tested-by: Jenkins
Reviewed-by: Andreas Heinisch <andreas.heinisch@yahoo.de>
2023-05-09 17:39:05 +02:00
Adolfo Jayme Barrientos
feb2bec3c3 Formula W.: tdf#78826 colons tdf#150045 sec. labels
Change-Id: Ied39588884eed9d1602bac7e1bca9cf2dc7ac0c9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151319
Tested-by: Jenkins
Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2023-05-03 18:12:51 +02:00
Heiko Tietze
a21e151508 Resolves tdf#101876 - Resizing function wizard content
GtkPane added
Function entries expand now

Change-Id: I3f900540fadb530a8c154ec1bdf3771daecb7acb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151258
Tested-by: Jenkins
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2023-05-03 06:55:33 +02:00
Xisco Fauli
2d62a54d15 formula: fix crash in FormulaDlg_Impl::UpdateSelection
m_pFuncDesc can be nullptr

See https://crashreport.libreoffice.org/stats/signature/formula::FormulaDlg_Impl::UpdateSelection()

Change-Id: If8a95bef8b0a8a03ffe63041409ee7c1cf322b0f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150550
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2023-04-18 15:05:46 +02:00
Mike Kaganski
116b9d6ddf Avoid conversions between OUString and OString in VCL
Standardize on OUString, which is the main internal string class.
Convert from/to OUString only when communicating with respective
external APIs.

Removes about 200 conversions from the code.

Change-Id: I96ecee7c6fd271bb76639220e96d69d2964bed26
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/149930
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2023-04-02 18:46:47 +02:00
Szymon Kłos
ae71f11d28 jsdialog: enable function wizard
Change-Id: I534556e87cda3239bff51f1e7d83355922f8af7c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148245
Tested-by: Szymon Kłos <szymon.klos@collabora.com>
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/149327
Tested-by: Jenkins
2023-03-23 07:01:35 +00:00
Noel Grandin
c596fd59dc no need to allocate these separately
they are all one or two words in size

Change-Id: I86611e14a32dda3ae2226bbfa775ad0234513888
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148425
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-03-07 19:15:55 +00:00
Caolán McNamara
9a930ef9ea can use a reference instead of a pointer
Change-Id: I770983c2a46c2181db80243efa7c926e356d5e6c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147745
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2023-02-27 08:59:58 +00:00
Noel Grandin
bee4402c7e no need to hold SvtSysLocale by std::unique_ptr
allocate it inline, it is only one pointer in size

Change-Id: I736f3322784897054993fbddd423f36357f817c8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147741
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-02-26 19:50:19 +00:00
Eike Rathke
e7ce9bddad Obtain actual 0-parameter count for OR(), AND() and 1-parameter functions
OR and AND for legacy infix notation are classified as binary
operators but in fact are functions with parameter count. In case
no argument is supplied, GetByte() returns 0 and for that case the
implicit binary operator 2 parameters were wrongly assumed.
Similar for functions expecting 1 parameter, without argument 1
was assumed. For "real" unary and binary operators the compiler
already checks parameters. Omit OR and AND and 1-parameter
functions from this implicit assumption and return the actual 0
count.

Change-Id: Ie05398c112a98021ac2875cf7b6de994aee9d882
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147173
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Jenkins
2023-02-17 02:24:08 +00:00
Noel Grandin
085466ae72 osl::Mutex->std::mutex in OpCodeMapData
Change-Id: I0b92e2a94060549c39df7d08a6409518252fc757
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146970
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-02-14 08:59:16 +00:00
Eike Rathke
cf8cfee9d4 Resolves: tdf#151886 Use default locale with English function names again
Automatically switching to en-US locale when using English
function names caused too much confusion. There also might be the
possibility that the '.' dot decimal separator clashes with the
inline array column separator in some locales.

A proper solution would make this user-specified and if set also
adjust the separators to the common English ones. For now keep the
default locale again as it previously was the case.

Change-Id: Ic4712c6609c14f35cf0d1d842ac7443806a6e115
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144924
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Jenkins
2023-01-01 20:26:05 +00:00
Stéphane Guillou
826b1f36bd tdf#146781 sc: update extended tip for function description search
Change-Id: Ifa8f5c2be8e848e6fe2f9cf863d4a5a66787d2d8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144153
Tested-by: Jenkins
Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2022-12-20 15:26:17 +00:00
Eike Rathke
8e392437fd crashtesting: assert seen on loading forum-mso-en4-573860.xlsx
While resolving named expression Pinnacle3
IF(AND(Pinnacle1+Pinnacle2<>11,Pinnacle1+Pinnacle2<>22,Pinnacle1+Pinnacle2>9),SUM(MID(Pinnacle1+Pinnacle2,1,1),MID(Pinnacle1+Pinnacle2,2,1)),Pinnacle1+Pinnacle2)

where resolving and inserting named expressions Pinnacle1
IF(AND(SUM($Sheet1.$D$3:$E$3)<>11;SUM($Sheet1.$D$3:$E$3)<>22;SUM($Sheet1.$D$3:$E$3)>9);SUM(MID(SUM($Sheet1.$D$3:$E$3);1;1);MID(SUM($Sheet1.$D$3:$E$3);2;1));SUM($Sheet1.$D$3:$E$3))

and Pinnacle2
IF(AND(Logic1<>11;Logic1<>22;Logic1>9);SUM(MID(Logic1;1;1);MID(Logic1;2;1));Logic1)

with Logic1
IF($Sheet1.$E$3+NilaiTahun>10;SUM(MID($Sheet1.$E$3+NilaiTahun;1;1);MID($Sheet1.$E$3+NilaiTahun;2;1));$Sheet1.$E$3+NilaiTahun)

with NilaiTahun
IF(SUM(MID($Sheet1.$F$3;1;1);MID($Sheet1.$F$3;2;1);MID($Sheet1.$F$3;3;1);MID($Sheet1.$F$3;4;1))<10;SUM(MID($Sheet1.$F$3;1;1);MID($Sheet1.$F$3;2;1);MID($Sheet1.$F$3;3;1);MID($Sheet1.$F$3;4;1));SUM(MID(SUM(MID($Sheet1.$F$3;1;1);MID($Sheet1.$F$3;2;1);MID($Sheet1.$F$3;3;1);MID($Sheet1.$F$3;4;1));1;1);SUM(MID(SUM(MID($Sheet1.$F$3;1;1);MID($Sheet1.$F$3;2;1);MID($Sheet1.$F$3;3;1);MID($Sheet1.$F$3;4;1));2;1))))

overall exceeds FORMULA_MAXTOKENS (8192) in the generated RPN
code, hence an ocStop is encountered as factor token.

(this cries for generating subroutine call token arrays where each
named expression could have their own RPN code and interim results
could be remembered for each while interpreting within one formula
cell; just dreaming..).

Change-Id: I744c4915a00849b107c7c25d7029aa19d976aa86
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144048
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Jenkins
2022-12-15 23:21:52 +00:00
Stéphane Guillou
fde7a73e5f upgrade tag names with new version of glade
Change-Id: Idcbf12c72eea8f7c8b4c7e787eeb2719f29cc69a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144152
Tested-by: Jenkins
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-12-14 10:39:37 +00:00