// This is the SIP interface definition for TQLocale.
//
// Copyright (c) 2007
// 	Riverbank Computing Limited <info@riverbankcomputing.co.uk>
// 
// This file is part of PyTQt.
// 
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
// 
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
// details.
// 
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE.  If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.


%ExportedDoc
<Sect2><Title>TQLocale (TQt v3.3+)</Title>
<FuncSynopsis>
	<FuncDef>short <Function>toShort</Function></FuncDef>
	<ParamDef>bool *<Parameter>ok</Parameter> = 0</ParamDef>
</FuncSynopsis>
<Para>
This returns a tuple of the <Literal>short</Literal> result and the
<Literal>ok</Literal> value.
</Para>

<FuncSynopsis>
	<FuncDef>ushort <Function>toUShort</Function></FuncDef>
	<ParamDef>bool *<Parameter>ok</Parameter> = 0</ParamDef>
</FuncSynopsis>
<Para>
This returns a tuple of the <Literal>ushort</Literal> result and the
<Literal>ok</Literal> value.
</Para>

<FuncSynopsis>
	<FuncDef>int <Function>toInt</Function></FuncDef>
	<ParamDef>bool *<Parameter>ok</Parameter> = 0</ParamDef>
</FuncSynopsis>
<Para>
This returns a tuple of the <Literal>int</Literal> result and the
<Literal>ok</Literal> value.
</Para>

<FuncSynopsis>
	<FuncDef>uint <Function>toUInt</Function></FuncDef>
	<ParamDef>bool *<Parameter>ok</Parameter> = 0</ParamDef>
</FuncSynopsis>
<Para>
This returns a tuple of the <Literal>uint</Literal> result and the
<Literal>ok</Literal> value.
</Para>

<FuncSynopsis>
	<FuncDef>TQ_LONG <Function>toLong</Function></FuncDef>
	<ParamDef>bool *<Parameter>ok</Parameter> = 0</ParamDef>
</FuncSynopsis>
<Para>
This returns a tuple of the <Literal>long</Literal> result and the
<Literal>ok</Literal> value.
</Para>

<FuncSynopsis>
	<FuncDef>TQ_ULONG <Function>toULong</Function></FuncDef>
	<ParamDef>bool *<Parameter>ok</Parameter> = 0</ParamDef>
</FuncSynopsis>
<Para>
This returns a tuple of the <Literal>ulong</Literal> result and the
<Literal>ok</Literal> value.
</Para>

<FuncSynopsis>
	<FuncDef>float <Function>toFloat</Function></FuncDef>
	<ParamDef>bool *<Parameter>ok</Parameter> = 0</ParamDef>
</FuncSynopsis>
<Para>
This returns a tuple of the <Literal>float</Literal> result and the
<Literal>ok</Literal> value.
</Para>

<FuncSynopsis>
	<FuncDef>double <Function>toDouble</Function></FuncDef>
	<ParamDef>bool *<Parameter>ok</Parameter> = 0</ParamDef>
</FuncSynopsis>
<Para>
This returns a tuple of the <Literal>double</Literal> result and the
<Literal>ok</Literal> value.
</Para>
</Sect2>
%End


%If (TQt_3_3_0 -)

