Commit Graph

135 Commits

Author SHA1 Message Date
a29d20932c add initial version of WEBSERVICE function
Change-Id: I8a835278c0d1b8f3a463aa5765b145410605aba4
2013-06-16 16:07:37 +02:00
3b9620e18b inital work on FILTERXML function
Change-Id: Ifb884a52b275df818812f8be6cd7650dcb97849d
2013-06-16 15:59:06 +02:00
0946de1e2f Resolves: #i121120 Support RightB(), LeftB(), LenB() and MidB()
Patch by: Zhang Lu
Review by: Wang Lei

(cherry picked from commit 424079cb8348d77e40f7d3291578bdffbe662f34)

Conflicts:
	formula/inc/formula/compiler.hrc
	formula/inc/formula/opcode.hxx
	oox/source/xls/formulabase.cxx
	sc/inc/helpids.h
	sc/util/hidother.src
	sc/util/makefile.mk

Change-Id: Ia04aa69aa2764842507b36ba7cc8c99e99a314e9
2013-06-11 12:30:10 +01:00
e38d20c1e1 Handle range references for group calculation. This is still untested.
Change-Id: I1eb1c217db66615028faa85720838579056dc150
2013-04-30 13:10:44 -04:00
dfc3f290b5 Let's not use VectorArray struct. There is no use for it.
Change-Id: Ic011143206c13fcbc1b3403bf5b7df46c6934899
2013-04-30 13:10:43 -04:00
ee289aaf45 Let's not forget to check this in...
Curse the sc / formula split...

Change-Id: Ib8d17ba63d05eb4df7e6918e0034d91dd82869e3
2013-04-30 13:10:42 -04:00
20d4db0fe3 Add method to allow fetching of double array, and store it in token.
Change-Id: If094dbf139e18ad23c73d6cf5a78ac4844132b14
2013-04-30 13:10:41 -04:00
7fb73a8475 Initial cut on vector formula ref tokens. Not used yet.
Change-Id: I4b28c269759bc01bfc94cfdd6a1c651d03d829c7
2013-04-30 13:10:41 -04:00
1946794ae0 mass removal of rtl:: prefixes for O(U)String*
Modules sal, salhelper, cppu, cppuhelper, codemaker (selectively) and odk
have kept them, in order not to break external API (the automatic using declaration
is LO-internal).

Change-Id: I588fc9e0c45b914f824f91c0376980621d730f09
2013-04-07 14:23:11 +02:00
5be14df244 ResMgr with LanguageTag
Change-Id: Ie5ce9157a7ea59db7b0509fbaec61d07f8f9edf0
2013-03-29 14:09:01 +01:00
292ffa80bc First cut on checking the token array on whether we could do vectorization.
Not tested yet.

Change-Id: I87f8a8595229d8d8e83526dc0334891d253cf2c7
2013-03-19 13:40:24 -04:00
3a09e0078a Use initializer in ctor.
Change-Id: I2721c083e26654f5ce5cc636d652cb4d50a158ad
2013-03-19 13:40:24 -04:00
0a0deec6f1 Fix indentation.
Change-Id: Ia277ac4e9eeb34a2b0244ebb5f09c428f5cf2b64
2013-03-19 13:40:24 -04:00
198a722974 Move GetHash() from FormulaTokenArray to ScTokenArray.
To allow access to reference tokens.

Change-Id: I3e2d2653722005c04b6d26e1a4ddfce0a459ef37
2013-03-19 13:40:23 -04:00
6433ab29af Implement (partially?) and test formula token array hash function.
For now, we don't factor in any differences in reference tokens in the
generated hash values.

Change-Id: Ie9836228eaad9c74edd884c3e8c4b273979760fd
2013-03-19 13:40:22 -04:00
fa81354d0e Skeleton for generating a hash value from an array of token.
To be implemented...

Change-Id: I4704f06b50dcc9dd5e1af9c3531ecd498015811c
2013-03-19 13:40:21 -04:00
8b27d78b4a automated removal of RTL_CONSTASCII_USTRINGPARAM for quoted OUStrings
Done with a perl regex:

s/OUString\s*\(\s*RTL_CONSTASCII_USTRINGPARAM\s*\((\s*"[^")]*?"\s*)\)\s*\)/OUString\($1\)/gms

Change-Id: Idf28320817cdcbea6d0f7ec06a9bf51bd2c3b3ec
Reviewed-on: https://gerrit.libreoffice.org/2832
Reviewed-by: Thomas Arnhold <thomas@arnhold.org>
Tested-by: Thomas Arnhold <thomas@arnhold.org>
2013-03-19 09:00:26 +00:00
a0296296fb fdo#60691 add modelines to *.src and *.hrc files
use solenv/bin/add-modulelines script for the task
and remove all UTF bom from *.src and *.hrc files

svx/source/dialog/hdft.src

Change-Id: I745d4f0fe9b05436a142a03f8512970f91c41bd4
2013-03-08 21:02:26 +00:00
a11f944b4c ocMacro and ocExternal need to be recalculated on load, fdo#60977
Change-Id: I9e69ca2feae44bc645e8a49e349557f0933a23eb
2013-02-25 08:16:31 +01:00
61c72ef4be ocColumn and ocRow do not need recalc on load, fdo#60645 related
Change-Id: I34fc7af10aca3484d30b443c6b0257451a218ed5
2013-02-15 14:16:14 +01:00
a60712be0e renamed SetRecalcMode...() to SetExclusiveRecalcMode...()
To emphasize exclusiveness of the four basic recalc modes renamed the
corresponding methods.

Change-Id: If6f99d2c84e4a042a3a3e3640cf416d306a2d0c5
2013-02-15 13:57:27 +01:00
ff319d0526 use AddRecalcMode(RECALCMODE_ONLOAD), fdo#60645 related
Instead of SetRecalcModeOnLoad() which sets the exclusive bit overriding
RECALCMODE_ALWAYS use AddRecalcMode() that handles these cases.

Change-Id: Ieeeff67d4dda1493e8c48f231b870513f655839a
2013-02-15 13:57:27 +01:00
9c55eab030 CELL needs to be recalculated during import as well, fdo#60645
Change-Id: If981199f01d4b33270d82c65fb033fa51222fb62
2013-02-14 21:50:27 +01:00
df931a5b0f fdo#60322 add calc function SKEWP as in ODFF v1.2
Change-Id: I4851df1473fc7788af1ac642bb0fb527ec872821
Reviewed-on: https://gerrit.libreoffice.org/2020
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Eike Rathke <erack@redhat.com>
2013-02-08 09:50:20 +00:00
63e3d8671e make it possible to update DDE links after loading, fdo#59032
Change-Id: Iba49bec62cb9081cdcd9410215f269b59c1be304
2013-01-30 22:10:05 +01:00
8f9cb3dddd ODFF: write RRI as RRI, not ZGZ
ODF OpenFormula defines the function RRI, the legacy OOo XML format
stored that as ZGZ but that was not changed for the ODFF implementation.
Correctly read/write RRI now but still accept ZGZ to be able to load
existing documents.

See also
http://docs.oasis-open.org/office/v1.2/cs01/OpenDocument-v1.2-cs01-part2.html#RRI

Change-Id: I617eaa37ff483e9a02a218e8432ba918f54bd61a
2013-01-30 01:49:31 +01:00
0dce7abb56 fdo#56124 IFERROR IFNA Excel import/export
Change-Id: I796e99f8893cb48fa2351f7799bb247a3488ce69
2013-01-12 17:31:29 +01:00
3201c72db7 fdo#56124 IFERROR IFNA function names were swapped
Change-Id: I3d13ab04b126a3268352df93a7ed4a35d7a085f2
2013-01-11 21:49:07 +01:00
3914d00c32 fdo#56124 changes to "add functions IFERROR and IFNA"
* reimplemented actual ScIfError() function for matrix cases and simpler
  pop/push of non-error values
* various smaller adaptions, see also inline comments of
  https://gerrit.libreoffice.org/1522

Change-Id: I80a8235a2cbb548c0ef993862e76741af46e30d2
2013-01-11 17:01:44 +01:00
5fd9feafa5 fdo#56124 add functions IFERROR and IFNA to calc as in ODFF1.2
Change-Id: I6403b51ac8c710ad3b8d2625e1482971f50e6b1d
2013-01-11 17:01:23 +01:00
b6fbc86429 fdo#58539: Correctly set cached matrix formula result.
During the import, a cached matrix value only has an empty matrix
of correct geometry, plus the token type of the top-left cell.  The
rest of the elements are imported as hybrid values.  For now, this
seems to do the trick.

In the future we may want to change it to fully populate the matrix
cache value during the import, and skip setting the hybrid values for
the non-top-left elements.

This commit also make several other trivial changes:

* Mark pRawToken mutable so that we can mark those IsFoo() methods
  const.

* Move the ScCompiler instance from static instance to member of
  ScXMLImport. Since we don't need the instance to persist once the
  import is over, this is more appropriate.

Change-Id: I1abde03c0fcd91b02ef4dbf8b5526f7965eaf19c
2013-01-09 11:29:50 -05:00
2a8470dca4 tabs to spaces
Change-Id: Id832383518af0dd77e401e40512a890265b5d83e
2012-12-15 21:42:41 +01:00
07df025a73 calcishmakkica: #i114428# merge some XOR related code
Merged from Apache OO with adaptions, parts of
http://svn.apache.org/viewvc?rev=1381446&view=rev
Original Apache OO committer: Andrew Rist <arist@apache.org>

Original Author: Marina Plakalovic <makkica@openoffice.org>
Original Committer: Eike Rathke [er] <eike.rathke@oracle.com>

 # HG changeset patch
 # User Eike Rathke [er] <eike.rathke@oracle.com>
 # Date 1284060031 -7200
 # Node ID 528da6bfd0daed4355d745590d5ac3a319b08fb4
 # Parent  237cb91dd986ff11eb100cc631206cda102e91f7

Change-Id: If456792f23429a80582a48b022d268e6179316a1
2012-12-15 21:42:40 +01:00
f2cb873631 calcishmakkica: #i90269# #i95144# #i101466# implement SUMIFS, AVERAGEIFS, COUNTIFS
Merged from Apache OO with adaptions.
http://svn.apache.org/viewvc?rev=1381447&view=rev
Original Apache OO committer: Andrew Rist <arist@apache.org>

Original Author: Marina Plakalovic <makkica@openoffice.org>
Original Committer: Eike Rathke [er] <eike.rathke@oracle.com>

 # HG changeset patch
 # User Eike Rathke [er] <eike.rathke@oracle.com>
 # Date 1288810126 -3600
 # Node ID 02cf226fcde498f6fd926d45df497e9fb412fe0f
 # Parent  528da6bfd0daed4355d745590d5ac3a319b08fb4

Change-Id: I08754653cd2ff20536ad3e9f260f747cb127ccdd
2012-12-15 21:42:39 +01:00
fff5031898 calcishmakkica: #i101466# implement AVERAGEIF
Merged from Apache OO with adaptions.
http://svn.apache.org/viewvc?rev=1381445&view=rev
Original Apache OO committer: Andrew Rist <arist@apache.org>

Original Author: Marina Plakalovic <makkica@openoffice.org>
Original Author: Eike Rathke [er] <eike.rathke@oracle.com>
Original Committer: Eike Rathke [er] <eike.rathke@oracle.com>

slightly reworked patch by <makkica>

 # HG changeset patch
 # User Eike Rathke [er] <eike.rathke@oracle.com>
 # Date 1284055400 -7200
 # Node ID 237cb91dd986ff11eb100cc631206cda102e91f7
 # Parent  1c32319bb02fdf173de6a609fca9f2e9c9f4c73a

Change-Id: Id168462272dc8d618513319ebab41fde5c728b08
2012-12-15 21:42:39 +01:00
a67906259a fdo#58149: Recalculate HYPERLINK formula cells on load.
The current implementation of HYPERLINK relies on its result being
1x2 matrix while only the first element is displayed visibly.  The
second element stores the URL which is only used when querying for
the URL (tooltip or launch URL event).

Starting with 4.0 we load cached formula results to avoid full
recalculation on load.  That unfortuntely ended up breaking the
HYPERLINK because the result was a simple string value rather than
a matrix; hence the need to recalculate it on load.

But unlike volatile formula cells, cells with HYPERLINK don't need
to be recalculated on every cell input change; only once when the file
is loaded.

P.S. This commit also reverses the logic of bNoProgressBar flag for
CalcFormulaTree(), to make it easier for human brain to process what
it means.

Change-Id: I7a24d96d225910b88071a8fe6320f59bf7a47163
2012-12-11 15:55:58 -05:00
9955dbebbd AllSettings with LanguageTag
Change-Id: I710ae66e51139662eb442b681fdf9cc9d158551d
2012-11-22 12:34:59 +01:00
4e0b79b546 Remove unused method in formula module
Change-Id: I67259c5a3894be406b2d38900368a3f8aac86921
Signed-off-by: Marcos Paulo de Souza <marcos.souza.org@gmail.com>
2012-11-01 14:22:03 +00:00
0bb0937b65 do not silently ignore a token API error, fdo#51926 related
Change-Id: Ie187dad84bd55bb76c795b5c4807566e80349b56
2012-08-27 22:03:49 +02:00
0ba9114c12 prefix more components
Change-Id: I9bf304a791b62f6b96711eb058f302cadfdb276a
2012-08-25 12:45:35 +02:00
889de665ec Typo ressource -> resource
Change-Id: Id13e7acfbe34eca5e124c9032d36d6f158bfb831
2012-07-30 09:26:00 +02:00
acf134e198 -Werror,-Wshadow (Clang 3.1)
...where a local variable in a nested class shadows a member of an outer class.
Fixed by renaming the relevant outer class members as "m..."

Change-Id: I6caa33914ff1060e08f66eadde879fb7b4e3e7cc
2012-07-23 10:47:05 +02:00
104261010a some UniString->rtl::OUString
Change-Id: Ie69b30094da25df23a36baca2c7723d6a41f48c3
2012-07-09 12:16:56 +01:00
bccf34c19a ditch String::CreateFromAscii
Change-Id: I2b482bd323ac510629c5ee31868010b7cd6ce691
2012-07-03 21:24:35 +01:00
4a29e35a9a re-base on ALv2 code. 2012-06-28 19:59:05 +01:00
ee1c5c4768 Reduce newline bloat at eof
Change-Id: I494ceee07d6825f9466cab810742d7f85291fe14
2012-06-27 13:32:28 +02:00
b6db3e3acc re-base on ALv2 code.
Change-Id: Ice06e639213aeb6f7f23cbf4634947dd25613db1
2012-06-21 13:11:06 +01:00
06e2005ed8 convert LocaleDataWrapper to OUString
Change-Id: Icb5f5adf9139d1c0f0e86d8128ea6742ce20b138
2012-06-18 15:13:51 +01:00
6191fa0847 reduce use of UniString ctor from null-terminated unicodearray
Change-Id: I98361309ada084d8f78517ce88f210d785f59cc0
2012-06-13 11:20:23 +01:00
033cce3e0f fdo#50822 add function XOR to calc as in ODFF1.2
Change-Id: I994119c0520658775d07f776237d31a03f53ab52
2012-06-12 22:30:00 +02:00