[Libreoffice] (no subject)

2010-11-20 Thread Sebastian Spaeth
Hi all, here some nice stats. Summary, is that we lost 34,000 lines of
code since we started to code on LO...

I used SLOCCount by David A. Wheeler to
check our project size. At the time of the fork ie the
LIBREOFFICE_CREATE tag our clone directory was this big:

Total Physical Source Lines of Code (SLOC) = 5,671,599
Totals grouped by language:
cpp:4731322 (83.42%)
java:401786 (7.08%)
xml: 185842 (3.28%)
ansic:   133211 (2.35%)
pascal:  103341 (1.82%)
perl: 70676 (1.25%)
sh:   15889 (0.28%)

Current Master is this big:
==
Total Physical Source Lines of Code (SLOC) = 5,638,347
Totals grouped by language:
cpp:4714769 (83.62%)
java:401831 (7.13%)
xml: 186150 (3.30%)
ansic:   119903 (2.13%)
pascal:  103360 (1.83%)
perl: 66601 (1.18%)
sh:   15797 (0.28%)
[snip]

Hope you like it
Sebastian


pgp09iLjPbnuh.pgp
Description: PGP signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] [Patch][EasyHacks] Replace ScfRef with boost::shared_ptr in calc filter code

2010-11-20 Thread Nigel Hawkins
On Fri, 2010-11-19 at 20:31 -0500, Kohei Yoshida wrote:
 Great work!  I've applied all your patches and committed as a single
 commit.  I hope that's okay.  

Not a problem. I generally commit locally in very small chunks and then
format-patch generates one patch per commit. I can squash them together
in future if that is the preferred style.
 
 Here, you replaced all instances of xFoo.is() with xFoo.get(), which is
 itself not incorrect.  But boost::shared_ptr overloads the operator
 bool() which returns the wrapped pointer value when a boolean value is
 expected, so in this example simply replacing xFoo.is() with xFoo is
 sufficient (and cleaner).  I've made this change while applying your
 last patch.

I have learnt something new today, so this is good. Having said that,
even after reading about the safe bool idiom, operator
unspecified_bool_type still seems a bit obscure.

Nigel

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] [PUSHED] RTL easy hack against bridges/

2010-11-20 Thread David Tardon
On Fri, Nov 19, 2010 at 10:11:49AM -0500, Kevin Hunter wrote:
 Hullo List,
 
 A simple one against but test cases, but, as I said in the commit
 message, they were in my (grep) road!
 
 Kevin

Pushed.

D.
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH] remove the bogus comments lying around

2010-11-20 Thread Gabriel Monnerat

Hello,

Here's a patch to remove some bogus comments.

--
Gabriel M. Monnerat



remove_bogus_comments.patch.tar
Description: Unix tar archive
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] newish to git: howto recover from bad merge?

2010-11-20 Thread Wols Lists
On 19/11/10 08:11, Kevin Hunter wrote:
 Hullo List,

 It must be something simple, but I'm having a devil of a time
 recovering from a bad merge.  Given my transcript below, how do I
 recover?

 It usually happens after I've committed a change to my local
 repository, that I then sent in as a patch.  That patch got applied
 with a slight modification, and then the conflict.

 -
 snip
 -

 Any pointers for the uninitiated would be awesome.

 Thanks!

As a git newbie myself ...

Firstly, I'm slightly surprised no-one suggested merely reverting your
patch. You'll need to look at how to do it - someone pointed me to this
link - http://book.git-scm.com/4_interactive_rebasing.html - which might
help you do that, though this page probably isn't quite the right one.

But I'm guessing all you want to do is get rid of your patch and replace
it with the official one - so just dropping your version should do
what you want?


The other thing, I noticed it said not currently on any branch. Are
you using branches? I forget sometimes, but what I do is checkout a
branch, make a bunch of changes, and submit the patch. Another set of
changes - do another branch. When my changes are merged, bin the branch
I made them on because they're now in master. Unless you're really
beginning to do a load of developing so you can't create each patch-set
on their own branch, that workflow should work well.

