ooo-build r12772 - in trunk: . patches/test
- From: kyoshida svn gnome org
- To: svn-commits-list gnome org
- Subject: ooo-build r12772 - in trunk: . patches/test
- Date: Wed, 4 Jun 2008 02:12:52 +0000 (UTC)
Author: kyoshida
Date: Wed Jun 4 02:12:51 2008
New Revision: 12772
URL: http://svn.gnome.org/viewvc/ooo-build?rev=12772&view=rev
Log:
2008-06-03 Kohei Yoshida <kyoshida novell com>
* patches/test/calc-external-defined-names.diff: on-going work to
support external defined names in Calc. Nothing useful yet.
Added:
trunk/patches/test/calc-external-defined-names.diff
Modified:
trunk/ChangeLog
Added: trunk/patches/test/calc-external-defined-names.diff
==============================================================================
--- (empty file)
+++ trunk/patches/test/calc-external-defined-names.diff Wed Jun 4 02:12:51 2008
@@ -0,0 +1,453 @@
+diff --git sc/source/core/data/cell.cxx sc/source/core/data/cell.cxx
+index 72f8e7b..3b6d107 100644
+--- sc/source/core/data/cell.cxx
++++ sc/source/core/data/cell.cxx
+@@ -1710,6 +1710,8 @@ void ScFormulaCell::InterpretTail( ScInterpretTailParameter eTailParam )
+ bChanged = TRUE;
+ bIsValue = FALSE;
+ aErgString = p->GetStringResult();
++ fprintf(stdout, "ScFormulaCell::InterpretTail: here (%d) aErgString = '%s'\n", __LINE__,
++ rtl::OUStringToOString(aErgString, RTL_TEXTENCODING_UTF8).getStr());
+ }
+ break;
+ default:
+diff --git sc/source/core/data/cell2.cxx sc/source/core/data/cell2.cxx
+index 4acf571..2fa8737 100644
+--- sc/source/core/data/cell2.cxx
++++ sc/source/core/data/cell2.cxx
+@@ -36,7 +36,7 @@
+ // MARKER(update_precomp.py): autogen include statement, do not remove
+ #include "precompiled_sc.hxx"
+
+-
++#include <stdio.h>
+
+ // INCLUDE ---------------------------------------------------------------
+
+@@ -444,6 +444,8 @@ void ScFormulaCell::GetString( String& rString )
+ rString = aErgString;
+ else
+ rString.Erase();
++ fprintf(stdout, "ScFormulaCell::GetString: str = '%s'\n",
++ rtl::OUStringToOString(rString, RTL_TEXTENCODING_UTF8).getStr());
+ }
+
+ const ScMatrix* ScFormulaCell::GetMatrix()
+@@ -1432,6 +1434,7 @@ void ScFormulaCell::CompileDBFormula()
+
+ void ScFormulaCell::CompileDBFormula( BOOL bCreateFormulaString )
+ {
++ fprintf(stdout, "ScFormulaCell::CompileDBFormula: --begin\n");
+ // zwei Phasen, muessen (!) nacheinander aufgerufen werden:
+ // 1. FormelString mit alten Namen erzeugen
+ // 2. FormelString mit neuen Namen kompilieren
+@@ -1484,6 +1487,7 @@ void ScFormulaCell::CompileDBFormula( BOOL bCreateFormulaString )
+
+ void ScFormulaCell::CompileNameFormula( BOOL bCreateFormulaString )
+ {
++ fprintf(stdout, "ScFormulaCell::CompileNameFormula: --begin\n");
+ // zwei Phasen, muessen (!) nacheinander aufgerufen werden:
+ // 1. FormelString mit alten RangeNames erzeugen
+ // 2. FormelString mit neuen RangeNames kompilieren
+diff --git sc/source/core/data/documen3.cxx sc/source/core/data/documen3.cxx
+index 39b95d0..c588bca 100644
+--- sc/source/core/data/documen3.cxx
++++ sc/source/core/data/documen3.cxx
+@@ -427,6 +427,17 @@ BOOL ScDocument::HasLink( const String& rDoc,
+ BOOL ScDocument::LinkExternalTab( SCTAB& rTab, const String& aDocTab,
+ const String& aFileName, const String& aTabName )
+ {
++ fprintf(stdout, "ScDocument::LinkExternalTab: --begin\n");
++
++ fprintf(stdout, "ScDocument::LinkExternalTab: file name = '%s'\n",
++ rtl::OUStringToOString(aFileName, RTL_TEXTENCODING_UTF8).getStr());
++
++ fprintf(stdout, "ScDocument::LinkExternalTab: tab name = '%s'\n",
++ rtl::OUStringToOString(aTabName, RTL_TEXTENCODING_UTF8).getStr());
++
++ fprintf(stdout, "ScDocument::LinkExternalTab: doc tab = '%s'\n",
++ rtl::OUStringToOString(aDocTab, RTL_TEXTENCODING_UTF8).getStr());
++
+ if ( IsClipboard() )
+ {
+ DBG_ERRORFILE( "LinkExternalTab in Clipboard" );
+diff --git sc/source/core/tool/compiler.cxx sc/source/core/tool/compiler.cxx
+index 49cf4a7..78b6365 100644
+--- sc/source/core/tool/compiler.cxx
++++ sc/source/core/tool/compiler.cxx
+@@ -86,6 +86,8 @@
+ #include "parclass.hxx"
+ #include "autonamecache.hxx"
+
++#include <stdio.h>
++
+ using namespace ::com::sun::star;
+ using rtl::OUString;
+
+@@ -2954,6 +2956,7 @@ BOOL ScCompiler::NextNewToken( bool bInArray )
+
+ String aOrg( cSymbol ); // preserve file names in IsReference()
+ String aUpper( ScGlobal::pCharClass->upper( aOrg ) );
++ fprintf(stdout, "ScCompiler::NextNewToken: token = '%s'\n", rtl::OUStringToOString(aUpper, RTL_TEXTENCODING_UTF8).getStr());
+ #if 0
+ fprintf( stderr, "Token '%s'\n",
+ rtl::OUStringToOString( aUpper, RTL_TEXTENCODING_UTF8 ).getStr() );
+@@ -2964,8 +2967,12 @@ BOOL ScCompiler::NextNewToken( bool bInArray )
+ // IsReference().
+ // IsBoolean before isValue to catch inline bools without the kludge
+ // for inline arrays.
++
++ bool bIsRef = IsReference(aOrg);
++ fprintf(stdout, "ScCompiler::NextNewToken: is reference? (%s)\n", bIsRef?"yes":"no");
++
+ if ( !(bMayBeFuncName && IsOpCode( aUpper, bInArray ))
+- && !IsReference( aOrg )
++ && !bIsRef
+ && !(bAllowBooleans && IsBoolean( aUpper ))
+ && !IsValue( aUpper )
+ && !IsNamedRange( aUpper )
+@@ -3000,6 +3007,8 @@ BOOL ScCompiler::NextNewToken( bool bInArray )
+ ScTokenArray* ScCompiler::CompileString( const String& rFormula,
+ ScAddress::Convention eConv )
+ {
++ fprintf(stdout, "ScCompiler::CompileString: --begin (formula = '%s')\n",
++ rtl::OUStringToOString(rFormula, RTL_TEXTENCODING_UTF8).getStr());
+ #if 0
+ fprintf( stderr, "CompileString '%s'\n",
+ rtl::OUStringToOString( rFormula, RTL_TEXTENCODING_UTF8 ).getStr() );
+@@ -3040,6 +3049,7 @@ ScTokenArray* ScCompiler::CompileString( const String& rFormula,
+ eLastOp = ocOpen;
+ while( NextNewToken( bInArray ) )
+ {
++ fprintf(stdout, "ScCompiler::CompileString: opcode = %d\n", pRawToken->GetOpCode());
+ if( pRawToken->GetOpCode() == ocOpen )
+ nBrackets++;
+ else if( pRawToken->GetOpCode() == ocClose )
+@@ -5154,6 +5164,7 @@ ScToken* ScCompiler::CreateStringFromToken( String& rFormula, ScToken* pTokenP,
+ ScToken* ScCompiler::CreateStringFromToken( rtl::OUStringBuffer& rBuffer, ScToken* pTokenP,
+ BOOL bAllowArrAdvance )
+ {
++ fprintf(stdout, "ScCompiler::CreateStringFromToken: --begin\n");
+ BOOL bNext = TRUE;
+ BOOL bSpaces = FALSE;
+ ScToken* t = pTokenP;
+@@ -5202,6 +5213,7 @@ ScToken* ScCompiler::CreateStringFromToken( rtl::OUStringBuffer& rBuffer, ScToke
+ break;
+ case svSingleRef:
+ {
++ fprintf(stdout, "ScCompiler::CreateStringFromToken: single ref\n");
+ SingleRefData& rRef = t->GetSingleRef();
+ ComplRefData aRef;
+ aRef.Ref1 = aRef.Ref2 = rRef;
+@@ -5269,6 +5281,7 @@ ScToken* ScCompiler::CreateStringFromToken( rtl::OUStringBuffer& rBuffer, ScToke
+ }
+ case svExternal:
+ {
++ fprintf(stdout, "ScCompiler::CreateStringFromToken: external\n");
+ // mapped or translated name of AddIns
+ String aAddIn( t->GetExternal() );
+ bool bMapped = mxSymbols->isODF_11(); // ODF 1.1 directly uses programmatical name
+@@ -5300,6 +5313,8 @@ ScToken* ScCompiler::CreateStringFromToken( rtl::OUStringBuffer& rBuffer, ScToke
+ {
+ if( bNext )
+ t = pArr->Next();
++ fprintf(stdout, "ScCompiler::CreateStringFromToken: --end (buf = '%s')\n",
++ rtl::OUStringToOString(OUString(rBuffer.getStr()), RTL_TEXTENCODING_UTF8).getStr());
+ return t;
+ }
+ return pTokenP;
+diff --git sc/source/core/tool/interpr4.cxx sc/source/core/tool/interpr4.cxx
+index 6b48e5c..92c73fa 100644
+--- sc/source/core/tool/interpr4.cxx
++++ sc/source/core/tool/interpr4.cxx
+@@ -3219,6 +3219,7 @@ void ScInterpreter::GlobalExit() // static
+
+ StackVar ScInterpreter::Interpret()
+ {
++ fprintf(stdout, "ScInterpreter::Interpret: --begins\n");
+ short nRetTypeExpr = NUMBERFORMAT_UNDEFINED;
+ ULONG nRetIndexExpr = 0;
+ USHORT nErrorFunction = 0;
+@@ -3253,6 +3254,7 @@ StackVar ScInterpreter::Interpret()
+ {
+ OpCode eOp = pCur->GetOpCode();
+ cPar = pCur->GetByte();
++ fprintf(stdout, "ScInterpreter::Interpret: opcode = %d\n", eOp);
+ if ( eOp == ocPush )
+ {
+ Push( (ScToken&) *pCur );
+@@ -3736,13 +3738,25 @@ StackVar ScInterpreter::Interpret()
+ break;
+ case svSingleRef :
+ {
++ fprintf(stdout, "ScInterpreter::Interpret: single ref\n");
+ ScAddress aAdr;
+ PopSingleRef( aAdr );
++ {
++ String aTmp, aTmpTabName;
++ aAdr.Format(aTmp, SCA_ABS_3D, pDok);
++ pDok->GetName(aAdr.Tab(), aTmpTabName);
++ fprintf(stdout, "ScInterpreter::Interpret: tab %d is linked ? (%s)\n",
++ aAdr.Tab(), pDok->IsLinked(aAdr.Tab())?"yes":"no");
++ fprintf(stdout, "ScInterpreter::Interpret: cell address = '%s' tab = %d tab name = '%s'\n",
++ rtl::OUStringToOString(aTmp, RTL_TEXTENCODING_UTF8).getStr(), aAdr.Tab(),
++ rtl::OUStringToOString(aTmpTabName, RTL_TEXTENCODING_UTF8).getStr());
++ }
+ if( !nGlobalError )
+ {
+ ScBaseCell* pCell = pDok->GetCell( aAdr );
+ if( pCell && pCell->HasStringData() )
+ {
++ fprintf(stdout, "ScInterpreter::Interpret: has string data\n");
+ GetCellString( aResult, pCell );
+ nRetTypeExpr = NUMBERFORMAT_TEXT;
+ nRetIndexExpr = 0;
+@@ -3870,6 +3884,8 @@ StackVar ScInterpreter::Interpret()
+ while( maxsp-- )
+ (*p++)->DecRef();
+ nGlobalError = nGlobError;
++
++ fprintf(stdout, "ScInterpreter::Interpret: --end\n");
+ return eResult;
+ }
+
+diff --git sc/source/core/tool/token.cxx sc/source/core/tool/token.cxx
+index 25be397..eabebd7 100644
+--- sc/source/core/tool/token.cxx
++++ sc/source/core/tool/token.cxx
+@@ -214,6 +214,7 @@ ComplRefData& ScRawToken::GetReference()
+
+ void ScRawToken::SetExternal( const sal_Unicode* pStr )
+ {
++ fprintf(stdout, "ScRawToken::SetExternal: --begin\n");
+ eOp = ocExternal;
+ eType = svExternal;
+ xub_StrLen nLen = GetStrLen( pStr ) + 1;
+@@ -308,6 +309,7 @@ ScToken* ScRawToken::CreateToken() const
+ return new ScJumpToken( eOp, (short*) nJump );
+ //break;
+ case svExternal :
++ fprintf(stdout, "ScRawToken::CreateToken: external\n");
+ return new ScExternalToken( eOp, sbyte.cByte, String( cStr+1 ) );
+ //break;
+ case svFAP :
+diff --git sc/source/filter/excel/excform.cxx sc/source/filter/excel/excform.cxx
+index 88bfbab..98d07d9 100644
+--- sc/source/filter/excel/excform.cxx
++++ sc/source/filter/excel/excform.cxx
+@@ -63,6 +63,7 @@
+ #include "xiname.hxx"
+ #endif
+
++#include <stdio.h>
+
+ const UINT16 ExcelToSc::nRowMask = 0x3FFF;
+ const UINT16 ExcelToSc::nLastInd = 399;
+@@ -152,7 +153,12 @@ void ImportExcel::Formula( const XclAddress& rXclPos,
+ bConvert = TRUE;
+
+ if( bConvert )
++ {
++ fprintf(stdout, "ImportExcel::Formula: converts\n");
+ eErr = pFormConv->Convert( pErgebnis, maStrm, nFormLen, true, FT_CellFormula);
++ }
++ else
++ fprintf(stdout, "ImportExcel::Formula: don't convert\n");
+
+ ScFormulaCell* pZelle = NULL;
+
+@@ -915,6 +921,8 @@ ConvErr ExcelToSc::Convert( const ScTokenArray*& pErgebnis, XclImpStream& aIn, s
+ ConvErr ExcelToSc::Convert( _ScRangeListTabs& rRangeList, XclImpStream& aIn, sal_Size nFormulaLen,
+ SCsTAB nTab, const FORMULA_TYPE eFT )
+ {
++ fprintf(stdout, "ExcelToSc::Convert: --begin\n");
++
+ RootData& rR = GetOldRoot();
+ BYTE nOp, nLen;
+ sal_Size nIgnore;
+@@ -1334,6 +1342,7 @@ ConvErr ExcelToSc::Convert( _ScRangeListTabs& rRangeList, XclImpStream& aIn, sal
+ eRet = ConvOK;
+
+ aIn.Seek( nEndPos );
++ fprintf(stdout, "ExcelToSc::Convert: --end\n");
+ return eRet;
+ }
+
+diff --git sc/source/filter/excel/excform8.cxx sc/source/filter/excel/excform8.cxx
+index ab1c96c..6556fc2 100644
+--- sc/source/filter/excel/excform8.cxx
++++ sc/source/filter/excel/excform8.cxx
+@@ -57,6 +57,7 @@
+ #include "xiname.hxx"
+ #endif
+
++#include <stdio.h>
+
+ ExcelToSc8::ExcelToSc8( const XclImpRoot& rRoot ) :
+ ExcelToSc( rRoot ),
+@@ -85,6 +86,7 @@ BOOL ExcelToSc8::Read3DTabReference( XclImpStream& rStrm, SCTAB& rFirstTab, SCTA
+ // otherwise it will seek to the first byte past additional content after <nFormulaLen>
+ ConvErr ExcelToSc8::Convert( const ScTokenArray*& rpTokArray, XclImpStream& aIn, sal_Size nFormulaLen, bool bAllowArrays, const FORMULA_TYPE eFT )
+ {
++ fprintf(stdout, "ExcelToSc8::Convert: --begin (1)\n");
+ BYTE nOp, nLen, nByte;
+ UINT16 nUINT16;
+ double fDouble;
+@@ -120,6 +122,7 @@ ConvErr ExcelToSc8::Convert( const ScTokenArray*& rpTokArray, XclImpStream& aIn,
+ {
+ aIn >> nOp;
+
++ fprintf(stdout, "ExcelToSc8::Convert: op = 0x%2.2X\n", nOp);
+ // #98524# always reset flags
+ aSRD.InitFlags();
+ aCRD.InitFlags();
+@@ -604,6 +607,9 @@ ConvErr ExcelToSc8::Convert( const ScTokenArray*& rpTokArray, XclImpStream& aIn,
+ aIn >> nXtiIndex >> nNameIdx;
+ aIn.Ignore( 2 );
+
++ fprintf(stdout, "ExcelToSc8::Convert: name or external name (xti index = %d; name index = %d)\n",
++ nXtiIndex, nNameIdx);
++
+ if( rLinkMan.IsSelfRef( nXtiIndex ) )
+ {
+ // internal defined name with explicit sheet, i.e.: =Sheet1!AnyName
+@@ -619,19 +625,33 @@ ConvErr ExcelToSc8::Convert( const ScTokenArray*& rpTokArray, XclImpStream& aIn,
+ {
+ case xlExtName:
+ {
++ fprintf(stdout, "ExcelToSc8::Convert: external name (%s)\n",
++ rtl::OUStringToOString(pExtName->GetName(), RTL_TEXTENCODING_UTF8).getStr());
+ aStack << aPool.Store( ocNoName, pExtName->GetName() );
++ String aApplic, aTopic;
++ if (rLinkMan.GetLinkData(aApplic, aTopic, nXtiIndex))
++ {
++ fprintf(stdout, "ExcelToSc8::Convert: app = '%s'; topic = '%s'\n",
++ rtl::OUStringToOString(aApplic, RTL_TEXTENCODING_UTF8).getStr(),
++ rtl::OUStringToOString(aTopic, RTL_TEXTENCODING_UTF8).getStr());
++ }
++ else
++ fprintf(stdout, "ExcelToSc8::Convert: link data fetch failed.\n");
++
+ GetTracer().TraceFormulaExtName();
+ }
+ break;
+
+ case xlExtAddIn:
+ {
++ fprintf(stdout, "ExcelToSc8::Convert: external addin\n");
+ aStack << aPool.Store( ocExternal, pExtName->GetName() );
+ }
+ break;
+
+ case xlExtDDE:
+ {
++ fprintf(stdout, "ExcelToSc8::Convert: external DDE\n");
+ String aApplic, aTopic;
+ if( rLinkMan.GetLinkData( aApplic, aTopic, nXtiIndex ) )
+ {
+@@ -814,6 +834,7 @@ ConvErr ExcelToSc8::Convert( const ScTokenArray*& rpTokArray, XclImpStream& aIn,
+ ConvErr ExcelToSc8::Convert( _ScRangeListTabs& rRangeList, XclImpStream& aIn, sal_Size nFormulaLen,
+ SCsTAB nTab, const FORMULA_TYPE eFT )
+ {
++ fprintf(stdout, "ExcelToSc8::Convert: --begin (2)\n");
+ BYTE nOp, nLen;//, nByte;
+ BOOL bError = FALSE;
+ BOOL bArrayFormula = FALSE;
+@@ -841,6 +862,7 @@ ConvErr ExcelToSc8::Convert( _ScRangeListTabs& rRangeList, XclImpStream& aIn, sa
+ {
+ aIn >> nOp;
+
++ fprintf(stdout, "ExcelToSc8::Convert: op = %2.2X\n", nOp);
+ // #98524# always reset flags
+ aSRD.InitFlags();
+ aCRD.InitFlags();
+@@ -1151,6 +1173,8 @@ ConvErr ExcelToSc8::Convert( _ScRangeListTabs& rRangeList, XclImpStream& aIn, sa
+ eRet = ConvOK;
+
+ aIn.Seek( nEndPos );
++
++ fprintf(stdout, "ExcelToSc8::Convert: --end\n");
+ return eRet;
+ }
+
+diff --git sc/source/filter/excel/read.cxx sc/source/filter/excel/read.cxx
+index 6797bfd..67b6c65 100644
+--- sc/source/filter/excel/read.cxx
++++ sc/source/filter/excel/read.cxx
+@@ -795,6 +795,7 @@ FltError ImportExcel::Read( void )
+
+ FltError ImportExcel8::Read( void )
+ {
++ fprintf(stdout, "ImportExcel8::Read: --begin\n");
+ #if EXC_INCL_DUMPER
+ {
+ Biff8RecDumper aDumper( GetRoot(), TRUE );
+diff --git sc/source/filter/excel/xilink.cxx sc/source/filter/excel/xilink.cxx
+index 00b76c7..44dfa23 100644
+--- sc/source/filter/excel/xilink.cxx
++++ sc/source/filter/excel/xilink.cxx
+@@ -63,6 +63,8 @@
+ #include "xiname.hxx"
+ #endif
+
++#include <stdio.h>
++
+ // ============================================================================
+ // *** Helper classes ***
+ // ============================================================================
+@@ -440,6 +442,9 @@ XclImpSupbook::XclImpSupbook( XclImpStream& rStrm ) :
+ bool bSelf = false;
+ XclImpUrlHelper::DecodeUrl( maXclUrl, bSelf, GetRoot(), aEncUrl );
+
++ fprintf(stdout, "XclImpSupbook::XclImpSupbook: decoded excel sURL = '%s'\n",
++ rtl::OUStringToOString(maXclUrl, RTL_TEXTENCODING_UTF8).getStr());
++
+ if( nSBTabCnt )
+ {
+ meType = EXC_SBTYPE_EXTERN;
+diff --git sc/source/filter/inc/fdumper.hxx sc/source/filter/inc/fdumper.hxx
+index 3b8a379..b3c7101 100644
+--- sc/source/filter/inc/fdumper.hxx
++++ sc/source/filter/inc/fdumper.hxx
+@@ -36,7 +36,7 @@
+ #ifndef SC_FDUMPER_HXX
+ #define SC_FDUMPER_HXX
+
+-#define SCF_INCL_DUMPER (OSL_DEBUG_LEVEL > 0)
++#define SCF_INCL_DUMPER (OSL_DEBUG_LEVEL > 0) && 0
+
+ #if SCF_INCL_DUMPER
+
+diff --git sc/source/ui/miscdlgs/linkarea.cxx sc/source/ui/miscdlgs/linkarea.cxx
+index 07e118a..bc1ae5a 100644
+--- sc/source/ui/miscdlgs/linkarea.cxx
++++ sc/source/ui/miscdlgs/linkarea.cxx
+@@ -38,7 +38,7 @@
+
+ #undef SC_DLLIMPLEMENTATION
+
+-
++#include <stdio.h>
+
+ //------------------------------------------------------------------
+
+@@ -84,6 +84,7 @@ ScLinkedAreaDlg::ScLinkedAreaDlg( Window* pParent ) :
+ pDocInserter( NULL )
+
+ {
++ fprintf(stdout, "ScLinkedAreaDlg::ScLinkedAreaDlg: ctor --begin\n");
+ FreeResource();
+
+ aCbUrl.SetHelpId( HID_SCDLG_LINKAREAURL ); // SvtURLBox ctor always sets SID_OPENURL
+diff --git sc/source/ui/view/tabvwshb.cxx sc/source/ui/view/tabvwshb.cxx
+index c358c34..608c4cb 100644
+--- sc/source/ui/view/tabvwshb.cxx
++++ sc/source/ui/view/tabvwshb.cxx
+@@ -369,6 +369,7 @@ void ScTabViewShell::ExecDrawIns(SfxRequest& rReq)
+
+ case SID_LINKS:
+ {
++ fprintf(stdout, "ScTabViewShell::ExecDrawIns: SID_LINKS\n");
+ SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
+ SfxAbstractLinksDialog* pDlg = pFact->CreateLinksDialog( pWin, pDoc->GetLinkManager() );
+ if ( pDlg )
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]