summaryrefslogtreecommitdiff
path: root/svl
AgeCommit message (Collapse)AuthorFilesLines
2013-10-31Convert indexOf->startsWith and lastIndexOf->endsWithNoel Grandin1-1/+1
This is both an optimisation and a cleanup. This converts code like aStr.indexOf("XX") == 0 to aStr.startsWith("XX") and converts code like aStr.lastIndexOf("XXX") == aStr.getLength() - 3 to aStr.endsWith("XXX") Note that in general aStr.lastIndexOf("X") == aStr.getLength() - 1 converts to aStr.isEmpty() || aStr.endsWith("X") so I used the surrounding context to determine if aStr could be empty when modifying the code. Change-Id: I22cb8ca7c2a4d0288b001f72adb27fd63af87669
2013-10-28fixincludeguards.sh: svlThomas Arnhold14-35/+36
Change-Id: I70ef44216fb7ddb4e12b9d90406b45cc594279f0
2013-10-25stop looking for Jar files in solverMichael Stahl1-0/+1
Change-Id: I4d2a93fa7395354fbf2893df9e254ab39fa365af
2013-10-25fdo#54938: More uses of cppu::supportsServiceMarcos Paulo de Souza1-7/+2
Change-Id: Id6bed78d92eba52283a17ab3ca66e751c225e48d Reviewed-on: https://gerrit.libreoffice.org/6423 Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>
2013-10-23clean up places accessing the NULL at the of an OUStringNoel Grandin1-2/+2
There were only a couple of real bugs fixed, but we're a little bit safer now. This also fixes the assert and the comment in OUString::operator[] about this. Change-Id: Ibe16b5794e0ba7ecd345fa0801586d25b015974c
2013-10-23clean up some include guardsThomas Arnhold1-2/+2
Conflicts: sw/source/ui/inc/content.hxx Change-Id: I58d81881271fc6e3320bf3b5f1321594b28614a6 Reviewed-on: https://gerrit.libreoffice.org/6388 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2013-10-23convert code to use OUString::endsWithNoel Grandin3-7/+7
Convert places that call aStr[aStr.getLength()-1] == 'x' to use the shorter form aStr.endsWith("x") Change-Id: I1b3a19c0e89b8989cdbeed440f95fc76f9a4b6b6
2013-10-22Bin comments that claim to say why some header is includedTor Lillqvist3-3/+3
They are practically always useless, often misleading or obsolete. Change-Id: I2d32182a31349c9fb3b982498fd22d93e84c0c0c
2013-10-20drop unnecessary tools/string includesCaolán McNamara1-1/+1
Change-Id: I4278999b9b7d184c26036bbe9e3b98420f461e8c
2013-10-18some GetTokens hidden in windows only codeCaolán McNamara1-5/+5
Change-Id: I45da175fe0f72996b26d66c29e0e6a1b4115b896
2013-10-17fdo#54938: Adapt svtools and comphelper module ...Marcos Paulo de Souza1-7/+2
to use cppu::supportsService and other pieces. Change-Id: I16893b3d31a8055acd214ff23d01e63d38fe0826 Signed-off-by: Stephan Bergmann <sbergman@redhat.com>
2013-10-12Simplify and avoid use of UNXTor Lillqvist1-15/+7
Change-Id: Ia1f718341858de57d0e417d079981d91968f912b
2013-10-11Compare by pointers first.Kohei Yoshida1-0/+3
Change-Id: Iec697f7100c06da37158e564ac64f0248f923638
2013-10-11Fix equality operator for SharedString & write test for it.Kohei Yoshida2-7/+19
Change-Id: Ib592ca2fe359293da6c10aa9e1535a91627cfc43
2013-10-11Formula tokens, formula cells and formula interpreters to use shared strings.Kohei Yoshida1-0/+9
Change-Id: I5da99869fc7f61ce698180fa5daa9be9db9ac132
2013-10-11Import shared formulas from xlsx without crashing.Kohei Yoshida1-0/+5
The key here is to only use the shared formula ID's and ignore the ref range. The ref ranges are not correct half the time. Change-Id: If65f9b1b44ab6239db37977b6dfe3f822a9cf67e
2013-10-11Add isEmpty() to SharedString. This simplies a lot of its call sites.Kohei Yoshida1-0/+5
Change-Id: I0ebc43abe59ac317c053a4f606dbe376d85c03b0
2013-10-08No more getIdentifier*() calls because they are not efficient.Kohei Yoshida2-22/+10
They shall never be used. Change-Id: I019c88b1511a67175d782777cd41e0ec0434f497
2013-10-08Store svl::SharedString in document cell storage instead of OUString.Kohei Yoshida1-0/+10
With this, both ScColumn and ScMatrix store svl::SharedString as their string values, instead of OUString. Change-Id: I3faece94d98f774881fd72b3ed5f6143504cd350
2013-10-08ContentInfo to store svl::SharedString instead of OUString.Kohei Yoshida1-0/+17
Change-Id: I633e3bb633317eeb61cd804faf20e79312f569f7
2013-10-08Re-implement interning in order to return both string arrays.Kohei Yoshida4-55/+134
One is for the cased string and the other one for the non-cased one. Change-Id: I798687f2efecaaea73a09e0b3348f85a9d9e8c07
2013-10-05This DEBUG_UNIT_TEST stuff is unusedTor Lillqvist1-11/+0
Change-Id: I947713bda2c37e22199161a2c59e5d9ed00b37a2
2013-10-05unused function 'operator<<'Tor Lillqvist1-7/+0
Change-Id: I05d3877e2b0cb4bfccd3a2ae6f24abfd6507c46d
2013-10-04Rename StringPool to SharedStringPool because that's what it is.Kohei Yoshida3-14/+14
Change-Id: I2fc3ce4f0c2291d402cb470346d5561373fb51e7
2013-10-04Let's just use sal_uIntPtr straight.Kohei Yoshida2-6/+6
So that the user of this class won't have to include the header just to get the string ID type. Change-Id: I0ccbc18fe02644f69701f57b0b1b9c30fd141d83
2013-10-04A little more test on shared string pool's life cycle management.Kohei Yoshida1-0/+44
Change-Id: Ic676dd875c27ce60a0707903d7f22207764829e0
2013-10-04No need to intern strings here; all OUString's are ref-counted.Kohei Yoshida2-2/+2
Calling intern() simply moves it to a global hash storage. Now the test passes. Change-Id: I0a93420abce1c3adaaa61d469dff5f359dd5ada4
2013-10-04Add purge() method to purge unreferenced strings from the pool.Kohei Yoshida2-1/+75
But this code needs more work. Change-Id: I538eebf5eb1738a2cfeebc22052b3d5db6001b6b
2013-10-04The map actualy needs to store OUString to have it ref-counted automatically.Kohei Yoshida1-3/+2
Change-Id: Iff6fcf3aba73f2d06ac0c885b39e69ac0febc49f
2013-10-04Correct way to get case-insensitive string identifiers.Kohei Yoshida2-5/+15
Change-Id: Ia343165941231fab34c4904b7a2fa10b07fa32bb
2013-10-04Let's not expose the internal pointer. Define different ID type.Kohei Yoshida2-23/+26
To prevent the string ID's from being used to instantiate string objects, which can mess up shared string object's life cycles. Change-Id: Ibcd9a4fa9f591d5c27a9e1b50bc9f83ae230e86a
2013-10-04Write some rudimentary tests for the new shared string pool class.Kohei Yoshida2-1/+51
Change-Id: Ie66de46d69f664839aa0a2d056cd3b8df4d4989b
2013-10-04Establish mapping between original strings and upper strings.Kohei Yoshida1-5/+46
This will be used to retrieve case insensitive string identifiers later. Change-Id: Ia34f57d0e8d0cb6bd4630f8d110853ed049770b5
2013-10-04Move this string pool code to svl.Kohei Yoshida2-0/+36
Change-Id: I1379fbc377607be8831133d64db2e14f8c75bff8
2013-10-03SfxStyleSheetBase::SetFollow: OSL_FAIL -> SAL_WARNMiklos Vajna1-1/+1
Change-Id: I9fb67a1b7ccd4c8fbc17274902a16d8c0b13d598
2013-10-02WaE: unused variableTor Lillqvist1-2/+0
Change-Id: Ieed1b52624afa8fc36fadb54d3209a3482416068
2013-10-02bWeiter -> bContinuePhilipp Riemer1-10/+10
Change-Id: Ia0bba3c1610dce5d364fb584f04e0b66cc41fb20 Reviewed-on: https://gerrit.libreoffice.org/6077 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2013-10-02-Werror,-Wunused-const-variableStephan Bergmann1-1/+0
Change-Id: I53dafdb4d23a7a2773a6f63e84f36be191d9f261
2013-10-02-Werror,-Wunused-const-variableStephan Bergmann1-59/+0
Change-Id: I6a772c5ba8df071caa88bfef4a1e9f114c26a369
2013-10-01desktop: stop replacing %PRODUCTNAME %PRODUCTXMLFILEFORMATVERSIONMichael Stahl1-8/+8
... and %PRODUCTXMLFILEFORMATNAME at runtime and hard-code OpenOffice.org 1.0 for these too. Change-Id: Id96390506d2a0f367f932e85d3115362ad483bc3
2013-09-30Introduce ASCII case conversion and use more/rtl/character.hxx.Arnaud Versini2-4/+4
Also remove all others implementations. Change-Id: I1dc108a9103f087bd8ce591dff2ac5dd254746f8 Signed-off-by: Stephan Bergmann <sbergman@redhat.com>
2013-09-26Missing #includeStephan Bergmann1-0/+1
Change-Id: I2af468933b1e9bdad1c6da1f881daaf068b6bec0
2013-09-25Related: fdo#38838 remove UniString::EqualsIgnoreCaseAsciiCaolán McNamara5-18/+13
Change-Id: Ib5c3a2daa4a48bc286b14fa2cebb3306ea0012bc
2013-09-23fdo#54686 Treat hard blank as soft blank in numberLaurent Balland-Poirier1-1/+3
AutoCorrect option "Add non-breaking space in French..." insert non-breaking space (hard blank) and avoid recognition of percent number and time number. This patch treats hard blanks as soft blank in number format recognition Rev.#1: change #define to const variable. Same change in svxaccor Rev.#2: improvements Change-Id: I30c2c36778cb53a0238a0829043dad4d709f97d2 Reviewed-on: https://gerrit.libreoffice.org/6015 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Eike Rathke <erack@redhat.com>
2013-09-19Sprinkle more boost_headers loveTor Lillqvist1-0/+2
Fix compilation errors when not using system boost. Might be more. It's sad that one has to micro-manage boost use like this. Change-Id: I3541789530fbdb0fb03e2b355144e63f8b031097
2013-09-04remove filerec.hxx inclusion where not neededPhilipp Riemer1-1/+0
Change-Id: Ia5a65cb53580ed1ed7535a787f4f762da5a43d43 Reviewed-on: https://gerrit.libreoffice.org/5792 Reviewed-by: David Tardon <dtardon@redhat.com> Tested-by: David Tardon <dtardon@redhat.com>
2013-09-03was convertIsoStringToLanguage(), use convertToLanguageTypeWithFallback()Eike Rathke1-1/+1
Change-Id: Ib45634b0baad4ef4c6754b13cee6d92c2bc504f8
2013-08-27These shall apparently check for URL scheme prefix matchStephan Bergmann1-2/+2
...they had originally been aURL.equalsIgnoreAsciiCaseAsciiL( "vnd.sun.star.pkg", 16 ) etc., so where likely confused with the OUString compareTo functions that take a maxLength argument. Change-Id: Ie12df4f589dda310b7e49eb93535ad797f88a8a7
2013-08-22Mark as constTakeshi Abe1-1/+1
Change-Id: I65a05b59da6dbc2d37a55129c54ca0f322702364
2013-08-21finish deprecation of O(U)String::valueOf()Luboš Luňák7-27/+27
Compiler plugin to replace with matching number(), boolean() or OUString ctor, ran it, few manual tweaks, mark as really deprecated. Change-Id: I4a79bdbcf4c460d21e73b635d2bd3725c22876b2