Cheers,
Wol
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Location of SfxPoolItem.Type() method

2010-11-20 Thread Mattias Johnsson
On 21 November 2010 01:04, Miklos Vajna vmik...@frugalware.org wrote:
 On Sun, Nov 21, 2010 at 12:21:08AM +1100, Mattias Johnsson 
 m.t.johns...@gmail.com wrote:
 int SfxPoolItem::operator==( const SfxPoolItem rCmp ) const
 {
     DBG_CHKTHIS(SfxPoolItem, 0);
     return rCmp.Type() == Type();
 }

 but for the life of me I can't find out where the Type() method is defined.

 Does anyone have any pointers?

 The SfxPoolItem itself is declared in svl/inc/svl/poolitem.hxx. You can
 see a TYPEINFO(); macro there, which is defined in
 tools/inc/tools/rtti.hxx.

 Now if you want the definition of that method, the implementation is in
 source/items/poolitem.cxx, where there is a TYPEINIT0() macro, defined
 in tools/inc/tools/rtti.hxx again.

 TYPEINIT0() calls TYPEINIT0_FACTORY(), that calls TYPEINIT_FACTORY(),
 where the real method is defined.

 Hope this helps. :)


Obviously I was thinking too simplistically :-P

Thanks!
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] [PUSHED] RTL goodness against filters/

2010-11-20 Thread Kevin Hunter

At 2:22am -0500 Sat, 20 Nov 2010, David Tardon wrote:

On Fri, Nov 19, 2010 at 03:04:52PM -0500, Kevin Hunter wrote:

Some more RTL goodness against filters/.


I corrected two obviously wrong changes:


Thank you for checking those.  I caught three of those, but missed those 
two.


For the latter, (OUString() vs = OUString()), you were obviously able to 
compile?  I originally had them exactly as you had them, but my compiler 
did not like them.  And I couldn't figure out why.  (Heh, so I pushed it 
off to someone else.  ;-) )


Cheers,

Kevin
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Issues Wiki

2010-11-20 Thread Gioele Barabucci

Júlio Hoffimann 20/11/2010 02:17:

There is a issues wiki for LibreOffice? A place where users can report bugs,
talk about new features, etc. We need some inspiration to contribute. :-)


There is a bug and enhancement tracker hosted at freedesktop.org.

You can file issues and ask for new features using 
https://bugs.freedesktop.org/enter_bug.cgi?product=LibreOffice. 
Remember to search whether there is an already reported bug before 
filing a new one.


--
Gioele Barabucci gio...@svario.it


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] newish to git: howto recover from bad merge?

2010-11-20 Thread Kevin Hunter

At 9:16am -0500 Sat, 20 Nov 2010, Wols Lists wrote:

Firstly, I'm slightly surprised no-one suggested merely reverting
your patch.



But I'm guessing all you want to do is get rid of your patch and
replace it with the official one - so just dropping your version
should do what you want?


This is what I was doing previously, but this workflow is not 
sustainable.  For the time being, yes, but I needed to learn the right 
way sooner rather than later.



The other thing, I noticed it said not currently on any branch.
Are you using branches?


Yes, I am.  Takeshi did an excellent job of explaining where that comes 
from, with followups from Kohei and Christian:


At 5:53am -0500 Fri, 19 Nov 2010, Takeshi Abe wrote
At 11:31am -0500 Fri, 19 Nov 2010, Kohei Yoshida wrote
At 7:45pm -0500 Fri, 19 Nov 2010, Christian Lohmaier wrote

Cheers,

Kevin
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Issues Wiki

2010-11-20 Thread Júlio Hoffimann
Thanks Gioele, but i'm looking for something like this
http://code.google.com/p/gaosp/issues/list

Would be helpful if some wiki exists.

http://code.google.com/p/gaosp/issues/listJúlio.

