Commit Graph

342 Commits

Author SHA1 Message Date
be8d4a5d8a -fsanitize=function
Change-Id: I29d648c45471e6d3503922ff00f7cd6491bb88f3
2014-07-02 16:10:39 +02:00
712d60f03d fdo#79372, fdo#56392 fix hyphenation
Change-Id: Iacf84d023d3b4795892bc444299a29bfc663345e
2014-07-01 00:18:13 +02:00
c78d948b61 Revert "fdo#79372 fix hyphenation (remove fdo#56392 fix, except hard hyphen part)"
This reverts commit 259d3421d4cf7788d9099daa40fc181c661783ee.
2014-07-01 00:15:11 +02:00
259d3421d4 fdo#79372 fix hyphenation (remove fdo#56392 fix, except hard hyphen part)
Change-Id: Ia2f482fb7737e61cfc42966dbc7af6e1cdb3b41d
2014-05-29 09:14:06 +02:00
3c1e30b77d Correct common misspellings, and remove some ASCII art along the way.
Change-Id: I42787db31769e8bde984c5f4f0aa90335e889b1c
Reviewed-on: https://gerrit.libreoffice.org/9356
Reviewed-by: Thomas Arnhold <thomas@arnhold.org>
Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org>
2014-05-17 12:38:38 +00:00
6e225b41f1 Resolves: fdo#55707 Word count incorrect if language is set to Finnish
Change-Id: I283dddaa4bd8baf05b90ce5f81d43b785021a3c4
2014-05-12 17:08:24 +01:00
f1570322af Fix compilation breakage for Android
Presumably helps for iOS, too.

Change-Id: Idadfa9c70b8206c6820f6c13374909f8d26ffd04
2014-05-12 13:21:57 +03:00
69a74afb07 Avoid expensive dlopen thrash for break iterators.
Change-Id: I770c1b3e5164cb486b5a5c2b1259f713914a1bae
2014-05-12 10:56:33 +01:00
e4f690b038 i18npool: sal_Bool->bool
Change-Id: Id73ee64dbf8586743f0e436e004e663a65d4548f
2014-04-23 11:11:47 +02:00
bb2f13b473 Avoid cargo cult rites
Change-Id: I39fee26048d5b4ddb03217309b7117bef9ec4cd8
2014-04-23 09:33:42 +03:00
0b6fb1f45a Put the dict_ja and _zh data in files instead of code for iOS
Map the file(s) into memory on demand. The executable file of an app
needs to be as small as possible. Including additional data files in
an app bundle is fine.

Change-Id: Ife9bfe99a2cf0473d459f38f50dfa3304b39e282
2014-04-14 17:21:19 +03:00
c67cc960ce coverity#704236 Logically dead code
the nStartPos > 0 check is inside a nStartPos == 0 block
so it can't happen so we'll return immediately, and so
there's no point changing numberOfChange in that case
either there

Change-Id: Id6d7fc31033de5c6f3bb0a9ed03234b58c0d509e
2014-03-11 13:53:25 +00:00
5e21a413c7 cppuhelper: retrofit std::exception into overriding exception specs
Change-Id: I56e32131b7991ee9948ce46765632eb823d463b3
2014-02-26 18:22:20 +01:00
2a42d5ec29 Remove visual noise from i18npool
Change-Id: I1cd4254713ce9c1bc7c232414c24e926f1f8a653
Reviewed-on: https://gerrit.libreoffice.org/8269
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-02-26 09:23:26 -06:00
313ea4b2c3 coverity#984096 Uninitialized scalar field
Change-Id: If67e1c48fba43fabcaffef92d96bc1377b4d1dd8
2014-02-18 02:55:13 -06:00
a4f17c00b1 i18npool: Constructor feature for few more implementations.
Change-Id: I018bbe39a30582f51cdd620b3bf3240456b7bd65
2014-01-27 08:42:54 +01:00
564c0aa657 i18npool: Ctor feature for few general services.
Change-Id: I1d489cacaf4717ab395b22a92e6dd6645cb92b1c
2014-01-27 08:42:53 +01:00
ca2888fd9e Use proper bool operations
Change-Id: I674ee59803fa5a1987787cf98f369dee63729adf
2014-01-10 17:11:45 +01:00
d8fd158759 fdo#72219: Fix for corruption of symbols in docx
Issue:
OUString uses UTF-16, so for a Unicode surrogate character there are 2
values stored, not just 1.
So we are getting assert failure in "rtl_uString_iterateCodePoints" method.

erAck: Underlying cause was that the dictionary breakiterator misused UTF-16 positions as Unicode code point positions.

