[Libreoffice] [PATCH] RTL_CONSTASCII_USTRINGPARAM cleaning in base
hello, short presentation: have some C++ and java programming skills, but not used it intensively since 4-5 years... Need some refresh, hence I am starting with easy hacks... Will allow me to refresh knowledge and have a look at LibreOffice Hope I am in line with the patch policy. PS: I will always try to rebuild before sending them. As soon as my git send-email will be fixed, mails for patches will be better... regards pjacquod From 195de6fac4e6d2c271db0252b4ea71aa2ecc2e81 Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Sat, 13 Nov 2010 12:39:36 +0100 Subject: [PATCH] RTL_CONSTASCII_USTRINGPARAM cleaning in base base/reportdesign/source/ui/report should now be clean and having no more createFromAssci with constant. --- reportdesign/source/ui/report/ReportController.cxx |4 ++-- reportdesign/source/ui/report/propbrw.cxx |2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/reportdesign/source/ui/report/ReportController.cxx b/reportdesign/source/ui/report/ReportController.cxx index eeb35f2..5efea58 100644 --- a/reportdesign/source/ui/report/ReportController.cxx +++ b/reportdesign/source/ui/report/ReportController.cxx @@ -1710,7 +1710,7 @@ void OReportController::impl_initialize( ) throw Exception(); ::comphelper::NamedValueCollection aArgs(getModel()-getArgs()); -setMode(aArgs.getOrDefault(Mode, rtl::OUString::createFromAscii(normal))); +setMode(aArgs.getOrDefault(Mode, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(normal; listen(true); setEditable( !m_aReportModel-IsReadOnly() ); @@ -1812,7 +1812,7 @@ void OReportController::doOpenHelpAgent() { if (getFrame().is()) { -rtl::OUString suURL = rtl::OUString::createFromAscii(vnd.sun.star.help://shared/text/shared/explorer/database/rep_main.xhp?UseDB=noDbPAR=swriter); +rtl::OUString suURL(RTL_CONSTASCII_USTRINGPARAM(vnd.sun.star.help://shared/text/shared/explorer/database/rep_main.xhp?UseDB=noDbPAR=swriter)); openHelpAgent(suURL); // openHelpAgent(68245 /* HID_REPORT_DESIGN... UNKNOWN */ ); // HID_APP_REPORT_TREE diff --git a/reportdesign/source/ui/report/propbrw.cxx b/reportdesign/source/ui/report/propbrw.cxx index 5bfb868..e21620d 100644 --- a/reportdesign/source/ui/report/propbrw.cxx +++ b/reportdesign/source/ui/report/propbrw.cxx @@ -121,7 +121,7 @@ PropBrw::PropBrw(const Reference XMultiServiceFactory _xORB,Window* pParent, if (m_xMeAsFrame.is()) { m_xMeAsFrame-initialize( VCLUnoHelper::GetInterface ( this ) ); -m_xMeAsFrame-setName(::rtl::OUString::createFromAscii(report property browser)); // change name! +m_xMeAsFrame-setName(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(report property browser))); // change name! } } catch (Exception) -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH] RTL_CONSTASCII_USTRINGPARAM in base
hello, it seems base in now clear (this one had spaces,...) I will do a full grep regards pjacquod From 08cfa904d88460a8f90bb6c6ea87095c522e7123 Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Sun, 14 Nov 2010 17:23:18 +0100 Subject: [PATCH] RTL_CONSTASCII_USTRINGPARAM in base --- reportdesign/source/filter/xml/dbloader2.hxx |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/reportdesign/source/filter/xml/dbloader2.hxx b/reportdesign/source/filter/xml/dbloader2.hxx index b7ad819..9a8ca26 100644 --- a/reportdesign/source/filter/xml/dbloader2.hxx +++ b/reportdesign/source/filter/xml/dbloader2.hxx @@ -91,7 +91,7 @@ public: // static methods static ::rtl::OUString getImplementationName_Static(void) throw( ::com::sun::star::uno::RuntimeException ) { -return ::rtl::OUString::createFromAscii(com.sun.star.comp.report.ORptTypeDetection); +return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.comp.report.ORptTypeDetection)); } static ::com::sun::star::uno::Sequence ::rtl::OUString getSupportedServiceNames_Static(void) throw( ::com::sun::star::uno::RuntimeException ); static ::com::sun::star::uno::Reference ::com::sun::star::uno::XInterface SAL_CALL -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH] RTL_CONSTASCII_USTRINGPARAM in components - customize
regards MPL/ GPLv3+ / LGPLv3+ pjacquod From c747bbc166d3637a37638b969908f6392cb793a0 Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Sun, 14 Nov 2010 19:55:57 +0100 Subject: [PATCH] RTL_CONSTASCII_USTRINGPARAM in components cleaning in components/cui/source/customize --- cui/source/customize/acccfg.cxx | 65 +++-- cui/source/customize/cfg.cxx | 25 +++--- cui/source/customize/cfgutil.cxx | 64 ++--- cui/source/customize/macropg.cxx | 10 +++--- 4 files changed, 81 insertions(+), 83 deletions(-) diff --git a/cui/source/customize/acccfg.cxx b/cui/source/customize/acccfg.cxx index 9f3274f..df7f98b 100644 --- a/cui/source/customize/acccfg.cxx +++ b/cui/source/customize/acccfg.cxx @@ -95,22 +95,22 @@ using namespace com::sun::star; // definitions //--- -static ::rtl::OUString SERVICE_STORAGEFACTORY = ::rtl::OUString::createFromAscii(com.sun.star.embed.StorageFactory ); -static ::rtl::OUString SERVICE_UICONFIGMGR = ::rtl::OUString::createFromAscii(com.sun.star.ui.UIConfigurationManager ); -static ::rtl::OUString SERVICE_DESKTOP = ::rtl::OUString::createFromAscii(com.sun.star.frame.Desktop ); -static ::rtl::OUString SERVICE_MODULEMANAGER= ::rtl::OUString::createFromAscii(com.sun.star.frame.ModuleManager); -static ::rtl::OUString SERVICE_GLOBALACCCFG = ::rtl::OUString::createFromAscii(com.sun.star.ui.GlobalAcceleratorConfiguration ); -static ::rtl::OUString SERVICE_MODULEUICONFIGSUPPLIER = ::rtl::OUString::createFromAscii(com.sun.star.ui.ModuleUIConfigurationManagerSupplier); -static ::rtl::OUString SERVICE_UICMDDESCRIPTION = ::rtl::OUString::createFromAscii(com.sun.star.frame.UICommandDescription ); +static ::rtl::OUString SERVICE_STORAGEFACTORY ( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.embed.StorageFactory))); +static ::rtl::OUString SERVICE_UICONFIGMGR ( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.ui.UIConfigurationManager ))); +static ::rtl::OUString SERVICE_DESKTOP ( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.frame.Desktop ))); +static ::rtl::OUString SERVICE_MODULEMANAGER( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.frame.ModuleManager ))); +static ::rtl::OUString SERVICE_GLOBALACCCFG ( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.ui.GlobalAcceleratorConfiguration ))); +static ::rtl::OUString SERVICE_MODULEUICONFIGSUPPLIER ( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.ui.ModuleUIConfigurationManagerSupplier))); +static ::rtl::OUString SERVICE_UICMDDESCRIPTION ( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.frame.UICommandDescription ))); -static ::rtl::OUString MODULEPROP_SHORTNAME = ::rtl::OUString::createFromAscii(ooSetupFactoryShortName); -static ::rtl::OUString MODULEPROP_UINAME= ::rtl::OUString::createFromAscii(ooSetupFactoryUIName ); -static ::rtl::OUString CMDPROP_UINAME = ::rtl::OUString::createFromAscii(Name ); +static ::rtl::OUString MODULEPROP_SHORTNAME ( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(ooSetupFactoryShortName ))); +static ::rtl::OUString MODULEPROP_UINAME( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(ooSetupFactoryUIName ))); +static ::rtl::OUString CMDPROP_UINAME ( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(Name ))); -static ::rtl::OUString FOLDERNAME_UICONFIG = ::rtl::OUString::createFromAscii(Configurations2); +static ::rtl::OUString FOLDERNAME_UICONFIG ( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(Configurations2 ))); -static ::rtl::OUString MEDIATYPE_PROPNAME = ::rtl::OUString::createFromAscii(MediaType ); -static ::rtl::OUString MEDIATYPE_UICONFIG = ::rtl::OUString::createFromAscii(application/vnd.sun.xml.ui.configuration ); +static ::rtl::OUString MEDIATYPE_PROPNAME ( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(MediaType))); +static ::rtl::OUString MEDIATYPE_UICONFIG ( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(application/vnd.sun.xml.ui.configuration
[Libreoffice] remove some comments / dead code in calc
find it by chance... regards pjacquod MPL/ GPLv3+ / LGPLv3+ From 0ad93f729c3141c0f40125b04c79a2891c51bece Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Sun, 14 Nov 2010 20:36:43 +0100 Subject: [PATCH] bogus comment / code in calc.. testvba --- sc/source/ui/vba/testvba/testvba.cxx |3 --- 1 files changed, 0 insertions(+), 3 deletions(-) diff --git a/sc/source/ui/vba/testvba/testvba.cxx b/sc/source/ui/vba/testvba/testvba.cxx index 70b1da0..3ca44cc 100644 --- a/sc/source/ui/vba/testvba/testvba.cxx +++ b/sc/source/ui/vba/testvba/testvba.cxx @@ -113,7 +113,6 @@ mxCompLoader( _xCompLoader ), msOutDirPath( convertToURL( _outDirPath ) ) { printf(%s\n, getenv(HOME) ); printf(file name %s\n, rtl::OUStringToOString( fileName, RTL_TEXTENCODING_UTF8 ).getStr() ); -//rtl::OUString sLogLocation( rtl::OUString::createFromAscii( getenv(HOME) ) ); rtl::OUString sLogLocation; Reference XPropertySet pathSettings( mxMCF-createInstanceWithContext( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( com.sun.star.comp.framework.PathSettings )), mxContext), uno::UNO_QUERY_THROW ); pathSettings-getPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( Work )) ) = sLogLocation; @@ -298,8 +297,6 @@ int main( int argv, char** argc ) dTest-traverse( ascii( argc[ 1 ] ) ); } delete dTest; -// tryDispose( xLoader, desktop ); -// tryDispose( xCC, remote context ); } catch( uno::Exception e ) -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 01/12] RTL_CONSTASCII_USTRINGPARAM in components/cui/...option
Hello, being off for some days, here the collection of patches I produced in between. Each patch concern the cleaning of directory, this will allow to review / descard some parts if needed. best regards pjacquod From c3b35d242fc9973d198571e19d37e7e12b746d97 Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Mon, 15 Nov 2010 22:33:50 +0100 Subject: [PATCH 01/12] RTL_CONSTASCII_USTRINGPARAM in components/cui/...option --- cui/source/options/connpoolconfig.cxx | 12 ++-- 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/cui/source/options/connpoolconfig.cxx b/cui/source/options/connpoolconfig.cxx index 41366d1..4bdc859 100644 --- a/cui/source/options/connpoolconfig.cxx +++ b/cui/source/options/connpoolconfig.cxx @@ -51,42 +51,42 @@ namespace offapp // static const ::rtl::OUString getConnectionPoolNodeName() { -static ::rtl::OUString s_sNodeName = ::rtl::OUString::createFromAscii(org.openoffice.Office.DataAccess/ConnectionPool); +static ::rtl::OUString s_sNodeName (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(org.openoffice.Office.DataAccess/ConnectionPool) ) ); return s_sNodeName; } // static const ::rtl::OUString getEnablePoolingNodeName() { -static ::rtl::OUString s_sNodeName = ::rtl::OUString::createFromAscii(EnablePooling); +static ::rtl::OUString s_sNodeName (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(EnablePooling) ) ); return s_sNodeName; } // static const ::rtl::OUString getDriverSettingsNodeName() { -static ::rtl::OUString s_sNodeName = ::rtl::OUString::createFromAscii(DriverSettings); +static ::rtl::OUString s_sNodeName (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DriverSettings) ) ); return s_sNodeName; } // static const ::rtl::OUString getDriverNameNodeName() { -static ::rtl::OUString s_sNodeName = ::rtl::OUString::createFromAscii(DriverName); +static ::rtl::OUString s_sNodeName (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DriverName) ) ); return s_sNodeName; } // static const ::rtl::OUString getEnableNodeName() { -static ::rtl::OUString s_sNodeName = ::rtl::OUString::createFromAscii(Enable); +static ::rtl::OUString s_sNodeName (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(Enable) ) ); return s_sNodeName; } // static const ::rtl::OUString getTimeoutNodeName() { -static ::rtl::OUString s_sNodeName = ::rtl::OUString::createFromAscii(Timeout); +static ::rtl::OUString s_sNodeName (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(Timeout) ) ); return s_sNodeName; } -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 02/12] RTL_CONSTASCII_USTRINGPARAM in components cui options
On 11/16/2010 10:37 PM, Pierre-André Jacquod wrote: Hello, being off for some days, here the collection of patches I produced in between. Each patch concern the cleaning of directory, this will allow to review / descard some parts if needed. best regards pjacquod ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice From 7da843dde65464842596338d8c442a246f01bc28 Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Mon, 15 Nov 2010 23:03:42 +0100 Subject: [PATCH 02/12] RTL_CONSTASCII_USTRINGPARAM in components cui options this time options should be cleared --- cui/source/options/cfgchart.cxx |4 ++-- cui/source/options/optgdlg.cxx| 14 +++--- cui/source/options/optimprove.cxx | 14 +++--- cui/source/options/optimprove2.cxx| 10 +- cui/source/options/optjava.cxx|2 +- cui/source/options/sdbcdriverenum.cxx |2 +- cui/source/options/treeopt.cxx| 20 ++-- 7 files changed, 33 insertions(+), 33 deletions(-) diff --git a/cui/source/options/cfgchart.cxx b/cui/source/options/cfgchart.cxx index a9e916c..03b9916 100644 --- a/cui/source/options/cfgchart.cxx +++ b/cui/source/options/cfgchart.cxx @@ -171,11 +171,11 @@ bool SvxChartColorTable::operator==( const SvxChartColorTable _rOther ) const // SvxChartOptions::SvxChartOptions() : -::utl::ConfigItem( rtl::OUString::createFromAscii( Office.Chart )), +::utl::ConfigItem( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(Office.Chart) ) ), mbIsInitialized( FALSE ) { maPropertyNames.realloc( 1 ); -maPropertyNames[ 0 ] = ::rtl::OUString::createFromAscii( DefaultColor/Series ); +maPropertyNames[ 0 ] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DefaultColor/Series) ); } SvxChartOptions::~SvxChartOptions() diff --git a/cui/source/options/optgdlg.cxx b/cui/source/options/optgdlg.cxx index 23e9d1a..15f08dc 100644 --- a/cui/source/options/optgdlg.cxx +++ b/cui/source/options/optgdlg.cxx @@ -136,7 +136,7 @@ namespace if ( rDesktopEnvironment.equalsIgnoreAsciiCaseAscii( gnome ) ) { #ifdef ENABLE_GTK -return ::rtl::OUString::createFromAscii( com.sun.star.ui.dialogs.GtkFilePicker ); +return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.ui.dialogs.GtkFilePicker) ); #else return rtl::OUString(); #endif @@ -144,7 +144,7 @@ namespace else if ( rDesktopEnvironment.equalsIgnoreAsciiCaseAscii( kde4 ) ) { #ifdef ENABLE_KDE4 -return ::rtl::OUString::createFromAscii( com.sun.star.ui.dialogs.KDE4FilePicker ); +return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.ui.dialogs.KDE4FilePicker) ); #else return rtl::OUString(); #endif @@ -152,15 +152,15 @@ namespace else if ( rDesktopEnvironment.equalsIgnoreAsciiCaseAscii( kde ) ) { #ifdef ENABLE_KDE -return ::rtl::OUString::createFromAscii( com.sun.star.ui.dialogs.KDEFilePicker ); +return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.ui.dialogs.KDEFilePicker) ); #else return rtl::OUString(); #endif } #if defined WNT -return ::rtl::OUString::createFromAscii( com.sun.star.ui.dialogs.SystemFilePicker ); +return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.ui.dialogs.SystemFilePicker) ); #elif (defined MACOSX defined QUARTZ) -return ::rtl::OUString::createFromAscii( com.sun.star.ui.dialogs.AquaFilePicker ); +return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.ui.dialogs.AquaFilePicker) ); #else return rtl::OUString(); #endif @@ -843,14 +843,14 @@ OfaViewTabPage::OfaViewTabPage(Window* pParent, const SfxItemSet rSet ) : { ::rtl::OUString aAutoStr( aIconStyleLB.GetEntry( 0 ) ); -aAutoStr += ::rtl::OUString::createFromAscii( ( ); +aAutoStr += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(() ); ULONG nAutoStyle = aStyleSettings.GetAutoSymbolsStyle(); if ( aIconStyleItemId[nAutoStyle] ) aAutoStr += aIconStyleLB.GetEntry( aIconStyleItemId[nAutoStyle] ); aIconStyleLB.RemoveEntry( 0 ); -aIconStyleLB.InsertEntry( aAutoStr += ::rtl::OUString::createFromAscii( ) ), 0 ); +aIconStyleLB.InsertEntry( aAutoStr += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM()) ), 0 ); // separate auto and other icon themes aIconStyleLB.SetSeparatorPos( 0 ); } diff --git a/cui/source/options/optimprove.cxx b/cui/source/options
[Libreoffice] [PATCH 03/12] RTL_CONSTASCII_USTRINGPARAM in components - forms
regards From f749c776fb979ee6700ce9477ae5b70b3b49d77c Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Mon, 15 Nov 2010 23:38:11 +0100 Subject: [PATCH 03/12] RTL_CONSTASCII_USTRINGPARAM in components - forms the whole directory components/forms/source/component should now be OK --- forms/source/component/Columns.cxx |4 +- forms/source/component/Currency.cxx |4 +- forms/source/component/DatabaseForm.cxx | 26 +++--- forms/source/component/Edit.cxx |2 +- forms/source/component/Filter.cxx| 18 +++--- forms/source/component/FormComponent.cxx |4 +- forms/source/component/FormattedField.cxx|6 ++-- forms/source/component/FormattedFieldWrapper.cxx |2 +- forms/source/component/FormsCollection.cxx |4 +- forms/source/component/GroupManager.cxx |2 +- forms/source/component/ListBox.cxx | 10 forms/source/component/RadioButton.cxx |4 +-- forms/source/component/clickableimage.cxx|2 +- 13 files changed, 43 insertions(+), 45 deletions(-) diff --git a/forms/source/component/Columns.cxx b/forms/source/component/Columns.cxx index af41076..f0364a4 100644 --- a/forms/source/component/Columns.cxx +++ b/forms/source/component/Columns.cxx @@ -94,8 +94,8 @@ const StringSequence getColumnTypes() //-- sal_Int32 getColumnTypeByModelName(const ::rtl::OUString aModelName) { -const ::rtl::OUString aModelPrefix = ::rtl::OUString::createFromAscii(com.sun.star.form.component.); -const ::rtl::OUString aCompatibleModelPrefix = ::rtl::OUString::createFromAscii(stardiv.one.form.component.); +const ::rtl::OUString aModelPrefix (RTL_CONSTASCII_USTRINGPARAM(com.sun.star.form.component.) ); +const ::rtl::OUString aCompatibleModelPrefix (RTL_CONSTASCII_USTRINGPARAM(stardiv.one.form.component.) ); sal_Int32 nTypeId = -1; if (aModelName == FRM_COMPONENT_EDIT) diff --git a/forms/source/component/Currency.cxx b/forms/source/component/Currency.cxx index 808863d..b604400 100644 --- a/forms/source/component/Currency.cxx +++ b/forms/source/component/Currency.cxx @@ -121,11 +121,11 @@ void OCurrencyModel::implConstruct() bPrependCurrencySymbol = sal_False; break; case 2: // $ 1 -sCurrencySymbol = ::rtl::OUString(String(aLocaleInfo.getCurrSymbol())) + ::rtl::OUString::createFromAscii( ); +sCurrencySymbol = ::rtl::OUString(String(aLocaleInfo.getCurrSymbol())) + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( ) ); bPrependCurrencySymbol = sal_True; break; case 3: // 1 $ -sCurrencySymbol = ::rtl::OUString::createFromAscii( ) + ::rtl::OUString(String(aLocaleInfo.getCurrSymbol())); +sCurrencySymbol = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( ) ) + ::rtl::OUString(String(aLocaleInfo.getCurrSymbol())); bPrependCurrencySymbol = sal_False; break; } diff --git a/forms/source/component/DatabaseForm.cxx b/forms/source/component/DatabaseForm.cxx index cb42736..162c617 100644 --- a/forms/source/component/DatabaseForm.cxx +++ b/forms/source/component/DatabaseForm.cxx @@ -995,7 +995,7 @@ void ODatabaseForm::Encode( ::rtl::OUString rString ) const switch( nCharCode ) { case 13: // CR -aResult += ::rtl::OUString::createFromAscii(%0D%0A); // Hex-Darstellung CR LF +aResult += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(%0D%0A) ); // Hex-Darstellung CR LF break; @@ -1042,7 +1042,7 @@ void ODatabaseForm::InsertTextPart( INetMIMEMessage rParent, const ::rtl::OUStr // Header -::rtl::OUString aContentDisp = ::rtl::OUString::createFromAscii(form-data; name=\); +::rtl::OUString aContentDisp (RTL_CONSTASCII_USTRINGPARAM(form-data; name=\) ); aContentDisp += rName; aContentDisp += UniString('\'); pChild-SetContentDisposition( aContentDisp ); @@ -1107,15 +1107,15 @@ sal_Bool ODatabaseForm::InsertFilePart( INetMIMEMessage rParent, const ::rtl::O // Header -::rtl::OUString aContentDisp = ::rtl::OUString::createFromAscii( form-data; name=\ ); +::rtl::OUString aContentDisp (RTL_CONSTASCII_USTRINGPARAM( form-data; name=\) ); aContentDisp += rName; aContentDisp += UniString('\'); -aContentDisp += ::rtl::OUString::createFromAscii(; filename=\); +aContentDisp += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(; filename=\) ); aContentDisp += aFileName; aContentDisp += UniString('\'); pChild-SetContentDisposition( aContentDisp ); pChild-SetContentType( aContentType ); -pChild-SetContentTransferEncoding(
[Libreoffice] [PATCH 04/12] RTL_CONSTASCII_USTRINGPARAM in components - inc
regards From 35e91cd08c4ba6fb1078a347d8736670fe6faf13 Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Mon, 15 Nov 2010 23:44:15 +0100 Subject: [PATCH 04/12] RTL_CONSTASCII_USTRINGPARAM in components - inc components/forms/source/inc should be OK now --- forms/source/inc/FormComponent.hxx |2 +- forms/source/inc/forms_module_impl.hxx |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/forms/source/inc/FormComponent.hxx b/forms/source/inc/FormComponent.hxx index a51426d..0beb592 100644 --- a/forms/source/inc/FormComponent.hxx +++ b/forms/source/inc/FormComponent.hxx @@ -104,7 +104,7 @@ namespace frm // old macro for quickly implementing XServiceInfo::getImplementationName #define IMPLEMENTATION_NAME(ImplName) \ virtual ::rtl::OUString SAL_CALL getImplementationName( ) throw(::com::sun::star::uno::RuntimeException) \ -{ return ::rtl::OUString::createFromAscii(com.sun.star.comp.forms.) + ::rtl::OUString::createFromAscii(#ImplName); } +{ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.comp.forms.) ) + ::rtl::OUString::createFromAscii(#ImplName); } class OControlModel; diff --git a/forms/source/inc/forms_module_impl.hxx b/forms/source/inc/forms_module_impl.hxx index cef7914..a1ac17d 100644 --- a/forms/source/inc/forms_module_impl.hxx +++ b/forms/source/inc/forms_module_impl.hxx @@ -135,7 +135,7 @@ namespace FORMS_MODULE_NAMESPACE { ::rtl::OUString aMainKeyName(sRootKey); aMainKeyName += *pImplName; -aMainKeyName += ::rtl::OUString::createFromAscii(/UNO/SERVICES); +aMainKeyName += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(/UNO/SERVICES) ); try { -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 05/12] RTL_CONSTASCII_USTRINGPARAM in components .. submission
regards From ae0569887c2f327499ff060a12594f50035319ac Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Mon, 15 Nov 2010 23:52:56 +0100 Subject: [PATCH 05/12] RTL_CONSTASCII_USTRINGPARAM in components .. submission components/forms/source/xforms/submission should be OK now --- forms/source/xforms/submission/replace.cxx | 18 -- .../xforms/submission/serialization_app_xml.cxx|2 +- .../xforms/submission/serialization_urlencoded.cxx |2 +- 3 files changed, 10 insertions(+), 12 deletions(-) diff --git a/forms/source/xforms/submission/replace.cxx b/forms/source/xforms/submission/replace.cxx index 3523059..dc0f0d0 100644 --- a/forms/source/xforms/submission/replace.cxx +++ b/forms/source/xforms/submission/replace.cxx @@ -67,19 +67,18 @@ CSubmission::SubmissionResult CSubmission::replace(const ::rtl::OUString aRepla if (!xLoader.is()) xLoader = Reference XComponentLoader (xFactory-createInstance( -::rtl::OUString::createFromAscii(com.sun.star.frame.Desktop)), UNO_QUERY_THROW); +::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.frame.Desktop) ) ), UNO_QUERY_THROW); // open the stream from the result... // build media descriptor Sequence PropertyValue descriptor(2); -descriptor[0] = PropertyValue(::rtl::OUString::createFromAscii( -InputStream), -1, makeAny(m_aResultStream), PropertyState_DIRECT_VALUE); -descriptor[1] = PropertyValue(::rtl::OUString::createFromAscii( -ReadOnly), -1, makeAny(sal_True), PropertyState_DIRECT_VALUE); +descriptor[0] = PropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(InputStream) ), +-1, makeAny(m_aResultStream), PropertyState_DIRECT_VALUE); +descriptor[1] = PropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(ReadOnly) ), +-1, makeAny(sal_True), PropertyState_DIRECT_VALUE); -//::rtl::OUString aURL = ::rtl::OUString::createFromAscii(private:stream); ::rtl::OUString aURL = m_aURLObj.GetMainURL(INetURLObject::NO_DECODE); -::rtl::OUString aTarget = ::rtl::OUString::createFromAscii(_default); +::rtl::OUString aTarget = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(_default) ); xLoader-loadComponentFromURL(aURL, aTarget, FrameSearchFlag::ALL, descriptor); return CSubmission::SUCCESS; @@ -88,7 +87,7 @@ CSubmission::SubmissionResult CSubmission::replace(const ::rtl::OUString aRepla if (aDocument.is()) { // parse the result stream into a new document Reference XDocumentBuilder xBuilder(xFactory-createInstance( -::rtl::OUString::createFromAscii(com.sun.star.xml.dom.DocumentBuilder)), UNO_QUERY_THROW); +::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.xml.dom.DocumentBuilder) ) ), UNO_QUERY_THROW); Reference XDocument aNewDocument = xBuilder-parse(m_aResultStream); if (aNewDocument.is()) { @@ -96,7 +95,6 @@ CSubmission::SubmissionResult CSubmission::replace(const ::rtl::OUString aRepla Reference XElement oldRoot = aDocument-getDocumentElement(); Reference XElement newRoot = aNewDocument-getDocumentElement(); -// aDocument-removeChild(Reference XNode (oldRoot, UNO_QUERY_THROW)); Reference XNode aImportedNode = aDocument-importNode(Reference XNode (newRoot, UNO_QUERY_THROW), sal_True); Reference XNode (aDocument, UNO_QUERY_THROW)-replaceChild(aImportedNode, Reference XNode (oldRoot, UNO_QUERY_THROW)); return CSubmission::SUCCESS; @@ -131,7 +129,7 @@ CSubmission::SubmissionResult CSubmission::replace(const ::rtl::OUString aRepla pHelper-m_aInteractionHandler = _xHandler; else pHelper-m_aInteractionHandler = CSS::uno::Reference XInteractionHandler (m_aFactory-createInstance( -::rtl::OUString::createFromAscii(com.sun.star.task.InteractionHandler)), UNO_QUERY); +::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.task.InteractionHandler) ) ), UNO_QUERY); OSL_ENSURE(pHelper-m_aInteractionHandler.is(), failed to create IntreractionHandler); CProgressHandlerHelper *pProgressHelper = new CProgressHandlerHelper; diff --git a/forms/source/xforms/submission/serialization_app_xml.cxx b/forms/source/xforms/submission/serialization_app_xml.cxx index 2e90215..2f96295 100644 --- a/forms/source/xforms/submission/serialization_app_xml.cxx +++ b/forms/source/xforms/submission/serialization_app_xml.cxx @@ -45,7 +45,7 @@ CSerializationAppXML::CSerializationAppXML() : m_aFactory(utl::getProcessServiceFactory()) , m_aPipe(CSS::uno::Reference CSS::io::XOutputStream (m_aFactory-createInstance( -
[Libreoffice] [PATCH 06/12] RTL_CONSTASCII_USTRINGPARAM components xpathlib
regards From 2bf8ae72c9787a733cb2992d8c409593fb1f7bab Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Mon, 15 Nov 2010 23:57:03 +0100 Subject: [PATCH 06/12] RTL_CONSTASCII_USTRINGPARAM components xpathlib components/forms/source/xforms/xpathlib should now be OK --- forms/source/xforms/xpathlib/extension.cxx |4 ++-- forms/source/xforms/xpathlib/xpathlib.cxx |8 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/forms/source/xforms/xpathlib/extension.cxx b/forms/source/xforms/xpathlib/extension.cxx index 26dfb55..8c29f0f 100644 --- a/forms/source/xforms/xpathlib/extension.cxx +++ b/forms/source/xforms/xpathlib/extension.cxx @@ -54,14 +54,14 @@ Reference XInterface SAL_CALL CLibxml2XFormsExtension::Create( ::rtl::OUString SAL_CALL CLibxml2XFormsExtension::getImplementationName_Static() { // printf(_implname_\n); -return ::rtl::OUString::createFromAscii(com.sun.star.comp.xml.xpath.XFormsExtension); +return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.comp.xml.xpath.XFormsExtension) ); } Sequence ::rtl::OUString SAL_CALL CLibxml2XFormsExtension::getSupportedServiceNames_Static() { // printf(_services_\n); Sequence ::rtl::OUString aSequence(1); -aSequence[0] = ::rtl::OUString::createFromAscii(com.sun.star.xml.xpath.XPathExtension); +aSequence[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.xml.xpath.XPathExtension) ); return aSequence; } diff --git a/forms/source/xforms/xpathlib/xpathlib.cxx b/forms/source/xforms/xpathlib/xpathlib.cxx index 21170a6..1b212af 100644 --- a/forms/source/xforms/xpathlib/xpathlib.cxx +++ b/forms/source/xforms/xpathlib/xpathlib.cxx @@ -311,10 +311,10 @@ static sal_Bool parseDateTime(const ::rtl::OUString aString, DateTime aDateTim sal_Int32 nDateLength = 10; sal_Int32 nTimeLength = 8; -::rtl::OUString aDateTimeSep = ::rtl::OUString::createFromAscii(T); -::rtl::OUString aDateSep = ::rtl::OUString::createFromAscii(-); -::rtl::OUString aTimeSep = ::rtl::OUString::createFromAscii(:); -::rtl::OUString aUTCString = ::rtl::OUString::createFromAscii(Z); +::rtl::OUString aDateTimeSep = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(T) ); +::rtl::OUString aDateSep = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(-) ); +::rtl::OUString aTimeSep = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(:) ); +::rtl::OUString aUTCString = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(Z) ); ::rtl::OUString aDateString = aDateTimeString.copy(0, nDateLength); ::rtl::OUString aTimeString = aDateTimeString.copy(nDateLength+1, nTimeLength); -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 07/12] RTL_CONSTASCII_USTRINGPARAM components in runtime
regards From ab42a6a840da58f039398b7f64eaa68c4560b3cd Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Mon, 15 Nov 2010 23:59:34 +0100 Subject: [PATCH 07/12] RTL_CONSTASCII_USTRINGPARAM components in runtime components/forms/source/runtime should be OK now --- forms/source/runtime/formoperations.cxx |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/forms/source/runtime/formoperations.cxx b/forms/source/runtime/formoperations.cxx index e857787..06382b2 100644 --- a/forms/source/runtime/formoperations.cxx +++ b/forms/source/runtime/formoperations.cxx @@ -414,7 +414,7 @@ namespace frm ::rtl::OUString sValue = ::rtl::OUString::valueOf( sal_Int32( nCount ) ); if ( !bFinalCount ) -sValue += ::rtl::OUString::createFromAscii( * ); +sValue += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( *) ); aState.State = sValue; aState.Enabled = sal_True; -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 08/12] RTL_CONSTASCII_USTRINGPARAM in components misc
regards From b82fc44186adb943a95eeaa369d49719ea47fd6c Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Tue, 16 Nov 2010 00:09:27 +0100 Subject: [PATCH 08/12] RTL_CONSTASCII_USTRINGPARAM in components misc components/forms/source/misc should be OK now --- forms/source/misc/InterfaceContainer.cxx | 10 +- forms/source/misc/limitedformats.cxx |6 +++--- forms/source/misc/services.cxx |8 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/forms/source/misc/InterfaceContainer.cxx b/forms/source/misc/InterfaceContainer.cxx index fd54c4c..400f2d7 100644 --- a/forms/source/misc/InterfaceContainer.cxx +++ b/forms/source/misc/InterfaceContainer.cxx @@ -96,7 +96,7 @@ lcl_hasVbaEvents( const Sequence ScriptEventDescriptor sEvents ) const ScriptEventDescriptor* pEnd = ( pDesc + sEvents.getLength() ); for ( ; pDesc != pEnd; ++pDesc ) { -if ( pDesc-ScriptType.equals( rtl::OUString::createFromAscii( VBAInterop ) ) ) +if ( pDesc-ScriptType.equals( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(VBAInterop) ) ) ) return true; } return false; @@ -112,7 +112,7 @@ lcl_stripVbaEvents( const Sequence ScriptEventDescriptor sEvents ) sal_Int32 nCopied = 0; for ( ; pDesc != pEnd; ++pDesc ) { -if ( !pDesc-ScriptType.equals( rtl::OUString::createFromAscii( VBAInterop ) ) ) +if ( !pDesc-ScriptType.equals( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(VBAInterop) ) ) ) { sStripped[ nCopied++ ] = *pDesc; } @@ -134,7 +134,7 @@ void OInterfaceContainer::impl_addVbEvents_nolck_nothrow( const sal_Int32 i_nIn break; Reference XMultiServiceFactory xDocFac( xDoc, UNO_QUERY_THROW ); -Reference XCodeNameQuery xNameQuery( xDocFac-createInstance( rtl::OUString::createFromAscii( ooo.vba.VBACodeNameProvider ) ), UNO_QUERY ); +Reference XCodeNameQuery xNameQuery( xDocFac-createInstance( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(ooo.vba.VBACodeNameProvider) ) ), UNO_QUERY ); if ( !xNameQuery.is() ) break; @@ -152,9 +152,9 @@ void OInterfaceContainer::impl_addVbEvents_nolck_nothrow( const sal_Int32 i_nIn Reference XPropertySet xProps( xElement, UNO_QUERY_THROW ); ::rtl::OUString sServiceName; -xProps-getPropertyValue( rtl::OUString::createFromAscii(DefaultControl ) ) = sServiceName; +xProps-getPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DefaultControl) ) ) = sServiceName; -Reference ooo::vba::XVBAToOOEventDescGen xDescSupplier( m_xServiceFactory-createInstance( rtl::OUString::createFromAscii( ooo.vba.VBAToOOEventDesc ) ), UNO_QUERY_THROW ); +Reference ooo::vba::XVBAToOOEventDescGen xDescSupplier( m_xServiceFactory-createInstance( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(ooo.vba.VBAToOOEventDesc) ) ), UNO_QUERY_THROW ); Reference XInterface xInterface = m_xServiceFactory-createInstance( sServiceName ); Sequence ScriptEventDescriptor vbaEvents = xDescSupplier-getEventDescriptions( xInterface, sCodeName ); // register the vba script events diff --git a/forms/source/misc/limitedformats.cxx b/forms/source/misc/limitedformats.cxx index d63cb79..5951697 100644 --- a/forms/source/misc/limitedformats.cxx +++ b/forms/source/misc/limitedformats.cxx @@ -64,8 +64,8 @@ namespace frm //- static const Locale getLocale(LocaleType _eType) { -static const Locale s_aEnglishUS( ::rtl::OUString::createFromAscii(en), ::rtl::OUString::createFromAscii(us), ::rtl::OUString() ); -static const Locale s_aGerman( ::rtl::OUString::createFromAscii(de), ::rtl::OUString::createFromAscii(DE), ::rtl::OUString() ); +static const Locale s_aEnglishUS( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(en) ), ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(us) ), ::rtl::OUString() ); +static const Locale s_aGerman( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(de) ), ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DE) ), ::rtl::OUString() ); static const ::rtl::OUString s_sEmptyString; static const Locale s_aSystem( s_sEmptyString, s_sEmptyString, s_sEmptyString ); @@ -342,7 +342,7 @@ namespace frm if (!bFoundIt) { // somebody gave us an format which we can't translate -::rtl::OUString sMessage = ::rtl::OUString::createFromAscii(This control supports only a very limited number of formats.); +::rtl::OUString sMessage (RTL_CONSTASCII_USTRINGPARAM(This control supports only a very limited number of formats.) ); throw IllegalArgumentException(sMessage, NULL, 2); } diff --git a/forms/source/misc/services.cxx b/forms/source/misc/services.cxx index a06f4be..844180f 100644 ---
[Libreoffice] [PATCH 09/12] RTL_CONSTASCII_USTRINGPARAM in components - xstor
regards From 14c040c9a7e20c49c2edb9fdc9185a2fda93362f Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Tue, 16 Nov 2010 00:36:35 +0100 Subject: [PATCH 09/12] RTL_CONSTASCII_USTRINGPARAM in components - xstor components/package/source/xstor should be OK now --- package/source/xstor/owriteablestream.cxx| 80 +++--- package/source/xstor/selfterminatefilestream.cxx |2 +- package/source/xstor/switchpersistencestream.cxx |2 +- package/source/xstor/xfactory.cxx| 12 ++-- 4 files changed, 48 insertions(+), 48 deletions(-) diff --git a/package/source/xstor/owriteablestream.cxx b/package/source/xstor/owriteablestream.cxx index b68162e..7db6a31 100644 --- a/package/source/xstor/owriteablestream.cxx +++ b/package/source/xstor/owriteablestream.cxx @@ -121,14 +121,14 @@ void SetEncryptionKeyProperty_Impl( const uno::Reference beans::XPropertySet if ( !xPropertySet.is() ) throw uno::RuntimeException(); -::rtl::OUString aString_EncryptionKey = ::rtl::OUString::createFromAscii( EncryptionKey ); +::rtl::OUString aString_EncryptionKey (RTL_CONSTASCII_USTRINGPARAM(EncryptionKey) ); try { xPropertySet-setPropertyValue( aString_EncryptionKey, uno::makeAny( aKey ) ); } catch ( uno::Exception aException ) { ::package::StaticAddLog( aException.Message ); -::package::StaticAddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX Can't set encryption ) ) ); +::package::StaticAddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX Can't set encryption) ) ); OSL_ENSURE( sal_False, Can't write encryption related properties!\n ); throw io::IOException(); // TODO } @@ -141,7 +141,7 @@ uno::Any GetEncryptionKeyProperty_Impl( const uno::Reference beans::XPropertySe if ( !xPropertySet.is() ) throw uno::RuntimeException(); -::rtl::OUString aString_EncryptionKey = ::rtl::OUString::createFromAscii( EncryptionKey ); +::rtl::OUString aString_EncryptionKey (RTL_CONSTASCII_USTRINGPARAM(EncryptionKey) ); try { return xPropertySet-getPropertyValue( aString_EncryptionKey ); } @@ -180,7 +180,7 @@ sal_Bool KillFile( const ::rtl::OUString aURL, const uno::Reference lang::XMul { uno::Reference ucb::XSimpleFileAccess xAccess( xFactory-createInstance ( -::rtl::OUString::createFromAscii( com.sun.star.ucb.SimpleFileAccess ) ), +::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.ucb.SimpleFileAccess ) ) ), uno::UNO_QUERY ); if ( xAccess.is() ) @@ -192,7 +192,7 @@ sal_Bool KillFile( const ::rtl::OUString aURL, const uno::Reference lang::XMul catch( uno::Exception aException ) { ::package::StaticAddLog( aException.Message ); -::package::StaticAddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX Quiet exception ) ) ); +::package::StaticAddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX Quiet exception) ) ); } return bRet; @@ -206,21 +206,21 @@ const sal_Int32 n_ConstBufferSize = 32000; ::rtl::OUString aTempURL; uno::Reference beans::XPropertySet xTempFile( -xFactory-createInstance( ::rtl::OUString::createFromAscii( com.sun.star.io.TempFile ) ), +xFactory-createInstance( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.io.TempFile) ) ), uno::UNO_QUERY ); if ( !xTempFile.is() ) throw uno::RuntimeException(); // TODO try { -xTempFile-setPropertyValue( ::rtl::OUString::createFromAscii( RemoveFile ), uno::makeAny( sal_False ) ); -uno::Any aUrl = xTempFile-getPropertyValue( ::rtl::OUString::createFromAscii( Uri ) ); +xTempFile-setPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(RemoveFile) ), uno::makeAny( sal_False ) ); +uno::Any aUrl = xTempFile-getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(Uri) ) ); aUrl = aTempURL; } catch ( uno::Exception aException ) { ::package::StaticAddLog( aException.Message ); -::package::StaticAddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX Quiet exception ) ) ); +::package::StaticAddLog( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX Quiet exception) ) ); } if ( !aTempURL.getLength() ) @@ -235,7 +235,7 @@ uno::Reference io::XStream CreateMemoryStream( const uno::Reference lang::XM if ( !xFactory.is() ) throw uno::RuntimeException(); -return uno::Reference io::XStream ( xFactory-createInstance ( ::rtl::OUString::createFromAscii( com.sun.star.comp.MemoryStream ) ), uno::UNO_QUERY_THROW ); +return uno::Reference io::XStream ( xFactory-createInstance (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.comp.MemoryStream) ) ),
[Libreoffice] [PATCH 10/12] RTL_CONSTASCII_USTRINGPARAM components - zippackage
regards From 2f86aef63beb00992aa720ddf86c5236c6fecc26 Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Tue, 16 Nov 2010 00:40:44 +0100 Subject: [PATCH 10/12] RTL_CONSTASCII_USTRINGPARAM components - zippackage components/package/source/zippackage should be OK now --- package/source/zippackage/ZipPackage.cxx|6 +++--- package/source/zippackage/zipfileaccess.cxx |6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/package/source/zippackage/ZipPackage.cxx b/package/source/zippackage/ZipPackage.cxx index 89767c9..7a73f4a 100644 --- a/package/source/zippackage/ZipPackage.cxx +++ b/package/source/zippackage/ZipPackage.cxx @@ -1435,7 +1435,7 @@ void SAL_CALL ZipPackage::commitChanges() { // write directly in case of local file uno::Reference ::com::sun::star::ucb::XSimpleFileAccess xSimpleAccess( -m_xFactory-createInstance( ::rtl::OUString::createFromAscii( com.sun.star.ucb.SimpleFileAccess ) ), +m_xFactory-createInstance( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.ucb.SimpleFileAccess) ) ), uno::UNO_QUERY ); OSL_ENSURE( xSimpleAccess.is(), Can't instatiate SimpleFileAccess service!\n ); uno::Reference io::XTruncate xOrigTruncate; @@ -1531,9 +1531,9 @@ void ZipPackage::DisconnectFromTargetAndThrowException_Impl( const uno::Referenc ::rtl::OUString aTempURL; try { uno::Reference beans::XPropertySet xTempFile( xTempStream, uno::UNO_QUERY_THROW ); -uno::Any aUrl = xTempFile-getPropertyValue( ::rtl::OUString::createFromAscii( Uri ) ); +uno::Any aUrl = xTempFile-getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(Uri) ) ); aUrl = aTempURL; -xTempFile-setPropertyValue( ::rtl::OUString::createFromAscii( RemoveFile ), +xTempFile-setPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(RemoveFile) ), uno::makeAny( sal_False ) ); } catch ( uno::Exception ) diff --git a/package/source/zippackage/zipfileaccess.cxx b/package/source/zippackage/zipfileaccess.cxx index 88b4530..7932df2 100644 --- a/package/source/zippackage/zipfileaccess.cxx +++ b/package/source/zippackage/zipfileaccess.cxx @@ -444,15 +444,15 @@ void SAL_CALL OZipFileAccess::removeEventListener( const uno::Reference lang::X uno::Sequence ::rtl::OUString SAL_CALL OZipFileAccess::impl_staticGetSupportedServiceNames() { uno::Sequence ::rtl::OUString aRet(2); -aRet[0] = ::rtl::OUString::createFromAscii(com.sun.star.packages.zip.ZipFileAccess); -aRet[1] = ::rtl::OUString::createFromAscii(com.sun.star.comp.packages.zip.ZipFileAccess); +aRet[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.packages.zip.ZipFileAccess) ); +aRet[1] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.comp.packages.zip.ZipFileAccess) ); return aRet; } //- ::rtl::OUString SAL_CALL OZipFileAccess::impl_staticGetImplementationName() { -return ::rtl::OUString::createFromAscii(com.sun.star.comp.package.zip.ZipFileAccess); +return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.comp.package.zip.ZipFileAccess) ); } //- -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 11/12] RTL_CONSTASCII_USTRINGPARAM components - zipapi
regards From 10ef6191861dab201993db7c01e5adf4d12fc415 Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Tue, 16 Nov 2010 00:43:12 +0100 Subject: [PATCH 11/12] RTL_CONSTASCII_USTRINGPARAM components - zipapi components/package/source/zipapi should be OK now --- package/source/zipapi/XUnbufferedStream.cxx |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package/source/zipapi/XUnbufferedStream.cxx b/package/source/zipapi/XUnbufferedStream.cxx index de2a69f..35e9dfe 100644 --- a/package/source/zipapi/XUnbufferedStream.cxx +++ b/package/source/zipapi/XUnbufferedStream.cxx @@ -301,8 +301,8 @@ sal_Int32 SAL_CALL XUnbufferedStream::readBytes( Sequence sal_Int8 aData, sa if ( 0 ) { uno::Reference lang::XMultiServiceFactory xFactory = comphelper::getProcessServiceFactory(); -uno::Reference ucb::XSimpleFileAccess xAccess( xFactory-createInstance( ::rtl::OUString::createFromAscii( com.sun.star.ucb.SimpleFileAccess ) ), uno::UNO_QUERY ); -uno::Reference io::XOutputStream xOut = xAccess-openFileWrite( ::rtl::OUString::createFromAscii( file:///d:/777/Encrypted/picture ) ); +uno::Reference ucb::XSimpleFileAccess xAccess( xFactory-createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.ucb.SimpleFileAccess) ) ), uno::UNO_QUERY ); +uno::Reference io::XOutputStream xOut = xAccess-openFileWrite(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( file:///d:/777/Encrypted/picture) ) ); xOut-writeBytes( aData ); xOut-closeOutput(); } -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 12/12] RTL_CONSTASCII_USTRINGPARAM in components - xmlsecurity- helpd
regards From ed5503c8a32a6fa2d41b73e199e6184eb9e0b15b Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Tue, 16 Nov 2010 20:26:46 +0100 Subject: [PATCH 12/12] RTL_CONSTASCII_USTRINGPARAM in components - xmlsecurity- helpd remove rtl::oustring::createfromascii(foo) and code clean up: suppression of commented out code --- xmlsecurity/source/helper/xmlsignaturehelper.cxx | 37 +- xmlsecurity/source/helper/xsecctl.cxx| 81 +- xmlsecurity/source/helper/xsecctl.hxx| 17 - xmlsecurity/source/helper/xsecparser.cxx | 33 ++--- xmlsecurity/source/helper/xsecparser.hxx |2 - xmlsecurity/source/helper/xsecverify.cxx |8 -- 6 files changed, 9 insertions(+), 169 deletions(-) diff --git a/xmlsecurity/source/helper/xmlsignaturehelper.cxx b/xmlsecurity/source/helper/xmlsignaturehelper.cxx index b46d8ba..baeee83 100644 --- a/xmlsecurity/source/helper/xmlsignaturehelper.cxx +++ b/xmlsecurity/source/helper/xmlsignaturehelper.cxx @@ -170,11 +170,6 @@ void XMLSignatureHelper::SetX509Certificate( void XMLSignatureHelper::SetDateTime( sal_Int32 nSecurityId, const Date rDate, const Time rTime ) { -/* -rtl::OUString aDate = String::CreateFromInt32( rDate.GetDate() ); -rtl::OUString aTime = String::CreateFromInt32( rTime.GetTime() ); -mpXSecController-setDateTime( nSecurityId, aDate, aTime ); -*/ ::com::sun::star::util::DateTime stDateTime; stDateTime.HundredthSeconds = (::sal_uInt16)rTime.Get100Sec(); stDateTime.Seconds = (::sal_uInt16)rTime.GetSec(); @@ -261,16 +256,10 @@ bool XMLSignatureHelper::CreateAndWriteSignature( const uno::Reference xml::sax /* * create a signature listener */ -/* -ImplXMLSignatureListener* pSignatureListener = new ImplXMLSignatureListener( -LINK( this, XMLSignatureHelper, SignatureCreationResultListener ), -LINK( this, XMLSignatureHelper, SignatureVerifyResultListener ), -LINK( this, XMLSignatureHelper, StartVerifySignatureElement ) ); -*/ + /* * configure the signature creation listener */ -//mpXSecController-setSignatureCreationResultListener( pSignatureListener ); /* * write signatures @@ -283,7 +272,6 @@ bool XMLSignatureHelper::CreateAndWriteSignature( const uno::Reference xml::sax /* * clear up the signature creation listener */ -//mpXSecController-setSignatureCreationResultListener( NULL ); return !mbError; } @@ -310,7 +298,6 @@ bool XMLSignatureHelper::ReadAndVerifySignature( const com::sun::star::uno::Refe * prepare ParserInputSrouce */ xml::sax::InputSource aParserInput; -// aParserInput.sSystemId = ouName; aParserInput.aInputStream = xInputStream; /* @@ -319,7 +306,7 @@ bool XMLSignatureHelper::ReadAndVerifySignature( const com::sun::star::uno::Refe uno::Reference lang::XMultiComponentFactory xMCF( mxCtx-getServiceManager() ); uno::Reference xml::sax::XParser xParser( xMCF-createInstanceWithContext( -rtl::OUString::createFromAscii(com.sun.star.xml.sax.Parser), mxCtx ), +rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(com.sun.star.xml.sax.Parser) ), mxCtx ), uno::UNO_QUERY ); DBG_ASSERT( xParser.is(), Can't create parser ); @@ -341,7 +328,6 @@ bool XMLSignatureHelper::ReadAndVerifySignature( const com::sun::star::uno::Refe /* * configure the signature verify listener */ -//mpXSecController-setSignatureVerifyResultListener( pSignatureListener ); /* * setup the connection: @@ -382,7 +368,6 @@ bool XMLSignatureHelper::ReadAndVerifySignature( const com::sun::star::uno::Refe /* * clear up the signature verify listener */ -//mpXSecController-setSignatureVerifyResultListener( NULL ); /* * release the signature reader @@ -418,24 +403,6 @@ sal_Int32 XMLSignatureHelper::GetSecurityEnvironmentNumber() } -/* -void XMLSignatureHelper::createSecurityContext( rtl::OUString tokenPath ) -{ -if ( !mxSEInitializer.is() ) -ImplCreateSEInitializer(); - -mxSecurityContext = mxSEInitializer-createSecurityContext(tokenPath); -} - -void XMLSignatureHelper::freeSecurityContext() -{ -if ( !mxSEInitializer.is() ) -ImplCreateSEInitializer(); - -mxSEInitializer-freeSecurityContext( mxSecurityContext ); -} -*/ - IMPL_LINK( XMLSignatureHelper, SignatureCreationResultListener, XMLSignatureCreationResult*, pResult ) { maCreationResults.insert( maCreationResults.begin() + maCreationResults.size(), *pResult ); diff --git a/xmlsecurity/source/helper/xsecctl.cxx b/xmlsecurity/source/helper/xsecctl.cxx index 864d6de..33c7fde 100644 --- a/xmlsecurity/source/helper/xsecctl.cxx +++ b/xmlsecurity/source/helper/xsecctl.cxx @@ -1365,46
Re: [Libreoffice] [PUSHED] Re: [PATCH 11/12] RTL_CONSTASCII_USTRINGPARAM components - zipapi
Hello, I saw it too, this allow me to rize a question. My firt though was to remove this one - since commentted out - but I left it there not knowing if this was a way to handle this here.? For my taste, I would have remove it. - Debug it at home, not on public branch... Your input? regards On 11/17/2010 05:39 PM, Caolán McNamara wrote: On Tue, 2010-11-16 at 22:50 +0100, Pierre-André Jacquod wrote: regards heh, I had a bit of a moment when I saw file:///d:/777/Encrypted/picture in there before I realized this is someones debugging code with an if (0) around it. Anyway, that's beside the point. Your changes were good, thanks for them, now pushed. C. ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] calc: some code deletion and comments translation
Hello, have done as well some small comment translations. regards From c29ea5e11ccc679166b5a0c5be2df925328465fb Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Sun, 21 Nov 2010 12:06:01 +0100 Subject: [PATCH] remove dead code in calc core data and some comments translation --- sc/source/core/data/documen5.cxx | 23 +-- sc/source/core/data/dptabsrc.cxx | 17 ++--- 2 files changed, 7 insertions(+), 33 deletions(-) diff --git a/sc/source/core/data/documen5.cxx b/sc/source/core/data/documen5.cxx index 8a2ea15..c9884b5 100644 --- a/sc/source/core/data/documen5.cxx +++ b/sc/source/core/data/documen5.cxx @@ -233,7 +233,7 @@ BOOL ScDocument::HasChartAtPoint( SCTAB nTab, const Point rPos, String* pName ) if (pName) pName-Erase(); -return FALSE; // nix gefunden +return FALSE; // nothing found } void ScDocument::UpdateChartArea( const String rChartName, @@ -434,10 +434,7 @@ void ScDocument::UpdateChartArea( const String rChartName, pChartListenerCollection-ChangeListening( rChartName, aNewRanges ); -// ((SdrOle2Obj*)pObject)-GetNewReplacement(); -// pObject-ActionChanged(); - -return; // nicht weitersuchen +return; // do not search anymore } } pObject = aIter.Next(); @@ -555,9 +552,6 @@ void ScDocument::UpdateChartRef( UpdateRefMode eUpdateRefMode, if ( bChanged ) { { -//SetChartRangeList( pChartListener-GetString(), aNewRLR ); -//pChartListener-ChangeListening( aNewRLR, bDataChanged ); - // Force the chart to be loaded now, so it registers itself for UNO events. // UNO broadcasts are done after UpdateChartRef, so the chart will get this // reference change. @@ -683,7 +677,7 @@ void ScDocument::UpdateChartListenerCollection() else { ScRange aRange; -// Range fuer Suche unwichtig +// Range for searching is not important ScChartListener aCLSearcher( EMPTY_STRING, this, aRange ); for (SCTAB nTab=0; nTab=MAXTAB; nTab++) { @@ -732,20 +726,13 @@ void ScDocument::UpdateChartListenerCollection() // unable to set the data. So a chart from the // same document is treated like a chart with // own data for the time being. -#if 0 + // data provider -uno::Reference chart2::data::XDataProvider xDataProvider = new -ScChart2DataProvider( this ); -xReceiver-attachDataProvider( xDataProvider ); // number formats supplier -uno::Reference util::XNumberFormatsSupplier xNumberFormatsSupplier( pShell-GetModel(), uno::UNO_QUERY ); -xReceiver-attachNumberFormatsSupplier( xNumberFormatsSupplier ); + // data ? // how to set?? Defined in XML-file, which is already loaded!!! // = we have to do this stuff here, BEFORE the chart is actually loaded - -bIsChart = true; -#endif } if (!bIsChart) diff --git a/sc/source/core/data/dptabsrc.cxx b/sc/source/core/data/dptabsrc.cxx index b0d7c71..b75dd43 100644 --- a/sc/source/core/data/dptabsrc.cxx +++ b/sc/source/core/data/dptabsrc.cxx @@ -301,7 +301,6 @@ void ScDPSource::SetOrientation(long nColumn, USHORT nNew) case sheet::DataPilotFieldOrientation_PAGE: nPageDims[nPageDimCount++] = nColumn; break; -// Wang Xu Ming -- 2009-9-1 // DataPilot Migration - CachePerformance case sheet::DataPilotFieldOrientation_HIDDEN: break; @@ -906,8 +905,8 @@ void ScDPSource::CreateRes_Impl() aInitState.AddMember( nPageDims[i], GetMemberId( nPageDims[i], pDim-GetSelectedData() ) ); } -pColResRoot = new ScDPResultMember( pResData, /*NULL, NULL, NULL, */bColumnGrand ); -pRowResRoot = new ScDPResultMember( pResData, /*NULL, NULL, NULL, */bRowGrand ); +pColResRoot = new ScDPResultMember( pResData, bColumnGrand ); +pRowResRoot = new ScDPResultMember( pResData, bRowGrand ); FillCalcInfo(false, aInfo, bHasAutoShow); long nColLevelCount = aInfo.aColLevels.size(); @@ -1089,8 +1088,6 @@ void ScDPSource::FillMemberResults() for (long i=0; inColLevelCount; i++) pColResults[i].realloc(nColDimSize); -// ScDPResultDimension* pColResDim = pColResRoot-GetChildDimension(); -// pColResDim-FillMemberResults( pColResults, 0,
[Libreoffice] further removing of dead code
Hello, here in components some other pieces to delete. Again some small parts in case I was to generous in deleting. regards From 1535d5e774e7d1ef08696344be8fcdfc6828f2c3 Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Sun, 21 Nov 2010 12:10:15 +0100 Subject: [PATCH 1/5] remove dead code components workben --- extensions/workben/testpgp.cxx | 93 +--- 1 files changed, 2 insertions(+), 91 deletions(-) diff --git a/extensions/workben/testpgp.cxx b/extensions/workben/testpgp.cxx index 1a7902c..482a832 100644 --- a/extensions/workben/testpgp.cxx +++ b/extensions/workben/testpgp.cxx @@ -512,75 +512,6 @@ inline rtl::OWString S2U (const sal_Char *ascii) return rtl::OWString::createFromAscii (ascii); } -#if 0 /* OLD */ - -/* - * queryModuleActivator. - */ -BOOL queryModuleActivator ( -const XServiceManagerRef rxManager, -XServiceActivatorRef rxActivator) -{ -XServiceProviderRef xProv; -XInterfaceRef xProvInst; - -xProv = rxManager-queryServiceProvider ( -Lstardiv.uno.ServiceActivator.module); -if (!xProv.is()) -{ -printf (Error: no ServiceActivator service.\n); -return FALSE; -} - -xProvInst = xProv-createInstance(); -if (!xProvInst.is()) -{ -printf (Error: no ServiceActivator instance.\n); -return FALSE; -} - -return xProvInst-queryInterface ( -XServiceActivator::getSmartUik(), rxActivator); -} - -/* - * install. - */ -BOOL install ( -const XServiceActivatorRef rxActivator, -const char *prefix) -{ -String aModule (module://); -char pBuffer[1024]; - -vos:ORealDynamicLoader::computeModuleName ( -prefix, pBuffer, sizeof(pBuffer)); -aModule += pBuffer; - -return rxActivator-install ( -StringToUString (aModule, CHARSET_SYSTEM)); -} - -/* - * uninstall. - */ -BOOL uninstall ( -const XServiceActivatorRef rxActivator, -const char *prefix) -{ -String aModule (module://); -char pBuffer[1024]; - -vos::ORealDynamicLoader::computeModuleName ( -prefix, pBuffer, sizeof(pBuffer)); -aModule += pBuffer; - -return rxActivator-deinstall ( -StringToUString (aModule, CHARSET_SYSTEM)); -} - -#endif /* OLD */ - /* * main. */ @@ -675,17 +606,7 @@ int SAL_CALL main (int argc, char **argv) if (nOptions OPTION_INSTALL) { -#if 0 /* OLD */ -XServiceActivatorRef xActivator; -if (queryModuleActivator (xManager, xActivator)) -{ -if (install (xActivator, pgp)) -printf (Module PGP installed.\n); -else -printf (Error: module PGP not installed.\n); -} -nOptions = ~OPTION_INSTALL; -#endif /* OLD */ + } if (nOptions (OPTION_DECRYPT | OPTION_ENCRYPT | OPTION_SIGN)) @@ -823,17 +744,7 @@ int SAL_CALL main (int argc, char **argv) if (nOptions OPTION_UNINSTALL) { -#if 0 /* OLD */ -XServiceActivatorRef xActivator; -if (queryModuleActivator (xManager, xActivator)) -{ -if (uninstall (xActivator, pgp)) -printf (Module PGP uninstalled.\n); -else -printf (Error: module PGP not uninstalled.\n); -} -nOptions = ~OPTION_UNINSTALL; -#endif /* OLD */ + } return 0; -- 1.7.1 From 32d97c884e80196ab3172b144b09f3c73624d55c Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Sun, 21 Nov 2010 12:24:47 +0100 Subject: [PATCH 2/5] remove dead code in components plugin unx --- extensions/source/plugin/unx/npnapi.cxx | 21 - 1 files changed, 0 insertions(+), 21 deletions(-) diff --git a/extensions/source/plugin/unx/npnapi.cxx b/extensions/source/plugin/unx/npnapi.cxx index f1f58fc..35c60de 100644 --- a/extensions/source/plugin/unx/npnapi.cxx +++ b/extensions/source/plugin/unx/npnapi.cxx @@ -340,27 +340,6 @@ static const char* l_NPN_UserAgent( NPP instance ) return pAgent; } -#if 0 -static void l_NPN_Version( int* major, int* minor, int* net_major, int* net_minor ) -{ -MediatorMessage* pMes = pConnector- -Transact( eNPN_Version, - NULL ); - -if( ! pMes ) -return; - -*major = pMes-GetUINT32(); -*minor = pMes-GetUINT32(); -*net_major = pMes-GetUINT32(); -*net_minor = pMes-GetUINT32(); - -medDebug( 1, pluginapp: NPN_Version: results %d %d, %d %d\n, *major, *minor, *net_major, *net_minor ); - -delete pMes; -} -#endif - static int32 l_NPN_Write( NPP instance, NPStream* stream, int32 len, void* buffer ) { UINT32 nFileID = pConnector-GetStreamID( stream ); -- 1.7.1 From 784685ee75435fd3d8507cc4565e7ad7a859418b Mon Sep 17 00:00:00 2001 From: pjacquod pjacq...@alumni.ethz.ch Date: Sun, 21 Nov 2010 12:32:21 +0100 Subject: [PATCH 3/5] dead code removed components plugin base ---
Re: [Libreoffice] Building problem, sc/source/ui/src/optdlg.src gives syntax error
On 11/22/2010 07:16 AM, Joost Eekhoorn wrote: Hi, PROBLEM 1: I am trying to make again, but it fails on ./sc/source/ui/src/optdlg.src I did remove the unxlngx6.pro http://unxlngx6.pro in the sc, and did the build there locally and it gave: Making:ui.srs { ^ f4101: optdlg.src, line 118: Warning in the object (Type: FixedLine): Resources without name are ignored. { ^ f640: optdlg.src, line 118: Error: syntax error f256: Error: !! 1 Error found!! Error starting rsc2 compiler dmake: Error code 1, while making '../../../unxlngx6.pro/srs/ui.srs http://unxlngx6.pro/srs/ui.srs' hello, rm -rf * ./download take a while but solve the problem since starting again from a fresh repository. Not the nicest way, but the easiest. regards ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] Building problem, sc/source/ui/src/optdlg.src gives syntax error
Hi, I know...but I had exactly this problem once, and the make clean did not solved the issue. At the end, I did this an evening, and all went well the next day. I would be interested to know if the make clean works for you. Thanks Pierre-André On 11/22/2010 10:48 AM, Michael Meeks wrote: On Mon, 2010-11-22 at 07:57 +0100, Pierre-André Jacquod wrote: hello, rm -rf * ./download Oh - that is going to waste a -lot- of time ;-) Just remove the build output, not the ( pristine ) git repos. 'make clean' should do that in the top-level. HTH, Michael. ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] [Pushed] further removing of dead code
Hi, thanks. Left it back, if someone would have needed to know something was there. regards On 11/22/2010 01:14 PM, Michael Meeks wrote: Hi Pierre, On Sun, 2010-11-21 at 15:28 +0100, Pierre-André Jacquod wrote: here in components some other pieces to delete. Again some small parts in case I was to generous in deleting. Thanks ! :-) I pushed this; I also went back and cleaned up some related comments that were not removed: nfuncs.cxx: /* provisional code should there ever be NPNVariables that we actually want to query from the PluginContext */ - followed by removal of the chunk of code this comment referred to - so I removed the comment too ;-) - xplugin.cxx, securityenvironment + similar issues here. Anyhow - all pushed now; thanks ! :-) ATB, Michael. ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] [patch] binfilter: cleanup and compilation warnings removal.
Hi, - Unused parameters in some methods are triggering compilation warnings. Should I fix them by removing the parameter name ? Sounds reasonable. Really though - the binfilter is not the best place to focus cleanups (though I appreciate it is fugly old code ;-) Most people will not want it (only useful for decade-old binary StarOffice file formats). Okay, but at compile time, there is really a flow of warning. So I wanted also to work a bit on it. That's just cleaning, not really improving. But when I see: clone/filters/binfilter/bf_sc/source/core/tool/sc_token.cxx:1573:28: warning: comparison is always false due to limited range of data type and the source code is (it starts form line 1573.. if( n MAXSTRLEN-1 ) /*N*/ { /*?*/ DBG_ERRORFILE( bad string array boundary ); /*?*/ USHORT nDiff = n - (MAXSTRLEN-1); /*?*/ n = MAXSTRLEN-1; /*?*/ rStream.Read( c, n ); /*?*/ rStream.SeekRel( nDiff ); /*N*/ } /*N*/ else /*N*/ rStream.Read( c, n ); /*N*/ cStr[ n ] = 0; would as cleaning be acceptable to change the code to: /*N*/ rStream.Read( c, n ); /*N*/ cStr[ n ] = 0; ??? I wonder... If yes, a lot of code can be removed (between 40 and 60 comparisons are generating this warning). So I would prefer not starting and beeing told not to touch it afterward. Thanks Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] [patch] binfilter: cleanup and compilation warnings removal.
On 11/23/2010 09:23 AM, Joachim Trémouroux wrote: Hi Michael, I will work on this. I see two possible ways: Ok Michael, then I will continue within binfilter... ::-)) But a additional question: From Norbert Thiebaud: To be consistent, I rather see them commented out i.e foo(int bar) - foo(int /*bar*/) rather than foo(int) To have a better code, would it not be better to change the prototyping of the function from foo (int) to foo() ?? Or did I miss a point? So would the code be cleaner or do you intend to drop the binfilter components very soon ? regards ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] warnig and coding, need a little help on C++
Hello, as I said, still in warm up phase and getting back familiar with C++.. So cleaning is a good exercise. I got a compiler warning: filters/binfilter/bf_sw/source/core/para/sw_paratr.cxx:214:26: warning: 'nTemp' may be used uninitialized in this function for this: case MID_DROPCAP_LINES : { sal_Int8 nTemp; rVal = nTemp; if(nTemp =1 nTemp 0x7f nLines = (BYTE)nTemp; } Well, that's fine for me, nTemp is effectively not initialized. And the second line is then the same as: rVal = rVal nTemp In my understanding, since nTemps is not initialized, if the compiler is nice, nTemp is then defaulted to 0 (or NULL). Then rVal = rVal 0 make not a lot of sense and is a true nop (no operation). And if the compiler is not nice, I do not know which value has nTemp, i could almost use random... So for me it seems the two first lines are not needed and even dangerous. OK, now the question: what did I missed ? Thank for your help regards ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 1/9] suppress warning in binfilters sc_token
Hello, here some patches in binfilter to remove warnings by compiling... Since some changes could (will) look strange, I submit it in little chunks, often with compiler warning in comment. This may help the reviewer. Hope I did no mistake regards Pierre-André From c747a9dcc4af190aac1f216a93f7abd4b39fec85 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Tue, 23 Nov 2010 07:46:54 +0100 Subject: [PATCH 1/9] suppress warning in binfilters sc_token changes based on following warnings: sc_token.cxx:1573:28: warning: comparison is always false due to limited range of data type sc_token.cxx:452:12: warning: unused parameter 'n' sc_token.cxx:452:12: warning: unused parameter 'rPos' sc_token.cxx:452:12: warning: unused parameter 'rPos' sc_token.cxx:452:12: warning: unused parameter 'n' sc_token.cxx:1613:26: warning: declaration of 'r' shadows a previous local sc_token.cxx:1593:25: warning: shadowed declaration is here --- binfilter/bf_sc/source/core/tool/sc_token.cxx | 45 ++--- 1 files changed, 18 insertions(+), 27 deletions(-) diff --git a/binfilter/bf_sc/source/core/tool/sc_token.cxx b/binfilter/bf_sc/source/core/tool/sc_token.cxx index fe98c35..0bfad52 100644 --- a/binfilter/bf_sc/source/core/tool/sc_token.cxx +++ b/binfilter/bf_sc/source/core/tool/sc_token.cxx @@ -449,7 +449,7 @@ namespace binfilter { /*N*/ return 0; /*N*/ } -/*N*/ void ScToken::SetByte( BYTE n ) +/*N*/ void ScToken::SetByte( BYTE /*n*/ ) /*N*/ { /*N*/ DBG_ERRORFILE( ScToken::SetByte: virtual dummy called ); /*N*/ } @@ -502,12 +502,12 @@ namespace binfilter { /*N*/ return aDummySingleRef; /*N*/ } -/*N*/ void ScToken::CalcAbsIfRel( const ScAddress rPos ) +/*N*/ void ScToken::CalcAbsIfRel( const ScAddress /*rPos*/ ) /*N*/ { /*N*/ DBG_ERRORFILE( ScToken::CalcAbsIfRel: virtual dummy called ); /*N*/ } -/*N*/ void ScToken::CalcRelFromAbs( const ScAddress rPos ) +/*N*/ void ScToken::CalcRelFromAbs( const ScAddress /*rPos*/ ) /*N*/ { /*N*/ DBG_ERRORFILE( ScToken::CalcRelFromAbs: virtual dummy called ); /*N*/ } @@ -524,7 +524,7 @@ namespace binfilter { /*N*/ return 0; /*N*/ } -/*N*/ void ScToken::SetIndex( USHORT n ) +/*N*/ void ScToken::SetIndex( USHORT /*n*/ ) /*N*/ { /*N*/ DBG_ERRORFILE( ScToken::SetIndex: virtual dummy called ); /*N*/ } @@ -1570,16 +1570,7 @@ namespace binfilter { /*N*/ { /*N*/ sal_Char c[ MAXSTRLEN+1 ]; /*N*/ rStream n; -/*N*/ if( n MAXSTRLEN-1 ) -/*N*/ { -/*?*/ DBG_ERRORFILE( bad string array boundary ); -/*?*/ USHORT nDiff = n - (MAXSTRLEN-1); -/*?*/ n = MAXSTRLEN-1; -/*?*/ rStream.Read( c, n ); -/*?*/ rStream.SeekRel( nDiff ); -/*N*/ } -/*N*/ else -/*N*/ rStream.Read( c, n ); +/*N*/ rStream.Read( c, n ); /*N*/ cStr[ n ] = 0; /*N*/ CharSet eSrc = rStream.GetStreamCharSet(); /*N*/ for ( BYTE j=0; jn; j++ ) @@ -1590,10 +1581,10 @@ namespace binfilter { /*N*/ case svSingleRef: /*N*/ case svDoubleRef: /*N*/ { -/*N*/ SingleRefData r = aRef.Ref1; -/*N*/ rStream r.nCol -/*N*/ r.nRow -/*N*/ r.nTab +/*N*/ SingleRefData r1 = aRef.Ref1; +/*N*/ rStream r1.nCol +/*N*/ r1.nRow +/*N*/ r1.nTab /*N*/ n; /*N*/ if ( nVer SC_RELATIVE_REFS ) /*N*/ { @@ -1602,18 +1593,18 @@ namespace binfilter { /*N*/ aBools.bRelRow = ( ( n 2 ) 0x03 ); /*N*/ aBools.bRelTab = ( ( n 4 ) 0x03 ); /*N*/ aBools.bOldFlag3D = ( ( n 6 ) 0x03 ); -/*N*/ r.OldBoolsToNewFlags( aBools ); +/*N*/ r1.OldBoolsToNewFlags( aBools ); /*N*/ } /*N*/ else -/*N*/ r.CreateFlagsFromLoadByte( n ); +/*N*/ r1.CreateFlagsFromLoadByte( n ); /*N*/ if( eType == svSingleRef ) -/*N*/ aRef.Ref2 = r; +/*N*/ aRef.Ref2 = r1; /*N*/ else /*N*/ { -/*N*/ SingleRefData r = aRef.Ref2; -/*N*/ rStream r.nCol -/*N*/ r.nRow -/*N*/ r.nTab +/*N*/ SingleRefData r2 = aRef.Ref2; +/*N*/ rStream r2.nCol +/*N*/ r2.nRow +/*N*/ r2.nTab /*N*/ n; /*N*/ if ( nVer SC_RELATIVE_REFS ) /*N*/ { @@ -1622,10 +1613,10 @@ namespace binfilter { /*N*/ aBools.bRelRow = ( ( n 2 ) 0x03 ); /*N*/ aBools.bRelTab = ( ( n 4 ) 0x03 ); /*N*/ aBools.bOldFlag3D = ( ( n 6 ) 0x03 ); -/*N*/ r.OldBoolsToNewFlags( aBools ); +/*N*/ r2.OldBoolsToNewFlags( aBools ); /*N*/ } /*N*/ else -/*N*/ r.CreateFlagsFromLoadByte( n ); +/*N*/ r2.CreateFlagsFromLoadByte( n ); /*N*/ } /*N*/ break; /*N*/ } -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 4/9] binfilter sc_interpr4.cxx further warnings removal
regards From f6202b304ca7f0ffdd16cbd2886872465273852a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Tue, 23 Nov 2010 21:58:53 +0100 Subject: [PATCH 4/9] binfilter sc_interpr4.cxx further warnings removal --- binfilter/bf_sc/source/core/tool/sc_interpr4.cxx | 17 - 1 files changed, 8 insertions(+), 9 deletions(-) diff --git a/binfilter/bf_sc/source/core/tool/sc_interpr4.cxx b/binfilter/bf_sc/source/core/tool/sc_interpr4.cxx index 31201a3..547d168 100644 --- a/binfilter/bf_sc/source/core/tool/sc_interpr4.cxx +++ b/binfilter/bf_sc/source/core/tool/sc_interpr4.cxx @@ -1358,7 +1358,7 @@ BOOL ScInterpreter::DoubleRefToPosSingleRef( const ScRange rRange, ScAddress r /*N*/ { /*N*/ ScBaseCell* pCell; /*N*/ ScQueryCellIterator aCellIter(pDok, nTab, aQueryParam); -/*N*/ if (pCell = aCellIter.GetFirst()) +/*N*/ if ( (pCell = aCellIter.GetFirst() ) ) /*N*/ { /*N*/ if (aCellIter.GetNext()) /*N*/ SetIllegalArgument(); @@ -1458,7 +1458,6 @@ BOOL ScInterpreter::DoubleRefToPosSingleRef( const ScRange rRange, ScAddress r /*?*/ /*?*/ for (i = nParamCount; (i 0) (nGlobalError == 0); i--) /*?*/ { -/*?*/ BYTE nStackType = GetStackType(); /*?*/ switch (eParamType[i]) /*?*/ { /*?*/ case PTR_DOUBLE : @@ -2098,14 +2097,14 @@ void ScInterpreter::ScMissing() /*?*/ { /*?*/ short nIdx[ 2 ]; /*?*/ nIdx[ 0 ] = j+1; -/*?*/ for( USHORT i = 0; i nC; i++ ) +/*?*/ for( USHORT k = 0; k nC; i++ ) /*?*/ { -/*?*/ nIdx[ 1 ] = i+1; +/*?*/ nIdx[ 1 ] = k+1; /*?*/ SbxVariable* p = refArray-Get( nIdx ); -/*?*/ if (pMat-IsString(i, j)) -/*?*/ p-PutString( pMat-GetString(i, j) ); +/*?*/ if (pMat-IsString(k, j)) +/*?*/ p-PutString( pMat-GetString(k, j) ); /*?*/ else -/*?*/ p-PutDouble( pMat-GetDouble(i, j) ); +/*?*/ p-PutDouble( pMat-GetDouble(k, j) ); /*?*/ } /*?*/ } /*?*/ pPar-PutObject( refArray ); @@ -3041,10 +3040,10 @@ void ScInterpreter::ScTTT() /*?*/ { // Stack abraeumen, geht davon aus, dass jede Funktion /*?*/ // prinzipiell ein Ergebnis pusht, im Fehlerfall kann dies /*?*/ // ein zufaelliger Wert sein -/*?*/ const ScToken* pResult = pStack[ sp - 1 ]; +/*?*/ const ScToken* pResult2 = pStack[ sp - 1 ]; /*?*/ while ( sp nStackBase ) /*?*/ Pop(); -/*?*/ PushTempToken( *pResult ); +/*?*/ PushTempToken( *pResult2 ); /*?*/ } /*N*/ } /*N*/ } -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 5/9] waring removal in binfilter core/para
regards From 01e9e819f9dd8f1726ddff7672f27cfcbd44760c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Thu, 25 Nov 2010 20:09:15 +0100 Subject: [PATCH 5/9] waring removal in binfilter core/para --- binfilter/bf_sw/source/core/para/sw_paratr.cxx | 16 1 files changed, 8 insertions(+), 8 deletions(-) diff --git a/binfilter/bf_sw/source/core/para/sw_paratr.cxx b/binfilter/bf_sw/source/core/para/sw_paratr.cxx index cb4dd70..646bb4b 100644 --- a/binfilter/bf_sw/source/core/para/sw_paratr.cxx +++ b/binfilter/bf_sw/source/core/para/sw_paratr.cxx @@ -104,7 +104,7 @@ using namespace ::com::sun::star; -/*N*/ void SwFmtDrop::Modify( SfxPoolItem *pA, SfxPoolItem *pB ) +/*N*/ void SwFmtDrop::Modify( SfxPoolItem * /*pA*/, SfxPoolItem * /*pB*/ ) /*N*/ { /*N*/ if( pDefinedIn ) /*N*/ { @@ -130,7 +130,7 @@ using namespace ::com::sun::star; -/*N*/ sal_Bool SwFmtDrop::GetInfo( SfxPoolItem rInfo ) const +/*N*/ sal_Bool SwFmtDrop::GetInfo( SfxPoolItem /*rInfo*/ ) const /*N*/ { /*N*/ // fuers UNDO: pruefe ob das Attribut wirklich in diesem Format steht /*N*/ #ifdef USED_30 @@ -180,7 +180,7 @@ using namespace ::com::sun::star; /*N*/ case MID_DROPCAP_LINES : rVal = (sal_Int16)nLines; break; /*N*/ case MID_DROPCAP_COUNT : rVal = (sal_Int16)nChars; break; /*N*/ case MID_DROPCAP_DISTANCE : rVal = (sal_Int16) TWIP_TO_MM100(nDistance); break; -/*N*/ case MID_DROPCAP_FORMAT: +/*N*/ case MID_DROPCAP_FORMAT: /*N*/ { /*N*/ style::DropCapFormat aDrop; /*N*/ aDrop.Lines = nLines ; @@ -244,8 +244,8 @@ using namespace ::com::sun::star; /*N*/ nDistance = MM100_TO_TWIP(pDrop-Distance); /*N*/ } /*N*/ else -/*N*/ //exception( wrong_type) -/*N*/ ; +/*N*/ { //exception( wrong_type) +/*N*/ } /*N*/ } /*N*/ break; /*N*/ case MID_DROPCAP_WHOLE_WORD: @@ -267,14 +267,14 @@ using namespace ::com::sun::star; /*N*/ } // class SwNumRuleItem - -/*N*/ SfxPoolItem* SwNumRuleItem::Clone( SfxItemPool *pPool ) const +/*N*/ SfxPoolItem* SwNumRuleItem::Clone( SfxItemPool * /*pPool*/ ) const /*N*/ { /*N*/ return new SwNumRuleItem( *this ); /*N*/ } /* -27.06.00 11:05 ---*/ -/*N*/ bool SwNumRuleItem::QueryValue( ::com::sun::star::uno::Any rVal, BYTE nMemberId ) const +/*N*/ bool SwNumRuleItem::QueryValue( ::com::sun::star::uno::Any rVal, BYTE /*nMemberId*/ ) const /*N*/ { /*N*/ ::rtl::OUString sRet = SwStyleNameMapper::GetProgName(GetValue(), GET_POOLID_NUMRULE ); /*N*/ rVal = sRet; @@ -283,7 +283,7 @@ using namespace ::com::sun::star; /* -27.06.00 11:05 ---*/ -/*N*/ bool SwNumRuleItem::PutValue( const ::com::sun::star::uno::Any rVal, BYTE nMemberId ) +/*N*/ bool SwNumRuleItem::PutValue( const ::com::sun::star::uno::Any rVal, BYTE /*nMemberId*/ ) /*N*/ { /*N*/ ::rtl::OUString uName; /*N*/ rVal = uName; -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 6/9] waring cleaning in sw_sw3redln.cxx
regards From 84e58630f70dc34f71ee34419d9843980b14b723 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Thu, 25 Nov 2010 20:18:10 +0100 Subject: [PATCH 6/9] waring cleaning in sw_sw3redln.cxx shadowing warning and unused parameters --- binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx | 11 --- 1 files changed, 4 insertions(+), 7 deletions(-) diff --git a/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx b/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx index b0a286b..e2453f4 100644 --- a/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx +++ b/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx @@ -97,8 +97,6 @@ namespace binfilter { /*N*/ { /*N*/ OpenRec( SWG_REDLINEDATA_LCL ); /*N*/ -/*N*/ BYTE cDFlags = OpenFlagRec(); -/*N*/ /*N*/ BYTE cType; /*N*/ UINT16 nStrIdx; /*N*/ @@ -106,10 +104,10 @@ namespace binfilter { /*N*/ nStrIdx; /*N*/ CloseFlagRec(); /*N*/ -/*N*/ UINT32 nDate, nTime; +/*N*/ UINT32 nDate2, nTime2; /*N*/ String aComment; -/*N*/ *pStrm nDate -/*N*/ nTime; +/*N*/ *pStrm nDate2 +/*N*/ nTime2; /*N*/ InString( *pStrm, aComment ); /*N*/ /*N*/ // Das oberste Element des Stack wurde als letztes geschrieben. @@ -120,7 +118,7 @@ namespace binfilter { /*N*/ nAuthorIdx = pDoc-GetRedlineAuthor(); /*N*/ /*N*/ pData = new SwRedlineData( (SwRedlineType)cType, nAuthorIdx, -/*N*/ DateTime( nDate, nTime ), aComment, +/*N*/ DateTime( nDate2, nTime2 ), aComment, /*N*/ pData ); /*N*/ /*N*/ CloseRec( SWG_REDLINEDATA_LCL ); @@ -128,7 +126,6 @@ namespace binfilter { /*N*/ /*N*/ // Der PaM ist erstmal egal und wird erst spaeter gesetzt /*N*/ SwPosition aDummyPos( pDoc-GetNodes().GetEndOfExtras() ); -/*N*/ BOOL bVisible = (cFlags 0x10) != 0; /*N*/ SwRedline *pRedline = /*N*/ new SwRedline( pData, aDummyPos, (cFlags 0x10) != 0, /*N*/ (cFlags 0x20) != 0, (cFlags 0x40) != 0 ); -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 7/9] warnings removal in binfilter sw_sw3redln.cxx
regards From 13a33d71df128454159d0e911f55179cddac2d72 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Thu, 25 Nov 2010 20:52:47 +0100 Subject: [PATCH 7/9] warnings removal in binfilter sw_sw3redln.cxx all code deletion due to compiler warning with message: sw_sw3redln.cxx:255:25: warning: comparison is always false due to limited range of data type --- binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx | 21 ++--- 1 files changed, 2 insertions(+), 19 deletions(-) diff --git a/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx b/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx index e2453f4..2a3f9ef 100644 --- a/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx +++ b/binfilter/bf_sw/source/core/sw3io/sw_sw3redln.cxx @@ -251,12 +251,7 @@ xub_StrLen lcl_sw3io_getNodeOff( const SwNodeIndex rNdIdx, xub_StrLen nCntntIdx // unbenutzte Content-Position. const SwNode rNode = rNdIdx.GetNode(); if( rNode.IsCntntNode() ) -{ -if( nCntntIdx STRING_MAXLEN52 ) -return STRING_MAXLEN52; -else -return nCntntIdx; -} +return nCntntIdx; if( rNode.IsStartNode() ) return 0; @@ -294,10 +289,6 @@ xub_StrLen lcl_sw3io_getNodeOff( const SwNodeIndex rNdIdx, xub_StrLen nCntntIdx /*?*/ // If the redline is within one node and starts behind the /*?*/ // last position that is possible within the 5.2 version, /*?*/ // it will be ignored. -/*?*/ if( pPos-nContent.GetIndex() STRING_MAXLEN52 -/*?*/ pPos-nNode.GetIndex() == pEndPos-nNode.GetIndex() -/*?*/ pEndPos-nContent.GetIndex() STRING_MAXLEN52 ) -/*?*/ continue; /*?*/ /*?*/ if( pDoc-IsInHeaderFooter( pPos-nNode ) ) /*?*/ { @@ -457,7 +448,7 @@ xub_StrLen lcl_sw3io_getNodeOff( const SwNodeIndex rNdIdx, xub_StrLen nCntntIdx /*N*/ xub_StrLen nLen = rNode.GetCntntNode()-Len(); /*N*/ xub_StrLen nIdx = static_cast xub_StrLen ( nNodeOff+nCntntOff ); /*N*/ ASSERT( nIdx=0 nIdx=nLen, ungueltiger Cntnt-Offset ); -/*N*/ if( nIdx0 || nIdx nLen ) +/*N*/ if( nIdx nLen ) /*N*/ { /*N*/ bInvalid = sal_True; /*N*/ } @@ -635,14 +626,6 @@ xub_StrLen lcl_sw3io_getNodeOff( const SwNodeIndex rNdIdx, xub_StrLen nCntntIdx /*?*/ else if( pContentIdx ) /*?*/ cFlags |= 0x20; /*?*/ -/*?*/ xub_StrLen nOffs = pMark-GetNodeOff(); -/*?*/ if( pDoc-GetNodes()[nIdx]-IsCntntNode() -/*?*/ nOffs STRING_MAXLEN52 ) -/*?*/ nOffs = STRING_MAXLEN52; -/*?*/ *pStrm (BYTE) cFlags -/*?*/ (UINT16)pMark-GetId() -/*?*/ (UINT16)nOffs; -/*?*/ /*?*/ if( pContentIdx ) /*?*/ { /*?*/ ASSERT( pContentIdx-GetNode().EndOfSectionIndex() - -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 9/9] binfilter sw3io warning fixes
regards From d8ca0db19fdc508ebc0bf0ee42107fdea2f498b1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Thu, 25 Nov 2010 21:10:27 +0100 Subject: [PATCH 9/9] binfilter sw3io warning fixes use of not initialized variables --- binfilter/bf_sw/source/core/sw3io/sw_sw3fmts.cxx | 20 ++-- 1 files changed, 10 insertions(+), 10 deletions(-) diff --git a/binfilter/bf_sw/source/core/sw3io/sw_sw3fmts.cxx b/binfilter/bf_sw/source/core/sw3io/sw_sw3fmts.cxx index 16c641a..3606f9b 100644 --- a/binfilter/bf_sw/source/core/sw3io/sw_sw3fmts.cxx +++ b/binfilter/bf_sw/source/core/sw3io/sw_sw3fmts.cxx @@ -310,7 +310,7 @@ sal_Bool lcl_sw3io_insFtn( const SwTxtNode *pTxtNd ) /*N*/ if( rSet.Count() ) /*N*/ { /*N*/ // Beim 3.1 Export den aktuellen Attrset merken -/*N*/ const SfxItemSet *pOldExportItemSet; +/*N*/ const SfxItemSet *pOldExportItemSet = NULL; /*N*/ if( pExportInfo ) /*N*/ { /*N*/ pOldExportItemSet = pExportInfo-pItemSet; @@ -938,21 +938,21 @@ sal_Bool lcl_sw3io_insFtn( const SwTxtNode *pTxtNd ) /*N*/ if( bWriteName ) /*N*/ OutString( *pStrm, rFmt.GetName() ); /*N*/ -/*N*/ BOOL bOldExportFlyFrmFmt; -/*N*/ const SwFlyFrm* pOldExportFlyFrm; /*N*/ if( pExportInfo ) /*N*/ { -/*N*/ bOldExportFlyFrmFmt = pExportInfo-bFlyFrmFmt; -/*N*/ pOldExportFlyFrm = pExportInfo-pFlyFrm; +/*N*/ BOOL bOldExportFlyFrmFmt = pExportInfo-bFlyFrmFmt; +/*N*/ const SwFlyFrm* pOldExportFlyFrm = pExportInfo-pFlyFrm; /*N*/ pExportInfo-bFlyFrmFmt = (cType == SWG_FLYFMT); /*N*/ pExportInfo-pFlyFrm = pExportFlyFrm; -/*N*/ } -/*N*/ OutAttrSet( rFmt.GetAttrSet(), SWG_SECTFMT == cType ); -/*N*/ if( pExportInfo ) -/*N*/ { +OutAttrSet( rFmt.GetAttrSet(), SWG_SECTFMT == cType ); /*N*/ pExportInfo-bFlyFrmFmt = bOldExportFlyFrmFmt; /*N*/ pExportInfo-pFlyFrm = pOldExportFlyFrm; + /*N*/ } +else +{ +/*N*/ OutAttrSet( rFmt.GetAttrSet(), SWG_SECTFMT == cType ); +} /*N*/ CloseRec( cType ); /*N*/ if( cType != SWG_FREEFMT cType != SWG_SECTFMT ) /*N*/ ((SwFmt)rFmt).SetWritten(); @@ -1103,7 +1103,7 @@ sal_Bool lcl_sw3io_insFtn( const SwTxtNode *pTxtNd ) extern BOOL TstFlyRange( const SwPaM* pPam, const SwIndex rFlyPos ); -/*N*/ void Sw3IoImp::CollectFlyFrms( const SwPaM* pPaM ) +/*N*/ void Sw3IoImp::CollectFlyFrms( const SwPaM* /*pPaM*/ ) /*N*/ { /*N*/ if( !pFlyFrms ) /*N*/ { -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] [PATCH 3/9] warnings in binfilters sc_interpr4.cxx
Quick question wouldn't it be better to have the comments in English instead of German? Sorry, !! I translate then when I can, but I did not the job to the end for this one. Not_appropriate_handling_for_me++ regards ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] warnig and coding, need a little help on C++
Thanks for helping. Heh, this also confuses cppcheck as well. cough... cough... ! I am not smarter than a machine... ! A professor I had told: this not a good point being too smart... I understand what he meant. For stepping in, not the easiest way. Once there is no waring any more when compiling, let start hacking to remove the overloaded operator and replace it through more instinctive function call ::--)) /joke ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] [PUSHED] Re: [PATCH 9/9] binfilter sw3io warning fixes
Hi, First thanks for reviewing, catching my errors and correcting. I have learned a lot. Next time I do so many errors, please reject and I will correct it myself. Michael, I will wait making less errors in changes before requesting an account, if you don't mind. Just a question for: Err, you sort of changed the logic there. That doesn't look quite right. OutAttrSet went from getting called always to only getting called when pExportInfo is set. I've fixed this up now as well. I don't understand my error: I wanted to keep the logic with structure changes, going from: var - here waring not initialized if (pexportinfo) { stuff 1 } OutAttrSet - the one you mentionned if (pexportinfo) { stuff 2 } to the new structure having (at least I though) the same overall logic but written slightly differently: if (pexportinfo) { var stuff 1 outAttrSet stuff 2 } else { OutAttrSet } I though, this would be better, solving the uninitialized warning, initializing only if needed and having only one IF evaluation. The OutAttrSet seems me to be executed in all case one and only once, as before. Is there a logic error here? Or did the patch 0009 (the concerned part attached here) something else? Thanks helping me to improve. regards Pierre-André @@ -938,21 +938,21 @@ sal_Bool lcl_sw3io_insFtn( const SwTxtNode *pTxtNd ) /*N*/ if( bWriteName ) /*N*/ OutString( *pStrm, rFmt.GetName() ); /*N*/ -/*N*/ BOOL bOldExportFlyFrmFmt; -/*N*/ const SwFlyFrm* pOldExportFlyFrm; /*N*/ if( pExportInfo ) /*N*/ { -/*N*/ bOldExportFlyFrmFmt = pExportInfo-bFlyFrmFmt; -/*N*/ pOldExportFlyFrm = pExportInfo-pFlyFrm; +/*N*/ BOOL bOldExportFlyFrmFmt = pExportInfo-bFlyFrmFmt; +/*N*/ const SwFlyFrm* pOldExportFlyFrm = pExportInfo-pFlyFrm; /*N*/ pExportInfo-bFlyFrmFmt = (cType == SWG_FLYFMT); /*N*/ pExportInfo-pFlyFrm = pExportFlyFrm; -/*N*/ } -/*N*/ OutAttrSet( rFmt.GetAttrSet(), SWG_SECTFMT == cType ); -/*N*/ if( pExportInfo ) -/*N*/ { +OutAttrSet( rFmt.GetAttrSet(), SWG_SECTFMT == cType ); /*N*/ pExportInfo-bFlyFrmFmt = bOldExportFlyFrmFmt; /*N*/ pExportInfo-pFlyFrm = pOldExportFlyFrm; + /*N*/ } +else +{ +/*N*/ OutAttrSet( rFmt.GetAttrSet(), SWG_SECTFMT == cType ); +} /*N*/ CloseRec( cType ); /*N*/ if( cType != SWG_FREEFMT cType != SWG_SECTFMT ) /*N*/ ((SwFmt)rFmt).SetWritten(); ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 2/7] waring within binfilter - sw3io
regards From 0735f42a61482b094d054266ea83781ee122c91e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Fri, 26 Nov 2010 21:04:20 +0100 Subject: [PATCH 2/7] waring within binfilter - sw3io delete some compiler warning, some of them due to shadowing. --- binfilter/bf_sw/source/core/sw3io/sw_sw3nodes.cxx | 54 ++-- 1 files changed, 27 insertions(+), 27 deletions(-) diff --git a/binfilter/bf_sw/source/core/sw3io/sw_sw3nodes.cxx b/binfilter/bf_sw/source/core/sw3io/sw_sw3nodes.cxx index c6fdf62..0629080 100644 --- a/binfilter/bf_sw/source/core/sw3io/sw_sw3nodes.cxx +++ b/binfilter/bf_sw/source/core/sw3io/sw_sw3nodes.cxx @@ -650,24 +650,24 @@ SV_DECL_PTRARR( SwTxtAttrs, SwTxtAttrPtr, 5, 5 )//STRIP008 ; /*N*/ String rNdText = (String )rNd.GetTxt(); /*N*/ String aText; /*N*/ ByteString aText8( rText8 ); -/*N*/ SvxFontItem aFontItem( rFont ); +/*N*/ SvxFontItem aFontItem1 ( rFont ); /*N*/ if( pConvToSymbolFmts -/*N*/ lcl_sw3io_isStarSymbolFontItem( aFontItem ) ) +/*N*/ lcl_sw3io_isStarSymbolFontItem( aFontItem1 ) ) /*N*/ { /*?*/ BYTE nFlags = pConvToSymbolFmts-GetFlags( rNd.GetFmtColl() ); /*?*/ if( (SW3IO_CONV_FROM_BATS nFlags) != 0 ) /*?*/ { -/*?*/ aFontItem.GetFamilyName() = sStarBats; -/*?*/ aFontItem.GetCharSet() = RTL_TEXTENCODING_SYMBOL; +/*?*/ aFontItem1.GetFamilyName() = sStarBats; +/*?*/ aFontItem1.GetCharSet() = RTL_TEXTENCODING_SYMBOL; /*?*/ } /*?*/ else if( (SW3IO_CONV_FROM_MATH nFlags) != 0 ) /*?*/ { -/*?*/ aFontItem.GetFamilyName() = sStarMath; -/*?*/ aFontItem.GetCharSet() = RTL_TEXTENCODING_SYMBOL; +/*?*/ aFontItem1.GetFamilyName() = sStarMath; +/*?*/ aFontItem1.GetCharSet() = RTL_TEXTENCODING_SYMBOL; /*?*/ } /*N*/ } /*N*/ ConvertText( aText8, aText, nOffset, rNd, -/*N*/ eSrcSet, aFontItem, 0, FALSE ); +/*N*/ eSrcSet, aFontItem1, 0, FALSE ); /*N*/ rNdText.Replace( nOffset, aText.Len(), aText ); /*N*/ if( bNdSym /*N*/ SFX_ITEM_SET == rNd.GetSwAttrSet().GetItemState( RES_CHRATR_FONT, @@ -676,12 +676,12 @@ SV_DECL_PTRARR( SwTxtAttrs, SwTxtAttrPtr, 5, 5 )//STRIP008 ; /*N*/ rFont.GetFamilyName().EqualsIgnoreCaseAscii( sStarMath ) ) ) /*N*/ { /*?*/ const Font rSymbolFont = SwNumRule::GetDefBulletFont(); -/*?*/ SvxFontItem aFontItem( rSymbolFont.GetFamily(), +/*?*/ SvxFontItem aFontItem2( rSymbolFont.GetFamily(), /*?*/ rSymbolFont.GetName(), /*?*/ rSymbolFont.GetStyleName(), /*?*/ rSymbolFont.GetPitch(), /*?*/ rSymbolFont.GetCharSet() ); -/*?*/ ((SwCntntNode)rNd).SetAttr( aFontItem ); +/*?*/ ((SwCntntNode)rNd).SetAttr( aFontItem2 ); /*N*/ } /*N*/ /*N*/ if( pEncs ) @@ -1370,7 +1370,7 @@ SV_DECL_PTRARR( SwTxtAttrs, SwTxtAttrPtr, 5, 5 )//STRIP008 ; /*N*/ { /*N*/ // Der Hint liegt zumindest teilweise im Text /*N*/ const SfxPoolItem rAttr = pHt-GetAttr(); -/*N*/ BOOL bInsert = FALSE, bSplit = FALSE; +/*N*/ BOOL bInsert1 = FALSE, bSplit = FALSE; /*N*/ /*N*/ USHORT nWhich = rAttr.Which(); /*N*/ switch( nWhich ) @@ -1385,7 +1385,7 @@ SV_DECL_PTRARR( SwTxtAttrs, SwTxtAttrPtr, 5, 5 )//STRIP008 ; /*N*/ // das SwFmtINetFmt ist auf dem Top-Level /*N*/ nINetFmtStart = nHtStart; /*N*/ nINetFmtEnd = nHtEnd; -/*N*/ bInsert = TRUE; +/*N*/ bInsert1 = TRUE; /*N*/ } /*N*/ else /*N*/ { @@ -1413,7 +1413,7 @@ SV_DECL_PTRARR( SwTxtAttrs, SwTxtAttrPtr, 5, 5 )//STRIP008 ; /*N*/ { /*N*/ // das Attribut beginnt erst hinter einen SwFmtINetFmt /*N*/ // oder spannt exakt den gleichen Bereich auf -/*N*/ bInsert = TRUE; +/*N*/ bInsert1 = TRUE; /*N*/ } /*N*/ else if( RES_TXTATR_NOEND_BEGIN = nWhich /*N*/ RES_TXTATR_NOEND_END nWhich ) @@ -1424,7 +1424,7 @@ SV_DECL_PTRARR( SwTxtAttrs, SwTxtAttrPtr, 5, 5 )//STRIP008 ; /*N*/ break; /*N*/ } /*N*/ -/*N*/ if( bInsert ) +/*N*/ if( bInsert1 ) /*N*/ { /*N*/ // das Item als letztes an seiner Start-Position beginnen, /*N*/ // aber in jedem Fall vor einem SwFmtINetFmt @@ -1638,7 +1638,7 @@ SV_DECL_PTRARR( SwTxtAttrs, SwTxtAttrPtr, 5, 5 )//STRIP008 ; // SWG_WRONGLIST Liste falscher Worte (opt) /*N*/ void Sw3IoImp::OutTxtNode -/*N*/ ( SwCntntNode rNode, xub_StrLen nStart, xub_StrLen nEnd, ULONG nPosIdx ) +/*N*/ ( SwCntntNode rNode, xub_StrLen nStart, xub_StrLen nEnd1, ULONG nPosIdx ) /*N*/ { /*N*/ SwTxtNode *pNd = ((SwTxtNode) rNode ); /*N*/ const SwFmtColl* pColl = pNd-GetAnyFmtColl(); @@ -1824,24 +1824,24 @@ SV_DECL_PTRARR( SwTxtAttrs, SwTxtAttrPtr, 5, 5 )//STRIP008 ; /*N*/ } /*N*/ #endif /*N*/ -/*N*/ if( (nEnd == STRING_LEN ? pNd-GetTxt().Len() : nEnd) STRING_MAXLEN52 ) -/*N*/ nEnd = STRING_MAXLEN52; +/*N*/ if( (nEnd1 == STRING_LEN ? pNd-GetTxt().Len() : nEnd1) STRING_MAXLEN52 ) +/*N*/ nEnd1 = STRING_MAXLEN52; /*N*/ /*N*/ SwInsHardBlankSoftHyph
[Libreoffice] [PATCH 3/7] binfilter sw3io - further shadowing warnings
regards From 2b6f503e9a8fc091dcfc216dc12175e646a76a68 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Fri, 26 Nov 2010 22:44:38 +0100 Subject: [PATCH 3/7] binfilter sw3io - further shadowing warnings --- binfilter/bf_sw/source/core/sw3io/sw_sw3misc.cxx | 146 +++-- 1 files changed, 76 insertions(+), 70 deletions(-) diff --git a/binfilter/bf_sw/source/core/sw3io/sw_sw3misc.cxx b/binfilter/bf_sw/source/core/sw3io/sw_sw3misc.cxx index 590ec5e..eee1c13 100644 --- a/binfilter/bf_sw/source/core/sw3io/sw_sw3misc.cxx +++ b/binfilter/bf_sw/source/core/sw3io/sw_sw3misc.cxx @@ -1041,9 +1041,9 @@ extern sal_Bool lcl_sw3io_isTOXHeaderSection( const SwStartNode rSttNd ); /*N*/ { /*N*/ OpenRec( SWG_TOXDESC ); /*N*/ String aTypeName, aTitle; -/*N*/ sal_uInt16 nStrIdx = IDX_NO_VALUE; +/*N*/ sal_uInt16 nStrIdx0 = IDX_NO_VALUE; /*N*/ if( IsVersion( SWG_LONGIDX ) ) -/*N*/ *pStrm nStrIdx; +/*N*/ *pStrm nStrIdx0; /*N*/ else /*N*/ InString( *pStrm, aTypeName ); /*N*/ @@ -1064,8 +1064,8 @@ extern sal_Bool lcl_sw3io_isTOXHeaderSection( const SwStartNode rSttNd ); /*N*/ // Wenn keine Name da ist, dann handelt es sich um /*N*/ // das Standard-Verzeichnis des entsprechenden Typs. Der /*N*/ // (internationalisierte) Name wird dann gesetzt. -/*N*/ if( IDX_NO_VALUE != nStrIdx ) -/*?*/ aTypeName = aStringPool.Find( nStrIdx ); +/*N*/ if( IDX_NO_VALUE != nStrIdx0 ) +/*?*/ aTypeName = aStringPool.Find( nStrIdx0 ); /*N*/ else if( !aTypeName.Len() ) /*N*/ aTypeName = SwTOXBase::GetTOXName( eTOXType ); /*N*/ @@ -1121,11 +1121,11 @@ extern sal_Bool lcl_sw3io_isTOXHeaderSection( const SwStartNode rSttNd ); /*N*/ *pStrm nTmpl; /*N*/ for( i = 0; Good() i nTmpl; i++ ) /*N*/ { -/*N*/ sal_uInt16 nStrIdx; -/*N*/ *pStrm nStrIdx; +/*N*/ sal_uInt16 nStrIdx1; +/*N*/ *pStrm nStrIdx1; /*N*/ if( i aForm.GetFormMax() ) /*N*/ { -/*N*/ String sNm( aStringPool.Find( nStrIdx ) ); +/*N*/ String sNm( aStringPool.Find( nStrIdx1 ) ); /*N*/ if( !sNm.Len() ) /*N*/ { /*N*/ // Bug 37672: falls keiner gefunden wird, nehme @@ -1395,6 +1395,8 @@ extern sal_Bool lcl_sw3io_isTOXHeaderSection( const SwStartNode rSttNd ); /*?*/ case TOX_TABLES: /*?*/ nPoolId = RES_POOLCOLL_LABEL_TABLE; /*?*/ break; +default: +break; /*N*/ } /*N*/ String aName; /*N*/ SwStyleNameMapper::FillUIName( nPoolId, aName ); @@ -1443,23 +1445,23 @@ extern void lcl_sw3io_FillSetExpFieldName( Sw3IoImp rIo, sal_uInt16 nStrId, /*N*/ /*N*/ sal_uInt8 cFlags = OpenFlagRec(); /*N*/ -/*N*/ sal_uInt16 nType, nCreateType, nCaptionDisplay, nStrIdx, nSeqStrIdx, nData; +/*N*/ sal_uInt16 nType0, nCreateType, nCaptionDisplay, nStrIdx0, nSeqStrIdx, nData; /*N*/ sal_uInt16 nOLEOptions = 0; /*N*/ sal_uInt8 cFormFlags; /*N*/ -/*N*/ String aTitle, aName, aDummy; +/*N*/ String aTitle, aName0, aDummy; /*N*/ -/*N*/ *pStrm nType +/*N*/ *pStrm nType0 /*N*/ nCreateType /*N*/ nCaptionDisplay -/*N*/ nStrIdx +/*N*/ nStrIdx0 /*N*/ nSeqStrIdx /*N*/ nData /*N*/ cFormFlags; /*N*/ CloseFlagRec(); /*N*/ /*N*/ sal_uInt16 nMainStyleIdx = IDX_NO_VALUE; -/*N*/ InString( *pStrm, aName ); +/*N*/ InString( *pStrm, aName0 ); /*N*/ InString( *pStrm, aTitle ); /*N*/ if( nVersion SWG_NEWTOX2 ) /*N*/ InString( *pStrm, aDummy ); // was AutoMarkURL @@ -1469,10 +1471,10 @@ extern void lcl_sw3io_FillSetExpFieldName( Sw3IoImp rIo, sal_uInt16 nStrId, /*N*/ nMainStyleIdx; /*N*/ } /*N*/ -/*N*/ TOXTypes eTOXType = (TOXTypes)nType; +/*N*/ TOXTypes eTOXType = (TOXTypes)nType0; /*N*/ String aTypeName; -/*N*/ if( IDX_NO_VALUE != nStrIdx ) -/*?*/ aTypeName = aStringPool.Find( nStrIdx ); +/*N*/ if( IDX_NO_VALUE != nStrIdx0 ) +/*?*/ aTypeName = aStringPool.Find( nStrIdx0 ); /*N*/ else /*N*/ aTypeName = SwTOXBase::GetTOXName( eTOXType ); /*N*/ @@ -1525,24 +1527,24 @@ extern void lcl_sw3io_FillSetExpFieldName( Sw3IoImp rIo, sal_uInt16 nStrId, /*N*/ { /*N*/ OpenRec( SWG_FORMTOKEN_LCL ); /*N*/ -/*N*/ sal_uInt16 nType, nStrIdx; +/*N*/ sal_uInt16 nType1, nStrIdx1; /*N*/ /*N*/ OpenFlagRec(); -/*N*/ *pStrm nType -/*N*/ nStrIdx; +/*N*/ *pStrm nType1 +/*N*/ nStrIdx1; /*N*/ CloseFlagRec(); /*N*/ -/*N*/ if( nType TOKEN_END ) +/*N*/ if( nType1 TOKEN_END ) /*N*/ { /*N*/ //#92986# some older versions created a /*N*/ //wrong content index entry definition -/*N*/ if(TOKEN_ENTRY == nType eTOXType == TOX_CONTENT) -/*N*/ nType = TOKEN_ENTRY_TEXT; -/*N*/ SwFormToken aToken( (FormTokenType)nType ); -/*N*/ if( IDX_NO_VALUE != nStrIdx ) +/*N*/
[Libreoffice] [PATCH 4/7] binfilter - sw_sw3style.cxx (shadowing) warnings removal
regards From 0b31675885126537da8351ba747cd6c6e7ad03fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Sat, 27 Nov 2010 00:06:37 +0100 Subject: [PATCH 4/7] binfilter - sw_sw3style.cxx (shadowing) warnings removal --- binfilter/bf_sw/source/core/sw3io/sw_sw3style.cxx | 20 ++-- 1 files changed, 14 insertions(+), 6 deletions(-) diff --git a/binfilter/bf_sw/source/core/sw3io/sw_sw3style.cxx b/binfilter/bf_sw/source/core/sw3io/sw_sw3style.cxx index db98772..e5fe502 100644 --- a/binfilter/bf_sw/source/core/sw3io/sw_sw3style.cxx +++ b/binfilter/bf_sw/source/core/sw3io/sw_sw3style.cxx @@ -187,10 +187,10 @@ public: -/*N*/ SwStyleSheet::SwStyleSheet( const String rName, SwStyleSheetPool rPool, -/*N*/ SfxStyleFamily eFam, USHORT nMask ) -/*N*/ : SfxStyleSheetBase( rName, rPool, eFam, nMask ), -/*N*/ rDoc( rPool.rDoc ), aSet( rPool.rPool, +/*N*/ SwStyleSheet::SwStyleSheet( const String rName, SwStyleSheetPool rPool1, +/*N*/ SfxStyleFamily eFam, USHORT nMask1 ) +/*N*/ : SfxStyleSheetBase( rName, rPool1, eFam, nMask1 ), +/*N*/ rDoc( rPool1.rDoc ), aSet( rPool1.rPool, /*N*/ RES_CHRATR_BEGIN, RES_CHRATR_END - 1, /*N*/ RES_PARATR_BEGIN, RES_PARATR_END - 1, /*N*/ RES_FRMATR_BEGIN, RES_FRMATR_END - 1, @@ -426,11 +426,15 @@ public: /*N*/ pParent = (*rDoc.GetFrmFmts())[ 0 ]; break; /*N*/ case SFX_STYLE_FAMILY_PARA: /*N*/ pParent = (*rDoc.GetTxtFmtColls())[ 0 ]; break; +default: +break; /*N*/ } /*N*/ if( pParent ) /*N*/ pFmt-SetDerivedFrom( pParent ); /*N*/ else +{ /*N*/ ASSERT( !this, Parent nicht gefunden ); +} /*N*/ } // Setzen des Follows @@ -447,7 +451,9 @@ public: /*N*/ if( pFollow ) /*N*/ GetColl()-SetNextTxtFmtColl( *pFollow ); /*N*/ else +{ /*N*/ ASSERT( !this, Follow nicht gefunden ); +} /*N*/ } /*N*/ } @@ -998,7 +1004,9 @@ sal_Char const SW_CONSTASCII_DEF( sHTML_listing, LISTING ); /*?*/ DBG_BF_ASSERT(0, STRIP); //STRIP001 ((SwConditionTxtFmtColl*)p-pFmt)-InsertCondition( /*?*/ } /*?*/ else +{ /*?*/ ASSERT( !this, Collection nicht gefunden ); +} /*N*/ } /*N*/ } /*N*/ //FEATURE::CONDCOLL @@ -1009,9 +1017,9 @@ sal_Char const SW_CONSTASCII_DEF( sHTML_listing, LISTING ); // Faktorei /*N*/ SfxStyleSheetBase* __EXPORT SwStyleSheetPool::Create( const String rName, -/*N*/ SfxStyleFamily eFam, USHORT nMask) +/*N*/ SfxStyleFamily eFam, USHORT nMask2) /*N*/ { -/*N*/ return new SwStyleSheet( rName, *this, eFam, nMask); +/*N*/ return new SwStyleSheet( rName, *this, eFam, nMask2); /*N*/ } -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 3/5] trivial warning fixes within binfilter bf_sw doc
regards From 94ae830669bfc1df7b4235c45d0a6a72def30be2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Sun, 28 Nov 2010 21:09:30 +0100 Subject: [PATCH 3/5] trivial warning fixes within binfilter bf_sw doc --- .../bf_sw/source/core/doc/sw_SwStyleNameMapper.cxx |2 +- binfilter/bf_sw/source/core/doc/sw_doc.cxx |8 ++-- binfilter/bf_sw/source/core/doc/sw_docbm.cxx |6 +- binfilter/bf_sw/source/core/doc/sw_docchart.cxx|2 +- binfilter/bf_sw/source/core/doc/sw_docdde.cxx |2 +- binfilter/bf_sw/source/core/doc/sw_docdesc.cxx |2 +- binfilter/bf_sw/source/core/doc/sw_docdraw.cxx | 18 --- binfilter/bf_sw/source/core/doc/sw_docedt.cxx |2 +- binfilter/bf_sw/source/core/doc/sw_docfld.cxx |4 +- binfilter/bf_sw/source/core/doc/sw_docfly.cxx |4 +- binfilter/bf_sw/source/core/doc/sw_docfmt.cxx |2 +- binfilter/bf_sw/source/core/doc/sw_docftn.cxx |2 +- binfilter/bf_sw/source/core/doc/sw_doclay.cxx | 14 +++--- binfilter/bf_sw/source/core/doc/sw_docnum.cxx | 10 ++-- binfilter/bf_sw/source/core/doc/sw_docredln.cxx| 49 binfilter/bf_sw/source/core/doc/sw_docsort.cxx |4 +- binfilter/bf_sw/source/core/doc/sw_doctxm.cxx |8 ++-- binfilter/bf_sw/source/core/doc/sw_fmtcol.cxx |4 +- binfilter/bf_sw/source/core/doc/sw_notxtfrm.cxx|8 ++-- binfilter/bf_sw/source/core/doc/sw_number.cxx |2 +- binfilter/bf_sw/source/core/doc/sw_poolfmt.cxx |2 +- binfilter/bf_sw/source/core/doc/sw_swtable.cxx |6 +- binfilter/bf_sw/source/core/doc/sw_tblrwcl.cxx |4 +- binfilter/bf_sw/source/core/doc/sw_visiturl.cxx|2 +- 24 files changed, 70 insertions(+), 97 deletions(-) diff --git a/binfilter/bf_sw/source/core/doc/sw_SwStyleNameMapper.cxx b/binfilter/bf_sw/source/core/doc/sw_SwStyleNameMapper.cxx index 159c82a..9a4b51c 100644 --- a/binfilter/bf_sw/source/core/doc/sw_SwStyleNameMapper.cxx +++ b/binfilter/bf_sw/source/core/doc/sw_SwStyleNameMapper.cxx @@ -709,7 +709,7 @@ const struct SwTableEntry NumRuleProgNameTable [] = /*N*/ } // Get the programmatic Name from the pool ID -/*N*/ void SwStyleNameMapper::FillProgName ( sal_uInt16 nId, String rFillName ) +/*N*/ void SwStyleNameMapper::FillProgName ( sal_uInt16 /*nId*/, String /*rFillName*/ ) /*N*/ {DBG_BF_ASSERT(0, STRIP); //STRIP001 /*N*/ } // Get the programmatic Name from the pool ID diff --git a/binfilter/bf_sw/source/core/doc/sw_doc.cxx b/binfilter/bf_sw/source/core/doc/sw_doc.cxx index 3c5811c..c5bfcc0 100644 --- a/binfilter/bf_sw/source/core/doc/sw_doc.cxx +++ b/binfilter/bf_sw/source/core/doc/sw_doc.cxx @@ -487,7 +487,7 @@ void SwDoc::SetGlobalMacro( USHORT nEvent, const SvxMacro rMacro ) //JP 24.06.96: Ist der ArrayPointer 0 dann returne nur, ob im Doc. eine //RefMark gesetzt ist // OS 25.06.96: ab jetzt wird immer die Anzahl der Referenzen returnt -/*N*/ USHORT SwDoc::GetRefMarks( SvStringsDtor* pNames ) const +/*N*/ USHORT SwDoc::GetRefMarks( SvStringsDtor* /*pNames*/ ) const /*N*/ { /*N*/ DBG_BF_ASSERT(0, STRIP); return 0;//STRIP001 const SfxPoolItem* pItem; /*N*/ } @@ -524,9 +524,9 @@ void SwDoc::SetGlobalMacro( USHORT nEvent, const SvxMacro rMacro ) /*N*/ } -/*N*/ void SwDoc::ReRead( SwPaM rPam, const String rGrfName, -/*N*/ const String rFltName, const Graphic* pGraphic, -/*N*/ const BfGraphicObject* pGrafObj ) +/*N*/ void SwDoc::ReRead( SwPaM /*rPam*/, const String /*rGrfName*/, +/*N*/ const String /*rFltName*/, const Graphic* /*pGraphic*/, +/*N*/ const BfGraphicObject* /*pGrafObj*/ ) /*N*/ { DBG_BF_ASSERT(0, STRIP); //STRIP001 SwGrfNode *pGrfNd; /*N*/ } diff --git a/binfilter/bf_sw/source/core/doc/sw_docbm.cxx b/binfilter/bf_sw/source/core/doc/sw_docbm.cxx index ca32fb5..f0ce7bb 100644 --- a/binfilter/bf_sw/source/core/doc/sw_docbm.cxx +++ b/binfilter/bf_sw/source/core/doc/sw_docbm.cxx @@ -181,7 +181,7 @@ namespace binfilter { // erzeugt einen eindeutigen Namen. Der Name selbst muss vorgegeben // werden, es wird dann bei gleichen Namen nur durchnumeriert. -/*N*/ void SwDoc::MakeUniqueBookmarkName( String rNm ) +/*N*/ void SwDoc::MakeUniqueBookmarkName( String /*rNm*/ ) /*N*/ { /*?*/ DBG_BF_ASSERT(0, STRIP); //STRIP001 ASSERT( rNm.Len(), es sollte ein Name vorgegeben werden! ); /*N*/ } @@ -189,8 +189,8 @@ namespace binfilter { /* */ /*N*/ SaveBookmark::SaveBookmark( int eType, const SwBookmark rBkmk, -/*N*/ const SwNodeIndex rMvPos, -/*N*/ const SwIndex* pIdx ) +/*N*/ const SwNodeIndex /*rMvPos*/, +/*N*/ const SwIndex* /*pIdx*/ ) /*N*/ : aName( rBkmk.GetName() ), aShortName( rBkmk.GetShortName() ), /*N*/ aCode( rBkmk.GetKeyCode() ), eBkmkType( (SaveBookmarkType)eType ), /*N*/ eOrigBkmType(rBkmk.GetType()) diff --git a/binfilter/bf_sw/source/core/doc/sw_docchart.cxx
[Libreoffice] [PATCH 5/5] trivial warning cleaning in binfilter - unocore (2)
regards From 09642903881c193ff01f2801461dcddeae0931ad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Mon, 29 Nov 2010 22:13:22 +0100 Subject: [PATCH 5/5] trivial warning cleaning in binfilter - unocore (2) --- binfilter/bf_sw/source/core/unocore/sw_unodraw.cxx | 12 ++- binfilter/bf_sw/source/core/unocore/sw_unomap.cxx | 11 +-- binfilter/bf_sw/source/core/unocore/sw_unoobj2.cxx |8 +- .../bf_sw/source/core/unocore/sw_unoparagraph.cxx | 27 --- binfilter/bf_sw/source/core/unocore/sw_unoport.cxx | 32 --- .../bf_sw/source/core/unocore/sw_unoredline.cxx| 12 ++-- .../bf_sw/source/core/unocore/sw_unoredlines.cxx |4 +- binfilter/bf_sw/source/core/unocore/sw_unosrch.cxx | 16 +++- .../bf_sw/source/core/unocore/sw_unostyle.cxx | 26 +++--- binfilter/bf_sw/source/core/unocore/sw_unotbl.cxx | 90 ++-- binfilter/bf_sw/source/core/unocore/sw_unotext.cxx | 18 ++-- 11 files changed, 155 insertions(+), 101 deletions(-) diff --git a/binfilter/bf_sw/source/core/unocore/sw_unodraw.cxx b/binfilter/bf_sw/source/core/unocore/sw_unodraw.cxx index 5533ee5..37cb25e 100644 --- a/binfilter/bf_sw/source/core/unocore/sw_unodraw.cxx +++ b/binfilter/bf_sw/source/core/unocore/sw_unodraw.cxx @@ -1285,27 +1285,29 @@ Any SwXShape::getPropertyDefault( const OUString rPropertyName ) return aRet; } -void SwXShape::addPropertyChangeListener(const OUString /*PropertyName*/, const Reference XPropertyChangeListener /*aListener*/) +void SwXShape::addPropertyChangeListener(const OUString /*PropertyName*/, +const Reference XPropertyChangeListener /*aListener*/) throw( UnknownPropertyException, WrappedTargetException, RuntimeException ) { DBG_WARNING(not implemented); } void SwXShape::removePropertyChangeListener( -const OUString PropertyName, -const Reference XPropertyChangeListener aListener) +const OUString /*PropertyName*/,const Reference XPropertyChangeListener /*aListener*/) throw( UnknownPropertyException, WrappedTargetException, RuntimeException ) { DBG_WARNING(not implemented); } -void SwXShape::addVetoableChangeListener(const OUString /*PropertyName*/, const Reference XVetoableChangeListener /*aListener*/) +void SwXShape::addVetoableChangeListener( +const OUString /*PropertyName*/, const Reference XVetoableChangeListener /*aListener*/) throw( UnknownPropertyException, WrappedTargetException, RuntimeException ) { DBG_WARNING(not implemented); } -void SwXShape::removeVetoableChangeListener(const OUString /*PropertyName*/, const Reference XVetoableChangeListener /*aListener*/) +void SwXShape::removeVetoableChangeListener(const OUString /*PropertyName*/, +const Reference XVetoableChangeListener /*aListener*/) throw( UnknownPropertyException, WrappedTargetException, RuntimeException ) { DBG_WARNING(not implemented); diff --git a/binfilter/bf_sw/source/core/unocore/sw_unomap.cxx b/binfilter/bf_sw/source/core/unocore/sw_unomap.cxx index 0d0fd71..1a46a94 100644 --- a/binfilter/bf_sw/source/core/unocore/sw_unomap.cxx +++ b/binfilter/bf_sw/source/core/unocore/sw_unomap.cxx @@ -2321,17 +2321,10 @@ const SfxItemPropertyMap* SwUnoPropertyMapProvider::GetPropertyMap(sal_uInt16 nP } return aMapArr[nPropertyId]; } -/* -04.07.98 11:42--- - * - * --*/ -sal_Bool SwItemPropertySet::FillItem(SfxItemSet rSet, sal_uInt16 nWhich, sal_Bool bGetProperty) const + +sal_Bool SwItemPropertySet::FillItem(SfxItemSet /*rSet*/, sal_uInt16 /*nWhich*/, sal_Bool /*bGetProperty*/) const { sal_Bool bRet = sal_False; -/* if(nWhich == SID_ATTR_PAGE_PAPERBIN) -{ -rSet.Put(SvxPaperBinItem(SID_ATTR_PAGE_PAPERBIN, 0)); -bRet = sal_True; -}*/ return bRet; } } diff --git a/binfilter/bf_sw/source/core/unocore/sw_unoobj2.cxx b/binfilter/bf_sw/source/core/unocore/sw_unoobj2.cxx index 81ba642..4a88ebc 100644 --- a/binfilter/bf_sw/source/core/unocore/sw_unoobj2.cxx +++ b/binfilter/bf_sw/source/core/unocore/sw_unoobj2.cxx @@ -1934,7 +1934,7 @@ Any SAL_CALL SwXTextRange::getPropertyValue( const OUString rPropertyName ) ---*/ void SAL_CALL SwXTextRange::addPropertyChangeListener( -const OUString aPropertyName, const Reference XPropertyChangeListener xListener ) +const OUString /*aPropertyName*/, const Reference XPropertyChangeListener /*xListener*/ ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) { DBG_WARNING(not implemented); @@ -1943,7 +1943,7 @@ void SAL_CALL SwXTextRange::addPropertyChangeListener( ---*/ void SAL_CALL SwXTextRange::removePropertyChangeListener( -const OUString aPropertyName, const Reference
[Libreoffice] [PATCH 4/5] trivial warning cleaning in binfilter - unocore (1)
regards From f5aac0dd10c586fbcdcd8e6a86e396601db8ad27 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Mon, 29 Nov 2010 08:20:37 +0100 Subject: [PATCH 4/5] trivial warning cleaning in binfilter - unocore (1) --- .../source/core/unocore/sw_SwXTextDefaults.cxx |8 ++-- binfilter/bf_sw/source/core/unocore/sw_unobkm.cxx | 17 --- binfilter/bf_sw/source/core/unocore/sw_unodraw.cxx |9 ++- .../bf_sw/source/core/unocore/sw_unofield.cxx | 24 ++--- .../bf_sw/source/core/unocore/sw_unoframe.cxx | 16 +++--- binfilter/bf_sw/source/core/unocore/sw_unoftn.cxx | 16 +++--- binfilter/bf_sw/source/core/unocore/sw_unoidx.cxx | 32 +--- binfilter/bf_sw/source/core/unocore/sw_unoobj.cxx | 16 +-- .../bf_sw/source/core/unocore/sw_unorefmk.cxx | 12 ++-- binfilter/bf_sw/source/core/unocore/sw_unosect.cxx | 22 + binfilter/bf_sw/source/core/unocore/sw_unosett.cxx | 50 +++- 11 files changed, 133 insertions(+), 89 deletions(-) diff --git a/binfilter/bf_sw/source/core/unocore/sw_SwXTextDefaults.cxx b/binfilter/bf_sw/source/core/unocore/sw_SwXTextDefaults.cxx index 14e8028..c1acdb5 100644 --- a/binfilter/bf_sw/source/core/unocore/sw_SwXTextDefaults.cxx +++ b/binfilter/bf_sw/source/core/unocore/sw_SwXTextDefaults.cxx @@ -166,28 +166,28 @@ Any SAL_CALL SwXTextDefaults::getPropertyValue( const OUString rPropertyName ) } -void SAL_CALL SwXTextDefaults::addPropertyChangeListener( const OUString rPropertyName, const Reference XPropertyChangeListener xListener ) +void SAL_CALL SwXTextDefaults::addPropertyChangeListener( const OUString /*rPropertyName*/, const Reference XPropertyChangeListener /*xListener*/ ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) { DBG_WARNING ( not implemented ); } -void SAL_CALL SwXTextDefaults::removePropertyChangeListener( const OUString rPropertyName, const Reference XPropertyChangeListener aListener ) +void SAL_CALL SwXTextDefaults::removePropertyChangeListener( const OUString /*rPropertyName*/, const Reference XPropertyChangeListener /*aListener*/ ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) { DBG_WARNING ( not implemented ); } -void SAL_CALL SwXTextDefaults::addVetoableChangeListener( const OUString rPropertyName, const Reference XVetoableChangeListener aListener ) +void SAL_CALL SwXTextDefaults::addVetoableChangeListener( const OUString /*rPropertyName*/, const Reference XVetoableChangeListener /*aListener*/ ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) { DBG_WARNING ( not implemented ); } -void SAL_CALL SwXTextDefaults::removeVetoableChangeListener( const OUString rPropertyName, const Reference XVetoableChangeListener aListener ) +void SAL_CALL SwXTextDefaults::removeVetoableChangeListener( const OUString /*rPropertyName*/, const Reference XVetoableChangeListener /*aListener*/ ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) { DBG_WARNING ( not implemented ); diff --git a/binfilter/bf_sw/source/core/unocore/sw_unobkm.cxx b/binfilter/bf_sw/source/core/unocore/sw_unobkm.cxx index 98d174d..fead095 100644 --- a/binfilter/bf_sw/source/core/unocore/sw_unobkm.cxx +++ b/binfilter/bf_sw/source/core/unocore/sw_unobkm.cxx @@ -275,7 +275,7 @@ uno::Reference beans::XPropertySetInfo SwXBookmark::getPropertySetInfo(void) return aRef; } -void SwXBookmark::setPropertyValue(const OUString PropertyName, const uno::Any aValue) +void SwXBookmark::setPropertyValue(const OUString PropertyName, const uno::Any /*aValue*/) throw( beans::UnknownPropertyException, beans::PropertyVetoException, lang::IllegalArgumentException, lang::WrappedTargetException, uno::RuntimeException ) { @@ -294,25 +294,26 @@ uno::Any SwXBookmark::getPropertyValue(const OUString rPropertyName) throw( bea return aRet; } -void SwXBookmark::addPropertyChangeListener(const OUString PropertyName, -const uno::Reference beans::XPropertyChangeListener aListener) +void SwXBookmark::addPropertyChangeListener(const OUString /*PropertyName*/, +const uno::Reference beans::XPropertyChangeListener /*aListener*/) throw( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException ) { } -void SwXBookmark::removePropertyChangeListener(const OUString PropertyName, -const uno::Reference beans::XPropertyChangeListener aListener) +void SwXBookmark::removePropertyChangeListener(const OUString /*PropertyName*/, +const uno::Reference beans::XPropertyChangeListener /*aListener*/) throw( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException ) { } -void SwXBookmark::addVetoableChangeListener(const OUString PropertyName, -const uno::Reference beans::XVetoableChangeListener aListener) +void
[Libreoffice] [PATCH 4/5] trivial warning cleaning in binfilter - unocore (1)
regards From f5aac0dd10c586fbcdcd8e6a86e396601db8ad27 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Mon, 29 Nov 2010 08:20:37 +0100 Subject: [PATCH 4/5] trivial warning cleaning in binfilter - unocore (1) --- .../source/core/unocore/sw_SwXTextDefaults.cxx |8 ++-- binfilter/bf_sw/source/core/unocore/sw_unobkm.cxx | 17 --- binfilter/bf_sw/source/core/unocore/sw_unodraw.cxx |9 ++- .../bf_sw/source/core/unocore/sw_unofield.cxx | 24 ++--- .../bf_sw/source/core/unocore/sw_unoframe.cxx | 16 +++--- binfilter/bf_sw/source/core/unocore/sw_unoftn.cxx | 16 +++--- binfilter/bf_sw/source/core/unocore/sw_unoidx.cxx | 32 +--- binfilter/bf_sw/source/core/unocore/sw_unoobj.cxx | 16 +-- .../bf_sw/source/core/unocore/sw_unorefmk.cxx | 12 ++-- binfilter/bf_sw/source/core/unocore/sw_unosect.cxx | 22 + binfilter/bf_sw/source/core/unocore/sw_unosett.cxx | 50 +++- 11 files changed, 133 insertions(+), 89 deletions(-) diff --git a/binfilter/bf_sw/source/core/unocore/sw_SwXTextDefaults.cxx b/binfilter/bf_sw/source/core/unocore/sw_SwXTextDefaults.cxx index 14e8028..c1acdb5 100644 --- a/binfilter/bf_sw/source/core/unocore/sw_SwXTextDefaults.cxx +++ b/binfilter/bf_sw/source/core/unocore/sw_SwXTextDefaults.cxx @@ -166,28 +166,28 @@ Any SAL_CALL SwXTextDefaults::getPropertyValue( const OUString rPropertyName ) } -void SAL_CALL SwXTextDefaults::addPropertyChangeListener( const OUString rPropertyName, const Reference XPropertyChangeListener xListener ) +void SAL_CALL SwXTextDefaults::addPropertyChangeListener( const OUString /*rPropertyName*/, const Reference XPropertyChangeListener /*xListener*/ ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) { DBG_WARNING ( not implemented ); } -void SAL_CALL SwXTextDefaults::removePropertyChangeListener( const OUString rPropertyName, const Reference XPropertyChangeListener aListener ) +void SAL_CALL SwXTextDefaults::removePropertyChangeListener( const OUString /*rPropertyName*/, const Reference XPropertyChangeListener /*aListener*/ ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) { DBG_WARNING ( not implemented ); } -void SAL_CALL SwXTextDefaults::addVetoableChangeListener( const OUString rPropertyName, const Reference XVetoableChangeListener aListener ) +void SAL_CALL SwXTextDefaults::addVetoableChangeListener( const OUString /*rPropertyName*/, const Reference XVetoableChangeListener /*aListener*/ ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) { DBG_WARNING ( not implemented ); } -void SAL_CALL SwXTextDefaults::removeVetoableChangeListener( const OUString rPropertyName, const Reference XVetoableChangeListener aListener ) +void SAL_CALL SwXTextDefaults::removeVetoableChangeListener( const OUString /*rPropertyName*/, const Reference XVetoableChangeListener /*aListener*/ ) throw(UnknownPropertyException, WrappedTargetException, RuntimeException) { DBG_WARNING ( not implemented ); diff --git a/binfilter/bf_sw/source/core/unocore/sw_unobkm.cxx b/binfilter/bf_sw/source/core/unocore/sw_unobkm.cxx index 98d174d..fead095 100644 --- a/binfilter/bf_sw/source/core/unocore/sw_unobkm.cxx +++ b/binfilter/bf_sw/source/core/unocore/sw_unobkm.cxx @@ -275,7 +275,7 @@ uno::Reference beans::XPropertySetInfo SwXBookmark::getPropertySetInfo(void) return aRef; } -void SwXBookmark::setPropertyValue(const OUString PropertyName, const uno::Any aValue) +void SwXBookmark::setPropertyValue(const OUString PropertyName, const uno::Any /*aValue*/) throw( beans::UnknownPropertyException, beans::PropertyVetoException, lang::IllegalArgumentException, lang::WrappedTargetException, uno::RuntimeException ) { @@ -294,25 +294,26 @@ uno::Any SwXBookmark::getPropertyValue(const OUString rPropertyName) throw( bea return aRet; } -void SwXBookmark::addPropertyChangeListener(const OUString PropertyName, -const uno::Reference beans::XPropertyChangeListener aListener) +void SwXBookmark::addPropertyChangeListener(const OUString /*PropertyName*/, +const uno::Reference beans::XPropertyChangeListener /*aListener*/) throw( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException ) { } -void SwXBookmark::removePropertyChangeListener(const OUString PropertyName, -const uno::Reference beans::XPropertyChangeListener aListener) +void SwXBookmark::removePropertyChangeListener(const OUString /*PropertyName*/, +const uno::Reference beans::XPropertyChangeListener /*aListener*/) throw( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException ) { } -void SwXBookmark::addVetoableChangeListener(const OUString PropertyName, -const uno::Reference beans::XVetoableChangeListener aListener) +void
Re: [Libreoffice] Script to find undocumented classes
Beware - I am a newcomer - maybe my point of view is quite wrong due to lack of understanding. But then at least I will understand something better :- ) My first remark: stepping in seems to me to be very difficult despite the very friendly behaviour of people here. un-documented code-base is an incredibly valuable one - it turns out most commercial code-bases are a total mess internally; LibreOffice is nothing special. Gnap... depend of which software you are speaking, then... For having (to) read a lot of code in a big software, I can say that this one (I mean this commercial one) at least is well documented and quite well written. And no, I do not work for them:- ) IMHO we cannot and should not put a break on writing that just to improve merge-ability, Why not drop merging from OOO after LibO 3.3? As newcomer, I have read x times not here due to merge / not touch due to merge... Then I am reluctant to touch some parts...At least, the burden should be on side of person merging OOo into LibO, not be of a concern for people contributing to LibO. enable the re-factoring that can make our APIs both pretty and intuitive over time, I think would very help any newcomer stepping in. Currently hunting warning, I do it deliberately in order to get used to the code and uses. But even there, sometimes I skip the point, not being able after following the function calling the function calling... and determining for sure that the change would have a cross effect. And I do not even tried yet to change a feature. Deliberate choice from me, clear, but yeah... Regards ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH] making binfilter compiling again
Thanks to review and push it quite quickly if possible. Changes have been done (for RTL_OUSTRING_...) without looking that the namespace rtl is not declared. I did not introduced it but just corrected the entries, since I am not enough familiar to know which is the prefered situation within the project. regards From a70f9654155a6fd17747305afb717471aac92b4c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Fri, 3 Dec 2010 20:39:37 +0100 Subject: [PATCH] making binfilter compiling again changes for RTL_CONSTASCII_USTRINGPARAM without taking into account namespaces --- binfilter/bf_sfx2/source/config/sfx2_evntconf.cxx | 14 +++--- .../bf_sfx2/source/notify/sfx2_eventsupplier.cxx |6 +++--- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/binfilter/bf_sfx2/source/config/sfx2_evntconf.cxx b/binfilter/bf_sfx2/source/config/sfx2_evntconf.cxx index b66811f..7f31956 100644 --- a/binfilter/bf_sfx2/source/config/sfx2_evntconf.cxx +++ b/binfilter/bf_sfx2/source/config/sfx2_evntconf.cxx @@ -374,13 +374,13 @@ void SfxEventConfigItem_Impl::Init( SfxConfigManager *pMgr ) /*N*/ OUSTRINGaLib= pMacro-GetLibName(); /*N*/ OUSTRINGaMacro = pMacro-GetMacName(); /*N*/ -/*N*/ pValues[ 0 ].Name = OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_EVENT_TYPE )); +/*N*/ pValues[ 0 ].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_EVENT_TYPE )); /*N*/ pValues[ 0 ].Value = aType; /*N*/ -/*N*/ pValues[ 1 ].Name = OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_LIBRARY )); +/*N*/ pValues[ 1 ].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_LIBRARY )); /*N*/ pValues[ 1 ].Value = aLib; /*N*/ -/*N*/ pValues[ 2 ].Name = OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_MACRO_NAME )); +/*N*/ pValues[ 2 ].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_MACRO_NAME )); /*N*/ pValues[ 2 ].Value = aMacro; /*N*/ /*N*/ aEventData = aProperties; @@ -393,10 +393,10 @@ void SfxEventConfigItem_Impl::Init( SfxConfigManager *pMgr ) /*?*/ OUSTRINGaLib= pMacro-GetLibName(); /*?*/ OUSTRINGaMacro = pMacro-GetMacName(); /*?*/ -/*?*/ pValues[ 0 ].Name = OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_EVENT_TYPE )); +/*?*/ pValues[ 0 ].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_EVENT_TYPE )); /*?*/ pValues[ 0 ].Value = aLib; /*?*/ -/*?*/ pValues[ 1 ].Name = OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_SCRIPT )); +/*?*/ pValues[ 1 ].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_SCRIPT )); /*?*/ pValues[ 1 ].Value = aMacro; /*?*/ /*?*/ aEventData = aProperties; @@ -408,10 +408,10 @@ void SfxEventConfigItem_Impl::Init( SfxConfigManager *pMgr ) /*?*/ /*?*/ OUSTRINGaMacro = pMacro-GetMacName(); /*?*/ -/*?*/ pValues[ 0 ].Name = OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_EVENT_TYPE )); +/*?*/ pValues[ 0 ].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_EVENT_TYPE )); /*?*/ pValues[ 0 ].Value = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SVX_MACRO_LANGUAGE_JAVASCRIPT)); /*?*/ -/*?*/ pValues[ 1 ].Name = OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_MACRO_NAME )); +/*?*/ pValues[ 1 ].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_MACRO_NAME )); /*?*/ pValues[ 1 ].Value = aMacro; /*?*/ /*?*/ aEventData = aProperties; diff --git a/binfilter/bf_sfx2/source/notify/sfx2_eventsupplier.cxx b/binfilter/bf_sfx2/source/notify/sfx2_eventsupplier.cxx index 117b1ef..bdd2134 100644 --- a/binfilter/bf_sfx2/source/notify/sfx2_eventsupplier.cxx +++ b/binfilter/bf_sfx2/source/notify/sfx2_eventsupplier.cxx @@ -387,11 +387,11 @@ namespace binfilter { aLibrary = sDocument; } /*N*/ -/*N*/ aOutProps[1].Name = OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_SCRIPT )); +/*N*/ aOutProps[1].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_SCRIPT )); /*N*/ aOutProps[1].Value = aScript; -/*N*/ aOutProps[2].Name = OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_LIBRARY )); +/*N*/ aOutProps[2].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_LIBRARY )); /*N*/ aOutProps[2].Value = aLibrary; -/*N*/ aOutProps[3].Name = OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_MACRO_NAME )); +/*N*/ aOutProps[3].Name = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( PROP_MACRO_NAME )); /*N*/ aOutProps[3].Value = aMacroName; /*N*/ rRet = aOutProps; /*N*/ } -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] binfilter and features...
Hi, currently trying to reduce the number of warning coming from binfilter, I found quite a lot functions like: func(var x) {} or func(var x) { ASSERT (lksd) }. sometimes func (var x) {return false} Would someone mind if I track down the call of such functions, remove the calls and at the end remove the function? This would reduce and simplified the codebase, also more efficient (less function calls) and - I hope - a smaller LibO. Of course, these functions are marker, but intend someone really to developp binfilter ? Which make me think: as new feature, for the next LibO release after 3.3, could it be that StarOffice file format are not supported any more, at least in writing modus?. Reading files would open it in read only, trying to save would produce a warning like this old format is deprecated, please save in a new one. Maybe the same for the old OOo format? Or do you intend to drop this in a quicker way? Just for feed-back. regards ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] crossing strange code: a little help
Hi within filters/binfilter/bf_sw/source/core/txtnode/sw_thints.cxx line 955, I crossed this code construct: if() { . while (TRUE) { DBG_BF_ASSERT(0, STRIP); } } With and without debugging option on, if the if is entered, then this is an endless loop? Does it means that the IF is never taken? thanks regards ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] binfilter and features...
On 12/05/2010 12:39 PM, Caolán McNamara wrote: All true. It was just a note that it might be easier, if you have an interest in binfilter, to just take the conservative approach and silence warnings with e.g converting I was thinking of taking a 2 steps approach: first silent warning in a conservative way (this is also less risk to introduce bugs) and then to down-size the module just keeping the needed part. In my opinion, the needed part would be, for the next releases, just the read capability of (older?) binary format build in within LibO. But if the decision is to drop it anyway for the next release, does not bring a lot I did not found any inputs about it within mailing lists. Has the point been discussed somewhere? Is this to be handle by the steering committee? Is there a technical steering committee for this kind of decision, where we could propose / give reasons for thinking this or that? Currently, as said, I am doing conservative warning fixes, but to start something more intrusive, would like to have first a kind of direction decision. regards ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 01/16] warning variable unused fix in binfilter bf_sw attr
Hi, here some patches to suppress warnings within binfilter. I took a - sometimes too - conservative approach for doing this. Hope I did not harm this module regards From 3c2cd665fe8a344626265f6c8a2a3b195556441d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Sat, 4 Dec 2010 10:18:51 +0100 Subject: [PATCH 01/16] warning variable unused fix in binfilter bf_sw attr --- binfilter/bf_sw/source/core/attr/sw_format.cxx |1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/binfilter/bf_sw/source/core/attr/sw_format.cxx b/binfilter/bf_sw/source/core/attr/sw_format.cxx index fdc874a..c424aa3 100644 --- a/binfilter/bf_sw/source/core/attr/sw_format.cxx +++ b/binfilter/bf_sw/source/core/attr/sw_format.cxx @@ -213,7 +213,6 @@ namespace binfilter { /*N*/ void SwFmt::CopyAttrs( const SwFmt rFmt, BOOL bReplace ) /*N*/ { /*N*/ // kopiere nur das Attribut-Delta Array -/*N*/ register SwCharFmt* pDropCharFmt = 0; /*N*/ /*N*/ if ( IsInCache() ) /*N*/ { -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 02/16] warning fix unused variable in binfilter bf_sw bastyp
regards From a03ec223cf70c17a1cd6bbf397dc954c8d9d13fe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Sat, 4 Dec 2010 10:25:53 +0100 Subject: [PATCH 02/16] warning fix unused variable in binfilter bf_sw bastyp --- binfilter/bf_sw/source/core/bastyp/sw_calc.cxx|2 +- binfilter/bf_sw/source/core/bastyp/sw_swtypes.cxx |4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/binfilter/bf_sw/source/core/bastyp/sw_calc.cxx b/binfilter/bf_sw/source/core/bastyp/sw_calc.cxx index 7cee1dd..76e7026 100644 --- a/binfilter/bf_sw/source/core/bastyp/sw_calc.cxx +++ b/binfilter/bf_sw/source/core/bastyp/sw_calc.cxx @@ -454,7 +454,7 @@ static int -/*N*/ String SwCalc::GetStrResult( double nValue, BOOL bRound ) +/*N*/ String SwCalc::GetStrResult( double nValue, BOOL /*bRound*/ ) /*N*/ { /*N*/ if( nValue = DBL_MAX ) /*N*/ switch( eError ) diff --git a/binfilter/bf_sw/source/core/bastyp/sw_swtypes.cxx b/binfilter/bf_sw/source/core/bastyp/sw_swtypes.cxx index 198f2a8..60965eb 100644 --- a/binfilter/bf_sw/source/core/bastyp/sw_swtypes.cxx +++ b/binfilter/bf_sw/source/core/bastyp/sw_swtypes.cxx @@ -127,9 +127,9 @@ IMPL_FIXEDMEMPOOL_NEWDEL( _SwCursor_SavePos, 20, 20 ) /*N*/ } -/*N*/ Locale CreateLocale( LanguageType eLanguage ) +/*N*/ Locale CreateLocale( LanguageType /*eLanguage*/ ) /*N*/ { -/*?*/ DBG_BF_ASSERT(0, STRIP); Locale temp; return temp;//STRIP001 String aLangStr, aCtryStr; +/*?*/ DBG_BF_ASSERT(0, STRIP); Locale temp; return temp; /*N*/ } -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 03/16] fix warning unused var in binfilter bf_sw crsr
regards From fe0b41fe4378e18478263caf8d09af1f3adafa28 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Sat, 4 Dec 2010 11:12:21 +0100 Subject: [PATCH 03/16] fix warning unused var in binfilter bf_sw crsr this is fixing warning, not optimizing. This means, some functions call have be left, even if it is possible they are not needed any more --- binfilter/bf_sw/source/core/crsr/sw_crsrsh.cxx | 34 ++--- binfilter/bf_sw/source/core/crsr/sw_findattr.cxx | 16 ++ binfilter/bf_sw/source/core/crsr/sw_findcoll.cxx | 17 +++ binfilter/bf_sw/source/core/crsr/sw_findtxt.cxx | 23 --- binfilter/bf_sw/source/core/crsr/sw_pam.cxx | 19 +--- binfilter/bf_sw/source/core/crsr/sw_swcrsr.cxx | 32 ++-- binfilter/bf_sw/source/core/crsr/sw_trvlreg.cxx | 16 +- binfilter/bf_sw/source/core/crsr/sw_trvltbl.cxx | 14 binfilter/bf_sw/source/core/crsr/sw_unocrsr.cxx | 19 +--- 9 files changed, 65 insertions(+), 125 deletions(-) diff --git a/binfilter/bf_sw/source/core/crsr/sw_crsrsh.cxx b/binfilter/bf_sw/source/core/crsr/sw_crsrsh.cxx index 17da949..dd19e9b 100644 --- a/binfilter/bf_sw/source/core/crsr/sw_crsrsh.cxx +++ b/binfilter/bf_sw/source/core/crsr/sw_crsrsh.cxx @@ -117,11 +117,11 @@ using namespace ::com::sun::star::util; // gebe den aktuellen zurueck -/*N*/ SwPaM* SwCrsrShell::GetCrsr( bool bMakeTblCrsr ) const +/*N*/ SwPaM* SwCrsrShell::GetCrsr( bool /*bMakeTblCrsr*/ ) const /*N*/ { /*N*/ if( pTblCrsr ) /*N*/ { -DBG_BF_ASSERT(0, STRIP); //STRIP001 /*?*/ if( bMakeTblCrsr pTblCrsr-IsCrsrMovedUpdt() ) +DBG_BF_ASSERT(0, STRIP); /*N*/ } /*N*/ return pCurCrsr; /*N*/ } @@ -148,19 +148,7 @@ DBG_BF_ASSERT(0, STRIP); //STRIP001 /*?*/ if( bMakeTblCrsr pTblCrsr-IsC /*N*/ void SwCrsrShell::EndAction( const BOOL bIdleEnd ) /*N*/ { -/* -//OS: Wird z.B. eine Basic-Action im Hintergrund ausgefuehrt, geht es so nicht -if( !bHasFocus ) -{ -// hat die Shell nicht den Focus, dann nur das EndAction an -// die ViewShell weitergeben. -ViewShell::EndAction( bIdleEnd ); -return; -} -*/ - /*N*/ bool bVis = bSVCrsrVis; - // Idle-Formatierung ? /*N*/ if( bIdleEnd Imp()-GetRegion() ) /*N*/ { @@ -209,7 +197,7 @@ DBG_BF_ASSERT(0, STRIP); //STRIP001 /*?*/ if( bMakeTblCrsr pTblCrsr-IsC /*?*/ //der Cursor geupdatet werden; um z.B. den /*?*/ //TabellenCursor zu erzeugen. Im UpdateCrsr wird /*?*/ //das jetzt beruecksichtigt! -DBG_BF_ASSERT(0, STRIP); //STRIP001 /*?*/ UpdateCrsr( SwCrsrShell::CHKRANGE, bIdleEnd ); +DBG_BF_ASSERT(0, STRIP); /*N*/ } /*N*/ return; /*N*/ } @@ -294,7 +282,6 @@ DBG_BF_ASSERT(0, STRIP); //STRIP001 /*?*/ UpdateCrsr( SwCrsrShell::CHKRANG /*M*/ /*M*/ // erfrage den Count fuer die Start-/End-Actions und ob die Shell /*M*/ // ueberhaupt den Focus hat -/*M*/ // if( ActionPend() /*|| !bHasFocus*/ ) /*M*/ //JP 12.01.98: Bug #46496# - es muss innerhalb einer BasicAction der /*M*/ //Cursor geupdatet werden; um z.B. den TabellenCursor zu /*M*/ //erzeugen. Im EndAction wird jetzt das UpdateCrsr gerufen! @@ -324,8 +311,7 @@ DBG_BF_ASSERT(0, STRIP); //STRIP001 /*?*/ UpdateCrsr( SwCrsrShell::CHKRANG /*M*/ pDoc-IsIdxInTbl( pTstCrsr-GetPoint()-nNode ) /*M*/ ( pTblCrsr || /*M*/ pTstCrsr-GetNode( TRUE )-FindStartNode() != -/*M*/ pTstCrsr-GetNode( FALSE )-FindStartNode() )) -/*M*/ /*|| ( !pTblCrsr lcl_IsInValueBox( *pTstCrsr, *this ) )*/ ) +/*M*/ pTstCrsr-GetNode( FALSE )-FindStartNode() )) ) /*M*/ {DBG_BF_ASSERT(0, STRIP); //STRIP001 /*M*/ } /*M*/ @@ -557,12 +543,8 @@ DBG_BF_ASSERT(0, STRIP); //STRIP001 /*?*/ UpdateCrsr( SwCrsrShell::CHKRANG /*M*/ pVisCrsr-Show(); // wieder anzeigen /*M*/ } - - // erzeuge eine Kopie vom Cursor und speicher diese im Stack - - /* * Loescht einen Cursor (gesteuert durch bOldCrsr) * - vom Stack oder( bOldCrsr = TRUE ) @@ -572,18 +554,12 @@ DBG_BF_ASSERT(0, STRIP); //STRIP001 /*?*/ UpdateCrsr( SwCrsrShell::CHKRANG */ - /* * Verbinde zwei Cursor miteinander. * Loesche vom Stack den obersten und setzen dessen GetMark im Aktuellen. */ - - - - - /*N*/ void SwCrsrShell::ShowCrsrs( BOOL bCrsrVis ) /*N*/ { /*N*/ if( !bHasFocus || bAllProtect || bBasicHideCrsr ) @@ -797,8 +773,6 @@ DBG_BF_ASSERT(0, STRIP); //STRIP001 /*?*/ UpdateCrsr( SwCrsrShell::CHKRANG #if defined(DBG_UTIL) || defined(WIN) - - /*N*/ SwCursor* SwCrsrShell::GetSwCrsr( bool bMakeTblCrsr ) const /*N*/ { /*N*/ return (SwCursor*)GetCrsr( bMakeTblCrsr ); diff --git a/binfilter/bf_sw/source/core/crsr/sw_findattr.cxx b/binfilter/bf_sw/source/core/crsr/sw_findattr.cxx index 03d2972..24d7af4 100644 --- a/binfilter/bf_sw/source/core/crsr/sw_findattr.cxx +++ b/binfilter/bf_sw/source/core/crsr/sw_findattr.cxx @@ -53,16
[Libreoffice] [PATCH 05/16] warning fix unused var in binfilter bf_sw docnode
regards From dafaabb2c38990bf4141c6074e15f0ca35d7e160 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Sat, 4 Dec 2010 15:19:44 +0100 Subject: [PATCH 05/16] warning fix unused var in binfilter bf_sw docnode only warning removal, not code optimization, hence some function calls that may not be needed anymore left behind. --- binfilter/bf_sw/source/core/docnode/sw_ndsect.cxx |5 ++--- binfilter/bf_sw/source/core/docnode/sw_ndtbl.cxx |1 - binfilter/bf_sw/source/core/docnode/sw_node.cxx|2 +- binfilter/bf_sw/source/core/docnode/sw_section.cxx |4 ++-- .../bf_sw/source/core/docnode/sw_swbaslnk.cxx |2 +- 5 files changed, 6 insertions(+), 8 deletions(-) diff --git a/binfilter/bf_sw/source/core/docnode/sw_ndsect.cxx b/binfilter/bf_sw/source/core/docnode/sw_ndsect.cxx index 9612c0d..441f3ca 100644 --- a/binfilter/bf_sw/source/core/docnode/sw_ndsect.cxx +++ b/binfilter/bf_sw/source/core/docnode/sw_ndsect.cxx @@ -437,7 +437,7 @@ namespace binfilter { /*N*/ SwSection* pSection = pFmt-GetSection(); /*N*/ /// OD 04.10.2002 #102894# /*N*/ /// remember hidden condition flag of SwSection before changes -/*N*/ bool bOldCondHidden = pSection-IsCondHidden() ? true : false; +/*N*/ pSection-IsCondHidden() ? true : false; /*N*/ /*N*/ if( *pSection == rSect ) /*N*/ { @@ -649,7 +649,6 @@ namespace binfilter { /*N*/ else /*?*/ new SwTxtNode( aInsPos, (SwTxtFmtColl*)GetDoc()-GetDfltTxtFmtColl() ); /*N*/ } -/*N*/ SwEndNode* pEndNd = new SwEndNode( aInsPos, *pSectNd ); /*N*/ /*N*/ pSectNd-GetSection() = rSection; /*N*/ SwSectionFmt* pSectFmt = pSectNd-GetSection().GetFmt(); @@ -778,7 +777,7 @@ namespace binfilter { /*N*/ pLast = aIter++; /*N*/ } /*N*/ } -/*N*/ SwDoc* pDoc = GetDoc(); +/*N*/ GetDoc(); /*N*/ /*N*/ SwSectionFmt* pFmt = pSection-GetFmt(); /*N*/ if( pFmt ) diff --git a/binfilter/bf_sw/source/core/docnode/sw_ndtbl.cxx b/binfilter/bf_sw/source/core/docnode/sw_ndtbl.cxx index 62293df..4a0616b 100644 --- a/binfilter/bf_sw/source/core/docnode/sw_ndtbl.cxx +++ b/binfilter/bf_sw/source/core/docnode/sw_ndtbl.cxx @@ -227,7 +227,6 @@ static bool lcl_IsItemSet(const SwCntntNode rNode, USHORT which) SwStartNode* pSttNd = new SwStartNode( aEndIdx, ND_STARTNODE, SwTableBoxStartNode ); pSttNd-pStartOfSection = pTblNd; -SwEndNode* pEndNd = new SwEndNode( aEndIdx, *pSttNd ); pPrvBox = new SwTableBox( pBoxFmt, *pSttNd, pLine ); diff --git a/binfilter/bf_sw/source/core/docnode/sw_node.cxx b/binfilter/bf_sw/source/core/docnode/sw_node.cxx index b25a262..531f27a 100644 --- a/binfilter/bf_sw/source/core/docnode/sw_node.cxx +++ b/binfilter/bf_sw/source/core/docnode/sw_node.cxx @@ -1144,7 +1144,7 @@ using namespace ::com::sun::star::i18n; // in pIdx kann die 2. Position returnt werden. /*N*/ int SwCntntNode::CanJoinPrev( SwNodeIndex* pIdx ) const /*N*/ { -/*N*/ const SwNodes rNds = GetNodes(); +/*N*/ GetNodes(); /*N*/ BYTE nNdType = GetNodeType(); /*N*/ SwNodeIndex aIdx( *this, -1 ); /*N*/ diff --git a/binfilter/bf_sw/source/core/docnode/sw_section.cxx b/binfilter/bf_sw/source/core/docnode/sw_section.cxx index 30052bf..26b8d11 100644 --- a/binfilter/bf_sw/source/core/docnode/sw_section.cxx +++ b/binfilter/bf_sw/source/core/docnode/sw_section.cxx @@ -115,7 +115,7 @@ namespace binfilter { /*N*/ SwSectionPtr pParentSect = GetParent(); /*N*/ if( pParentSect ) /*N*/ { -/*N*/ bool bPHFlag = pParentSect-IsHiddenFlag(); +/*N*/ pParentSect-IsHiddenFlag(); /*N*/ if( pParentSect-IsHiddenFlag() ) /*?*/ SetHidden( TRUE ); /*N*/ @@ -1132,7 +1132,7 @@ void SwSectionFmt::MakeFrms() -/*N*/ BOOL SwIntrnlSectRefLink::IsInRange( ULONG nSttNd, ULONG nEndNd, xub_StrLen nStt, xub_StrLen /*nEnd */) const +/*N*/ BOOL SwIntrnlSectRefLink::IsInRange( ULONG nSttNd, ULONG nEndNd, xub_StrLen /*nStt*/, xub_StrLen /*nEnd */) const /*N*/ { /*N*/ SwStartNode* pSttNd = rSectFmt.GetSectionNode( FALSE ); /*N*/ return pSttNd diff --git a/binfilter/bf_sw/source/core/docnode/sw_swbaslnk.cxx b/binfilter/bf_sw/source/core/docnode/sw_swbaslnk.cxx index 920f809..75f098d 100644 --- a/binfilter/bf_sw/source/core/docnode/sw_swbaslnk.cxx +++ b/binfilter/bf_sw/source/core/docnode/sw_swbaslnk.cxx @@ -368,7 +368,7 @@ namespace binfilter { /*?*/ 0 != (pANd = pDoc-GetNodes()[pAPos-nNode]) /*?*/ 0 != (pTblNd = pANd-FindTableNode()) ) /*?*/ { -/*?*/ BOOL bLastGrf = !pTblNd-GetTable().DecGrfsThatResize(); +/*?*/ pTblNd-GetTable().DecGrfsThatResize(); /*?*/ SwHTMLTableLayout *pLayout = /*?*/ pTblNd-GetTable().GetHTMLTableLayout(); /*?*/ if( pLayout ) -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 06/16] warning fix unused var in binfilter bf_sw draw
regards From eac219396edebdf58deba912b02edac9a7999554 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Sat, 4 Dec 2010 15:30:11 +0100 Subject: [PATCH 06/16] warning fix unused var in binfilter bf_sw draw --- binfilter/bf_sw/source/core/draw/sw_dcontact.cxx | 75 +++--- 1 files changed, 9 insertions(+), 66 deletions(-) diff --git a/binfilter/bf_sw/source/core/draw/sw_dcontact.cxx b/binfilter/bf_sw/source/core/draw/sw_dcontact.cxx index 67d2f4a..18b3149 100644 --- a/binfilter/bf_sw/source/core/draw/sw_dcontact.cxx +++ b/binfilter/bf_sw/source/core/draw/sw_dcontact.cxx @@ -221,7 +221,7 @@ namespace binfilter { |* |*/ -/*N*/ SwFlyDrawContact::SwFlyDrawContact( SwFlyFrmFmt *pToRegisterIn, SdrModel *pMod ) : +/*N*/ SwFlyDrawContact::SwFlyDrawContact( SwFlyFrmFmt *pToRegisterIn, SdrModel* /*pMod*/ ) : /*N*/ SwContact( pToRegisterIn ) /*N*/ { /*N*/ SetMaster( new SwFlyDrawObj() ); @@ -266,7 +266,7 @@ namespace binfilter { |* |*/ -/*N*/ void SwFlyDrawContact::Modify( SfxPoolItem *pOld, SfxPoolItem *pNew ) +/*N*/ void SwFlyDrawContact::Modify( SfxPoolItem* /*pOld*/, SfxPoolItem* /*pNew*/ ) /*N*/ { /*N*/ } @@ -628,7 +628,7 @@ namespace binfilter { |* |*/ -/*N*/ void SwDrawContact::Modify( SfxPoolItem *pOld, SfxPoolItem *pNew ) +/*N*/ void SwDrawContact::Modify( SfxPoolItem* /*pOld*/, SfxPoolItem* pNew ) /*N*/ { /*N*/ //Es kommen immer Sets herein. /*N*/ //MA 03. Dec. 95: Falsch es kommen nicht immer Sets herein @@ -984,63 +984,6 @@ void SwDrawContact::ConnectToLayout( const SwFmtAnchor* pAnch ) } } break; -/* -case FLY_AT_FLY: -{ -if( pAnch-GetCntntAnchor() ) // LAYER_IMPL -{ -SwFrm *pAnchor = 0; -//Erst einmal ueber den Inhalt suchen, weil konstant schnell. Kann -//Bei verketteten Rahmen aber auch schief gehen, weil dann evtl. -//niemals ein Frame zu dem Inhalt existiert. Dann muss leider noch -//die Suche vom StartNode zum FrameFormat sein. -SwNodeIndex aIdx( pAnch-GetCntntAnchor()-nNode ); -SwCntntNode *pCNd = pFmt-GetDoc()-GetNodes().GoNext( aIdx ); -if ( pCNd 0 != (pAnchor = pCNd-GetFrm( 0, 0, FALSE ) ) ) -pAnchor = pAnchor-FindFlyFrm(); -else -{ -const SwNodeIndex rIdx = pAnch-GetCntntAnchor()-nNode; -SwSpzFrmFmts rFmts = *pFmt-GetDoc()-GetSpzFrmFmts(); -for( USHORT i = 0; i rFmts.Count(); ++i ) -{ -SwFrmFmt *pFmt = rFmts[i]; -SwFlyFrmFmt* pFlyFmt; -if( 0 != (pFlyFmt = PTR_CAST( SwFlyFrmFmt, pFmt )) -pFlyFmt-GetCntnt().GetCntntIdx() //#57390#, Reader -rIdx == *pFlyFmt-GetCntnt().GetCntntIdx() ) -{ -pAnchor = pFlyFmt-GetFrm( 0, FALSE ); -break; -} -} -} -if ( pAnchor ) //Kann sein, dass der Anker noch nicht existiert -{ -pAnchor-FindFlyFrm()-AppendDrawObj( this ); -bSetAnchorPos = false; -} -} -} -break; -*/ -/* -case FLY_IN_CNTNT: -{ -ClrContourCache( GetMaster() ); -SwCntntNode *pNode = GetFmt()-GetDoc()- -GetNodes()[pAnch-GetCntntAnchor()-nNode]-GetCntntNode(); -SwCntntFrm *pCntnt = pNode-GetFrm( 0, 0, FALSE ); -if ( pCntnt ) -{ -//Kann sein, dass der Anker noch nicht existiert -pCntnt-AppendDrawObj( this ); -pCntnt-InvalidatePrt(); -} -bSetAnchorPos = false; -} -break; -*/ #ifdef DBG_UTIL default: ASSERT( FALSE, Unknown Anchor. ); #endif @@ -1195,7 +1138,7 @@ const Point SwDrawVirtObj::GetOffset() const return maOffset; } -void SwDrawVirtObj::operator=( const SdrObject rObj ) +void SwDrawVirtObj::operator=( const SdrObject /*rObj*/ ) { DBG_BF_ASSERT(0, STRIP);//STRIP001 } @@ -1334,7 +1277,7 @@ void SwDrawVirtObj::RecalcBoundRect() bool SwDrawVirtObj::Paint(ExtOutputDevice rOut, const SdrPaintInfoRec rInfoRec) const { -bool bRet; +bool bRet = FALSE; Point
[Libreoffice] [PATCH 07/16] fix warning unused var in binfilter bf_sw fields
regards From 0049d6aa3dd25887c742b51a764776103e67daf8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Sat, 4 Dec 2010 15:44:52 +0100 Subject: [PATCH 07/16] fix warning unused var in binfilter bf_sw fields still only fixes, no optimization has been done. On purpose, avoid introducing new bugs... --- binfilter/bf_sw/source/core/fields/sw_authfld.cxx |2 +- binfilter/bf_sw/source/core/fields/sw_dbfld.cxx |2 +- binfilter/bf_sw/source/core/fields/sw_docufld.cxx |4 ++-- binfilter/bf_sw/source/core/fields/sw_fldbas.cxx |6 +++--- binfilter/bf_sw/source/core/fields/sw_usrfld.cxx |2 +- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/binfilter/bf_sw/source/core/fields/sw_authfld.cxx b/binfilter/bf_sw/source/core/fields/sw_authfld.cxx index 4a1bf01..289ca69 100644 --- a/binfilter/bf_sw/source/core/fields/sw_authfld.cxx +++ b/binfilter/bf_sw/source/core/fields/sw_authfld.cxx @@ -402,7 +402,7 @@ USHORT SwAuthorityFieldType::GetSequencePos(long nHandle) //body the directly available text node will be used if(!pTxtNode) pTxtNode = rFldTxtNode; -ULONG nPos = pTxtNode-GetIndex(); +pTxtNode-GetIndex(); if( pTxtNode-GetTxt().Len() pTxtNode-GetFrm() pTxtNode-GetNodes().IsDocNodes() ) { diff --git a/binfilter/bf_sw/source/core/fields/sw_dbfld.cxx b/binfilter/bf_sw/source/core/fields/sw_dbfld.cxx index 435500c..62950a9 100644 --- a/binfilter/bf_sw/source/core/fields/sw_dbfld.cxx +++ b/binfilter/bf_sw/source/core/fields/sw_dbfld.cxx @@ -573,7 +573,7 @@ BOOL SwDBNameInfField::PutValue( const ::com::sun::star::uno::Any rAny, BYTE nM /*N*/ SwDBNextSetField::SwDBNextSetField(SwDBNextSetFieldType* pTyp, /*N*/ const String rCond, -/*N*/ const String rDummy, +/*N*/ const String /*rDummy*/ , /*N*/ const SwDBData rDBData) : /*N*/ SwDBNameInfField(pTyp, rDBData), aCond(rCond), bCondValid(TRUE) /*N*/ {} diff --git a/binfilter/bf_sw/source/core/fields/sw_docufld.cxx b/binfilter/bf_sw/source/core/fields/sw_docufld.cxx index 0318cae..e2f0090 100644 --- a/binfilter/bf_sw/source/core/fields/sw_docufld.cxx +++ b/binfilter/bf_sw/source/core/fields/sw_docufld.cxx @@ -1254,7 +1254,7 @@ BOOL SwDocInfoField::PutValue( const uno::Any rAny, BYTE nMId ) /*N*/ /*N*/ if( TYP_CONDTXTFLD == nSubType ) /*N*/ { -/*N*/ SwNewDBMgr* pMgr = pDoc-GetNewDBMgr(); +/*N*/ pDoc-GetNewDBMgr(); /*N*/ /*N*/ bValid = sal_False; /*N*/ String sTmpName; @@ -1686,7 +1686,7 @@ BOOL SwPostItField::PutValue( const uno::Any rAny, BYTE nMId ) /* --- ---*/ -/*N*/ String SwExtUserFieldType::Expand(sal_uInt16 nSub, sal_uInt32 nFormat) const +/*N*/ String SwExtUserFieldType::Expand(sal_uInt16 nSub, sal_uInt32 /*nFormat*/) const /*N*/ { /*N*/ SvxAddressItem aAdr; /*N*/ String aRet( aEmptyStr ); diff --git a/binfilter/bf_sw/source/core/fields/sw_fldbas.cxx b/binfilter/bf_sw/source/core/fields/sw_fldbas.cxx index 5bc383c..96fda38 100644 --- a/binfilter/bf_sw/source/core/fields/sw_fldbas.cxx +++ b/binfilter/bf_sw/source/core/fields/sw_fldbas.cxx @@ -203,10 +203,10 @@ using namespace ::com::sun::star; /*N*/ return GetPar2(); /*N*/ } -void SwField::SetPar1(const String rStr) +void SwField::SetPar1(const String /*rStr*/) {} -void SwField::SetPar2(const String rStr) +void SwField::SetPar2(const String /*rStr*/) {} /*N*/ USHORT SwField::GetSubType() const @@ -215,7 +215,7 @@ void SwField::SetPar2(const String rStr) /*N*/ return 0; /*N*/ } -void SwField::SetSubType(USHORT nType) +void SwField::SetSubType(USHORT /*nType*/) { // ASSERT(0, Sorry Not implemented); } diff --git a/binfilter/bf_sw/source/core/fields/sw_usrfld.cxx b/binfilter/bf_sw/source/core/fields/sw_usrfld.cxx index f7862a8..8198a19 100644 --- a/binfilter/bf_sw/source/core/fields/sw_usrfld.cxx +++ b/binfilter/bf_sw/source/core/fields/sw_usrfld.cxx @@ -298,7 +298,7 @@ void SwUserField::SetPar2(const String rStr) /*N*/ if( GetDoc()-GetDrawModel() GetDepends() ) /*?*/ {DBG_BF_ASSERT(0, STRIP); }//STRIP001 ((SwDPage*)GetDoc()-GetDrawModel()-GetPage( 0 ))- /*N*/ -/*N*/ sal_Bool bModified = GetDoc()-IsModified(); +/*N*/ GetDoc()-IsModified(); /*N*/ GetDoc()-SetModified(); /*N*/ } /*N*/ } -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 10/16] fix warning unused var in binfilter bf_sw sw3io
regards From 18b052aa37f4adb95f3250de4967b739bd14be11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Sat, 4 Dec 2010 20:07:52 +0100 Subject: [PATCH 10/16] fix warning unused var in binfilter bf_sw sw3io --- binfilter/bf_sw/source/core/sw3io/sw_sw3field.cxx |2 +- binfilter/bf_sw/source/core/sw3io/sw_sw3imp.cxx |3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/binfilter/bf_sw/source/core/sw3io/sw_sw3field.cxx b/binfilter/bf_sw/source/core/sw3io/sw_sw3field.cxx index e014201..fb043ad 100644 --- a/binfilter/bf_sw/source/core/sw3io/sw_sw3field.cxx +++ b/binfilter/bf_sw/source/core/sw3io/sw_sw3field.cxx @@ -2303,7 +2303,7 @@ SwAuthorityFieldType* lcl_sw3io_InAuthorityFieldType( Sw3IoImp rIo ) ASSERT( !rIo.IsSw31Export(), Wer will denn da ein Script-Feld exportieren ); -BYTE cFlags = ((SwScriptField*)pFld)-IsCodeURL() ? 0x01 : 0x00; +((SwScriptField*)pFld)-IsCodeURL() ? 0x01 : 0x00; String aCode; if( ((SwScriptField*)pFld)-IsCodeURL() ) diff --git a/binfilter/bf_sw/source/core/sw3io/sw_sw3imp.cxx b/binfilter/bf_sw/source/core/sw3io/sw_sw3imp.cxx index 0bed171..d1cb2dc 100644 --- a/binfilter/bf_sw/source/core/sw3io/sw_sw3imp.cxx +++ b/binfilter/bf_sw/source/core/sw3io/sw_sw3imp.cxx @@ -424,7 +424,7 @@ public: /*N*/ { /*N*/ if( pDoc-GetDrawModel() ) /*N*/ { -/*N*/ SdrPage *pPage = pDoc-GetDrawModel()-GetPage( 0 ); +/*N*/ pDoc-GetDrawModel()-GetPage( 0 ); /*N*/ SwHiddenDrawObjList_Impl::const_iterator aIter = pHiddenDrawObjs-begin(); /*N*/ while( aIter != pHiddenDrawObjs-end() ) /*N*/ { @@ -1747,7 +1747,6 @@ const int RES_POOLCOLL_HTML_DT_40 = 0x3007; /*N*/ // Autoformate in dieser Liste muessen mit einer /*N*/ // Extension versehen werden! /*N*/ sal_uInt16 nFmtId = 0; -/*N*/ const String rName = rFmt.GetName(); /*N*/ // TODO: unicode: correct? /*N*/ if( rFmt.IsAuto() ) // Autoformat /*N*/ nFmtId = Count()+1; //++nId; -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 11/16] fix warning unused var in binfilter bf_sw swg
regards From c8861cfc5de23428356c1a5cf6aaed6d2a0eced3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Sat, 4 Dec 2010 20:13:44 +0100 Subject: [PATCH 11/16] fix warning unused var in binfilter bf_sw swg --- binfilter/bf_sw/source/core/swg/sw_rdflds.cxx |2 +- binfilter/bf_sw/source/core/swg/sw_rdhnt.cxx |4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/binfilter/bf_sw/source/core/swg/sw_rdflds.cxx b/binfilter/bf_sw/source/core/swg/sw_rdflds.cxx index 4db68bb..fc13bd3 100644 --- a/binfilter/bf_sw/source/core/swg/sw_rdflds.cxx +++ b/binfilter/bf_sw/source/core/swg/sw_rdflds.cxx @@ -541,7 +541,7 @@ static SwField* In_SwDocInfoField( SwSwgReader rPar, SwDocInfoFieldType* pType, return new SwDocInfoField( pType, (USHORT)nType | nSubType ); } -static SwField* In_SwTemplNameField( SwSwgReader rPar, SwTemplNameFieldType* pType ) +static SwField* In_SwTemplNameField( SwSwgReader /*rPar*/, SwTemplNameFieldType* pType ) { return new SwTemplNameField( pType, nNewFldFmt ); } diff --git a/binfilter/bf_sw/source/core/swg/sw_rdhnt.cxx b/binfilter/bf_sw/source/core/swg/sw_rdhnt.cxx index e3650e6..27f4857 100644 --- a/binfilter/bf_sw/source/core/swg/sw_rdhnt.cxx +++ b/binfilter/bf_sw/source/core/swg/sw_rdhnt.cxx @@ -340,7 +340,7 @@ static USHORT InSWG_SwNoHyphenHere } static USHORT InSWG_SwSoftHyphen -( SwSwgReader rPar, SfxItemSet* pSet, SwTxtNode* pNd, xub_StrLen nBgn, xub_StrLen nEnd ) +( SwSwgReader /*rPar*/, SfxItemSet* pSet, SwTxtNode* pNd, xub_StrLen nBgn, xub_StrLen /*nEnd*/ ) { if( !pSet ) pNd-Insert( CHAR_SOFTHYPHEN, SwIndex( pNd, nBgn )); @@ -348,7 +348,7 @@ static USHORT InSWG_SwSoftHyphen } static USHORT InSWG_SwHardBlank -( SwSwgReader rPar, SfxItemSet* pSet, SwTxtNode* pNd, xub_StrLen nBgn, xub_StrLen nEnd ) +( SwSwgReader /*rPar*/, SfxItemSet* pSet, SwTxtNode* pNd, xub_StrLen nBgn, xub_StrLen /*nEnd*/ ) { if( !pSet ) pNd-Insert( CHAR_HARDBLANK, SwIndex( pNd, nBgn )); -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH 12/16] fix warning unused var binfilter bf_sw text
regards From 22f6a25fcbba5eb41b73436f36a9542b2f898ef4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Sat, 4 Dec 2010 20:38:53 +0100 Subject: [PATCH 12/16] fix warning unused var binfilter bf_sw text --- binfilter/bf_sw/source/core/text/sw_atrstck.cxx |5 ++--- binfilter/bf_sw/source/core/text/sw_frmform.cxx |6 +- binfilter/bf_sw/source/core/text/sw_itrform2.cxx |4 ++-- binfilter/bf_sw/source/core/text/sw_itrtxt.cxx |4 binfilter/bf_sw/source/core/text/sw_porexp.cxx |2 +- binfilter/bf_sw/source/core/text/sw_porfld.cxx |5 ++--- binfilter/bf_sw/source/core/text/sw_porlin.cxx |6 +++--- binfilter/bf_sw/source/core/text/sw_porrst.cxx |6 +++--- binfilter/bf_sw/source/core/text/sw_portxt.cxx |2 +- binfilter/bf_sw/source/core/text/sw_txtfld.cxx |2 +- binfilter/bf_sw/source/core/text/sw_txtfly.cxx |2 +- binfilter/bf_sw/source/core/text/sw_txtftn.cxx | 15 +++ binfilter/bf_sw/source/core/text/sw_txthyph.cxx |2 +- 13 files changed, 25 insertions(+), 36 deletions(-) diff --git a/binfilter/bf_sw/source/core/text/sw_atrstck.cxx b/binfilter/bf_sw/source/core/text/sw_atrstck.cxx index 91eeaec..4c678ac 100644 --- a/binfilter/bf_sw/source/core/text/sw_atrstck.cxx +++ b/binfilter/bf_sw/source/core/text/sw_atrstck.cxx @@ -376,7 +376,7 @@ const BYTE StackPos[ RES_TXTATR_WITHEND_END - RES_CHRATR_BEGIN + 1 ] = { * SwAttrHandler::Push() */ -/*M*/ sal_Bool SwAttrHandler::Push( const SwTxtAttr rAttr, const SfxPoolItem rItem, SwFont rFnt ) +/*M*/ sal_Bool SwAttrHandler::Push( const SwTxtAttr rAttr, const SfxPoolItem rItem, SwFont /*rFnt*/ ) /*M*/ { /*M*/ ASSERT( rItem.Which() RES_TXTATR_WITHEND_END || /*M*/ RES_UNKNOWNATR_CONTAINER == rItem.Which() , @@ -692,12 +692,11 @@ const BYTE StackPos[ RES_TXTATR_WITHEND_END - RES_CHRATR_BEGIN + 1 ] = { /*M*/ break; /*M*/ /*M*/ USHORT nRotateStack = StackPos[ RES_CHRATR_ROTATE ]; -/*M*/ const SfxPoolItem* pRotateItem = 0; /*M*/ const SwTxtAttr* pRotateAttr = aAttrStack[ nRotateStack ].Top(); /*M*/ /*M*/ if ( pRotateAttr ) /*M*/ { -/*?*/DBG_BF_ASSERT(0, STRIP); //STRIP001 pRotateItem = lcl_GetItem( *pRotateAttr, RES_CHRATR_ROTATE ); +/*?*/DBG_BF_ASSERT(0, STRIP); /*M*/ } /*M*/ else /*M*/ rFnt.SetVertical( diff --git a/binfilter/bf_sw/source/core/text/sw_frmform.cxx b/binfilter/bf_sw/source/core/text/sw_frmform.cxx index a373014..afa7067 100644 --- a/binfilter/bf_sw/source/core/text/sw_frmform.cxx +++ b/binfilter/bf_sw/source/core/text/sw_frmform.cxx @@ -606,8 +606,6 @@ MSHORT FormatLevel::nLevel = 0; /*?*/ const SwpHints *pHints = pFoll-GetTxtNode()-GetpSwpHints(); /*?*/ if( pHints ) /*?*/ { -/*?*/ SwFtnBossFrm *pFtnBoss = 0; -/*?*/ SwFtnBossFrm *pEndBoss = 0; /*?*/ for( MSHORT i = 0; i pHints-Count(); ++i ) /*?*/ { /*?*/ const SwTxtAttr *pHt = (*pHints)[i]; @@ -662,8 +660,6 @@ MSHORT FormatLevel::nLevel = 0; /*?*/ const SwpHints *pHints = GetTxtNode()-GetpSwpHints(); /*?*/ if( pHints ) /*?*/ { -/*?*/ SwFtnBossFrm *pFtnBoss = 0; -/*?*/ SwFtnBossFrm *pEndBoss = 0; /*?*/ for( MSHORT i = 0; i pHints-Count(); ++i ) /*?*/ { /*?*/ const SwTxtAttr *pHt = (*pHints)[i]; @@ -991,7 +987,7 @@ MSHORT FormatLevel::nLevel = 0; /*N*/ { // Wenn wir Zeilen abgeben, darf kein Join auf den Folows gerufen werden, /*N*/ // im Gegenteil, es muss ggf. sogar ein Follow erzeugt werden. /*N*/ // Dies muss auch geschehen, wenn die Textmasse komplett im Master -/*N*/ // bleibt, denn es könnte ja ein harter Zeilenumbruch noch eine weitere +/*N*/ // bleibt, denn es k�nnte ja ein harter Zeilenumbruch noch eine weitere /*N*/ // Zeile (ohne Textmassse) notwendig machen! /*N*/ nEnd = rLine.GetEnd(); /*N*/ if( GetFollow() ) diff --git a/binfilter/bf_sw/source/core/text/sw_itrform2.cxx b/binfilter/bf_sw/source/core/text/sw_itrform2.cxx index 2a974cc..9465c2e 100644 --- a/binfilter/bf_sw/source/core/text/sw_itrform2.cxx +++ b/binfilter/bf_sw/source/core/text/sw_itrform2.cxx @@ -1445,7 +1445,7 @@ extern sal_Bool IsUnderlineBreak( const SwLinePortion rPor, const SwFont rFnt /*M*/ xub_StrLen nNewStart = nStart + pCurr-GetLen(); /*M*/ /*M*/ // adjust text if kana compression is enabled -/*M*/ const SwScriptInfo rSI = GetInfo().GetParaPortion()-GetScriptInfo(); +/*M*/ GetInfo().GetParaPortion()-GetScriptInfo(); /*M*/ /*M*/ if ( GetInfo().CompressLine() ) /*M*/ { @@ -1535,7 +1535,7 @@ extern sal_Bool IsUnderlineBreak( const SwLinePortion rPor, const SwFont rFnt /*N*/ /*N*/ // Das Dummyflag besitzen Zeilen, die nur Flyportions enthalten, diese /*N*/ // sollten kein Register etc. beachten.
[Libreoffice] [PATCH 15/16] fix warning unused var in binfilter - bf_sw unocore
regards From 151194c8a68754f9521bd485a9124f6e08f36239 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Sat, 4 Dec 2010 21:58:35 +0100 Subject: [PATCH 15/16] fix warning unused var in binfilter - bf_sw unocore trying to stay on the safe side, means not always removing the function call that initialized the parameter. So if this function call changed the parameter, no issue. --- .../bf_sw/source/core/unocore/sw_unocrsrhelper.cxx |2 -- binfilter/bf_sw/source/core/unocore/sw_unodraw.cxx |3 --- .../bf_sw/source/core/unocore/sw_unoframe.cxx |6 ++ binfilter/bf_sw/source/core/unocore/sw_unoftn.cxx |1 - binfilter/bf_sw/source/core/unocore/sw_unoidx.cxx |7 +++ binfilter/bf_sw/source/core/unocore/sw_unoobj.cxx |2 +- binfilter/bf_sw/source/core/unocore/sw_unoobj2.cxx |1 - .../bf_sw/source/core/unocore/sw_unoparagraph.cxx |4 ++-- binfilter/bf_sw/source/core/unocore/sw_unoport.cxx |2 +- .../bf_sw/source/core/unocore/sw_unoportenum.cxx |5 ++--- binfilter/bf_sw/source/core/unocore/sw_unosect.cxx |3 --- binfilter/bf_sw/source/core/unocore/sw_unosett.cxx |4 +--- .../bf_sw/source/core/unocore/sw_unostyle.cxx | 10 -- binfilter/bf_sw/source/core/unocore/sw_unotbl.cxx | 11 --- 14 files changed, 20 insertions(+), 41 deletions(-) diff --git a/binfilter/bf_sw/source/core/unocore/sw_unocrsrhelper.cxx b/binfilter/bf_sw/source/core/unocore/sw_unocrsrhelper.cxx index 2f431f2..2969570 100644 --- a/binfilter/bf_sw/source/core/unocore/sw_unocrsrhelper.cxx +++ b/binfilter/bf_sw/source/core/unocore/sw_unocrsrhelper.cxx @@ -295,7 +295,6 @@ sal_Bool getCrsrPropertyValue(const SfxItemPropertyMap* pMap { const SwTableNode* pTblNode = pSttNode-FindTableNode(); SwFrmFmt* pTableFmt = (SwFrmFmt*)pTblNode-GetTable().GetFrmFmt(); -SwTable rTable = ((SwTableNode*)pSttNode)-GetTable(); if(FN_UNO_TEXT_TABLE == pMap-nWID) { Reference XTextTable xTable = SwXTextTables::GetObject(*pTableFmt); @@ -402,7 +401,6 @@ sal_Bool getCrsrPropertyValue(const SfxItemPropertyMap* pMap nPaMEnd = nTmp; } Sequence ::rtl::OUString aCharStyles; -USHORT nCharStylesFound = 0; SwpHints* pHints = pTxtNode-GetpSwpHints(); for(USHORT nAttr = 0; nAttr pHints-GetStartCount(); nAttr++ ) { diff --git a/binfilter/bf_sw/source/core/unocore/sw_unodraw.cxx b/binfilter/bf_sw/source/core/unocore/sw_unodraw.cxx index 37cb25e..48fcfa9 100644 --- a/binfilter/bf_sw/source/core/unocore/sw_unodraw.cxx +++ b/binfilter/bf_sw/source/core/unocore/sw_unodraw.cxx @@ -1541,7 +1541,6 @@ void SwXGroupShape::add( const Reference XShape xShape ) throw (RuntimeExcep SwFrmFmt* pFmt = GetFrmFmt(); if(pSvxShape pFmt) { -sal_Bool bOk = FALSE; ReferenceXShapes xShapes; if( xShapeAgg.is() ) { @@ -1594,7 +1593,6 @@ void SwXGroupShape::add( const Reference XShape xShape ) throw (RuntimeExcep void SwXGroupShape::remove( const Reference XShape xShape ) throw (RuntimeException) { SolarMutexGuard aGuard; -sal_Bool bOk = FALSE; ReferenceXShapes xShapes; if( xShapeAgg.is() ) { @@ -1610,7 +1608,6 @@ void SwXGroupShape::remove( const Reference XShape xShape ) throw (RuntimeEx sal_Int32 SwXGroupShape::getCount(void) throw( uno::RuntimeException ) { SolarMutexGuard aGuard; -sal_Int32 nRet = 0; ReferenceXIndexAccess xAcc; if( xShapeAgg.is() ) { diff --git a/binfilter/bf_sw/source/core/unocore/sw_unoframe.cxx b/binfilter/bf_sw/source/core/unocore/sw_unoframe.cxx index 4d1fdbb..b8f2fc8 100644 --- a/binfilter/bf_sw/source/core/unocore/sw_unoframe.cxx +++ b/binfilter/bf_sw/source/core/unocore/sw_unoframe.cxx @@ -1570,7 +1570,7 @@ void SwXFrame::setPropertyToDefault( const OUString rPropertyName ) SwFrmFmt* pFmt = GetFrmFmt(); if(pFmt) { -const SwAttrSet rFmtSet = pFmt-GetAttrSet(); +pFmt-GetAttrSet(); const SfxItemPropertyMap* pCur = SfxItemPropertyMap::GetByName(_pMap, rPropertyName); if (!pCur) throw UnknownPropertyException(OUString ( RTL_CONSTASCII_USTRINGPARAM ( Unknown property: ) ) + rPropertyName, static_cast cppu::OWeakObject * ( this ) ); @@ -1910,7 +1910,6 @@ void SwXFrame::attachToRange(const uno::Reference XTextRange xTextRange) SvInPlaceObjectRef xIPObj; if( (*pCLSID) = aCLSID ) { -sal_Bool bInternal = sal_True; if( !aClassName.MakeId( aCLSID ) ) { IllegalArgumentException aExcept; @@ -2192,7 +2191,7 @@ uno::Reference XTextCursor SwXTextFrame::createTextCursor(void) throw( Runti SwXTextCursor*
[Libreoffice] [PATCH 16/16] removing code due to endless loop
regards From 6551d69a5fbc85f3af92cada84bf543a083d4453 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Sat, 4 Dec 2010 22:05:10 +0100 Subject: [PATCH 16/16] removing code due to endless loop these part of code have been removed. The While(true) loop means either that the if statement is never taken, or that the program hangs there. The second case is not safe, the first case means that this code is not needed. --- binfilter/bf_sw/source/core/txtnode/sw_thints.cxx | 23 - 1 files changed, 0 insertions(+), 23 deletions(-) diff --git a/binfilter/bf_sw/source/core/txtnode/sw_thints.cxx b/binfilter/bf_sw/source/core/txtnode/sw_thints.cxx index 06b91e2..1ad 100644 --- a/binfilter/bf_sw/source/core/txtnode/sw_thints.cxx +++ b/binfilter/bf_sw/source/core/txtnode/sw_thints.cxx @@ -923,16 +923,6 @@ using namespace ::com::sun::star::i18n; /*N*/ /*N*/ if( pNd == this ) /*N*/ { -/*?*/ if( aThisSet.Count() ) -/*?*/ { -/*?*/ SfxItemIter aIter( aThisSet ); -/*?*/ const SfxPoolItem* pItem = aIter.GetCurItem(); -/*?*/ while( TRUE ) -/*?*/ { -DBG_BF_ASSERT(0, STRIP); //STRIP001 /*?*/ if( lcl_IsNewAttrInSet( *pSwpHints, *pItem, GetTxt().Len() ) ) -/*?*/ } -/*?*/ } -/*N*/ /*N*/ } /*N*/ else /*N*/ { @@ -947,19 +937,6 @@ using namespace ::com::sun::star::i18n; /*N*/ { /*?*/ DBG_BF_ASSERT(0, STRIP); //STRIP001 SfxItemIter aIter( aThisSet ); /*N*/ } -/*N*/ -/*N*/ if( aNdSet.Count() ) -/*N*/ { -/*?*/ SfxItemIter aIter( aNdSet ); -/*?*/ const SfxPoolItem* pItem = aIter.GetCurItem(); -/*?*/ while( TRUE ) -/*?*/ { -DBG_BF_ASSERT(0, STRIP); //STRIP001 /*?*/ if( lcl_IsNewAttrInSet( *pNd-pSwpHints, *pItem, pNd-GetTxt().Len() ) ) -/*?*/ } -/*?*/ -/*?*/ SwFmtChg aTmp1( pNd-GetFmtColl() ); -/*?*/ pNd-SwModify::Modify( aTmp1, aTmp1 ); -/*N*/ } /*N*/ } /*N*/ /*N*/ if( pNd-pSwpHints-CanBeDeleted() ) -- 1.7.1 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] binfilter and features...
Hi, There is alright, a phonecon typically once a week or so. maybe we can put this topic on the agenda would be great and you could dial in if its at a suitable time. doing this during free time, I may really depend if the possibility arise or not. But basically, we could think of a kind of general rule according to the following points: Do we want to support the file format X ? if yes Is the product that produce this file format as default / main / native file format out of support ? if yes Is this product out of support since more than X (3??) years? if yes == LibO supports this file format as read only. In case of changes, the user has to choose another file format, supported for writing. Note: for me, for an average user, having to install a plug-in is not an option. At least as I see even in my west-european neighborhood, despite well educated (university-level!) people, but not computer freaks, using it as a mere tools. I always wonder as people are using computer in a way much more nearer of using hammers than cars Of course, if the product is still on support, this is another story, since there other criteria should determine if this is read or read-write. But this kind of rule could help to shrink down in a regular manner the LibO code, having a basis for suppressing some part of the code. I proposed 3 years, this in average, this is the renewal time for PC's. Actually, for basic users, this is somewhat longer (about 5 years), but as you have seen (or not) for docx-format, after 3 years of the introduction of the new format, people not able to read the new format are really in trouble. This also helps or forces the end-user to migrate to the new format / up to date format, without loosing access to its archive. This is a good help for LibO, I think, avoiding having X former file-format existing around. Other views, ideas? regards ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] fighting with debug macros...
Hello, still trying to learn a bit the code. Compiling without DEBUG on gives some new warnings:- ) This lead me to look at some code construct. Here is in pseudo-code a typical construct I am crossing: var y = ; var x = ; code if ( y MAXVALUE) { ASSERT(x, out of range); // only use of var x is here } // there is no else statement code Looking at easy hacks, I also saw that ASSERT is deprecated. I have looked at the OSL macros, but did not found an equivalent of ASSERT(condition, message) (defined in filters/binfilter/inc/bf_sw/errhdl.hxx But further, this is not very useful for the end-user, since LibO is shipped without debug-level on. (right? ) So I was thinking: * either a macro exists to do a hello user, I will crash. Thanks to send this report, that is added within the if statement. ?? * or to change the code to something like: var y = ...; #if OSL_DEBUG_LEVEL 0 var x = ...; /* if this is not possible to insert x below, and the initialization of x does not change any state */ #endif code #if OSL_DEBUG_LEVEL 0 if ( y MAXVALUE) { ASSERT(x, txt); // only use of var x is here } // there is no else statement #endif code to avoid shipping unneeded code to end-user. This will also make code execution more efficient, avoiding dummy branches. By the way: what is the right way to achieve the goal of the easy hack : align ASSERT ( friends) macro foo ? include /ure/sal/inc/osl/diagnose.h in file, and use only OSL_Debug macros loosing all messages? Is it possible to add an additional OSL_ASSERT(condition, message) macro? Or not wanted? Thanks for your inputs. regards ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] some hints needed for fdo 42286 in calc
hello, I am trying to debug fdo 42286 in calc. It has to do with autofilter, where some empty lines (rows) are shown despite the filter criteria that is set. (and a strange filter behaviour). As entry point, I found sc/.. tools/queryparam.cxx dbdata.cxx but it seems that there all is Ok. As I understand it, there the query is just prepared but I am not able to find the code where the actual calculation for displaying it is done. could someone hint me / give me a search criteria ? Just an additional remark: disassembling the bug's attached file, I see that the content.xml ends with some strange empty row definitions... But this still does not justify to appear witin the filter in my opinion. Or does this indicates the file is ill formatted ? (sorry, I do not know the oasis spec) table:table-row table:style-name=ro1 table:number-rows-repeated=1048532 table:table-cell table:number-columns-repeated=1024/ /table:table-row table:table-row table:style-name=ro1 table:visibility=filtertable:table-cell table:number-columns-repeated=1024/ /table:table-row table:table-row table:style-name=ro1 table:table-cell table:number-columns-repeated=1024/ /table:table-row table:table-row table:style-name=ro1 table:visibility=filtertable:table-cell table:number-columns-repeated=1024/ /table:table-row table:table-row table:style-name=ro1 table:table-cell table:number-columns-repeated=1024/ /table:table-row table:table-row table:style-name=ro1 table:visibility=filter table:number-rows-repeated=5 table:table-cell table:number-columns-repeated=1024/ /table:table-row etc all of this kind thanks for a hint regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] some hints needed for fdo 42286 in calc
hello, and query information. The query is executed in ScDBDocFunc::Query and related functions. thanks I will look there come back if needed P.S. Do you know if this is a regression against 3.3? Then it might be No 3.3 available to test (and a bit short of place on HD). But happens on LibreOffice 3.4.2 OOO340m1 (Build:1206) (OpenSuse 11.4 distribution) and on master, build by myself (also OpenSuse 3.4.2) regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] [PATCH] fdo 42286 in calc solved ?
Hello, Thanks for your hints. It took some times, but know I have clearly identified the problem , but I do not if my solution is right or could create more problems. In short, the problem is that GetAreadData is called each time the filter determines its values, instead of using the current area. This does not have influence, as long as your selection area does not end with empties rows or empties columns. But this behaviour produce a wrong result as soon as your filtered area ends with empties rows, and as special case, if you select all rows, since it decreases the area of 1 row if the last row is empty. Basically this happens with the call of function ExtendDataArea. This originates from documen3.cxx, function GetFilterEntries line 1390 (the call itself is at line 1398). (more details below, if needed) My solution: suppress this call... I have tested it and it seems to work. I did not managed to find a case where something is broken with the filter.. But it seems me too simple. Could you check this before I push it ? If Ok, would you like then to approve it cherry-pick it to 3.4.5 ? Thanks best regards Pierre-André ps: if what I did is right, I will then update the bug ticket --- What happens? As I understand after debugging and following the logic, each time the filter is activated (it is an auto-filter) it tries do determine the data range when it search for its value to show in the filter drop-down. For that it searches the biggest contiguous area of data, as when applying the filter without selection. Except the fact that here it goes wrong, since an area has already selected (either manually or stored as table:database-range ... tag. which contains and finish (important in this analysis) with several empty rows (columns would produce the same problem). And it tries to fit the Area with the GetAreaData algorithm, starting with a predefined area. The result: it does not extend it (next row is emtpy), but thinking he as extended the area of one row to far (this the last row int the area is empty), it reduce the selected area of one row. And this produce the strange comportment described. (more detailed analysis below). Each time the filter value is changed , the function ScTAble::GetAreaData (in sc/source/core/data/table1.cxx, line 740 in my check-out) is called. At the end of the called function, there is a check: if the last row is empty, then the Area is reduced by one, deacreasing its last row value by 1 (line 835/836) if (!bFound) --rEndRow; This is obviously wrong, especially if you select e.g the 3 first columns (completely) and then apply auto-filter. Since empty lines *are* part of the selection... and not only the last one is empty. So each time I change the filter value, I reduce by 1 the last row number... I see that the content.xml ends with some strange empty row It is ill-formatted by the user ;-) Cells in columns A:G down to the However, strange are the spurious entries with table:visibility=filter no, this is the result of this filter changes coupled with the order of ALL value filter or partial filters. This also creates a mess with the storage of table:database-range table:name=__Anonymous_Sheet_DB__0 reducing the area within the range, depending when you save your file... From 568c0635089964488a05043d7422eb40be15ccaf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Tue, 15 Nov 2011 20:55:53 +0100 Subject: [PATCH] fdo#42286 do not change selection area when determining filter values Just use the current area, does not redetermine it in order to find the list of values for drop-down of the filter. --- sc/source/core/data/documen3.cxx |1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/sc/source/core/data/documen3.cxx b/sc/source/core/data/documen3.cxx index 273af5f..14b0655 100644 --- a/sc/source/core/data/documen3.cxx +++ b/sc/source/core/data/documen3.cxx @@ -1395,7 +1395,6 @@ bool ScDocument::GetFilterEntries( ScDBData* pDBData = pDBCollection-GetDBAtCursor(nCol, nRow, nTab, false); //!?? if (pDBData) { -pDBData-ExtendDataArea(this); SCTAB nAreaTab; SCCOL nStartCol; SCROW nStartRow; -- 1.7.3.4 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [PATCH] fdo#42286, do not shrink the selected area
hello, here attached an new patch (hopefully wiser) to solve the mentioned bug. This ensure that the call to ExtendDataArea does as commented in the code sc/source/core/tool/dbdata.cxx : // Extend the DB area to include data rows immediately below. and does not shrink the original area... So having a smaller area after the function is clearly wrong. If you agree, I will push it to master. BUT this is a workaround, to compensate the not so correct behaviour of GetDataArea :-( I did this patch in order to bring the correction in time for 3.5.0 3.4.5, but I agree, that this is suppressing a symptom and not the root cause. About the root cause: I am still studing the code of the both mentioned functions and their integration with filters and filtered areas. Before touching it, I would like to define what should be the desired effect. Further some tests have shown me that the behaviour (regarding area) is not the same, depending if the filter is activated with Data-Filter-AutoFilter or Standard filter. I fear some parts will need to be quite overhauled. As said, won't be ready for 3.5, so first this short term solution. Thanks toa all for having helped me so far. Best regards Pierre-André 0001-fdo-42286-do-not-shrink-the-filtered-area-when-calli.patch Description: application/mbox ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] [PATCH] fdo#42286, do not shrink the selected area
Hi, BUT this is a workaround, to compensate the not so correct behaviour of GetDataArea :-( The behaviour in bINcludeOld = false seems me strange (ergh I think wrong but you told me to be cautious), since it removes from the side of the area that has not yet been extended above the last line / column, if empty. The implementation seems to me flawed, since it does it even if no extension has been possible (e.g rEndRow = MAXROW), and suppress just ONE line, if empty. What about the new last one ? if also empty, we are exactly in the same situation as before, just a bit smaller. Hence it seems me that the original programmer (12 years ago) just assumed that only the last line / column could be empty, not e.g. the last 4 rows. I wouldn't say it's wrong unless I checked the original intention behind that code when GetDataArea() is called with bIncludeOld=false, maybe it's just the call in ExtendDataArea() that should pass true instead? Done, you're right. Finally, changed the call of the flags and documented the flags' meaning. If you could cherry-pick 88611e702a18d2 for 3.4.5, would be nice. Many thanks desired effect. Further some tests have shown me that the behaviour (regarding area) is not the same, depending if the filter is activated with Data-Filter-AutoFilter or Standard filter. I fear some parts will need to be quite overhauled. And the difference exactly is ...? Visually: the standard filter adapts and shows the selected area at activation of the filter, the auto-filter does not reflect the fact that it will take into account a wider area. This area extension happens only when the drop-down button is activated and the list of possible value is calculated... and the area extended. More subtly, this leads to 2 different ranges stored within the file if you do select some area but not all data, activate standard filter , save or if you do exactly the same with same data / input except activating auto-filter instead of standard filter. Out of subject: from a user perspective, I am not convinced from te fact that the filter is allowed to change an area that has been user-defined. No problem to auto-extend an area if auto-determined. But if a user takes the time to do the area, this should be holly. But this point belongs to the user-interface list I guess... Best regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] final and override
Hello, However, given that override and final will only make it into GCC 4.7 (according to http://wiki.apache.org/stdcxx/C++0xCompilerSupport), it according to gcc.gnu.org too.. but since it seems that MSCV (according the same wiki) supports it / will support it, why not just wait a bit and then use it directly, setting a minimal compiler version ? This would allow a cleaner code, not having to take into account before implementation status. (would also be valid for other major features ) Most probably a too harsh approach ? regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] [PATCH] fdo#42286, do not shrink the selected area
Hi Eike Now you also changed bOnlyDown=false to bOnlyDown=true, which leads to not include newly appended columns of an area. half true: the condition is exactly that the newly appended column data touch by an angle the already defined area (like C3 to B2) and that all other cells below the area are empty. All columns right/left of the area are filtered. Why? very bad reason: I did not really intended to commit this change yet. I wanted to ask you about it. But it seems I was too deeply thinking about it, I oversee my mixing. F** less bad reason: If you activates the auto-filter, and append a column as mentioned above, you suddenly have columns filtered without seeing it, the drop-down at the top of the column not being present. I will change it (due to point 1), except you oppose :- ) Grounded speculation: if user adds a column or row immediately adjacent to a data area it is usually related to the already existing data and she wants that to be included, maybe even doesn't know that earlier the filter was setup using a selection. A good point. On the other hand,this makes impossible to filter in the middle of data. But this case is very special. Else, I have attached 3 patches for review touching this function: * the first one make the flag onlyDown working also for shrinking... No reason that you can just extend down, but shrink on all direction? This seems to be more coherent with the flag activation. * the second patch make the shrinking corresponding to the name of the function: GetDataArea: i.e. shrinks as long as the outer row/column is empty, and not just delete the last one since empty. * the 3d one: just minor clean up: variable scope reduction and better documentation. Thanks for all best regards Pierre-André From cfd04dda7e441ffa3dcc5a21b6b8f87cbfda05b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Tue, 29 Nov 2011 09:10:26 +0100 Subject: [PATCH 3/3] reduce scope of var and better comment of function GetDataArea --- sc/source/core/data/table1.cxx | 40 +--- 1 files changed, 21 insertions(+), 19 deletions(-) diff --git a/sc/source/core/data/table1.cxx b/sc/source/core/data/table1.cxx index ce2051b..5de641f 100644 --- a/sc/source/core/data/table1.cxx +++ b/sc/source/core/data/table1.cxx @@ -741,17 +741,19 @@ bool ScTable::GetDataStart( SCCOL rStartCol, SCROW rStartRow ) const void ScTable::GetDataArea( SCCOL rStartCol, SCROW rStartRow, SCCOL rEndCol, SCROW rEndRow, bool bIncludeOld, bool bOnlyDown ) const { -// bIncludeOld = true ensure that the returned area contains at least the initial area, -// independently of the case if this area has empty rows / columns at its borders -// bOnlyDown = true means extend the inputed area only down, i.e increase only rEndRow +// return the smallest area containing at least all contiguous cells having data. This area +// is a square containing also empty cells. It may shrink or extend the area given as input +// Flags as modifiers: +// +// bIncludeOld = true ensure that the returned area contains at least the initial area, +// independently of the emptniess of rows / columns (i.e. does not allow shrinking) +// bOnlyDown = true means extend / shrink the inputed area only down, i.e modifiy only rEndRow + bool bLeft = false; bool bRight = false; bool bTop = false; bool bBottom = false; -bool bChanged; -bool bFound; -SCCOL i; -SCROW nTest; +bool bChanged = false; do { @@ -782,12 +784,12 @@ void ScTable::GetDataArea( SCCOL rStartCol, SCROW rStartRow, SCCOL rEndCol, S if (rStartRow 0) { -nTest = rStartRow-1; -bFound = false; -for (i=rStartCol; i=rEndCol !bFound; i++) +SCROW nTest = rStartRow-1; +bool needExtend = false; +for ( SCCOL i = rStartCol; i=rEndCol !needExtend; i++) if (aCol[i].HasDataAt(nTest)) -bFound = true; -if (bFound) +needExtend = true; +if (needExtend) { --rStartRow; bChanged = true; @@ -798,12 +800,12 @@ void ScTable::GetDataArea( SCCOL rStartCol, SCROW rStartRow, SCCOL rEndCol, S if (rEndRow MAXROW) { -nTest = rEndRow+1; -bFound = false; -for (i=rStartCol; i=rEndCol !bFound; i++) +SCROW nTest = rEndRow+1; +bool needExtend = false; +for ( SCCOL i = rStartCol; i=rEndCol !needExtend; i++) if (aCol[i].HasDataAt(nTest)) -bFound = true; -if (bFound) +needExtend = true; +if (needExtend) {
Re: [Libreoffice] [PATCH] fdo#42286, do not shrink the selected area (2)
Hello, sorry, I was sure there was more about it...but too early this morning, I could not sort out all points. Now you also changed bOnlyDown=false to bOnlyDown=true, which leads to not include newly appended columns of an area. Why? by the way, this reflect the comment in void ScDBData::ExtendDataArea(ScDocument* pDoc) { // Extend the DB area to include data rows immediately below. which comment is from Kohei ( 9f9ff37f ) who toke this from a previous comment. Hence, the change would make the call be in line with the comment. This is the original reason why I started to play with it and changed it like this, since comment and implementation were not coherent. Regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] [PATCH] fdo#42286, do not shrink the selected area (2)
Hello, To give you a background, this extend range downward functionality was Thanks for your explanation. Following the remark of Eicke, I ended up with 3 possible patches :-/ which all have small differences in behaviour. I have a favorite, but do not want to choose alone. Please push the one you think is the best for the filter drop-down. The first one is my favorite: 0001-fdo42286-strict-use-of-GetDataArea-and-strict-extens.patch it extends the area down. It takes into account the cells strictly below the already selected area. It never shrinks / shortens the selected area. This is the one that implement in my opinion the best the behaviour of adding data below already active area. The second one: 0001-fdo42286-extend-down-but-also-shrink-if-cells-are-em.patch has the same logic, except it allows to shrink the area, if cells are emptied. This the filter is allowed to extend, it could be seen as logic that it is also allowed to shrink. The last one: 0001-fdo42286-extend-down-even-if-last-row-empty-but-a-co.patch extend down, but also if data is added to the first cell bellow. so if you have something like (o means empty cell, x cell with data), initial filter only on B2:D3 o oXXXo oXXXo X and add the last X below right, the the last line will be included in the area and shown with empty cells selection. I do not like this, since it suddenly take into account a column which was not part of the initial filtered area. Due to my job, I have not been very available last week, and it will be the same this week. (I will not be able to code / push until 9th). would be nice if this could be inserted before branching to 3.5.0 As prerequisite for working, the following commits are needed: 7359ad4fc772bc355905ef8b4a4a7b44dcfc1ebe 2e5023f974dd94dfeec0554ce07d0544f9ce7638 e42ee773ffc12e38d596ce2aa016f0849c4e5ac6 Regards Pierre-André 0001-fdo42286-strict-use-of-GetDataArea-and-strict-extens.patch Description: application/mbox 0001-fdo42286-extend-down-but-also-shrink-if-cells-are-em.patch Description: application/mbox 0001-fdo42286-extend-down-even-if-last-row-empty-but-a-co.patch Description: application/mbox ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] [PATCH] fdo#42286, do not shrink the selected area (2)
Hi Eicke, The second one: 0001-fdo42286-extend-down-but-also-shrink-if-cells-are-em.patch For consistency it makes sense to also shrink the area, as re-initializing the filter area with only one cell or one row selected . erroneously included. Please go ahead with this one. OK Please check that a defined data base range did not change behavior with your previous changes. I have look at the code where GetDataArea is called. The only places where a behaviour change could happen are in function GetDBData ( sc/source/ui/docshell/docsh5.cxx ) if bOnlyDown is true. In this case, the area will be shrink - if needed - only for the number of rows. Before, all 4 sides (top, right, left and bottom) could be shrink. But this change exists only if we shrink. For expanding, the behaviour was already ensured as described (bOnlyDown = true would have expanded only down, not the other directions). This now makes the behaviour symmetric between shrinking / expanding the area. Based on flags and description, the former behaviour was buggy, but maybe something has been build depending of it. Despite knowing what is changed, I was not able to produce a way of using it that seemed to be problematic. I see you have worked on this function, maybe something will strike you immediately :- ). So here the patch. If no one object, I will push it during my Christmas Holiday. Best regards Pierre-André From 994b2c2e5a760503f8e466ae8068cf1cc453a712 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Thu, 15 Dec 2011 19:29:17 +0100 Subject: [PATCH 1/2] fdo42286 better solution: extend and shrink end of row if needed --- sc/source/core/tool/dbdata.cxx |6 ++ 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/sc/source/core/tool/dbdata.cxx b/sc/source/core/tool/dbdata.cxx index 3d60554..3cc4146 100644 --- a/sc/source/core/tool/dbdata.cxx +++ b/sc/source/core/tool/dbdata.cxx @@ -544,10 +544,8 @@ void ScDBData::UpdateReference(ScDocument* pDoc, UpdateRefMode eUpdateRefMode, void ScDBData::ExtendDataArea(ScDocument* pDoc) { // Extend the DB area to include data rows immediately below. -SCCOL nCol1a = nStartCol, nCol2a = nEndCol; -SCROW nRow1a = nStartRow, nRow2a = nEndRow; -pDoc-GetDataArea(nTable, nCol1a, nRow1a, nCol2a, nRow2a, true, true); -nEndRow = nRow2a; +// or shrink it if all cells are empty +pDoc-GetDataArea(nTable, nStartCol, nStartRow, nEndCol, nEndRow, false, true); } namespace { -- 1.7.3.4 ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] bug 36874 (label printing) further improvement?
Hello, Just to mix in the middle: from this and a previous mail from you: It would be much better if the label-definitions contain all dimensions, i.e. yes My calculation is based on the assumption (presumption?) that the page containing the labels is symmetrical, i.e. rotating the page 180 degrees is not a problem, left margine equals right margin and top margin equals bottom margin. some labels paper that I bought last year (I guess of too bad quality) were not symmetric But anyway, the change is already very good. Thanks regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] making binfilter aka StarOffice FileFormat read-only
Hello, these days, I have tried (and not really with full success) to understand how binfilter works... My goal: since it is an old legacy format, make StarOffice formats read-only, and clean binfilter component of all code used for writing files. Reason: with read-only, you will still be able to read your old files / archive, but his will push the users to use a current / supported format in case of change. So a less heavy software, use of well-maintained (see minutes of tech steering call ... 2010.12.09) After some code reading here a resume of my understanding. Thanks for correcting, asking, challenging me. I hope I did not understand it too wrongly. An easy (and clean) possibility would be to change the filters defined in binfilter as read-only filters (using as filter flag SFX_FILTER_OPENREADONLY defined as 0x0001L) This will make the opening read-only. By this way, this is not possible any more to save using these file formats. (I have not yet found where this is set, but still searching) Currently, I have simulated it locally adding in libs-core/sfx2/source/bastyp/fltfnc.cxx: (almost at the end of the function SfxFilterContainer::ReadSingleFilter_Impl ) if (nFormatVersion SOFFICE_FILEFORMAT_60) { pFilter-nFormatType = ( nFlags | SFX_FILTER_OPENREADONLY); } this is not a nice hack, but it demonstrates me that it works / how it works. This shows me: a) it works. Yesss : -) b) there are functions defined in libs-core and binfilter (sfx2 of libs-core and sfx2 in binfilters) that are redundant. e.g SFX_FILTER_OPENREADONLY (and other constant values) are defined in both filters/binfilter/inc/bf_sfx2/docfilt.hxx libs-core/sfx2/inc/sfx2/docfilt.hxx c) it seems there are elements in the sfx2 of binfilter that are still called, generated, but have no impact on the running system. For exemple function SfxFilterContainer::ReadExternalFilters (in binfilter/bf_sfx2/source/bastyp/sfx2_fltfnc.cxx) is still called, produced me a lot of debug text, but the above mentionned code inserted at the same place (as in libs-core but within his function) did not produced any effect. So this function is still called, but its effects are not taken into account. d) So binfilter could be simplified if I take out all wrinting stuff, and not needed section of code still called... I noticed the following at SaveAs: all StarOffice format were still available, but were producing an error at saving, since they are now by me read-only... I did not find the place, but could someone hint me where this is? Actually, I think the list of format displayed at Save or SaveAs should contain only not read-only filters, something like this in pseudo-code: (if (filter.getFlags() SFX_FILTER_OPENREADONLY) != SFX_FILTER_OPENREADONLY) { display this filter in save / saveas dialog} (note: I also saw a function isReadOnly() or something like this that could be called on filter objects, returning true / false. Is probably even better...) I do not think there are currently READONLY filters, but basically, I think this is a bug not taking this flag into account. And so in one go all problem solved in switching the binfilter to READ-ONLY. If someone could help me for this part... Finaly, at saving, this work like this: (valid for StarOffice format... beware, other format, other paths) SfxObjectShell::PreDoSaveAs_Impl(param) in libs-core SfxObjectShell::SaveTo_Impl(param) for ExporTo in libs-core SfxObjectShell::PreDoSaveAs_Impl(param) SfxObjectShell::SaveTo_Impl(param) 2 in sfx2_objstor.cxx SfxObjectShell::SaveAsOwnFormat( param) in sfx2_objstor.cxx SfxObjectShell::SaveAs(param) in sfx2_objstor.cxx SfxObjectShell::SaveInfoAndConfig_Impl(param2) BasicManager::Store(param) BasicManager::Store(param2) BasicLibInfo::Store(param) StgWriter::Write (param) Sw3Writer::WriteStorage() Sw3IO::SaveAs Sw3IO::Save ExportTo is finished and has returned with the ExportTo function going magically to the binfilter module. I did not understood what I read there, with the uno part... Until (and with) the function BasicLibInfo::Store(param), this the common part of binfilter for all modules. Then it splits to writer, calc,... At opening with read-write filter, some of these write functions are called (for the lock file). With a read-only filter, this does not happens. At opening, there is also the dark magic call (:- ( through uno to go through the different filters one by one for generating them So how to go ahead? Here I am asking you: - is it OK to go ahead with this idea? - should I make a feature/StarOffice-read-only branch ? - could someone (help me) implement the sorting in order to ensure that read-only filters are not available for Save / Save As? Of course, if going ahead on this way, I will search the code in order to find the right place for activating the SFX_FILTER_OPENREADONLY flag as property for the filter, not using this hackhopefully Thanks for your feed-backs Regards Pierre-André
Re: [Libreoffice] starmath / cppunit breakage in master
Hi, Does setting #define MDDS_HASH_CONTAINER_STLPORT 1 before #include mdds/mixed_type_matrix.hpp help? I also saw someone having a similar issue in the same exact spot, which I haven't been able to reproduce. Maybe this is related. I had also a problem after having upgraded to mds 0.4.0 with an up to date (25.12.2010) git At the ende, I managed to compile making a hack to 0.4.0 (very dirty...). Since this part was outside of my understanding, I am not able to know if the error was from my side or not... and since you were on holliday I kept it if someone also run in trouble. Below more explanation. Since then, I did not recompile the whole stuff... take too long by me.:- ) regards I guess this is specific to system-mdds. Conceptually there should be no difference whether it's system or internal, since mdds is just a collection of header files with no libraries to build or link against. From the looks of the log file, it *may* have some issues with gcc 4.5.x's implementation of unordered_map, but I'm not sure 100%... I have tried make clean, make distclean I have used ./autogen.sh --with-num-cpus=2 --without-junit --disable-kde --enable-binfilter compiler: gcc version 4.5.0 20100604 [gcc-4_5-branch revision 160292] (SUSE Linux) I did not success to compile, until I changed: libo_dev/solver/330/unxlngi6.pro/inc/mdds/hash_container/map.hpp simulating having MDDS_HASH_CONTAINER_STLPORT defined: like this: #else // c++0x #include hash_map #define _mdds_unordered_map_type ::std::hash_map //#include unordered_map //#define _mdds_unordered_map_type ::std::unordered_map #endif Else, I got error like Compiling: sc/source/core/tool/scmatrix.cxx In file included from /usr/include/c++/4.5/bits/stl_algobase.h:63:0, from /usr/include/c++/4.5/unordered_map:41, from /home/pjacquod/LibO_dev/libo_dev/solver/330/unxlngi6.pro/inc/mdds/hash_container/map.hpp:41, from /home/pjacquod/LibO_dev/libo_dev/solver/330/unxlngi6.pro/inc/mdds/mixed_type_matrix_flag_storage.hpp:32, from /home/pjacquod/LibO_dev/libo_dev/solver/330/unxlngi6.pro/inc/mdds/mixed_type_matrix.hpp:34, from /home/pjacquod/LibO_dev/libo_dev/clone/calc/sc/source/core/tool/scmatrix.cxx:45: /usr/include/c++/4.5/bits/cpp_type_traits.h:78:10: error: redefinition of 'struct _STL::__true_type' ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] making binfilter aka StarOffice FileFormat read-only
Hi, On 01/14/2011 07:33 PM, Regina Henschel wrote: Hi all, there is something wrong actually. Removing *Export*-filter is reasonable, but now in LibO RC3 I cannot *read* my SO5 files. Kind regards Regina Up to now, nothing has been committed. On trunk master, all is OK, I just tested it. regards ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] error compiling in libs-gui/canevas
hello, there is an error compiling canevas: the reason: in vcl/inc/vcl/sysdata.hxx there has been a change at line 125: -void* pRenderFormat; // render format for drawable +void* pXRenderFormat; // render format for drawable This produce the error (see below) in canevas compilation. Since I have no idea about this part and do not know why this change has been made, I do not risk to fix this of my own... Could someone who understands better than me this part fix it? or give me a go to just change in libs-gui/canvas/source/cairo/cairo_xlib_cairo.cxx (and if needed other canevas part) the pRenderFormat to pXRenderFormat ... without much understanding :- ) regards Pierre-André Compiling: canvas/source/cairo/cairo_xlib_cairo.cxx .../libs-gui/canvas/source/cairo/cairo_xlib_cairo.cxx: In constructor 'cairo::X11SysData::X11SysData(const SystemGraphicsData)': .../libs-gui/canvas/source/cairo/cairo_xlib_cairo.cxx:79:31: error: 'const struct SystemGraphicsData' has no member named 'pRenderFormat' .../libs-gui/canvas/source/cairo/cairo_xlib_cairo.cxx: In member function 'virtual boost::shared_ptrVirtualDevice cairo::X11Surface::createVirtualDevice() const': /libs-gui/canvas/source/cairo/cairo_xlib_cairo.cxx:266:29: error: 'struct SystemGraphicsData' has no member named 'pRenderFormat' ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] Announcement: StarOffice file-format not available any more for saving
Hello, from now I have started to delete within binfilter the code allowing to *save* using the StarOffice file format. The import (read) is still possible and will remain. Bye bye saving sdw, sxw This will of course not happens in one go... With this push, I have done the following changes: * StarWriter does not export anymore * start of deletion of functions within binfilter/bf_sw, i.e StarWriter format For testing: I have my set of files created with those formats, allowing me to test the reading functionality while deleting code. But if other wants to test it to ensure also that nothing has been broken, I would be happy. In order to allow interested to test easily, I will push my changes to master at periodic intervals (each 2-3 weeks, I think/hope if free time allows), grouping them and making a short announce as reply to this mail. Best regards Pierre-André PS: do not forget the --enable-binfilter flag, if you want to check it ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] Announcement: StarOffice file-format not available any more for saving
Hello, On 01/24/2011 03:43 PM, Caolán McNamara wrote: You also needed to adjust the smoketest make check because that has a save as staroffice binary file format test in it. I noticed this failed this morning and bodged it up to work again. Oops, sorry, I was not aware of it. Could you just give me a hint where the code is, so I can have a look? Thanks Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] Announcement: StarOffice file-format not available any more for saving
Hello, Wonderful :-) do you want help with this ? we could add an easy hack, and ask people to contact you, for impress / calc etc. Thanks for this point. I will think if this is easily feasible. But I am still myself on the (intensive) learning part, so I currently do not feel me yet enough confident to describe an easy hack :- ) regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] Comment-translation of writer/sw/source/ui/config
On 02/24/2011 08:33 PM, Kohei Yoshida wrote: On Thu, 2011-02-24 at 19:46 +0100, Jonathan Aquilina wrote: Martin i think it would be easier as well as not to end up having ur email black listed for sending out large amounts of emails, but if its for a single module i would attach them all in one email. For the record this is what git send-email --thread --no-change-reply-to does, which the guideline mentions. yes but it does not recommend to make a commit per file for the same task within the same directory... Looking at the patches, there are some with 1 line changed in one file. In this case, I would recommend to have one commit for translation within a directory. If you are programming, you will very often not be able to have one commit with just one file changed, knowing that a commit should be compilable and runnable... Martin, you can still locally commit as often as you did. But when you are finished with your work, you can group together commits where it makes sense. (in your case, e.g. one commit for translation per directory, except with extra-big file for example). Just beware, still holds to the rule 1 commit is compilable For this you can use git rebase -i. At http://book.git-scm.com/4_interactive_rebasing.html you have a good explanation. At the end, you can then send the git send-mail, with the fewer number of commits. (I am not sure if this could be achieved on the fly, but I think this could be risky, a least too risky for me...) I hope this can help regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] Nonsense comments?
On 02/25/2011 09:46 PM, Caolán McNamara wrote: po files can have translator-comments in them to help translators about ambiguous terms/words, while the .src/.sdf format doesn't though, translation with gettext would support this with comment using key-words / tags. Key words are configurable, maybe a convention has been set with ### as marker... right ? I recall a problem with trying to get the Spanish translation of an obscure paper size (8.5 x 13 ) set as Oficio given that this with gettext, it would be roughly something like coding in file.cxx: /* TRANSLATORS paper size (8.5 x 13 ) */ printf(Long Bond); with xgettext --add-comments TRANSLATORS the po-file for this language would then looks (after translation) like #. paper size (8.5 x 13 ) #src: file.cxx 123 msgid Long Bond msgstr Oficio in crazy idea to go to gettext, when really time available : -) regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] [PUSHED][PATCH]Cleanup comments
Hello, pushed, thanks, Maybe not forgetting the [patch] tag in subject will help not to miss your submission. best regards On 02/27/2011 04:51 PM, Arnaud Versini wrote: Hi, This patch remove some useless comments in msfilter. Thanks -- Arnaud Versini ___ 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] Remove using namespace ::rtl
Hello, Even if binfilters is going to be extracted from LO, doesn't it worth I am doing, this, leting it be only an import filter. to purge using namespace ::rtl from it (I think about the people I think that when cross-module cleaning is done, this is worth to do it also within binfilter: to get ride of old style, to be consistent with the rest. But should not be top 1 priority :- ) regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] Remove using namespace ::rtl
Hello, Finally since I'm not sure for the moment about what must be done on using namespace com::sun::star::uno, I did the work on binfilters. Thanks regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] [PATCH] [PUSHED] Easy Hacks: Translation of Comments from German to English
Hello, thanks, just changed a typo best regards Pierre-André On 03/06/2011 04:10 PM, Daniel Di Marco wrote: Hi, I translated some more comments. The patch is attached. Cheers, Daniel ___ 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] [PUSHED] [PATCH] Remove commented out code
Hello, all seems to me OK, then I pushed. Thanks regards Pierre-André On 03/08/2011 12:19 PM, Bálint Dózsa wrote: Hi, I have removed some commented out code form// //xmloff/. My code is under the LGPLv3+/MPL dual license. Regards, Balint Dozsa ___ 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
bug 49610 in impress: suspicious commit found, but help needed
hello, this bug is a bad regression. Following with debugger, I had as suspect the function void Outliner::ProvideNextTextObject (void) line 979 in sd/source/ui/view/Outliner.cxx (or something called late from this) as main suspect. After bibisect from QA the commit bdfbbb33a491f3ce34375de14ba33436b04 slidesorter1: #i116014# Outliner holds ViewShell as weak_ptr. * found as LGPLv3-only fix at svn rev 1172131 (http://svn.apache.org/viewvc?view=revisionrevision=1172131) touch the suspected function, within the commit frame between last good and first bad binaries. As I just do not understand what it is about here, (neither the goal of the change nor the actual content), could you have a look about it? I guess it will be the quickest way. Beware: currently this commit is just a suspect, since I need more than 4 hours to compile (I am on linux, yeah, but with my hardware...) I am still compiling the checkout to try test. If / when I get more info (means I have compiled it), I will update to confirm (or not) my suspect. Thanks and regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [ANN] Please use Gerrit from now on for Patch Review
Hello, well as free time contributor with commit access to current repository, I followed this gerrit story. So not kind of surprise, but yeah, until THIS mail and posts, was me very unclear what it would mean. To say it, first I had a lot of doubt. Reading mails, entry in the wiki, looking the web ans thinking, I now have the feeling this could be a good move. Just to say, I basically just really do not like the fact of having to use openId, would prefer to have an account at fd.o. I did it really for the LibO, a kind of forced to. And NO, I do NOT have any google, flickr, facebook or other account. Do not trust them enough to put my data there, so to use them as authentication But no choice (!) I kind of understood. [+1 for / to Lionel thread] I - sorry - do not want to read a lot gerrit documentation, I am here already in my free time. So I raise some questions that are not clear for me, that I did not saw in the wiki, based on my previous experiences. Here some points: [WORKFLOW] 1. I have been beaten back by tinderbox (Mac OS X hurt me well), fixing some stupid point of my commits run after run. So would this workflow be supported : some patch done I push to gerrit and let tinderbox run. In case of success I get ? a +1 of each tinderbox ? How do I know it passes with success. Once tinderbox is successful, since my change is small or I am confident with, I put a +2 to my patch, which means this will insert automatically it to master. So I will be able to positive review my own patch ? 2. If I have several patches, that need to be together, how should I proceed with pushing them together to gerrit ? (If I want to have three patches in the same review ID from gerrit) ? [ADMIN] 1. I followed the asked process of setting up an account, etc.. mailed to Norbert so he can match my fd.o account to gerrit. Well, how may I now see that I actually have / will have commit access to gerrit repo ? 2. When my ssh key expires, it is enough to just change it into my gerrit account ? 3. May be a stupid remark, but why do not use this way (opening gerrit account ) then to ask for license stuff ? You would have to ack to be able to open account, or to load patches. This would ease, ensure the process towards this goal ? Thanks Regards Pierre-André On 06/18/2012 12:09 PM, Bjoern Michaelsen wrote: Hi all, with: http://sweetshark.livejournal.com/13298.html gerrit is documented and ready to go. Please use it for code review as much as possible now as it simplifies things a lot over manual patch fiddling on mailing lists. I will update the EasyHacks to point to gerrit instead in the next days. The last remaining step will be making the repo at gerrit the reference (and the one at freedesktop a read-only mirror). I assume that to be prepared and done until mid-July(*). From that point on, we will have a lot of opportunity to improve our tinderbox testing and reporting, making life easier and better for everyone working on the codebase. Best, Bjoern (*) Along with the other repos. ___ 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] What is bibisect? And what is it doing in my office?
Hi, just to say thanks for bibisect Impressive example with fdo49610 to find the problematic commit. Regards Pierre-André On 12/09/2011 02:59 PM, Bjoern Michaelsen wrote: Hi all, So I hope with this, we make regression finding some more fun and allow us -- QA and developers together -- to stabilize this release more quickly that ever before. Bjoern ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: bug 49610 in impress: suspicious commit found, but help needed
Hello, I locally reverted bdfbbb33a491f3ce34375de14ba33436b04 - sadly the change mixes a lot of reformatting with that fix. Hard to tell if that is now causing some ripple effects. :/ I can confirm this is the origin of the problem. The generated bug is very nasty (creates data loss) and the fix has to / should be in 3.6 as well as in 3.5.5 I also have to say honestly that fixing this patch is beyond my knowledge of LibO code in this area. So if you say OK, I will push my revert to master. This is not the most polite way of fixing it. destroying your correction, but the one that fit to my knowledge there. Or have you time to investigate it and fix it ? Sorry, this sounds not very constructive, but in this period I do not have a lot of free time, so I can not offer more. Tack regards Pierre-André On 06/20/2012 11:10 PM, Thorsten Behrens wrote: Pierre-André Jacquod wrote: As I just do not understand what it is about here, (neither the goal of the change nor the actual content), could you have a look about it? I guess it will be the quickest way. Hi Pierre-André, well the goal was to decouple live cycles of Outliner and ViewShell Cheers, -- Thorsten ___ 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: Cppunit-1.13.0 released
hello, updated :-) http://en.wikipedia.org/wiki/CppUnit regards On 07/07/2012 04:19 AM, Markus Mohrhard wrote: Hey, after we have no longer any build issues with cppunit I have now officially tagged the 1.13.0 release of cppunit. I would like to thank everybody who helped during this release. The changes against the 1.12.1 release are: - improved windows build experience (VisualStudio project files for 2005 to 2010). - warning free code - no auto_ptr in a header any more - some old bugs fixed (sf#2185407, sf#2186611, sf#3123759, sf#2983798, rhbz#641350, fdo#51317) All other changes can be seen in the NEWS file and at http://cgit.freedesktop.org/libreoffice/cppunit/log/ Please spread the news about our first cppunit release and encourage people to provide bug report, patches and documentation. Regards, Markus ___ 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: Cppunit-1.13.0 released
hello, git clone git://anongit.freedesktop.org/git/libreoffice/cppunit/ or http://cgit.freedesktop.org/libreoffice/cppunit/ regards On 07/07/2012 09:40 AM, Andreas Radke wrote: Am Sat, 7 Jul 2012 04:19:39 +0200 schrieb Markus Mohrhard markus.mohrh...@googlemail.com: Hey, after we have no longer any build issues with cppunit I have now officially tagged the 1.13.0 release of cppunit. I would like to thank everybody who helped during this release. Have you forked the original project? I can't find the new release in the projects page at http://sourceforge.net/apps/mediawiki/cppunit/index.php?title=Main_Page or http://sourceforge.net/projects/cppunit/ -Andy ArchLinux ___ 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
[PATCH] Re: input for fdo#45779 from a basegfx knowledgeable person needed
Hello, back again after a while. On 02/15/2012 11:30 AM, Thorsten Behrens wrote: Fixed with d37abad97d72bae0fd0269de12e94c7a7d3fd7e1 - but, if you like, would be cool to chase down why in the first place the ppt import creates polygons with empty sub-paths, that looks like a worthwhile optimization - code is around filter/source/msfilter/msdffimp.cxx probably. It happens that basegfx::GetLineArrow(...) (also defined within msdffimp.cxx, line 1102) does not create a valid polygon when eLineEnd has the value mso_lineNoEnd... In the switch(eLineEnd), this goes to default: break; without creating any polygon, letting the return value undefined. So I propose to skip the creation these incorrect polygons if eLineEnd has the value mso_lineNoEnd. But since I do not understand well the import / translation from msformat, I may also have missed a big point. Hence thanks for reviewing this patch, before I push it. I hope it helps. Regards Pierre-André From ec4bf50361f3d2c75e2de20fdb1ddebddba8d406 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Sat, 28 Apr 2012 18:57:02 +0200 Subject: [PATCH] impress ms import filter avoid b2dpolygon with 0 b2dpoints when the lineEnd value is mso_lineNoEnd, the created polygon was incomplete and with no points, then disabling it. --- filter/source/msfilter/msdffimp.cxx | 44 +++--- 1 files changed, 25 insertions(+), 19 deletions(-) diff --git a/filter/source/msfilter/msdffimp.cxx b/filter/source/msfilter/msdffimp.cxx index 80785fa..f208dd9 100644 --- a/filter/source/msfilter/msdffimp.cxx +++ b/filter/source/msfilter/msdffimp.cxx @@ -1329,17 +1329,20 @@ void DffPropertyReader::ApplyLineAttributes( SfxItemSet rSet, const MSO_SPT eSh if ( IsProperty( DFF_Prop_lineStartArrowhead ) ) { MSO_LineEnd eLineEnd = (MSO_LineEnd)GetPropertyValue( DFF_Prop_lineStartArrowhead ); -MSO_LineEndWidtheWidth = (MSO_LineEndWidth)GetPropertyValue( DFF_Prop_lineStartArrowWidth, mso_lineMediumWidthArrow ); -MSO_LineEndLength eLenght = (MSO_LineEndLength)GetPropertyValue( DFF_Prop_lineStartArrowLength, mso_lineMediumLenArrow ); -sal_Int32 nArrowWidth; -sal_BoolbArrowCenter; -rtl::OUString aArrowName; -basegfx::B2DPolygon aPoly(GetLineArrow( nLineWidth, eLineEnd, eWidth, eLenght, nArrowWidth, bArrowCenter, aArrowName, bScaleArrows )); +if ( eLineEnd != mso_lineNoEnd ) +{ +MSO_LineEndWidtheWidth = (MSO_LineEndWidth)GetPropertyValue( DFF_Prop_lineStartArrowWidth, mso_lineMediumWidthArrow ); +MSO_LineEndLength eLenght = (MSO_LineEndLength)GetPropertyValue( DFF_Prop_lineStartArrowLength, mso_lineMediumLenArrow ); +sal_Int32 nArrowWidth; +sal_BoolbArrowCenter; +rtl::OUString aArrowName; +basegfx::B2DPolygon aPoly(GetLineArrow( nLineWidth, eLineEnd, eWidth, eLenght, nArrowWidth, bArrowCenter, aArrowName, bScaleArrows )); -rSet.Put( XLineStartWidthItem( nArrowWidth ) ); -rSet.Put( XLineStartItem( aArrowName, basegfx::B2DPolyPolygon(aPoly) ) ); -rSet.Put( XLineStartCenterItem( bArrowCenter ) ); +rSet.Put( XLineStartWidthItem( nArrowWidth ) ); +rSet.Put( XLineStartItem( aArrowName, basegfx::B2DPolyPolygon(aPoly) ) ); +rSet.Put( XLineStartCenterItem( bArrowCenter ) ); +} } / // LineEnd // @@ -1347,17 +1350,20 @@ void DffPropertyReader::ApplyLineAttributes( SfxItemSet rSet, const MSO_SPT eSh if ( IsProperty( DFF_Prop_lineEndArrowhead ) ) { MSO_LineEnd eLineEnd = (MSO_LineEnd)GetPropertyValue( DFF_Prop_lineEndArrowhead ); -MSO_LineEndWidtheWidth = (MSO_LineEndWidth)GetPropertyValue( DFF_Prop_lineEndArrowWidth, mso_lineMediumWidthArrow ); -MSO_LineEndLength eLenght = (MSO_LineEndLength)GetPropertyValue( DFF_Prop_lineEndArrowLength, mso_lineMediumLenArrow ); +if ( eLineEnd != mso_lineNoEnd) +{ +MSO_LineEndWidtheWidth = (MSO_LineEndWidth)GetPropertyValue( DFF_Prop_lineEndArrowWidth, mso_lineMediumWidthArrow ); +MSO_LineEndLength eLenght = (MSO_LineEndLength)GetPropertyValue( DFF_Prop_lineEndArrowLength, mso_lineMediumLenArrow ); -sal_Int32 nArrowWidth; -sal_BoolbArrowCenter; -rtl::OUString aArrowName; -basegfx::B2DPolygon aPoly(GetLineArrow( nLineWidth, eLineEnd, eWidth, eLenght, nArrowWidth, bArrowCenter, aArrowName, bScaleArrows )); +sal_Int32 nArrowWidth; +
some license statement
Hello, just to confirm that all of my past future contributions to LibreOffice may be licensed under the MPL/LGPLv3+ dual license. Best regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [PATCH] Re: input for fdo#45779 from a basegfx knowledgeable person needed
Hello, On 05/03/2012 11:30 AM, Thorsten Behrens wrote: So what I suggest is a more defensive fix (or some larger review across the code is in order): make GetLineArrow() return the B2DPolyPolygon right away, and have *that one* be empty (i.e. not a Since I do not intend to become a specialist of this kind of elements, I choose your more defensive proposition. So here the patch... Thanks for a review and an ack before I push it. Regards Pierre-André From b77f2a21d222607edff535d3a069b8c30d4d2664 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Andr=C3=A9=20Jacquod?= pjacq...@alumni.ethz.ch Date: Thu, 17 May 2012 17:51:33 +0200 Subject: [PATCH] fdo#45779 avoiding creation of inconsistent B2DPolygon this avoid the root cause of this bug, avoiding creating a B2DPlygon which contains no points. It seems the code relies somehow on an null B2DPolyPolygon, hence the change done here. Better would be to have time to look how to remove this fact. But currently it seems the code relies on a rSet.Put( XLineStartItem( aArrowName, aPolyPoly) where aPolyPoly is not defined in certain cases. Change-Id: I61b75d925090d1c9a0da96ce1a6eea50a2d60e5a --- filter/source/msfilter/msdffimp.cxx | 29 +++-- 1 files changed, 15 insertions(+), 14 deletions(-) diff --git a/filter/source/msfilter/msdffimp.cxx b/filter/source/msfilter/msdffimp.cxx index 80785fa..3d9efa7 100644 --- a/filter/source/msfilter/msdffimp.cxx +++ b/filter/source/msfilter/msdffimp.cxx @@ -1099,12 +1099,13 @@ void SvxMSDffManager::SolveSolver( const SvxMSDffSolverContainer rSolver ) -static basegfx::B2DPolygon GetLineArrow( const sal_Int32 nLineWidth, const MSO_LineEnd eLineEnd, +static basegfx::B2DPolyPolygon GetLineArrow( const sal_Int32 nLineWidth, const MSO_LineEnd eLineEnd, const MSO_LineEndWidth eLineWidth, const MSO_LineEndLength eLineLenght, sal_Int32 rnArrowWidth, sal_Bool rbArrowCenter, rtl::OUString rsArrowName, sal_Bool bScaleArrow ) { -basegfx::B2DPolygon aRetval; +basegfx::B2DPolyPolygon aRetPolyPoly; + double fLineWidth = nLineWidth 70 ? 70.0 : nLineWidth; double fLenghtMul, fWidthMul; sal_Int32 nLineNumber; @@ -1140,7 +1141,7 @@ static basegfx::B2DPolygon GetLineArrow( const sal_Int32 nLineWidth, const MSO_L aTriangle.append(basegfx::B2DPoint( fWidthMul * fLineWidth, fLenghtMul * fLineWidth )); aTriangle.append(basegfx::B2DPoint( 0.0, fLenghtMul * fLineWidth )); aTriangle.setClosed(true); -aRetval = aTriangle; +aRetPolyPoly = basegfx::B2DPolyPolygon(aTriangle); aArrowName.appendAscii(RTL_CONSTASCII_STRINGPARAM(msArrowEnd )); } break; @@ -1169,7 +1170,7 @@ static basegfx::B2DPolygon GetLineArrow( const sal_Int32 nLineWidth, const MSO_L aTriangle.append(basegfx::B2DPoint( fWidthMul * fLineWidth * 0.15, fLenghtMul * fLineWidth )); aTriangle.append(basegfx::B2DPoint( 0.0, fLenghtMul * fLineWidth * 0.91 )); aTriangle.setClosed(true); -aRetval = aTriangle; +aRetPolyPoly = basegfx::B2DPolyPolygon(aTriangle); aArrowName.appendAscii(RTL_CONSTASCII_STRINGPARAM(msArrowOpenEnd )); } break; @@ -1181,7 +1182,7 @@ static basegfx::B2DPolygon GetLineArrow( const sal_Int32 nLineWidth, const MSO_L aTriangle.append(basegfx::B2DPoint( fWidthMul * fLineWidth * 0.50 , fLenghtMul * fLineWidth * 0.60 )); aTriangle.append(basegfx::B2DPoint( 0.0, fLenghtMul * fLineWidth )); aTriangle.setClosed(true); -aRetval = aTriangle; +aRetPolyPoly = basegfx::B2DPolyPolygon(aTriangle); aArrowName.appendAscii(RTL_CONSTASCII_STRINGPARAM(msArrowStealthEnd )); } break; @@ -1193,16 +1194,16 @@ static basegfx::B2DPolygon GetLineArrow( const sal_Int32 nLineWidth, const MSO_L aTriangle.append(basegfx::B2DPoint( fWidthMul * fLineWidth * 0.50 , fLenghtMul * fLineWidth )); aTriangle.append(basegfx::B2DPoint( 0.0, fLenghtMul * fLineWidth * 0.50 )); aTriangle.setClosed(true); -aRetval = aTriangle; +aRetPolyPoly = basegfx::B2DPolyPolygon(aTriangle); rbArrowCenter = sal_True; aArrowName.appendAscii(RTL_CONSTASCII_STRINGPARAM(msArrowDiamondEnd )); } break; case mso_lineArrowOvalEnd : { -aRetval = XPolygon( Point( (sal_Int32)( fWidthMul * fLineWidth * 0.50 ), 0 ), +aRetPolyPoly = basegfx::B2DPolyPolygon( XPolygon( Point( (sal_Int32)( fWidthMul * fLineWidth * 0.50 ), 0 ), (sal_Int32)( fWidthMul * fLineWidth * 0.50 ), -(sal_Int32)( fLenghtMul * fLineWidth * 0.50 ), 0, 3600 ).getB2DPolygon(); +
Re: --enable-debug vs --enable-symbols (Re: [Libreoffice-commits] .: 12 commits - config_host.mk.in configure.in filter/source oox/source sal/inc sc/source solenv/gbuild toolkit/source xmlhelp/source)
hello, On 05/16/2012 04:07 PM, Lubos Lunak wrote: If somebody does a developer build, there are not many good reasons why -O2 should be used - it takes noticably more time and it makes debugging miserable. I can't think of anything else than final builds and profiling as a good non-corner-case reason for -O2. At least I understand why I always got debug builds with optimization, which does not ease the use of debugger... and why it takes so long to build. As occasional developer, I do not want to dig to deep in build options - that is also not my interest. So with --enable-symbols, I was really expecting to get symbols without optimization, not wanting all asserts outputs. Could it not stay like that? Or how do you obtain this effect (symbols, without optimization, without all asserts output?) I really do not want to take time to search for such thinks, hacking LO is already during my free time. Regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: --enable-debug vs --enable-symbols (Re: [Libreoffice-commits] .: 12 commits - config_host.mk.in configure.in filter/source oox/source sal/inc sc/source solenv/gbuild toolkit/source xmlhelp/source)
Hello, On 05/20/2012 11:24 PM, Norbert Thiebaud wrote: On Wed, May 16, 2012 at 11:30 PM, Pierre-André Jacquod pjacq...@alumni.ethz.ch wrote: expecting to get symbols without optimization, not wanting all asserts outputs. If you are intending to debug why wouldn't you want the misnamed 'assert output' ? Better said, I do not care of them / are not useful: I try to solve some bugzilla points and it happens I have not yet have seen one caught by an assert :- ) Hence the minimum is the best for me. But yeah, I admit I most probably did not get the power of all this stuff. Regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] Announcement: StarOffice file-format not available any more for saving
Hello, On 03/25/2011 10:12 PM, Caolán McNamara wrote: On Fri, 2011-03-25 at 22:09 +0100, Pierre-André Jacquod wrote: something... Hopefully my tests are good And make check was successful,.. at last :- ) in case you're relying on it as some oracle :-) No, the other way around: I run make check to be sure not to break it, as I did once:- ) More seriously: I have my set of files for testing, but will nerveless be happy and thankful if other are also sometimes trying to use binfilter. regards ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] -Woverloaded-virtual
Hello, On 03/25/2011 02:13 PM, Lubos Lunak wrote: On Friday 25 of March 2011, Caolán McNamara wrote: argh!, I meant to say then things are *not* too bad, not *too* bad. I mean that's far less that I would have feared, quite manageable. Ok. In that case, if there are no objections, I'll commit my patches. just a bet: binfilter was off in your try? So I have some warning more to handle, once I am finished with cleaning. And I am always +1 for all what shows potential problems. Else it bites you harder later... regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] release plan : inconsistency between 3.3.3 and 3.4
Hello, jumping late into the subject, but On 04/11/2011 12:25 PM, Michael Meeks wrote: The plan is (of course), to keep releasing 3.3.x releases as long as people are interested in creating them I suppose[1] - we should come up May I disagree ?? This is not a very predictable use for all involved: users, distros, etc... When to jump to next version? What happens for bug discovered in distros ? Especially if we have 3-4 X.Y release a year IMHO it is good to have a stable release of 3.3 after releasing 3.4 - Here I fully agree, Could it be not possible to have some rules, like the release of version X.Y.0 means end of support for X.(Y-2) version. En in case of X.0.0 version, only the latest (X-1).Y.Z version is supported ? and that in what-ever X.Y.Z and X.(Y-1).W, only the latest Z and W are supported? But this would implies to have at least within the X.Y path an update mechanism, especially for Windows. But this could lead to problems, since distro's have a more slowly pace of release. So what about picking long term support, e.g. 3.5 is long term support, means 2 years, what ever happens for the number of releases ? This kind of scheme would limited (and clarify) the number of release that are / could be cared of. (again, usefull with several X.Y a year) So if you get a bug report, you know against which release you have to test / it will be tested. Just thinking loud... other wants to do it also? :-) regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
Re: [Libreoffice] minutes of tech steering call ...
Hi, * announcing binfilter as deprecated in 3.4 + want to warn people in plenty of time + officially deprecate it, we drop save support in 3.4 The code cleaning is not yet finished, I still have commits (and done commits) that missed the 3.4 freeze (argh, missing free time) and some that needs to be done. + be warned - it will die in a new major release soon. Will be this 3.5 ? Or do you want to wait for the next version? If post 3.5, then I will continue the cleaning. If no, I may change my work and try to perform cleaning (ergh, deletion) as proposed here below. And also make sure when you remove it completely: Don't remove the filter-detection part of it. I.e. when a user then opens a binfilter-covered format, don't present the user with the file-format selection box, but use a sorry, support for this format was removed - open it in 3.4 or similar dialog. Regards Pierre-André ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice
[Libreoffice] [patch] unused variable in Windows build
Hello, a small patch to suppress an unused variable (within a WNT define) according cppchecker Since I can not build on Windows, if someone could review / compile it for me before pushing ? Thanks and regards Pierre-André 0001-unused-variable-in-Windows-build.patch Description: application/mbox ___ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice