#ifndef _Encodings_h #define _Encodings_h /* * subtitle editor * * http://kitone.free.fr/subtitleeditor/ * * Copyright @ 2005-2006, kitone * * Contact: kitone at free dot fr * * This program 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 of the License, or (at your option) any later version. * * This program is distributed 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 this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * * See gpl.txt for more information regarding the GNU General Public License. * * * \file * \brief * \author kitone (kitone at free dot fr) */ #include "utility.h" struct EncodingInfo { gchar *charset; gchar *name; }; static EncodingInfo encodings_info [] = { { "ISO-8859-1", N_("Western") }, { "ISO-8859-2", N_("Central European") }, { "ISO-8859-3", N_("South European") }, { "ISO-8859-4", N_("Baltic") }, { "ISO-8859-5", N_("Cyrillic") }, { "ISO-8859-6", N_("Arabic") }, { "ISO-8859-7", N_("Greek") }, { "ISO-8859-8", N_("Hebrew Visual") }, { "ISO-8859-8-I", N_("Hebrew") }, { "ISO-8859-9", N_("Turkish") }, { "ISO-8859-10", N_("Nordic") }, { "ISO-8859-13", N_("Baltic") }, { "ISO-8859-14", N_("Celtic") }, { "ISO-8859-15", N_("Western") }, { "ISO-8859-16", N_("Romanian") }, { "UTF-8", N_("Unicode") }, { "UTF-7", N_("Unicode") }, { "UTF-16", N_("Unicode") }, { "UCS-2", N_("Unicode") }, { "UCS-4", N_("Unicode") }, { "ARMSCII-8", N_("Armenian") }, { "BIG5", N_("Chinese Traditional") }, { "BIG5-HKSCS", N_("Chinese Traditional") }, { "CP866", N_("Cyrillic/Russian") }, { "EUC-JP", N_("Japanese") }, { "EUC-KR", N_("Korean") }, { "EUC-TW", N_("Chinese Traditional") }, { "GB18030", N_("Chinese Simplified") }, { "GB2312", N_("Chinese Simplified") }, { "GBK", N_("Chinese Simplified") }, { "GEORGIAN-ACADEMY", N_("Georgian") }, { "HZ", N_("Chinese Simplified") }, { "IBM850", N_("Western") }, { "IBM852", N_("Central European") }, { "IBM855", N_("Cyrillic") }, { "IBM857", N_("Turkish") }, { "IBM862", N_("Hebrew") }, { "IBM864", N_("Arabic") }, { "ISO2022JP", N_("Japanese") }, { "ISO2022KR", N_("Korean") }, { "ISO-IR-111", N_("Cyrillic") }, { "JOHAB", N_("Korean") }, { "KOI8R", N_("Cyrillic") }, { "KOI8U", N_("Cyrillic/Ukrainian") }, { "SHIFT_JIS", N_("Japanese") }, { "TCVN", N_("Vietnamese") }, { "TIS-620", N_("Thai") }, { "UHC", N_("Korean") }, { "VISCII", N_("Vietnamese") }, { "WINDOWS-1250", N_("Central European") }, { "WINDOWS-1251", N_("Cyrillic") }, { "WINDOWS-1252", N_("Western") }, { "WINDOWS-1253", N_("Greek") }, { "WINDOWS-1254", N_("Turkish") }, { "WINDOWS-1255", N_("Hebrew") }, { "WINDOWS-1256", N_("Arabic") }, { "WINDOWS-1257", N_("Baltic") }, { "WINDOWS-1258", N_("Vietnamese") }, { NULL, NULL} }; class Encodings { public: static EncodingInfo* get_from_charset(const Glib::ustring &charset); static EncodingInfo* get_from_index(unsigned int id); protected: static bool is_initialized; static bool initialize(); }; #endif//_Encodings_h