diff options
Diffstat (limited to 'kspread')
-rw-r--r-- | kspread/dialogs/kspread_dlg_layout.h | 2 | ||||
-rw-r--r-- | kspread/dialogs/kspread_dlg_preference.cc | 6 | ||||
-rw-r--r-- | kspread/dialogs/kspread_dlg_preference.h | 2 | ||||
-rw-r--r-- | kspread/formula.cc | 6 | ||||
-rw-r--r-- | kspread/formula.h | 4 | ||||
-rw-r--r-- | kspread/kspread_cell.cc | 6 | ||||
-rw-r--r-- | kspread/kspread_cell.h | 4 | ||||
-rw-r--r-- | kspread/kspread_doc.cc | 4 | ||||
-rw-r--r-- | kspread/kspread_doc.h | 2 | ||||
-rw-r--r-- | kspread/kspread_format.h | 2 | ||||
-rw-r--r-- | kspread/kspread_functions_text.cc | 6 | ||||
-rw-r--r-- | kspread/kspread_locale.cc | 4 | ||||
-rw-r--r-- | kspread/kspread_locale.h | 2 | ||||
-rw-r--r-- | kspread/kspread_numformat.cc | 6 | ||||
-rw-r--r-- | kspread/kspread_util.cc | 4 | ||||
-rw-r--r-- | kspread/kspread_util.h | 6 | ||||
-rw-r--r-- | kspread/tests/formula_tester.cc | 2 | ||||
-rw-r--r-- | kspread/valueconverter.cc | 2 | ||||
-rw-r--r-- | kspread/valueconverter.h | 4 | ||||
-rw-r--r-- | kspread/valueparser.cc | 10 | ||||
-rw-r--r-- | kspread/valueparser.h | 8 |
21 files changed, 46 insertions, 46 deletions
diff --git a/kspread/dialogs/kspread_dlg_layout.h b/kspread/dialogs/kspread_dlg_layout.h index 03c8486b..657850c7 100644 --- a/kspread/dialogs/kspread_dlg_layout.h +++ b/kspread/dialogs/kspread_dlg_layout.h @@ -518,7 +518,7 @@ public: bool isSingleCell() { return ( left == right && top == bottom ); } bool checkCircle( TQString const & name, TQString const & parent ); - KLocale * locale() const { return m_pView->doc()->locale(); } + TDELocale * locale() const { return m_pView->doc()->locale(); } struct CellBorderFormat diff --git a/kspread/dialogs/kspread_dlg_preference.cc b/kspread/dialogs/kspread_dlg_preference.cc index b26e2816..a14312d2 100644 --- a/kspread/dialogs/kspread_dlg_preference.cc +++ b/kspread/dialogs/kspread_dlg_preference.cc @@ -157,7 +157,7 @@ parameterLocale::parameterLocale( View* _view, TQVBox *box , char *name ) m_bUpdateLocale=false; TQGroupBox* tmpTQGroupBox = new TQVGroupBox( i18n("Settings"), box, "GroupBox" ); - KLocale* locale=_view->doc()->locale(); + TDELocale* locale=_view->doc()->locale(); m_language=new TQLabel( tmpTQGroupBox,"label"); m_number=new TQLabel( tmpTQGroupBox,"label6"); @@ -186,11 +186,11 @@ void parameterLocale::updateDefaultSystemConfig() { m_bUpdateLocale=true; static_cast<Locale*>(m_pView->doc()->locale())->defaultSystemConfig( ); - KLocale* locale=m_pView->doc()->locale(); + TDELocale* locale=m_pView->doc()->locale(); updateToMatchLocale( locale ); } -void parameterLocale::updateToMatchLocale(KLocale* locale) +void parameterLocale::updateToMatchLocale(TDELocale* locale) { m_language->setText( i18n("Language: %1").arg( locale->language() )); m_number->setText( i18n("Default number format: %1").arg( locale->formatNumber(12.55) )); diff --git a/kspread/dialogs/kspread_dlg_preference.h b/kspread/dialogs/kspread_dlg_preference.h index bdd2af09..484f26a2 100644 --- a/kspread/dialogs/kspread_dlg_preference.h +++ b/kspread/dialogs/kspread_dlg_preference.h @@ -57,7 +57,7 @@ public slots: /** * Updates the GUI widgets to match the specified locale. */ - void updateToMatchLocale(KLocale* locale); + void updateToMatchLocale(TDELocale* locale); TQLabel *m_shortDate,*m_time,*m_money,*m_date,*m_language,*m_number; TQPushButton *m_updateButton; diff --git a/kspread/formula.cc b/kspread/formula.cc index 45cf8d02..b357151b 100644 --- a/kspread/formula.cc +++ b/kspread/formula.cc @@ -425,7 +425,7 @@ bool Formula::isValid() const { if( d->dirty ) { - KLocale* locale = d->cell ? d->cell->locale() : 0; + TDELocale* locale = d->cell ? d->cell->locale() : 0; if ((!locale) && d->sheet) locale = d->sheet->doc()->locale(); Tokens tokens = scan( d->expression, locale ); @@ -455,13 +455,13 @@ void Formula::clear() Tokens Formula::tokens() const { - KLocale* locale = d->cell ? d->cell->locale() : 0; + TDELocale* locale = d->cell ? d->cell->locale() : 0; if ((!locale) && d->sheet) locale = d->sheet->doc()->locale(); return scan( d->expression, locale ); } -Tokens Formula::scan( const TQString& expr, KLocale* locale ) const +Tokens Formula::scan( const TQString& expr, TDELocale* locale ) const { // to hold the result Tokens tokens; diff --git a/kspread/formula.h b/kspread/formula.h index 8ece47c5..18b1d176 100644 --- a/kspread/formula.h +++ b/kspread/formula.h @@ -23,7 +23,7 @@ #include <tqstring.h> #include <tqvaluevector.h> -class KLocale; +class TDELocale; namespace KSpread { @@ -304,7 +304,7 @@ class Formula * If the expression contains error (e.g. unknown operator, string no terminated) * this function returns tokens which is not valid. */ - Tokens scan( const TQString& expr, KLocale* locale = 0 ) const; + Tokens scan( const TQString& expr, TDELocale* locale = 0 ) const; TQString dump() const; diff --git a/kspread/kspread_cell.cc b/kspread/kspread_cell.cc index 7e2d85cd..d8799d9f 100644 --- a/kspread/kspread_cell.cc +++ b/kspread/kspread_cell.cc @@ -404,7 +404,7 @@ TQString Cell::columnName() const return columnName( d->column ); } -KLocale* Cell::locale() const +TDELocale* Cell::locale() const { return d->format->sheet()->doc()->locale(); } @@ -6814,9 +6814,9 @@ bool Cell::loadCellData(const TQDomElement & text, Paste::Operation op ) kdWarning(36001) << "Couldn't parse '" << t << "' as number." << endl; } /* We will need to localize the text version of the number */ - KLocale* locale = format()->sheet()->doc()->locale(); + TDELocale* locale = format()->sheet()->doc()->locale(); - /* KLocale::formatNumber requires the precision we want to return. + /* TDELocale::formatNumber requires the precision we want to return. */ int precision = t.length() - t.find('.') - 1; diff --git a/kspread/kspread_cell.h b/kspread/kspread_cell.h index fd100c45..588ae12d 100644 --- a/kspread/kspread_cell.h +++ b/kspread/kspread_cell.h @@ -41,7 +41,7 @@ #include "kspread_condition.h" -class KLocale; +class TDELocale; class TQDomElement; class TQDomDocument; class KoXmlWriter; @@ -211,7 +211,7 @@ public: /** * Returns the locale setting of this cell. */ - KLocale* locale() const; + TDELocale* locale() const; /** * Returns true if this cell holds a formula. */ diff --git a/kspread/kspread_doc.cc b/kspread/kspread_doc.cc index 09611b95..6b11b6da 100644 --- a/kspread/kspread_doc.cc +++ b/kspread/kspread_doc.cc @@ -95,7 +95,7 @@ class Doc::Private public: Map *map; - KLocale *locale; + TDELocale *locale; StyleManager *styleManager; ValueParser *parser; ValueFormatter *formatter; @@ -395,7 +395,7 @@ void Doc::initEmpty() KoDocument::initEmpty(); } -KLocale *Doc::locale () const +TDELocale *Doc::locale () const { return d->locale; } diff --git a/kspread/kspread_doc.h b/kspread/kspread_doc.h index 40a6e48c..f734d6fb 100644 --- a/kspread/kspread_doc.h +++ b/kspread/kspread_doc.h @@ -151,7 +151,7 @@ public: */ virtual TQCString mimeType() const { return MIME_TYPE; } - KLocale *locale () const; + TDELocale *locale () const; Map *map () const; StyleManager *styleManager () const; ValueParser *parser () const; diff --git a/kspread/kspread_format.h b/kspread/kspread_format.h index 41e3f0ae..5af772b8 100644 --- a/kspread/kspread_format.h +++ b/kspread/kspread_format.h @@ -34,7 +34,7 @@ class TQDomElement; class TQDomDocument; class DCOPObject; -class KLocale; +class TDELocale; class KoGenStyle; class KoGenStyles; class KoOasisLoadingContext; diff --git a/kspread/kspread_functions_text.cc b/kspread/kspread_functions_text.cc index e61aff93..432bfc28 100644 --- a/kspread/kspread_functions_text.cc +++ b/kspread/kspread_functions_text.cc @@ -252,7 +252,7 @@ Value func_dollar (valVector args, ValueCalc *calc, FuncExtra *) // do round, because formatMoney doesn't value = floor (value * pow (10.0, precision) + 0.5) / pow (10.0, precision); - KLocale *locale = calc->conv()->locale(); + TDELocale *locale = calc->conv()->locale(); TQString s = locale->formatMoney (value, locale->currencySymbol(), precision); return Value (s); @@ -303,9 +303,9 @@ Value func_fixed (valVector args, ValueCalc *calc, FuncExtra *) no_commas = calc->conv()->asBoolean (args[2]).asBoolean(); TQString result; - KLocale *locale = calc->conv()->locale(); + TDELocale *locale = calc->conv()->locale(); - // unfortunately, we can't just use KLocale::formatNumber because + // unfortunately, we can't just use TDELocale::formatNumber because // * if decimals < 0, number is rounded // * if no_commas is true, thousand separators shouldn't show up diff --git a/kspread/kspread_locale.cc b/kspread/kspread_locale.cc index fbbfbfbf..fc665f0a 100644 --- a/kspread/kspread_locale.cc +++ b/kspread/kspread_locale.cc @@ -5,7 +5,7 @@ using namespace KSpread; Locale::Locale() - : KLocale("kspread") + : TDELocale("kspread") { insertCatalogue("koffice"); } @@ -84,7 +84,7 @@ TQDomElement Locale::save( TQDomDocument& doc ) const void Locale::defaultSystemConfig( ) { - KLocale locale("kspread"); + TDELocale locale("kspread"); setWeekStartDay( locale.weekStartDay() ); setDecimalSymbol( locale.decimalSymbol()); setThousandsSeparator( locale.thousandsSeparator() ); diff --git a/kspread/kspread_locale.h b/kspread/kspread_locale.h index 7b3041e7..12081731 100644 --- a/kspread/kspread_locale.h +++ b/kspread/kspread_locale.h @@ -9,7 +9,7 @@ class TQDomDocument; namespace KSpread { -class Locale : public KLocale +class Locale : public TDELocale { public: Locale(); diff --git a/kspread/kspread_numformat.cc b/kspread/kspread_numformat.cc index 906086f9..769aa61a 100644 --- a/kspread/kspread_numformat.cc +++ b/kspread/kspread_numformat.cc @@ -253,7 +253,7 @@ void resetGlobals() g_convertionInfo.ampm = false; } -void initGlobals( KLocale const * const locale ) +void initGlobals( TDELocale const * const locale ) { g_Monday = locale->calendar()->weekDayName( 1, false ); g_Tuesday = locale->calendar()->weekDayName( 2, false ); @@ -438,7 +438,7 @@ void createScientificStruct( BaseFormat * data, TQString const & format, bool in } -int doPreScan( TQString & format, TQString const & formatBack, KLocale const * const /* locale */, +int doPreScan( TQString & format, TQString const & formatBack, TDELocale const * const /* locale */, bool insert, BaseFormat * data ) { int type = g_formatStore.getType( format, data ); @@ -1571,7 +1571,7 @@ void createDateTime( TQString & result, Value const & value, } TQString formatNumber( Value const & value, TQString format, bool & setRed, - KLocale const * const locale, bool insert ) + TDELocale const * const locale, bool insert ) { // need delocalized strings: dcSymbol: '.', thSymbol = ',' if ( !g_init ) diff --git a/kspread/kspread_util.cc b/kspread/kspread_util.cc index 81761bad..3950c5b9 100644 --- a/kspread/kspread_util.cc +++ b/kspread/kspread_util.cc @@ -1015,7 +1015,7 @@ bool KSpread::localReferenceAnchor( const TQString &_ref ) } -TQString KSpread::Oasis::decodeFormula(const TQString& expr, const KLocale* locale) +TQString KSpread::Oasis::decodeFormula(const TQString& expr, const TDELocale* locale) { // parsing state enum { Start, InNumber, InString, InIdentifier, InReference, InSheetName } state; @@ -1208,7 +1208,7 @@ TQString KSpread::Oasis::decodeFormula(const TQString& expr, const KLocale* loca return result; } -/*TQString KSpread::Oasis::encodeFormula(const TQString& expr, const KLocale* locale) +/*TQString KSpread::Oasis::encodeFormula(const TQString& expr, const TDELocale* locale) { // TODO move Cell::convertFormulaToOasisFormat to this point //expr = "not here yet"; diff --git a/kspread/kspread_util.h b/kspread/kspread_util.h index fc39708b..ad5227f8 100644 --- a/kspread/kspread_util.h +++ b/kspread/kspread_util.h @@ -35,7 +35,7 @@ class TQPen; class TQDomElement; class TQDomDocument; -class KLocale; +class TDELocale; bool util_isPointValid(TQPoint point); bool util_isRectValid(TQRect rect); @@ -340,14 +340,14 @@ namespace Oasis * @param locale The locale to which the expression should be converted. */ // TODO check visibility - KSPREAD_EXPORT TQString decodeFormula(const TQString& expr, const KLocale* locale = 0); + KSPREAD_EXPORT TQString decodeFormula(const TQString& expr, const TDELocale* locale = 0); /** * Converts a localized formula/cell reference to an OpenDocument * representation of a formula/cell reference. * @param expr The expression to convert to OpenDocument format. * @param locale The locale from which the expression should be converted. */ - KSPREAD_EXPORT TQString encodeFormula(const TQString& expr, const KLocale* locale = 0); + KSPREAD_EXPORT TQString encodeFormula(const TQString& expr, const TDELocale* locale = 0); } } // namespace KSpread diff --git a/kspread/tests/formula_tester.cc b/kspread/tests/formula_tester.cc index 19a70d61..97993c82 100644 --- a/kspread/tests/formula_tester.cc +++ b/kspread/tests/formula_tester.cc @@ -414,7 +414,7 @@ void FormulaOasisConversionTester::checkOasis( const char *file, int line, const { testCount++; - KLocale locale("en_US"); + TDELocale locale("en_US"); locale.setDecimalSymbol(","); // KSpread -> OpenDocument diff --git a/kspread/valueconverter.cc b/kspread/valueconverter.cc index cd649c36..21cb7531 100644 --- a/kspread/valueconverter.cc +++ b/kspread/valueconverter.cc @@ -28,7 +28,7 @@ ValueConverter::ValueConverter (ValueParser* p) : parser( p ) { } -KLocale* ValueConverter::locale() +TDELocale* ValueConverter::locale() { return parser->locale(); } diff --git a/kspread/valueconverter.h b/kspread/valueconverter.h index 367d08ae..3657aeec 100644 --- a/kspread/valueconverter.h +++ b/kspread/valueconverter.h @@ -20,7 +20,7 @@ #ifndef KSPREAD_VALUECONVERTER #define KSPREAD_VALUECONVERTER -class KLocale; +class TDELocale; #include "kspread_value.h" @@ -48,7 +48,7 @@ class ValueConverter { Value asDate (const Value &value) const; Value asTime (const Value &value) const; - KLocale* locale(); + TDELocale* locale(); private: ValueParser *parser; diff --git a/kspread/valueparser.cc b/kspread/valueparser.cc index ff5b4b8c..08ebe628 100644 --- a/kspread/valueparser.cc +++ b/kspread/valueparser.cc @@ -27,11 +27,11 @@ using namespace KSpread; -ValueParser::ValueParser( KLocale* locale ) : parserLocale( locale ) +ValueParser::ValueParser( TDELocale* locale ) : parserLocale( locale ) { } -KLocale* ValueParser::locale() +TDELocale* ValueParser::locale() { return parserLocale; } @@ -364,7 +364,7 @@ Value ValueParser::tryParseDate (const TQString& str, bool *ok) { // Note: if shortdate format only specifies 2 digits year, then 3/4/1955 // will be treated as in year 3055, while 3/4/55 as year 2055 - // (because 55 < 69, see KLocale) and thus there's no way to enter for + // (because 55 < 69, see TDELocale) and thus there's no way to enter for // year 1995 // The following fixes the problem, 3/4/1955 will always be 1955 @@ -374,11 +374,11 @@ Value ValueParser::tryParseDate (const TQString& str, bool *ok) tmpDate = tmpDate.addYears( -1900 ); // this is another HACK ! - // with two digit years, 0-69 is treated as year 2000-2069 (see KLocale) + // with two digit years, 0-69 is treated as year 2000-2069 (see TDELocale) // however, in Excel only 0-29 is year 2000-2029, 30 or later is 1930 // onwards - // the following provides workaround for KLocale so we're compatible + // the following provides workaround for TDELocale so we're compatible // with Excel // (e.g 3/4/45 is Mar 4, 1945 not Mar 4, 2045) if( ( tmpDate.year() >= 2030 ) && ( tmpDate.year() <= 2069 ) ) diff --git a/kspread/valueparser.h b/kspread/valueparser.h index 120c2734..0d00aa49 100644 --- a/kspread/valueparser.h +++ b/kspread/valueparser.h @@ -25,7 +25,7 @@ #include "kspread_global.h" -class KLocale; +class TDELocale; namespace KSpread { @@ -40,9 +40,9 @@ Value in the desired format. class ValueParser { public: /** constructor */ - ValueParser (KLocale *locale); + ValueParser (TDELocale *locale); - KLocale* locale(); + TDELocale* locale(); /** try to parse the text in a given cell and set value accordingly */ void parse (const TQString& str, Cell *cell); @@ -56,7 +56,7 @@ class ValueParser { Value tryParseTime (const TQString& str, bool *ok = 0); protected: - KLocale* parserLocale; + TDELocale* parserLocale; // Try to parse the text as a bool/number/date/time/etc. // Helpers for parse. |