/***************************************************************************
                            kde_KLocale.cpp -  description
                             -------------------
    begin                : Tue Mar 19 20:11:49 2002
    copyright            : (C) 2000-2001 Lost Highway Ltd. All rights reserved.
    email                : Lost_Highway@tipitina.demon.co.uk
    generated by         : duke@tipitina on Tue Mar 19 20:11:49 2002, using kalyptus 0.9.
 ***************************************************************************/

/***************************************************************************
 *                                                                         *
 *   This library is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU Library General Public License as       *
 *   published by the Free Software Foundation; either version 2 of the    *
 *   License, or (at your option) any later version.                       *
 *                                                                         *
 ***************************************************************************/

extern "C" {
#include "kde_KLocale.h"
}

#include <klocale.h>
#include <qdatetime.h>
#include <qstringlist.h>

class KLocaleBridge : public KLocale
{
public:
	KLocaleBridge(const QString& catalogue, KConfig* config) : KLocale(catalogue, config) {}
	KLocaleBridge(const KLocale& rhs) : KLocale(rhs) {}
	~KLocaleBridge() {}
	void protected_initInstance() {
		KLocale::initInstance();
		return;
	}
};

kde_KLocale * kde_new_KLocale(qt_QString * catalogue, kde_KConfig* config){
	return (kde_KLocale *) new KLocaleBridge((QString&)* (QString*)catalogue, (KConfig*)config);
}
kde_KLocale * kde_new_KLocale1(kde_KLocale* rhs){
	return (kde_KLocale *) new KLocaleBridge((KLocale&)* (KLocale*)rhs);
}
void kde_del_KLocale( kde_KLocale* p ){
	delete (KLocaleBridge*) p;
}
qt_QString * kde_KLocale_translate( kde_KLocale* instPointer,char* index){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->translate((char*)index));
}
qt_QString * kde_KLocale_translate1( kde_KLocale* instPointer,char* index, char* fallback){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->translate((char*)index, (char*)fallback));
}
qt_QString * kde_KLocale_translate2( kde_KLocale* instPointer,char* singular, char* plural, unsigned long n){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->translate((char*)singular, (char*)plural, (unsigned long)n));
}
//int kde_KLocale_setCharset( kde_KLocale* instPointer,qt_QString * charset){
//	return (int) ((KLocaleBridge*)instPointer)->setCharset((QString&)* (QString*)charset);
//}
int kde_KLocale_setEncoding( kde_KLocale* instPointer,int mibEnum){
	return (int) ((KLocaleBridge*)instPointer)->setEncoding((int)mibEnum);
}
int kde_KLocale_setLanguage( kde_KLocale* instPointer,qt_QString * language){
	return (int) ((KLocaleBridge*)instPointer)->setLanguage((QString&)* (QString*)language);
}
int kde_KLocale_setLanguage1( kde_KLocale* instPointer,qt_QStringList* languages){
	return (int) ((KLocaleBridge*)instPointer)->setLanguage((QStringList&)* (QStringList*)languages);
}
int kde_KLocale_setCountry( kde_KLocale* instPointer,qt_QString * country){
	return (int) ((KLocaleBridge*)instPointer)->setCountry((QString&)* (QString*)country);
}
qt_QString * kde_KLocale_decimalSymbol( kde_KLocale* instPointer){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->decimalSymbol());
}
qt_QString * kde_KLocale_thousandsSeparator( kde_KLocale* instPointer){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->thousandsSeparator());
}
qt_QString * kde_KLocale_currencySymbol( kde_KLocale* instPointer){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->currencySymbol());
}
qt_QString * kde_KLocale_monetaryDecimalSymbol( kde_KLocale* instPointer){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->monetaryDecimalSymbol());
}
qt_QString * kde_KLocale_monetaryThousandsSeparator( kde_KLocale* instPointer){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->monetaryThousandsSeparator());
}
qt_QString * kde_KLocale_positiveSign( kde_KLocale* instPointer){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->positiveSign());
}
qt_QString * kde_KLocale_negativeSign( kde_KLocale* instPointer){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->negativeSign());
}
int kde_KLocale_fracDigits( kde_KLocale* instPointer){
	return (int) ((KLocaleBridge*)instPointer)->fracDigits();
}
int kde_KLocale_positivePrefixCurrencySymbol( kde_KLocale* instPointer){
	return (int) ((KLocaleBridge*)instPointer)->positivePrefixCurrencySymbol();
}
int kde_KLocale_negativePrefixCurrencySymbol( kde_KLocale* instPointer){
	return (int) ((KLocaleBridge*)instPointer)->negativePrefixCurrencySymbol();
}
int kde_KLocale_positiveMonetarySignPosition( kde_KLocale* instPointer){
	return (int) ((KLocaleBridge*)instPointer)->positiveMonetarySignPosition();
}
int kde_KLocale_negativeMonetarySignPosition( kde_KLocale* instPointer){
	return (int) ((KLocaleBridge*)instPointer)->negativeMonetarySignPosition();
}
qt_QString * kde_KLocale_formatMoney( kde_KLocale* instPointer,double num, qt_QString * currency, int digits){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->formatMoney((double)num, (QString&)* (QString*)currency, (int)digits));
}
qt_QString * kde_KLocale_formatMoney1( kde_KLocale* instPointer,qt_QString * numStr){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->formatMoney((QString&)* (QString*)numStr));
}
qt_QString * kde_KLocale_formatNumber( kde_KLocale* instPointer,double num, int precision){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->formatNumber((double)num, (int)precision));
}
qt_QString * kde_KLocale_formatNumber1( kde_KLocale* instPointer,qt_QString * numStr){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->formatNumber((QString&)* (QString*)numStr));
}
qt_QString * kde_KLocale_formatDate( kde_KLocale* instPointer,qt_QDate * pDate, int shortFormat){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->formatDate((QDate&)* (QDate*)pDate, (bool)shortFormat));
}
qt_QString * kde_KLocale_formatTime( kde_KLocale* instPointer,qt_QTime * pTime, int includeSecs){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->formatTime((QTime&)* (QTime*)pTime, (bool)includeSecs));
}
int kde_KLocale_use12Clock( kde_KLocale* instPointer){
	return (int) ((KLocaleBridge*)instPointer)->use12Clock();
}
int kde_KLocale_weekStartsMonday( kde_KLocale* instPointer){
	return (int) ((KLocaleBridge*)instPointer)->weekStartsMonday();
}
qt_QString * kde_KLocale_monthName( kde_KLocale* instPointer,int i, int shortName){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->monthName((int)i, (bool)shortName));
}
qt_QString * kde_KLocale_weekDayName( kde_KLocale* instPointer,int i, int shortName){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->weekDayName((int)i, (bool)shortName));
}
qt_QString * kde_KLocale_formatDateTime( kde_KLocale* instPointer,qt_QDateTime * pDateTime, int shortFormat, int includeSecs){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->formatDateTime((QDateTime&)* (QDateTime*)pDateTime, (bool)shortFormat, (bool)includeSecs));
}
double kde_KLocale_readMoney( kde_KLocale* instPointer,qt_QString * numStr, int* ok){
	return (double) ((KLocaleBridge*)instPointer)->readMoney((QString&)* (QString*)numStr, (bool*)ok);
}
double kde_KLocale_readNumber( kde_KLocale* instPointer,qt_QString * numStr, int* ok){
	return (double) ((KLocaleBridge*)instPointer)->readNumber((QString&)* (QString*)numStr, (bool*)ok);
}
qt_QDate * kde_KLocale_readDate( kde_KLocale* instPointer,qt_QString * str, int* ok){
	QDate _d= ((KLocaleBridge*)instPointer)->readDate((QString&)* (QString*)str, (bool*)ok);
	return (qt_QDate *)new QDate(_d.year(),_d.month(),_d.day());
}
qt_QDate * kde_KLocale_readDate1( kde_KLocale* instPointer,qt_QString * intstr, qt_QString * fmt, int* ok){
	QDate _d= ((KLocaleBridge*)instPointer)->readDate((QString&)* (QString*)intstr, (QString&)* (QString*)fmt, (bool*)ok);
	return (qt_QDate *)new QDate(_d.year(),_d.month(),_d.day());
}
qt_QTime * kde_KLocale_readTime( kde_KLocale* instPointer,qt_QString * str, int* ok){
	QTime _t= ((KLocaleBridge*)instPointer)->readTime((QString&)* (QString*)str, (bool*)ok);
	return (qt_QTime *)new QTime(_t.hour(),_t.minute(),_t.second(),_t.msec());
}
qt_QString * kde_KLocale_language( kde_KLocale* instPointer){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->language());
}
qt_QString * kde_KLocale_country( kde_KLocale* instPointer){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->country());
}
qt_QString * kde_KLocale_languages( kde_KLocale* instPointer){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->languages());
}
qt_QStringList* kde_KLocale_languagesTwoAlpha( kde_KLocale* instPointer){
	return (qt_QStringList*)new QStringList(((KLocaleBridge*)instPointer)->languagesTwoAlpha());
}
qt_QStringList* kde_KLocale_languageList( kde_KLocale* instPointer){
	return (qt_QStringList*)new QStringList(((KLocaleBridge*)instPointer)->languageList());
}
//qt_QString * kde_KLocale_charset( kde_KLocale* instPointer){
//	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->charset());
//}
char* kde_KLocale_encoding( kde_KLocale* instPointer){
	return (char*) ((KLocaleBridge*)instPointer)->encoding();
}
int kde_KLocale_encodingMib( kde_KLocale* instPointer){
	return (int) ((KLocaleBridge*)instPointer)->encodingMib();
}
qt_QTextCodec* kde_KLocale_codecForEncoding( kde_KLocale* instPointer){
	return (qt_QTextCodec*) ((KLocaleBridge*)instPointer)->codecForEncoding();
}
void kde_KLocale_setDateFormat( kde_KLocale* instPointer,qt_QString * format){
	((KLocaleBridge*)instPointer)->setDateFormat((QString&)* (QString*)format);
	return;
}
void kde_KLocale_setDateFormatShort( kde_KLocale* instPointer,qt_QString * format){
	((KLocaleBridge*)instPointer)->setDateFormatShort((QString&)* (QString*)format);
	return;
}
void kde_KLocale_setTimeFormat( kde_KLocale* instPointer,qt_QString * format){
	((KLocaleBridge*)instPointer)->setTimeFormat((QString&)* (QString*)format);
	return;
}
void kde_KLocale_setWeekStartsMonday( kde_KLocale* instPointer,int start){
	((KLocaleBridge*)instPointer)->setWeekStartsMonday((bool)start);
	return;
}
qt_QString * kde_KLocale_dateFormat( kde_KLocale* instPointer){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->dateFormat());
}
qt_QString * kde_KLocale_dateFormatShort( kde_KLocale* instPointer){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->dateFormatShort());
}
qt_QString * kde_KLocale_timeFormat( kde_KLocale* instPointer){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->timeFormat());
}
void kde_KLocale_setDecimalSymbol( kde_KLocale* instPointer,qt_QString * symbol){
	((KLocaleBridge*)instPointer)->setDecimalSymbol((QString&)* (QString*)symbol);
	return;
}
void kde_KLocale_setThousandsSeparator( kde_KLocale* instPointer,qt_QString * separator){
	((KLocaleBridge*)instPointer)->setThousandsSeparator((QString&)* (QString*)separator);
	return;
}
void kde_KLocale_setPositiveSign( kde_KLocale* instPointer,qt_QString * sign){
	((KLocaleBridge*)instPointer)->setPositiveSign((QString&)* (QString*)sign);
	return;
}
void kde_KLocale_setNegativeSign( kde_KLocale* instPointer,qt_QString * sign){
	((KLocaleBridge*)instPointer)->setNegativeSign((QString&)* (QString*)sign);
	return;
}
void kde_KLocale_setPositiveMonetarySignPosition( kde_KLocale* instPointer,int signpos){
	((KLocaleBridge*)instPointer)->setPositiveMonetarySignPosition((KLocale::SignPosition)signpos);
	return;
}
void kde_KLocale_setNegativeMonetarySignPosition( kde_KLocale* instPointer,int signpos){
	((KLocaleBridge*)instPointer)->setNegativeMonetarySignPosition((KLocale::SignPosition)signpos);
	return;
}
void kde_KLocale_setPositivePrefixCurrencySymbol( kde_KLocale* instPointer,int prefix){
	((KLocaleBridge*)instPointer)->setPositivePrefixCurrencySymbol((bool)prefix);
	return;
}
void kde_KLocale_setNegativePrefixCurrencySymbol( kde_KLocale* instPointer,int prefix){
	((KLocaleBridge*)instPointer)->setNegativePrefixCurrencySymbol((bool)prefix);
	return;
}
void kde_KLocale_setFracDigits( kde_KLocale* instPointer,int digits){
	((KLocaleBridge*)instPointer)->setFracDigits((int)digits);
	return;
}
void kde_KLocale_setMonetaryThousandsSeparator( kde_KLocale* instPointer,qt_QString * separator){
	((KLocaleBridge*)instPointer)->setMonetaryThousandsSeparator((QString&)* (QString*)separator);
	return;
}
void kde_KLocale_setMonetaryDecimalSymbol( kde_KLocale* instPointer,qt_QString * symbol){
	((KLocaleBridge*)instPointer)->setMonetaryDecimalSymbol((QString&)* (QString*)symbol);
	return;
}
void kde_KLocale_setCurrencySymbol( kde_KLocale* instPointer,qt_QString * symbol){
	((KLocaleBridge*)instPointer)->setCurrencySymbol((QString&)* (QString*)symbol);
	return;
}
int kde_KLocale_pageSize( kde_KLocale* instPointer){
	return (int) ((KLocaleBridge*)instPointer)->pageSize();
}
void kde_KLocale_setPageSize( kde_KLocale* instPointer,int paperFormat){
	((KLocaleBridge*)instPointer)->setPageSize((int)paperFormat);
	return;
}
int kde_KLocale_measureSystem( kde_KLocale* instPointer){
	return (int) ((KLocaleBridge*)instPointer)->measureSystem();
}
void kde_KLocale_setMeasureSystem( kde_KLocale* instPointer,int value){
	((KLocaleBridge*)instPointer)->setMeasureSystem((KLocale::MeasureSystem)value);
	return;
}
void kde_KLocale_insertCatalogue( kde_KLocale* instPointer,qt_QString * catalogue){
	((KLocaleBridge*)instPointer)->insertCatalogue((QString&)* (QString*)catalogue);
	return;
}
void kde_KLocale_removeCatalogue( kde_KLocale* instPointer,qt_QString * catalogue){
	((KLocaleBridge*)instPointer)->removeCatalogue((QString&)* (QString*)catalogue);
	return;
}
void kde_KLocale_setActiveCatalogue( kde_KLocale* instPointer,qt_QString * catalogue){
	((KLocaleBridge*)instPointer)->setActiveCatalogue((QString&)* (QString*)catalogue);
	return;
}
qt_QString * kde_KLocale_translateQt( kde_KLocale* instPointer,char* context, char* sourceText, char* message){
	return (qt_QString *)new QString(((KLocaleBridge*)instPointer)->translateQt((char*)context, (char*)sourceText, (char*)message));
}
void kde_KLocale_splitLocale( qt_QString * str, qt_QString * language, qt_QString * country, qt_QString * charset){
	KLocaleBridge::splitLocale((QString&)* (QString*)str, (QString&)* (QString*)language, (QString&)* (QString*)country, (QString&)* (QString*)charset);
	return;
}
void kde_KLocale_setMainCatalogue( char* catalogue){
	KLocaleBridge::setMainCatalogue((char*)catalogue);
	return;
}
qt_QString * kde_KLocale_langLookup( qt_QString * fname, char* rtype){
	return (qt_QString *)new QString(KLocaleBridge::langLookup((QString&)* (QString*)fname, (char*)rtype));
}
qt_QString * kde_KLocale_defaultLanguage( ){
	return (qt_QString *)new QString(KLocaleBridge::defaultLanguage());
}
qt_QString * kde_KLocale_defaultCountry( ){
	return (qt_QString *)new QString(KLocaleBridge::defaultCountry());
}
//void kde_KLocale_initInstance( ){
//	KLocaleBridge::protected_initInstance();
//	return;
//}