2010/11/20 Gioele Barabucci gio...@svario.it

 Júlio Hoffimann 20/11/2010 02:17:

  There is a issues wiki for LibreOffice? A place where users can report
 bugs,
 talk about new features, etc. We need some inspiration to contribute. :-)


 There is a bug and enhancement tracker hosted at freedesktop.org.

 You can file issues and ask for new features using 
 https://bugs.freedesktop.org/enter_bug.cgi?product=LibreOffice. Remember
 to search whether there is an already reported bug before filing a new one.

 --
 Gioele Barabucci gio...@svario.it


 ___
 LibreOffice mailing list
 LibreOffice@lists.freedesktop.org
 http://lists.freedesktop.org/mailman/listinfo/libreoffice

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] Issues Wiki

2010-11-20 Thread Gioele Barabucci

Júlio Hoffimann 20/11/2010 17:06:

Thanks Gioele, but i'm looking for something like this
http://code.google.com/p/gaosp/issues/list

Would be helpful if some wiki exists.


The list of open bugs and enhancement requests is available at 
https://bugs.freedesktop.org/buglist.cgi?product=LibreOfficebug_status=__open__.


(Blame Bugzilla for that ugly URI. ;))

--
Gioele Barabucci gio...@svario.it

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] question about memory leak detected by cppcheck

2010-11-20 Thread Caolán McNamara
On Sat, 2010-11-20 at 08:37 +0100, Julien Nabet wrote:

  SfxAllEnumValue_Impl *pVal = new SfxAllEnumValue_Impl;
...
  const SfxAllEnumValue_Impl *pTemp = pVal;
...
  pValues-Insert( pTemp, nPos );

 And cppcheck says :
 Checking ./filters/binfilter/bf_svtools/source/items/svt_aeitem.cxx...
 [./filters/binfilter/bf_svtools/source/items/svt_aeitem.cxx:110]: 
 (error) Memory leak: pVal
 
 In my opinion it's a false positive

Without looking at the full impl of SfxAllEnumValueArr its hard to tell.
I would imagine that cppcheck can't tell either :-). So, just for the
sake of a cppcheck test change

const SfxAllEnumValue_Impl *pTemp = pVal;
pValues-Insert( pTemp, nPos );

to 

pValues-Insert( pVal, nPos );

or

pValues-Insert( (const SfxAllEnumValue_Impl*)pTmp, nPos );

and see if cppcheck still complains, or if the cast has confused it.

C.

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PUSHED] Re: [PATCH] RTL_CONSTASCII_USTRINGPARAM for libs-core/connectivity/drivers

2010-11-20 Thread Caolán McNamara
On Fri, 2010-11-19 at 22:53 +0100, Julien Nabet wrote:
 Hello,
 
 Here's patch for the last changes to do that I've seen in 
 libs-core/connectivity/drivers

-(::rtl::OUString::createFromAscii( i18n(Address Book) ));
+(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( i18n(Address
Book)) ));

Hmm, what's i18n in this context, I can't seem to see a define or
function called i18n. Is that a KDE/QT thing, if its e.g. a function
that returns a char * then it might not be a safe change, while if its a
define, then depending on what it does it might be ok.


-m_sMozillaURI =
rtl::OUString::createFromAscii( getSchemeURI( SCHEME_MOZILLA ) );
+m_sMozillaURI =
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( getSchemeURI( SCHEME_MOZILLA )) );

is definitely not safe here. The RTL_CONSTASCII_USTRINGPARAM does a
sizeof on its arg, so it should only be passed a string literal or
array, not a char*.

Otherwise, it looks good, so pushed.

C.

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PUSHED] Re: [PATCH] RTL_CONSTASCII_USTRINGPARAM for libs-core

2010-11-20 Thread Caolán McNamara
On Fri, 2010-11-19 at 23:23 +0100, Julien Nabet wrote:
 Hello,
 
 Here's a patch for libs-core

Looks good, top part was duplicate of previous patch. So pushed the
extra bits. Thanks for this.

When I see an empty sting being created, e.g.
OUString::createFromAscii() best to just replace it with the default
ctor of OUString() as better style. So I made that change while I was at
it.

