[Libreoffice] [PUSHED]Re: [PATCH] EasyHack RTL_CONSTASCII_USTRINGPARAM in desktop
On Sun, 2010-10-31 at 11:56 +0100, Joost Eekhoorn wrote: MPL 1.1 / GPLv3+ / LGPLv3+ Excellent, pushed, thanks. About coding conventions: In /desktop/source/app/dispatchwatcher.cxx starts with using ::rtl::OUString; and then there are: ::rtl::OUString rtl::OUString OUString What is the advised way? Well, all are valid so I don't have any strong feelings about it. Though I personally favour rtl::OUString, It's not really worth changing them IMO. C. ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH] EasyHack RTL_CONSTASCII_USTRINGPARAM 3
Hi, I'am not sure of my previous mail... Regards. createFromAscii_5.patch Description: Binary data ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH] EasyHack RTL_CONSTASCII_USTRINGPARAM 3
Hi, Quote : I'am not sure of my previous mail. I sent it 3 hours ago but it did not appear (and it's in my 'sent-mail' directory) : maybe some problem with my ISP because of the end of DST this night... Regards. ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] EasyHack RTL_CONSTASCII_USTRINGPARAM in cui
MPL 1.1 / GPLv3+ / LGPLv3+ In ./cui/source/tabpages/numpages.cxx (line 2852): String sMsg( RTL_CONSTASCII_USTRINGPARAM( Preview) ); Should that not be RTL_CONSTASCII_STRINGPARAM, because sMsg is a String and not a OUString? Joost diff --git a/cui/source/tabpages/autocdlg.cxx b/cui/source/tabpages/autocdlg.cxx index 469c6ea..e1ddae0 100644 --- a/cui/source/tabpages/autocdlg.cxx +++ b/cui/source/tabpages/autocdlg.cxx @@ -2730,9 +2730,9 @@ void OfaSmartTagOptionsTabPage::FillListBox( const SmartTagMgr rSmartTagMgr ) aSmartTagCaption = aSmartTagType; const rtl::OUString aLBEntry = aSmartTagCaption + - OUString::createFromAscii( () + + OUString(RTL_CONSTASCII_USTRINGPARAM( ()) + aName + - OUString::createFromAscii()); + OUString(RTL_CONSTASCII_USTRINGPARAM())); SvLBoxEntry* pEntry = m_aSmartTagTypesLB.SvTreeListBox::InsertEntry( aLBEntry ); if ( pEntry ) diff --git a/cui/source/tabpages/numpages.cxx b/cui/source/tabpages/numpages.cxx index 0db81ac..582f34b 100644 --- a/cui/source/tabpages/numpages.cxx +++ b/cui/source/tabpages/numpages.cxx @@ -91,7 +91,6 @@ using namespace com::sun::star::text; using namespace com::sun::star::container; using namespace com::sun::star::style; using rtl::OUString; -#define C2U(cChar) OUString::createFromAscii(cChar) SV_IMPL_PTRARR(SvxNumSettingsArr_Impl,SvxNumSettings_ImplPtr); @@ -126,7 +125,7 @@ ReferenceXDefaultNumberingProvider lcl_GetNumberingProvider() { Reference XMultiServiceFactory xMSF = ::comphelper::getProcessServiceFactory(); Reference XInterface xI = xMSF-createInstance( -::rtl::OUString::createFromAscii( com.sun.star.text.DefaultNumberingProvider ) ); +::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( com.sun.star.text.DefaultNumberingProvider )) ); ReferenceXDefaultNumberingProvider xRet(xI, UNO_QUERY); DBG_ASSERT(xRet.is(), service missing: \com.sun.star.text.DefaultNumberingProvider\); ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PUSHED] Re: EasyHack RTL_CONSTASCII_USTRINGPARAM in cui
On Sun, 2010-10-31 at 15:37 +0100, Joost Eekhoorn wrote: MPL 1.1 / GPLv3+ / LGPLv3+ All good, committed and pushed, thanks :-) In ./cui/source/tabpages/numpages.cxx (line 2852): String sMsg( RTL_CONSTASCII_USTRINGPARAM( Preview) ); Should that not be RTL_CONSTASCII_STRINGPARAM, because sMsg is a String and not a OUString? That's ok, if you look a the String class (UniString in tools/inc/tools/string.hxx) you can see that it has a constructor which takes as arguments, a char pointer, length and text encoding and a default fourth argument, so RTL_CONSTASCII_USTRINGPARAM is compatible with that constructor and its ok. Of course having another String class as well as rtl::OUString is annoying, and there's another Easy hack to remove the String/UniString class in favour of OUString, but it's a little bit tricky given the different APIs they have. e.g. in many cases a rtl::OUStringBuffer might be called for, and in others using OUString can be quite clumsy so extension/addition to e.g. the comphelper/inc/comphelper/string.hxx helper class might be called for to make it easy to replace UniString with rtl::OUString. C. ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] [PATCH] Internal separation of options of configure
Correct description would be: Grouped inner Optional Features (--enable/disable-) and Optional Packages (--with/without-) to ease maintenance. Minor fix: ]\n] - ]\n Option --with-servlet-api-jar=JARFILE was named wrong in --help. (It was named as --servlet-api-jar=JARFILE.) No changes to the order of configure --help options. ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PUSHED]Re: [PATCH] EasyHack RTL_CONSTASCII_USTRINGPARAM 3
On Sun, 2010-10-31 at 13:41 +0100, Gert Faller wrote: Hi, I'am not sure of my previous mail... This looks good. I pushed this patch as well. I see (again this was already there and not added by your patch) a few rather odd rtl::OUString sEmpty(OUString::createFromAscii()) in there to create an empty string. Clearly rtl::OUString sEmpty; is sufficient to do that. And places that have if (sSomething == OUString::createFromAscii()) ... if sSomething was empty is a bit of a long-way-around, if (!sSomething.getLength()) ... if sSomething was empty would be sufficient when sSomething is an rtl::OUString and knock a few cycles off that test. while where sSomething is an old-style String then if (sSomething == String(OUString::createFromAscii())) ... if sSomething was empty could just become if (!sSomething.Len()) ... if sSomething was empty C. ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] [PUSHED] Re: [PATCH] Easy Hacks : Use RTL_CONSTASCII_USTRINGPARAM macro bis
On Sat, 2010-10-30 at 22:08 +0100, Caolán McNamara wrote: old: OUString sFoo(OUString::createFromAscii(bBool ? true : false)); new: OUString sFoo(RTL_CONSTASCII_USTRINGPARAM(bBool ? true : false)); would be expanded as... OUString sFoo(bBool ? true : false, ((sal_Int32)(sizeof(bBool ? true : false)-1)); I think this is fine, but I'm a little bit wary of making that change Resolved this to my satisfaction, fixed now, thanks :-) C. ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] support for mono 2.8
While building Go/LibO for ArchLinux I've run into a few issues today after we had updated our mono packages to the 2.8 release. 1) the patches/mono/*.diff call mkbundle2 at several places. mkbundle2 (that called /usr/lib/mono/2.0/mkbundle.exe) isn't shipped anymore in the mono 2.8 release /usr/bin. It's replacement is mkbundle that calls /usr/lib/mono/4.0/mkbundle.exe though the 2.0/mkbundle.exe still exists without a script to call it from /usr/bin. I replaced all mkbundle2 calls in the *.diffs with a sed command and have run into 2) somehow the pkgconfig path isn't well read /build/src/libreoffice-build-3.2.99.2/build/libreoffice-3.2.99.2/cli_ure/source/bootstrap/native_glue.cxx:75:34: fatal error: mono/metadata/object.h: No such file or directory compilation terminated. dmake: Error code 1, while making '../../unxlngx6.pro/slo/native_glue.obj' The header is present: /usr/include/mono-2.0/mono/metadata/object.h current mono.pc: prefix=${pcfiledir}/../.. exec_prefix=${pcfiledir}/../.. libdir=${prefix}/lib includedir=${prefix}/include/mono-2.0 sysconfdir=/etc Name: Mono Description: Mono Runtime Version: 2.8 Any idea why the header isn't found? Is it a big step to make LibO compile and work with mono 2.8 or just a few hacks to satisfy the build process for the 3.3.0 release? -Andy ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PUSHED] Re: EasyHack RTL_CONSTASCII_USTRINGPARAM in sc
On Sun, 2010-10-31 at 21:18 +0100, Joost Eekhoorn wrote: MPL 1.1 / GPLv3+ / LGPLv3+ Excellent, all good. Thanks for the stylistic improvement in cFA_joost_5.patch while you were adding the RTL_CONSTASCII_USTRINGPARAM's :-) C. ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] (no subject)
From 09a62885c6c5aea12412d9bcb37a997bce87fa2d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niko=20R=C3=B6nkk=C3=B6?= ron...@iki.fi Date: Mon, 1 Nov 2010 00:36:23 +0200 Subject: [PATCH] Wrong option name in help MIME-Version: 1.0 Content-Type: multipart/mixed; boundary=kaben8Ohv4ahdainoh7Ohche4iequoodah1thahph0aiyefaingeeshohzaihaes This is a multi-part message in MIME format. --kaben8Ohv4ahdainoh7Ohche4iequoodah1thahph0aiyefaingeeshohzaihaes Content-Type: text/plain; charset=UTF-8; format=fixed Content-Transfer-Encoding: 8bit Option --with-servlet-api-jar was named wrong in --help. --- configure.in |7 --- 1 files changed, 4 insertions(+), 3 deletions(-) --kaben8Ohv4ahdainoh7Ohche4iequoodah1thahph0aiyefaingeeshohzaihaes Content-Type: text/x-patch; name=0001-Wrong-option-name-in-help-bootstrap.patch Content-Transfer-Encoding: 8bit Content-Disposition: attachment; filename=0001-Wrong-option-name-in-help-bootstrap.patch diff --git a/configure.in b/configure.in index 6f0539a..af00634 100644 --- a/configure.in +++ b/configure.in @@ -641,9 +641,10 @@ AC_ARG_WITH(commons-logging-jar, ]) AC_ARG_WITH(servlet-api-jar, -[ --servlet-api-jar=JARFILE Specify path to jarfile manually ], -[ SERVLETAPI_JAR=$withval -]) +AS_HELP_STRING([--with-servlet-api-jar=JARFILE], +[Specify path to jarfile manually.]), +[SERVLETAPI_JAR=$withval], +) AC_ARG_WITH(system-jfreereport, [ --with-system-jfreereport Use JFreeReport already on system --kaben8Ohv4ahdainoh7Ohche4iequoodah1thahph0aiyefaingeeshohzaihaes-- ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice