ScBaseCell::nTextWidth is no more.

Change-Id: I32368d39a21d44bef8ab7fe265077cd147a50024
diff --git a/sc/inc/cell.hxx b/sc/inc/cell.hxx
index c84e985..5fbfb0b 100644
--- a/sc/inc/cell.hxx
+++ b/sc/inc/cell.hxx
@@ -101,10 +101,6 @@ public:
        Returns false for formula cells returning nothing, use HasEmptyData() for that. */
    bool            IsBlank() const;

// for idle-calculations
    inline sal_uInt16   GetTextWidth() const { return nTextWidth; }
    inline void     SetTextWidth( sal_uInt16 nNew ) { nTextWidth = nNew; }

    inline sal_uInt8     GetScriptType() const { return nScriptType; }
    inline void     SetScriptType( sal_uInt8 nNew ) { nScriptType = nNew; }

@@ -148,7 +144,6 @@ private:
    SvtBroadcaster* mpBroadcaster;  /// Broadcaster for changed values. Cell takes ownership!

protected:
    sal_uInt16          nTextWidth;
    sal_uInt8            eCellType;      // enum CellType - sal_uInt8 spart Speicher
    sal_uInt8            nScriptType;
};
diff --git a/sc/inc/document.hxx b/sc/inc/document.hxx
index 8c3fac2..2f59ef1 100644
--- a/sc/inc/document.hxx
+++ b/sc/inc/document.hxx
@@ -1844,6 +1844,8 @@ public:
    void RemoveSubTotalCell(ScFormulaCell* pCell);
    void SetSubTotalCellsDirty(const ScRange& rDirtyRange);

    void SetTextWidth( const ScAddress& rPos, sal_uInt16 nWidth );

private: // CLOOK-Impl-methods

    /**
diff --git a/sc/source/core/data/cell.cxx b/sc/source/core/data/cell.cxx
index 5ffd85e..bc6367c 100644
--- a/sc/source/core/data/cell.cxx
+++ b/sc/source/core/data/cell.cxx
@@ -69,7 +69,6 @@ IMPL_FIXEDMEMPOOL_NEWDEL( ScNoteCell )

ScBaseCell::ScBaseCell( CellType eNewType ) :
    mpBroadcaster( 0 ),
    nTextWidth( TEXTWIDTH_DIRTY ),
    eCellType( sal::static_int_cast<sal_uInt8>(eNewType) ),
    nScriptType( SC_SCRIPTTYPE_UNKNOWN )
{
@@ -77,7 +76,6 @@ ScBaseCell::ScBaseCell( CellType eNewType ) :

ScBaseCell::ScBaseCell( const ScBaseCell& rCell ) :
    mpBroadcaster( 0 ),
    nTextWidth( rCell.nTextWidth ),
    eCellType( rCell.eCellType ),
    nScriptType( SC_SCRIPTTYPE_UNKNOWN )
{
@@ -1002,7 +1000,7 @@ void ScFormulaCell::Compile( const rtl::OUString& rFormula, bool bNoListening,
    else
    {
        bChanged = true;
        SetTextWidth( TEXTWIDTH_DIRTY );
        pDocument->SetTextWidth(aPos, TEXTWIDTH_DIRTY);
        SetScriptType( SC_SCRIPTTYPE_UNKNOWN );
    }
    if ( bWasInFormulaTree )
@@ -1096,7 +1094,7 @@ void ScFormulaCell::CompileXML( ScProgress& rProgress )
    else
    {
        bChanged = true;
        SetTextWidth( TEXTWIDTH_DIRTY );
        pDocument->SetTextWidth(aPos, TEXTWIDTH_DIRTY);
        SetScriptType( SC_SCRIPTTYPE_UNKNOWN );
    }

@@ -1367,7 +1365,7 @@ void ScFormulaCell::Interpret()
                            pIterCell->bTableOpDirty = false;
                            pIterCell->aResult.SetResultError( errNoConvergence);
                            pIterCell->bChanged = true;
                            pIterCell->SetTextWidth( TEXTWIDTH_DIRTY);
                            pDocument->SetTextWidth(pIterCell->aPos, TEXTWIDTH_DIRTY);
                            pIterCell->SetScriptType( SC_SCRIPTTYPE_UNKNOWN);
                        }
                    }
@@ -1662,7 +1660,7 @@ void ScFormulaCell::InterpretTail( ScInterpretTailParameter eTailParam )
        }
        if( bChanged )
        {
            SetTextWidth( TEXTWIDTH_DIRTY );
            pDocument->SetTextWidth(aPos, TEXTWIDTH_DIRTY);
            SetScriptType( SC_SCRIPTTYPE_UNKNOWN );
        }
        if (bContentChanged && pDocument->IsStreamValid(aPos.Tab()))
diff --git a/sc/source/core/data/document.cxx b/sc/source/core/data/document.cxx
index 8cfc787..acce598 100644
--- a/sc/source/core/data/document.cxx
+++ b/sc/source/core/data/document.cxx
@@ -5695,6 +5695,13 @@ void ScDocument::SetSubTotalCellsDirty(const ScRange& rDirtyRange)
    maSubTotalCells.swap(aNewSet); // update the list.
}

void ScDocument::SetTextWidth( const ScAddress& rPos, sal_uInt16 nWidth )
{
    SCTAB nTab = rPos.Tab();
    if (ValidTab(nTab) && nTab < static_cast<SCTAB>(maTabs.size()) && maTabs[nTab])
        maTabs[nTab]->SetTextWidth(rPos.Col(), rPos.Row(), nWidth);
}

void ScDocument::EnableUndo( bool bVal )
{
    // The undo manager increases lock count every time undo is disabled.