Change-Id: I923485f56c2d879b63687adaea2b489a3479991c
Reviewed-on: https://gerrit.libreoffice.org/6955
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Eike Rathke <erack@redhat.com>
2014-01-08 19:38:45 +00:00
6cd3118b63 fdo#54938: Convert i18npool to use cppu::supportsService
Change-Id: I9acc496cd95c8362972fa0c41d35b77fc0715aba
Signed-off-by: Stephan Bergmann <sbergman@redhat.com>
2013-12-18 10:17:14 +01:00
108eee306e Related: rhbz#1040291 Change language name from 'Oriya' to 'Odia'
Except for our external api where the Oriya is stuck (and similar for
the vba implementation)

Change-Id: I8288c930567385eea49a4c303727b13ef8b8a89f
2013-12-11 15:11:18 +00:00
f24fa8efad Add Lao breakiterator support for selecting and counting Lao words.
Change-Id: I6da721dc25394dfee12e3028aefbf0546d1be984
Reviewed-on: https://gerrit.libreoffice.org/6669
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2013-11-13 16:25:58 +00:00
fcd1637d51 convert OUString compareToAscii == 0 to equalsAscii
Convert code like
   aStr.compareToAscii("XXX") == 0
to
  aStr.equalsAscii("XXX")
which is both easier to read and faster.

Change-Id: I448abf58f2fa0e7715dba53f8e8825ca0587c83f
2013-11-11 12:58:13 +02:00
ef90021abe convert OUString !compareToAscii to equalsAscii
Convert code like
   if( ! aStr.compareToAscii("XXX") )
to
   if( aStr.equalsAscii("XXX") )
which is both clearer and faster.

Change-Id: I267511bccab52f5225b291acbfa4e388b5a5302b
2013-11-11 12:58:12 +02:00
16c31e90f7 don't access string out of bounds
Change-Id: I562fbdb9eec3af297ea95a0d161721ec345e6a19
2013-11-06 09:12:36 +00:00
e629b148af Fix indentation
Change-Id: I2bef2334392dba63f86b24917a50bf1eb0df98dc
2013-10-28 20:06:50 +02:00
b2ad9eecf1 Do not access nextCellIndex (nor Text) past the end
At least for Winfried CppunitTest_sd_import_tests aborts with triggering the
assert in OUString::operator[] at (presumably past-the-end) index 18 from

com::sun::i18n::BreakIterator_th::makeIndex (this=0x2b775adf9440,
  Text=..., nStartPos=18) at
  i18npool/source/breakiterator/breakiterator_th.cxx:122
com::sun::i18n::BreakIterator_CTL::previousCharacters
  (this=0x2b775adf9440, Text=..., nStartPos=18,
  rLocale=..., nCharacterIteratorMode=1, nCount=1, nDone=@0x7fff9a84a8fc: 0) at
  i18npool/source/breakiterator/breakiterator_ctl.cxx:62
com::sun::i18n::BreakIteratorImpl::previousCharacters
  (this=0x2b775ae00a98, Text=..., nStartPos=18, rLocale=...,
  nCharacterIteratorMode=1, nCount=1, nDone=@0x7fff9a84a8fc: 0) at
  i18npool/source/breakiterator/breakiteratorImpl.cxx:65
ServerFontLayout::setNeedFallback (this=0xfba5d0, rArgs=..., nCharPos=17,
  bRightToLeft=false) at vcl/generic/glyphs/gcach_layout.cxx:114
HbLayoutEngine::layout (this=0xfba670, rLayout=..., rArgs=...) at
  vcl/generic/glyphs/gcach_layout.cxx:437
...

and from the preceding if block in BreakIterator_th::makeIndex it indeed looks
like the invariant is that nextCellIndex need not be larger than cellIndexSize
which needs not be larger than Text (ake cachedText) getLength().

Change-Id: Ib92a76020b2bb3902c5e58aa2e6c4e679e51b94a
2013-10-28 18:11:46 +01:00
a7724966ab Bin comments that claim to say why some header is included
They are practically always useless, often misleading or obsolete.

Change-Id: I2d32182a31349c9fb3b982498fd22d93e84c0c0c
2013-10-22 16:56:28 +03:00
634f1d11d2 fdo#56392 fix hyph. of words with single punctuation marks
Change-Id: I0a24fb53c2ff48c26b1c97b9a4768c3a725cd686
2013-09-26 12:22:53 +02:00
968f4d72a2 fdo#56392 fix hyphenation of words with punctuation
Change-Id: I17e094fa93a7ba6a554f4bc2dfd353f718f1a500
Reviewed-on: https://gerrit.libreoffice.org/6040
Reviewed-by: Németh László <nemeth@numbertext.org>
Tested-by: Németh László <nemeth@numbertext.org>
2013-09-26 08:33:39 +00:00
6ea6a422fb s/wiki.services.openoffice.org/wiki.openoffice.org/g
Change-Id: I059fbee385a109069c70f3869021c8e2ee48fee1
2013-09-07 14:21:22 +02:00
660fe83b43 use sensible indentation
that always annoyed me

Change-Id: I0c439ddb00d78590b465cd47db6e60d1939bd9f7
2013-09-05 14:57:29 +02:00
58eac0df5f renamed LocaleData to LocaleDataImpl to prevent confusion
... between com::sun::i18n::LocaleData of
com/sun/star/i18n/LocaleData.hpp and i18npool/inc/localedata.hxx

Change-Id: Id23f67c1e3a654fd4f2886029ee45fcc1f466879
2013-09-05 14:57:27 +02:00
57931a7cf7 Mark as const
Change-Id: Ib78b25641ae20a3eb23545649f08b963e34c74ff
2013-07-29 17:39:30 +09:00
462df4920e Fix indentation
Change-Id: I33c9f4390c493fcc89bcd42529c026a9a76fb697
2013-06-22 12:17:29 +02:00
38cbae190d Fix indentation
Change-Id: I67224a03f7de2db6cab220b9491a6f949ad89def
2013-06-22 11:06:17 +02:00
baf8f02b00 mismatched new[]/delete
Change-Id: I0bfa3c090c436c0397ead80f2759ab7335f3aa0f
2013-06-05 17:45:49 +01:00
878b09a1a9 fdo#64926 use icu's breakiterator for Tibetan and Dzongkha
Change-Id: I78010e216eb1582fa5074666f36c95f5b0eceee5
Reviewed-on: https://gerrit.libreoffice.org/4082
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2013-05-31 09:57:22 +00:00
cb6d67c21f Spelling "separate" (etc) correctly is hard 2013-05-15 11:14:28 +03:00
3ca2240e48 use LanguageTagIcu
Change-Id: I3ced460cc5a03554dc77e19381af8a5ba202d2ab
2013-04-25 00:01:07 +02: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
9a063f939b i18npool: cleanup macros
This is the last one :)

Change-Id: If3e546648a42bcc17e57fb4965f7cdc063243825
2013-04-02 14:21:19 +02:00
57dbe20c2b fdo#46808, clean up some old queryInterface() calls
clean up stuff like this
  xI->queryInterface( getCppuType((const Reference< XExtendedInputSequenceChecker>*)0) ) >>= xISC;
to
  xISC.set(xI, UNO_QUERY);

Change-Id: I3b16a38c2a363440f6079cfe6ae47f009d3940db
2013-03-04 10:13:19 +02:00
138e5a0518 make it possible to build with system icu 4.2 (RHEL-6)
Change-Id: I69bf7bc33a619c4aa9483e2dc3d5540e4dfa7458
2013-02-19 15:42:14 +00:00
79a3c9b186 partly revert 92a9b7780c6e13a4da3b12794342edbc4c09ef51 for ICU < 49
Re-enable build with ICU 4.6 and 4.8
ICU versions prior to 49 don't know Conditional_Japanese_Starter and
Hebrew_Letter

Also, the change in i18npool/CustomTarget_breakiterator.mk

- -e "s#\[:LineBreak = Close_Punctuation:\]#\[& \[:LineBreak = Close_Parenthesis:\]\]#" \

with i18npool/source/breakiterator/data/line.txt

-$CL = [:LineBreak = Close_Punctuation:] ;
+$CL = [:LineBreak = Close_Parenthesis:];

did not produce equivalent results. Instead use

$CP = [:LineBreak =  Close_Parenthesis:];
$CL = [[:LineBreak =  Close_Punctuation:] $CP];

Change-Id: I14fc14319ea34f23393264560452a79bb49fc3a7
2013-01-02 19:23:03 +01:00
92a9b7780c follow logical consequences of a minimum icu version of 4.6
since commit f20ed8959bc0a984177377a734d34f767653625b

Change-Id: I4f2fc5d9eb7a581b9ed707a3c3f96be817141846
2012-12-29 18:02:25 +00:00
9c6006b961 fdo#58590 - cleanup and accelerate break-iterators.
Doing word-count by switching per-word between two different
kinds of word iterator was insanely slow. This preserves an
ICU break-iterator for each type of word-breaking.
2012-12-21 11:40:02 +00:00
9df0baaf0b fdo#46808, convert i18n::BreakIterator impl to XComponentContext
Change-Id: I2e6800d0f5a6346fc743d5a57bab34d1e36b4ee4
2012-11-27 18:18:07 +01:00
5584761358 Related: #112623# add regression test for japanese word break rules
Change-Id: I05baf163cc00d3770b9a8b25b099ffcbd9623a2f
2012-09-19 14:38:02 +01:00
346cf4ee5d Related: #i50172# add regression test for Tamil cursoring
Change-Id: I8f6c3814aa3630f5f640f611fb51ce72641715c6
2012-09-07 12:39:58 +01:00