C.

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH] RTL_CONSTASCII_USTRINGPARAM for libs-core/fpicker

2010-11-20 Thread Julien Nabet

Hello,

Here's a patch for libs-core/fpicker

Julien.
(LGPLv3+ / MPL)


libs_core_fpicker.txt.bz2
Description: application/bzip
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PUSHED] Re: [PATCH] RTL_CONSTASCII_USTRINGPARAM for libs-core/fpicker

2010-11-20 Thread Caolán McNamara
On Sat, 2010-11-20 at 17:50 +0100, Julien Nabet wrote:
 Hello,
 
 Here's a patch for libs-core/fpicker

Looks all good. Thanks for this.

I did leave out the changes inside the VISTAFILEDIALOG_CHECKED_COMCALL
macro.

as its inside a define where the parameter is passed into it, so it
can't be guaranteed to be a literal. 

As an aside though, nothing in LibreOffice itself appears to use
VISTAFILEDIALOG_CHECKED_COMCALL, so I wonder if it can be removed
entirely. Though maybe VISTAFILEDIALOG_CHECKED_COMCALL called via some
other strange windows programming specific magic. 

C.


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] [PUSHED] Re: [PATCH] RTL_CONSTASCII_USTRINGPARAM for libs-core/connectivity/drivers

2010-11-20 Thread Caolán McNamara
On Sun, 2010-11-21 at 02:36 +0900, Takeshi Abe wrote:
 Both versions of i18n return a QString.

Thanks. Yeah, and with an operator to convert to const char*, not a
candidate for RTL_CONSTASCII_USTRINGPARAM then. The check I have in the
rostrings branch would catch that when integrated once I figure out how
to convert from the older sgi std::identity to the new c++0x
std::identity thing.

C.


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PUSHED] Re: [PATCH] RTL_CONSTASCII_USTRINGPARAM for libs-core/embeddedobj

2010-11-20 Thread Caolán McNamara
On Sat, 2010-11-20 at 13:47 +0100, Julien Nabet wrote:
 Hello,
 
 Here's a patch for libs-core/embeddedobj

Thanks for this. Pushed.

C.

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH] binfilter/ : #if 0 removals

2010-11-20 Thread Kevin Hunter

Hullo List,

Some #if 0 removals in binfilter.

Cheers,

Kevin


if0_removals.txz
Description: application/xz-compressed-tar
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] feature/rip-build-repo - branch for removal of the need of the 'build' repo

2010-11-20 Thread Norbert Thiebaud
On Thu, Nov 18, 2010 at 10:18 PM, Jan Holesovsky ke...@suse.cz wrote:
 Hi,

 In case you are interested to try to build without the 'build' repo (the
 rawbuild/ way), you can try to get the feature/rip-build-repo branch
 which I hope is going to become the 'official' way of building soon ;-)

btw, I got it working on MacOS

Norbert
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Libreoffice] LibreOffice Beta 3

2010-11-20 Thread NoOp
On 11/19/2010 04:34 PM, Kevin Hunter wrote:
 At 6:54pm -0500 Fri, 19 Nov 2010, David Burleigh wrote:
 I am running LibreOffice Beta 3 under Ubuntu 10.10 (64-bit) and it
 seems to gradually bog down with use, so that I have to exit and
 restart it several times a day. It gets so that cursor movement is
 very slow. This was also a problem with Beta 2, and I was hoping that
 Beta 3 would fix it, but not so...
 
 Heh, this has been my experience with Calc for awhile.  I, too, would 
 like to see it fixed.  However (and here's the annoying part) it's 
 rather difficult to track these sorts of vague issues down.  If you can 
 find a directly repeatable use case, like save 5 files over 100KiB in 
 size, reload twice, and you can *really* notice the slow down you would 
 be doing the devs (and yourself!) wonders.
 
 Unfortunately, because these gradual slow downs are caused by a number 
 of different pieces of the code and in small increments, there's likely 
 not a single action to say Aha! There's the bugger.
 
 One slow down of which I've become aware is in charting with Calc. 
 Clicking in and out of a chart is a nightmare after 5 minutes of heavy 
 use.  With luck, now that there's an articulated example, someone may 
 have more luck tracking down that particular issue.

Is there something like this available for LO?
https://wiki.mozilla.org/Performance:Leak_Tools

I'm a standard 'user' (linux, but I also test on WinXP  Win7 (if
forced:-)), so if someone can point to debugging tools/procedures I'll
be happy to test.



___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


[Libreoffice] [PATCH] RTL_CONSTASCII_USTRINGPARAM for libs-core/framework

2010-11-20 Thread Julien Nabet

Hello,

Here's a patch for libs-core/framework

Julien.
(LGPLv3+ / MPL)
diff --git a/framework/source/jobs/jobdata.cxx 
b/framework/source/jobs/jobdata.cxx
index 55cda74..09b2165 100644
--- a/framework/source/jobs/jobdata.cxx
+++ b/framework/source/jobs/jobdata.cxx
@@ -182,7 +182,7 @@ void JobData::setAlias( const ::rtl::OUString sAlias )
 // try to open the configuration set of this job directly and get a 
property access to it
 // We open it readonly here
 ::rtl::OUString sKey;
-sKey  = ::rtl::OUString::createFromAscii(JOBCFG_ROOT);
+sKey  = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(JOBCFG_ROOT));
 sKey += ::utl::wrapConfigurationElementName(m_sAlias);
 
 ConfigAccess aConfig(m_xSMGR, sKey);
@@ -199,11 +199,11 @@ void JobData::setAlias( const ::rtl::OUString sAlias )
 css::uno::Any aValue;
 
 // read uno implementation name
-aValue   = 
xJobProperties-getPropertyValue(::rtl::OUString::createFromAscii(JOBCFG_PROP_SERVICE));
+aValue   = 
xJobProperties-getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(JOBCFG_PROP_SERVICE)));
 aValue = m_sService;
 
 // read whole argument list
-aValue = 
xJobProperties-getPropertyValue(::rtl::OUString::createFromAscii(JOBCFG_PROP_ARGUMENTS));
+aValue = 
xJobProperties-getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(JOBCFG_PROP_ARGUMENTS)));
 css::uno::Reference css::container::XNameAccess  xArgumentList;
 if (
 (aValue = xArgumentList)  
@@ -313,7 +313,7 @@ void JobData::setJobConfig( const css::uno::Sequence 
css::beans::NamedValue 
 // It doesn nothing here then ... or it change the mode automaticly, if
 // it was opened using another one before.
 ::rtl::OUString sKey;
-sKey  = ::rtl::OUString::createFromAscii(JOBCFG_ROOT);
+sKey  = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(JOBCFG_ROOT));
 sKey += ::utl::wrapConfigurationElementName(m_sAlias);
 
 ConfigAccess aConfig(m_xSMGR, sKey);
@@ -481,11 +481,11 @@ css::uno::Sequence css::beans::NamedValue  
JobData::getConfig() const
 lConfig.realloc(2);
 sal_Int32 i = 0;
 
-lConfig[i].Name = ::rtl::OUString::createFromAscii(PROP_ALIAS);
+lConfig[i].Name = 
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(PROP_ALIAS));
 lConfig[i].Value = m_sAlias;
 ++i;
 
-lConfig[i].Name = ::rtl::OUString::createFromAscii(PROP_SERVICE);
+lConfig[i].Name = 
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(PROP_SERVICE));
 lConfig[i].Value = m_sService;
 ++i;
 }
@@ -556,7 +556,7 @@ void JobData::disableJob()
 // Convert and write the user timestamp to the configuration.
 css::uno::Any aValue;
 aValue = Converter::convert_DateTime2ISO8601(DateTime());
-
xPropSet-setPropertyValue(::rtl::OUString::createFromAscii(EVENTCFG_PROP_USERTIME),
 aValue);
+
xPropSet-setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(EVENTCFG_PROP_USERTIME)),
 aValue);
 }
 
 aConfig.close();
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice