summaryrefslogtreecommitdiff
path: root/lotuswordpro
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2011-08-23 00:38:42 +0100
committerCaolán McNamara <caolanm@redhat.com>2011-08-23 10:35:45 +0100
commit050b80a6fc9b6f0c550c5ca20fa3c93e9552c13a (patch)
treeadde9066eb1669bc9df616b839c96ab6070d1b12 /lotuswordpro
parentaf6ce167af13f896e1786ef7d3c2d194aaf1c3dd (diff)
ditch deprecated api
Diffstat (limited to 'lotuswordpro')
-rw-r--r--lotuswordpro/source/filter/lwptblformula.cxx48
-rw-r--r--lotuswordpro/source/filter/lwptblformula.hxx16
2 files changed, 21 insertions, 43 deletions
diff --git a/lotuswordpro/source/filter/lwptblformula.cxx b/lotuswordpro/source/filter/lwptblformula.cxx
index 89c3f840a973..23c207b2aa2b 100644
--- a/lotuswordpro/source/filter/lwptblformula.cxx
+++ b/lotuswordpro/source/filter/lwptblformula.cxx
@@ -68,7 +68,7 @@
#include "lwptblformula.hxx"
#include "lwptablelayout.hxx"
-
+#include <rtl/ustrbuf.hxx>
#include <boost/scoped_array.hpp>
//////////////////////////////////////////////////////////////////
@@ -442,16 +442,9 @@ LwpFormulaConst::LwpFormulaConst(double dVal)
m_dVal = dVal;
}
-/**
-*
-* @date 03/26/2005
-* @param
-* @param
-* @return sal_Bool.
-*/
-String LwpFormulaConst::ToString(LwpTableLayout* /*pCellsMap*/)
+rtl::OUString LwpFormulaConst::ToString(LwpTableLayout* /*pCellsMap*/)
{
- return String::CreateFromDouble(m_dVal);
+ return rtl::OUString::valueOf(m_dVal);
}
/**
@@ -486,14 +479,8 @@ LwpFormulaCellAddr::LwpFormulaCellAddr(sal_Int16 aCol, sal_Int16 aRow)
* @param
* @return String
*/
-String LwpFormulaCellAddr::ToString(LwpTableLayout* pCellsMap)
+rtl::OUString LwpFormulaCellAddr::ToString(LwpTableLayout* pCellsMap)
{
-// String aCellAddr;
-// aCellAddr.AppendAscii("<");//&lt;
-// aCellAddr+=m_aCol;
-// aCellAddr+=m_aRow;
-// aCellAddr.AppendAscii(">");//&gt;
-
String aCellAddr;
aCellAddr.AppendAscii("<");//&lt;
@@ -528,17 +515,8 @@ LwpFormulaCellRangeAddr::LwpFormulaCellRangeAddr(sal_Int16 aStartCol,
* @param
* @return String.
*/
-String LwpFormulaCellRangeAddr::ToString(LwpTableLayout* pCellsMap)
+rtl::OUString LwpFormulaCellRangeAddr::ToString(LwpTableLayout* pCellsMap)
{
-// String aCellAddr;
-// aCellAddr.AppendAscii("<");//&lt;
-// aCellAddr+=m_aStartCol;
-// aCellAddr+=m_aStartRow;
-// aCellAddr.AppendAscii(":");
-// aCellAddr+=m_aEndCol;
-// aCellAddr+=m_aEndRow;
-// aCellAddr.AppendAscii(">");//&gt;
-
String aCellAddr;
aCellAddr.AppendAscii("<");//&lt;
@@ -605,11 +583,11 @@ void LwpFormulaFunc::AddArg(LwpFormulaArg* pArg)
*/
String LwpFormulaFunc::ToArgString(LwpTableLayout* pCellsMap)
{
- String aFormula;
- aFormula.AppendAscii("(");
- aFormula+=ToString(pCellsMap);
- aFormula.AppendAscii(")");
- return aFormula;
+ rtl::OUStringBuffer aFormula;
+ aFormula.append(static_cast<sal_Unicode>('('));
+ aFormula.append(ToString(pCellsMap));
+ aFormula.append(static_cast<sal_Unicode>(')'));
+ return aFormula.makeStringAndClear();
}
/**
* Convert the function to a formula string.
@@ -618,7 +596,7 @@ String LwpFormulaFunc::ToArgString(LwpTableLayout* pCellsMap)
* @param
* @return sal_Bool.
*/
-String LwpFormulaFunc::ToString(LwpTableLayout* pCellsMap)
+rtl::OUString LwpFormulaFunc::ToString(LwpTableLayout* pCellsMap)
{
String aFormula;
@@ -654,7 +632,7 @@ String LwpFormulaFunc::ToString(LwpTableLayout* pCellsMap)
* @param
* @return sal_Bool.
*/
-String LwpFormulaOp::ToString(LwpTableLayout* pCellsMap)
+rtl::OUString LwpFormulaOp::ToString(LwpTableLayout* pCellsMap)
{
String aFormula;
if (2==m_aArgs.size())
@@ -687,7 +665,7 @@ String LwpFormulaOp::ToString(LwpTableLayout* pCellsMap)
* @param
* @return sal_Bool.
*/
-String LwpFormulaUnaryOp::ToString(LwpTableLayout* pCellsMap)
+rtl::OUString LwpFormulaUnaryOp::ToString(LwpTableLayout* pCellsMap)
{
String aFormula;
if (1==m_aArgs.size())
diff --git a/lotuswordpro/source/filter/lwptblformula.hxx b/lotuswordpro/source/filter/lwptblformula.hxx
index 7901e83d939b..648b9266f329 100644
--- a/lotuswordpro/source/filter/lwptblformula.hxx
+++ b/lotuswordpro/source/filter/lwptblformula.hxx
@@ -109,7 +109,7 @@ class LwpTableLayout;
class LwpFormulaArg
{
public:
- virtual String ToString(LwpTableLayout* pCellsMap)=0;
+ virtual rtl::OUString ToString(LwpTableLayout* pCellsMap)=0;
virtual String ToArgString(LwpTableLayout* pCellsMap){ return ToString(pCellsMap);}
};
@@ -124,7 +124,7 @@ class LwpFormulaConst:public LwpFormulaArg
{
public:
LwpFormulaConst( double dVal);
- virtual String ToString(LwpTableLayout* pCellsMap);
+ virtual rtl::OUString ToString(LwpTableLayout* pCellsMap);
private:
double m_dVal;
};
@@ -133,7 +133,7 @@ class LwpFormulaText:public LwpFormulaArg
{
public:
LwpFormulaText( String aText);
- virtual String ToString(LwpTableLayout* /*pCellsMap*/){return m_aText;}
+ virtual rtl::OUString ToString(LwpTableLayout* /*pCellsMap*/){return m_aText;}
private:
String m_aText;
};
@@ -146,7 +146,7 @@ public:
sal_Int16 GetCol(){return m_aCol;}
sal_Int16 GetRow(){return m_aRow;}
- virtual String ToString(LwpTableLayout* pCellsMap);
+ virtual rtl::OUString ToString(LwpTableLayout* pCellsMap);
private:
sal_Int16 m_aCol;
sal_Int16 m_aRow;
@@ -157,7 +157,7 @@ class LwpFormulaCellRangeAddr:public LwpFormulaArg
public:
LwpFormulaCellRangeAddr(sal_Int16 aStartCol, sal_Int16 aStartRow, sal_Int16 aEndCol, sal_Int16 aEndRow);
- virtual String ToString(LwpTableLayout* pCellsMap);
+ virtual rtl::OUString ToString(LwpTableLayout* pCellsMap);
private:
sal_Int16 m_aStartCol;
sal_Int16 m_aStartRow;
@@ -173,7 +173,7 @@ public:
void AddArg(LwpFormulaArg* pArg);
- virtual String ToString(LwpTableLayout* pCellsMap);
+ virtual rtl::OUString ToString(LwpTableLayout* pCellsMap);
String ToArgString(LwpTableLayout* pCellsMap);
protected:
@@ -185,14 +185,14 @@ class LwpFormulaOp : public LwpFormulaFunc
{
public:
LwpFormulaOp(sal_uInt16 nTokenType):LwpFormulaFunc(nTokenType){;}
- String ToString(LwpTableLayout* pCellsMap);
+ virtual rtl::OUString ToString(LwpTableLayout* pCellsMap);
};
class LwpFormulaUnaryOp : public LwpFormulaFunc
{
public:
LwpFormulaUnaryOp(sal_uInt16 nTokenType):LwpFormulaFunc(nTokenType){;}
- String ToString(LwpTableLayout* pCellsMap);
+ virtual rtl::OUString ToString(LwpTableLayout* pCellsMap);
};