Age | Commit message (Collapse) | Author |
|
...instead of having individual overloads for OUString, OUStringLiteral, and
literal char16_t const[N]. (The variants taking OUString are still needed for
!LIBO_INTERNAL_ONLY, though. The variants taking ASCII-only literal char
const[N] are also left in place.)
This nicely reduces the number of needed overloads. std::u16string_view allows
to pass as arguments:
* OUString
* OUStringLiteral
* OUStringChar (with the necessary conversion added now)
* OUStringNumber
* u"..." char16_t string literals
* u"..."sv std::u16string_view literals
* std::u16string, plain char16_t*, and more
A notable exceptions is OUStringConcat, which now needs to be wrapped in
OUString(...), see the handful of places that needed to be adapted.
One caveat is the treatment of embedded NUL characters, as
std::u16string_view(u"x\0y")
constructs a view of size 1, while only
u"x\0y"sv
constructs a view of size 3 (which matches the old behavior of overloads for
literal char16_t const[N] via the ConstCharArrayDetector<>::TypeUtf16
machinery). See the new checkEmbeddedNul in
sal/qa/rtl/strings/test_oustring_stringliterals.cxx.
The functions that have been changed are generally those that:
* already take a string of determined length, so that using std::u16string_view,
which is always constructed with a determined length, is no pessimization
(e.g., there are operator == overloads taking plain pointers, which do not
need to determine the string length upfront);
* could not benefit from the fact that the passed-in argument is an OUString
(e.g., the corresponding operator = overload can reuse the passed-in
OUString's rtl_uString pData member);
* do not run into overload resolution ambiguity issues, like the comparison
operators would do.
One inconsistency that showed up is that while the original
replaceAll(OUString const &, OUString const &, sal_Int32 fromIndex = 0)
overload takes an optional third fromIndex argument, the existing replaceAll
overloads taking OUStringLiteral and literal char16_t const[N] arguments did
not. Fixing that required a new (LIBO_INTERNAL_ONLY)
rtl_uString_newReplaceAllFromIndexUtf16LUtf16L (with test code in
sal/qa/rtl/strings/test_strings_replace.cxx).
Another issue was posed by test code in
sal/qa/rtl/strings/test_oustring_stringliterals.cxx that used the
RTL_STRING_UNITTEST-only OUString(Except*CharArrayDetector) ctors to verify that
certain function calls should not compile (and would compile under
RTL_STRING_UNITTEST by taking those Except*CharArrayDetector converted to
OUString as arguments). Those problematic "should fail to compile" tests have
been converted into a new CompilerTest_sal_rtl_oustring.
Change-Id: Id72e8c4cc338258cadad00ddc6ea5b9da2e1f780
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102020
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I025aafd0da19fb0382591545f3aa14e84c9c362e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101912
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I799dcb6e7042e6d0174616458fa09b80ede59163
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101910
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I513c81faa9b93fbcb7eb93ac60152dcc97b41481
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101585
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
though doing this logging always when ~100% of the time there is noone
listening seems wasteful
Change-Id: Ib18462b70136ac52a4b9340a3a0890b4f97a4593
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101839
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
It passed "make check" on Linux
Change-Id: I0d84ef2053f0dd9f804c5a99e3f9099f86460010
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101812
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
|
|
O[U]StringView had an odd mixture of uses. For one, it was used like
std::[u16]string_view, for which directly using the latter std types is clearly
the better alternative. For another, it was used in concatenation sequences,
when neither of the two leading terms were of our rtl string-related types.
For that second use case introduce O[U]String::Concat (as std::[u16]string_view
can obviously not be used, those not being one of our rtl string-related types).
Also, O[U]StringLiteral is occasionally used for this, but the planned changes
outlined in the 33ecd0d5c4fff9511a8436513936a3f7044a775a "Change OUStringLiteral
from char[] to char16_t[]" commit message will make that no longer work, so
O[U]String::Concat will be the preferred solution in such use cases going
forward, too.
O[U]StringView was also occasionally used to include O[U]StringBuffer values in
concatenation sequences, for which a more obvious alternative is to make
O[U]StringBuffer participate directly in the ToStringHelper/O[U]StringConcat
machinery.
Change-Id: I1f0e8d836796c9ae01c45f32c518be5f52976622
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101586
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I6517f3b68389c0f3581cc750c61b8e59d075d35e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101633
Tested-by: Jenkins
Reviewed-by: Andrea Gelmini <andrea.gelmini@gelma.net>
|
|
Change-Id: I473956d570feac508e52a3e52cc26cc154f4dc56
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101627
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Tested-by: Jenkins
|
|
0c8fa58a2d73702770687ed15b98822d09f96ac3 "Support ConstCharArrayDetector also
for UTF-16 arrays" had introduced those LIBO_INTERNAL_ONLY ctor and operator ==
overloads, but they never got called because the existing 'sal_Unicode const *'
overloads always won.
(The other function overloads introduced with
0c8fa58a2d73702770687ed15b98822d09f96ac3 should be unproblematic, as they do not
have any 'sal_Unicode const *' overload counterparts.)
Also fix the resulting loplugin:elidestringvar and loplugin:stringconstant
fallout. For one, those plugins look at the actual ctor overloads being used,
so had missed those cases that accidentally had used an unexpected overload.
And for another, the heuristic the plugins used to detect the
ConstCharArrayDetector overloads turned out to be too simplistic now and would
have started to cause false positives.
Change-Id: I4426890979fb832d53f391c7e1b62bc1ad501a65
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101582
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I5d7673315b3bcbcdc47d31c8fad958e907699a6d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101573
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I9c73dba293cd831834a560e9fd8e8c2d135e2358
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101494
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I4901eb118c4f6da17ff1fdf86a1af779f24b6e17
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101493
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
This is a prerequisite for making conversion from OUStringLiteral to OUString
more efficient at least for C++20 (by replacing its internals with a constexpr-
generated sal_uString-compatible layout with a SAL_STRING_STATIC_FLAG refCount,
conditionally for C++20 for now).
For a configure-wise bare-bones build on Linux, size reported by `du -bs
instdir` grew by 118792 bytes from 1155636636 to 1155755428.
In most places just a u"..." string literal prefix had to be added. In some
places
char const a[] = "...";
variables have been changed to char16_t, and a few places required even further
changes to code (which prompted the addition of include/o3tl/string_view.hxx
helper function o3tl::equalsIgnoreAsciiCase and the additional
OUString::createFromAscii overload).
For all uses of macros expanding to string literals, the relevant uses have been
rewritten as
u"" MACRO
instead of changing the macro definitions. It should be possible to change at
least some of those macro definitions (and drop the u"" from their call sites)
in follow-up commits.
Change-Id: Iec4ef1a057d412d22443312d40c6a8a290dc6144
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101483
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
instead of using "SELECT" which similar to other UIObjects we will write "CHOOSE"
Change-Id: I32c1ab5f8a5dd21df87d90923d5821f8f0b16e76
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101265
Tested-by: Jenkins
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
|
|
For example the DSL syntax will be:
>>Choose element with position 18 in 'colorset' from 'cui/ui/colorpage/colorset'
Change-Id: I9186b870da096719873c8709dedbc4bb4d315e2c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101267
Tested-by: Jenkins
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
|
|
so we can differentiate the case of embedded welded widgets co-sharing the
tab-cycle sequence with vcl widgets vs the case its all welded widgets
Change-Id: I5c57b4e98d2f5c543522a72e31d554a67c259307
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101485
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I031c42cd85395a777c20bdd052da4233bc2fedab
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101414
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I42b46c0cada25703e8e9600533a220252796457e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101289
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
These extended tips are extracted from <ahelp> in Help files
Only for ui files, where dialogs/widget pair could be determined.
Other forms of <ahelp hid=".."> such as .uno:.. and *HID* ... will
be addressed elswhere.
Change#1 Removed extended tips from GtkMenu of
svx/.../acceptrejectchangesdialog.ui
Change#2 Some empty ET's slipped in cui/macroselectdialog.ui
Change-Id: Ic8dc62734143f621fcd3c4156fc004f585630277
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101186
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
As a separate commit so the locale data can be backported to 7-0
without introducing a new UI string.
Change-Id: I00379e326e7b7e89abba990908155f4d8a8c8c36
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101140
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Jenkins
|
|
Change-Id: I8dc0cdcfe6bd90efc596df28e6c6d968b92618b5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101098
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Tested-by: Jenkins
|
|
Change-Id: I59a37e1d37fa749cba5159daa23fe663bcc55435
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101045
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I6a300169d33bdc36e4c7e720a7afc336a86eea68
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100962
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
tackle some read-only vars.
Mark some of them const to make it obvious they are not really used, and
to make the constantparam plugin see more data.
Change-Id: Ia25927745866746aa1aa9d5affd5857ad9f9ee24
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100895
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
I copied and modified the unusedfields plugin to find unused
variables.
Change-Id: I18ed6daa202da70a2e564e4fe4760aed7ce070ba
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100891
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: Ie3e38afd976620068c644809c4a88cd3809759a5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100907
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I16cc2f75c3e639915c90edc626829e455bda4383
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100889
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I9aa4b1efbecb71141647dbf5d8809482be15d266
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100888
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: If9a1639d28aa7a540f301657387a04309ba82580
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100873
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I0fa9f21c30bba8f781178b0811f3f7d755af1bb3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100627
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I12806e2afc022c079d9db758973b8d1bfc0c7107
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100752
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I323a114d3b71a74267ee7a89c5fb29821611e57e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100751
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: Ie429a10a8f54c6779d437ee4bc75a5ea0c427848
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100727
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
look for expressions like
!(a && !b)
which can be expanded out
Change-Id: I72515a9638762b050f9a258c08da39ebfa2ef8e7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100579
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I9a5fe6a097c5d06e3ac3ab6c4c77cbe082d1a17d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100745
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
The one from framework is more feature complete, so use that one.
Change-Id: I499f0ae1d20c588cfc04beebc643819559325882
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100726
Tested-by: Jenkins
Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
|
|
Now that all popups are welded.
Change-Id: I5ad8a4eb6b9512ea9dd075b56d0ae6ee201fff19
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100597
Tested-by: Jenkins
Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
|
|
Change-Id: Ia69fb105c6cc661ac94a360d47655b3faa9d6bb8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100618
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I6b3b6ef1530a192f4b6bf87aa9688687063683ea
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100591
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
This patch will add support for all the normal valuesets inside any dialog .
for example it will help in "Select Presets and Shadow Styles in borders tab ( format table or format cell )" to test tdf#133641 .
You can use the support by this line:
>> obj_name.executeAction("SELECT", mkPropertyValues({"POS": "4"}))
Change-Id: I35d0608318f1bca4f4e702ebcc258957835ce0db
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100373
Tested-by: Jenkins
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
|
|
Change-Id: I6560756eb63856a22b43e3e65a7b7843cd2d5376
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100447
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: Id8987e65ef3fae9c009af59d3a1f9d0e83726648
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100404
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
If we removed something that is a link to a real file from our list of images
to pack, but that real image is not in the list of images to pack, add it in
instead so the real image does get packed
Change-Id: I71bcbdf872a59194a1d94f287dda8fc27e4a6464
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99961
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I30621ab2e98c2387f3de67b2871516e5e25da761
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99565
Tested-by: Jenkins
Reviewed-by: Rizal Muttaqin <riz_17_oke@yahoo.co.id>
|
|
Change-Id: If636d1bda03c2932225980d9f2f31f0d06748a34
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99713
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
and cast to that instead of "Edit" and override the Editable controls impls to
do something suitable when called
Change-Id: I24cc02b603e9551df4e3eb39f6cb4839883db777
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99709
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: Ib3ef6ec415d5e61d484e338290030fac2ed7b215
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99647
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I5d31d603a9e5f91723a310900aeee875df1599c2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99445
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
not its width, but its width and the the width of the corner square
or just take its position if visible
Change-Id: Ideaea789046fb03067501798b5a541985ef75e0e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99485
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|