class TQLocale
{
%TypeHeaderCode
#include <tqlocale.h>
%End

public:
	enum Language {
		C,
		Abkhazian,
		Afan,
		Afar,
		Afrikaans,
		Albanian,
		Amharic,
		Arabic,
		Armenian,
		Assamese,
		Aymara,
		Azerbaijani,
		Bashkir,
		Basque,
		Bengali,
		Bhutani,
		Bihari,
		Bislama,
		Breton,
		Bulgarian,
		Burmese,
		Byelorussian,
		Cambodian,
		Catalan,
		Chinese,
		Corsican,
		Croatian,
		Czech,
		Danish,
		Dutch,
		English,
		Esperanto,
		Estonian,
		Faroese,
		FijiLanguage,
		Finnish,
		French,
		Frisian,
		Gaelic,
		Galician,
		Georgian,
		German,
		Greek,
		Greenlandic,
		Guarani,
		Gujarati,
		Hausa,
		Hebrew,
		Hindi,
		Hungarian,
		Icelandic,
		Indonesian,
		Interlingua,
		Interlingue,
		Inuktitut,
		Inupiak,
		Irish,
		Italian,
		Japanese,
		Javanese,
		Kannada,
		Kashmiri,
		Kazakh,
		Kinyarwanda,
		Kirghiz,
		Korean,
		Kurdish,
		Kurundi,
		Laothian,
		Latin,
		Latvian,
		Lingala,
		Lithuanian,
		Macedonian,
		Malagasy,
		Malay,
		Malayalam,
		Maltese,
		Maori,
		Marathi,
		Moldavian,
		Mongolian,
		NauruLanguage,
		Nepali,
		Norwegian,
		Occitan,
		Oriya,
		Pashto,
		Persian,
		Polish,
		Portuguese,
		Punjabi,
		Quechua,
		RhaetoRomance,
		Romanian,
		Russian,
		Samoan,
		Sangho,
		Sanskrit,
		Serbian,
		SerboCroatian,
		Sesotho,
		Setswana,
		Shona,
		Sindhi,
		Singhalese,
		Siswati,
		Slovak,
		Slovenian,
		Somali,
		Spanish,
		Sundanese,
		Swahili,
		Swedish,
		Tagalog,
		Tajik,
		Tamil,
		Tatar,
		Telugu,
		Thai,
		Tibetan,
		Tigrinya,
		TongaLanguage,
		Tsonga,
		Turkish,
		Turkmen,
		Twi,
		Uigur,
		Ukrainian,
		Urdu,
		Uzbek,
		Vietnamese,
		Volapuk,
		Welsh,
		Wolof,
		Xhosa,
		Yiddish,
		Yoruba,
		Zhuang,
		Zulu,
		LastLanguage
	};

	enum Country {
		AnyCountry,
		Afghanistan,
		Albania,
		Algeria,
		AmericanSamoa,
		Andorra,
		Angola,
		Anguilla,
		Antarctica,
		AntiguaAndBarbuda,
		Argentina,
		Armenia,
		Aruba,
		Australia,
		Austria,
		Azerbaijan,
		Bahamas,
		Bahrain,
		Bangladesh,
		Barbados,
		Belarus,
		Belgium,
		Belize,
		Benin,
		Bermuda,
		Bhutan,
		Bolivia,
		BosniaAndHerzegowina,
		Botswana,
		BouvetIsland,
		Brazil,
		BritishIndianOceanTerritory,
		BruneiDarussalam,
		Bulgaria,
		BurkinaFaso,
		Burundi,
		Cambodia,
		Cameroon,
		Canada,
		CapeVerde,
		CaymanIslands,
		CentralAfricanRepublic,
		Chad,
		Chile,
		China,
		ChristmasIsland,
		CocosIslands,
		Colombia,
		Comoros,
		DemocraticRepublicOfCongo,
		PeoplesRepublicOfCongo,
		CookIslands,
		CostaRica,
		IvoryCoast,
		Croatia,
		Cuba,
		Cyprus,
		CzechRepublic,
		Denmark,
		Djibouti,
		Dominica,
		DominicanRepublic,
		EastTimor,
		Ecuador,
		Egypt,
		ElSalvador,
		EquatorialGuinea,
		Eritrea,
		Estonia,
		Ethiopia,
		FalklandIslands,
		FaroeIslands,
		FijiCountry,
		Finland,
		France,
		MetropolitanFrance,
		FrenchGuiana,
		FrenchPolynesia,
		FrenchSouthernTerritories,
		Gabon,
		Gambia,
		Georgia,
		Germany,
		Ghana,
		Gibraltar,
		Greece,
		Greenland,
		Grenada,
		Guadeloupe,
		Guam,
		Guatemala,
		Guinea,
		GuineaBissau,
		Guyana,
		Haiti,
		HeardAndMcDonaldIslands,
		Honduras,
		HongKong,
		Hungary,
		Iceland,
		India,
		Indonesia,
		Iran,
		Iraq,
		Ireland,
		Israel,
		Italy,
		Jamaica,
		Japan,
		Jordan,
		Kazakhstan,
		Kenya,
		Kiribati,
		DemocraticRepublicOfKorea,
		RepublicOfKorea,
		Kuwait,
		Kyrgyzstan,
		Lao,
		Latvia,
		Lebanon,
		Lesotho,
		Liberia,
		LibyanArabJamahiriya,
		Liechtenstein,
		Lithuania,
		Luxembourg,
		Macau,
		Macedonia,
		Madagascar,
		Malawi,
		Malaysia,
		Maldives,
		Mali,
		Malta,
		MarshallIslands,
		Martinique,
		Mauritania,
		Mauritius,
		Mayotte,
		Mexico,
		Micronesia,
		Moldova,
		Monaco,
		Mongolia,
		Montserrat,
		Morocco,
		Mozambique,
		Myanmar,
		Namibia,
		NauruCountry,
		Nepal,
		Netherlands,
		NetherlandsAntilles,
		NewCaledonia,
		NewZealand,
		Nicaragua,
		Niger,
		Nigeria,
		Niue,
		NorfolkIsland,
		NorthernMarianaIslands,
		Norway,
		Oman,
		Pakistan,
		Palau,
		PalestinianTerritory,
		Panama,
		PapuaNewGuinea,
		Paraguay,
		Peru,
		Philippines,
		Pitcairn,
		Poland,
		Portugal,
		PuertoRico,
		Qatar,
		Reunion,
		Romania,
		RussianFederation,
		Rwanda,
		SaintKittsAndNevis,
		StLucia,
		StVincentAndTheGrenadines,
		Samoa,
		SanMarino,
		SaoTomeAndPrincipe,
		SaudiArabia,
		Senegal,
		Seychelles,
		SierraLeone,
		Singapore,
		Slovakia,
		Slovenia,
		SolomonIslands,
		Somalia,
		SouthAfrica,
		SouthGeorgiaAndTheSouthSandwichIslands,
		Spain,
		SriLanka,
		StHelena,
		StPierreAndMiquelon,
		Sudan,
		Suriname,
		SvalbardAndJanMayenIslands,
		Swaziland,
		Sweden,
		Switzerland,
		SyrianArabRepublic,
		Taiwan,
		Tajikistan,
		Tanzania,
		Thailand,
		Togo,
		Tokelau,
		TongaCountry,
		TrinidadAndTobago,
		Tunisia,
		Turkey,
		Turkmenistan,
		TurksAndCaicosIslands,
		Tuvalu,
		Uganda,
		Ukraine,
		UnitedArabEmirates,
		UnitedKingdom,
		UnitedStates,
		UnitedStatesMinorOutlyingIslands,
		Uruguay,
		Uzbekistan,
		Vanuatu,
		VaticanCityState,
		Venezuela,
		VietNam,
		BritishVirginIslands,
		USVirginIslands,
		WallisAndFutunaIslands,
		WesternSahara,
		Yemen,
		Yugoslavia,
		Zambia,
		Zimbabwe,
		LastCountry
	};

	TQLocale();
	TQLocale(const TQString &);
	TQLocale(Language,Country = AnyCountry);
	TQLocale(const TQLocale &);

	Language language() const;
	Country country() const;
	TQString name() const;

	short toShort(const TQString &,bool * = 0) const;
	ushort toUShort(const TQString &,bool * = 0) const;
	int toInt(const TQString &,bool * = 0) const;
	uint toUInt(const TQString &,bool * = 0) const;
	TQ_LONG toLong(const TQString &,bool * = 0) const;
	TQ_ULONG toULong(const TQString &,bool * = 0) const;
	//TQ_LLONG toLongLong(const TQString &,bool * = 0) const;
	//TQ_ULLONG toULongLong(const TQString &,bool * = 0) const;
	float toFloat(const TQString &,bool * = 0) const;
	double toDouble(const TQString &,bool * = 0) const;

	//TQString toString(short) const;
	//TQString toString(ushort) const;
	TQString toString(int /Constrained/) const;
	//TQString toString(uint) const;
	//TQString toString(TQ_LONG) const;
	//TQString toString(TQ_ULONG) const;
	//TQString toString(Q_LLONG) const;
	//TQString toString(Q_ULLONG) const;
	//TQString toString(float,char = 'g',int = 6) const;
	TQString toString(double,char = 'g',int = 6) const;

	static TQString languageToString(Language);
	static TQString countryToString(Country);
	static void setDefault(const TQLocale &);

	static TQLocale c();
	static TQLocale system();
};

%End
