mirror of
https://github.com/OpenMW/openmw.git
synced 2025-06-25 15:41:37 +00:00
Added new command line option: "encoding"
Added new command line option: "encoding" which allow to change font encoding used in game messages. Currently there are three evailable encodings: win1250 - Central and Eastern European (languages that use Latin script, such as Polish, Czech, Slovak, Hungarian, Slovene, Bosnian, Croatian, Serbian (Latin script), Romanian and Albanian) win1251 - languages that use the Cyrillic alphabet such as Russian, Bulgarian, Serbian Cyrillic and others win1252 - Western European (Latin) - default Signed-off-by: Lukasz Gromanowski <lgromanowski@gmail.com>
This commit is contained in:
parent
aded4608c0
commit
ac9b1715d5
12 changed files with 635 additions and 14 deletions
|
@ -370,7 +370,7 @@ void OMW::Engine::go()
|
||||||
|
|
||||||
// Create the world
|
// Create the world
|
||||||
mEnvironment.mWorld = new MWWorld::World (mOgre, mPhysicEngine, mFileCollections, mMaster,
|
mEnvironment.mWorld = new MWWorld::World (mOgre, mPhysicEngine, mFileCollections, mMaster,
|
||||||
mResDir, mNewGame, mEnvironment);
|
mResDir, mNewGame, mEnvironment, mEncoding);
|
||||||
|
|
||||||
// Set up the GUI system
|
// Set up the GUI system
|
||||||
mGuiManager = new OEngine::GUI::MyGUIManager(mOgre.getWindow(), mOgre.getScene(), false, cfgDir);
|
mGuiManager = new OEngine::GUI::MyGUIManager(mOgre.getWindow(), mOgre.getScene(), false, cfgDir);
|
||||||
|
@ -519,3 +519,8 @@ void OMW::Engine::setCompileAll (bool all)
|
||||||
{
|
{
|
||||||
mCompileAll = all;
|
mCompileAll = all;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void OMW::Engine::setEncoding(const std::string& encoding)
|
||||||
|
{
|
||||||
|
mEncoding = encoding;
|
||||||
|
}
|
|
@ -56,6 +56,7 @@ namespace OMW
|
||||||
|
|
||||||
class Engine : private Ogre::FrameListener
|
class Engine : private Ogre::FrameListener
|
||||||
{
|
{
|
||||||
|
std::string mEncoding;
|
||||||
boost::filesystem::path mDataDir;
|
boost::filesystem::path mDataDir;
|
||||||
boost::filesystem::path mResDir;
|
boost::filesystem::path mResDir;
|
||||||
OEngine::Render::OgreRenderer mOgre;
|
OEngine::Render::OgreRenderer mOgre;
|
||||||
|
@ -157,6 +158,9 @@ namespace OMW
|
||||||
|
|
||||||
/// Compile all scripts (excludign dialogue scripts) at startup?
|
/// Compile all scripts (excludign dialogue scripts) at startup?
|
||||||
void setCompileAll (bool all);
|
void setCompileAll (bool all);
|
||||||
|
|
||||||
|
/// Font encoding
|
||||||
|
void setEncoding(const std::string& encoding);
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -80,6 +80,13 @@ bool parseOptions (int argc, char**argv, OMW::Engine& engine)
|
||||||
( "fs-strict", boost::program_options::value<bool>()->
|
( "fs-strict", boost::program_options::value<bool>()->
|
||||||
implicit_value (true)->default_value (false),
|
implicit_value (true)->default_value (false),
|
||||||
"strict file system handling (no case folding)")
|
"strict file system handling (no case folding)")
|
||||||
|
|
||||||
|
( "encoding", boost::program_options::value<std::string>()->
|
||||||
|
default_value("win1252"),
|
||||||
|
"Font encoding used in OpenMW game messages:\n"
|
||||||
|
"\n\twin1250 - Central and Eastern European such as Polish, Czech, Slovak, Hungarian, Slovene, Bosnian, Croatian, Serbian (Latin script), Romanian and Albanian languages\n"
|
||||||
|
"\n\twin1251 - Cyrillic alphabet such as Russian, Bulgarian, Serbian Cyrillic and other languages\n"
|
||||||
|
"\n\twin1252 - Western European (Latin) alphabet, used by default")
|
||||||
;
|
;
|
||||||
|
|
||||||
bpo::variables_map variables;
|
bpo::variables_map variables;
|
||||||
|
@ -125,6 +132,24 @@ bool parseOptions (int argc, char**argv, OMW::Engine& engine)
|
||||||
if (!run)
|
if (!run)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
|
// Font encoding settings
|
||||||
|
std::string encoding(variables["encoding"].as<std::string>());
|
||||||
|
if (encoding == "win1250")
|
||||||
|
{
|
||||||
|
std::cout << "Using Central and Eastern European font encoding." << std::endl;
|
||||||
|
engine.setEncoding(encoding);
|
||||||
|
}
|
||||||
|
else if (encoding == "win1251")
|
||||||
|
{
|
||||||
|
std::cout << "Using Cyrillic font encoding." << std::endl;
|
||||||
|
engine.setEncoding(encoding);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
std::cout << "Using default (English) font encoding." << std::endl;
|
||||||
|
engine.setEncoding("win1252");
|
||||||
|
}
|
||||||
|
|
||||||
// directory settings
|
// directory settings
|
||||||
if (variables["fs-strict"].as<bool>()==true)
|
if (variables["fs-strict"].as<bool>()==true)
|
||||||
engine.enableFSStrict();
|
engine.enableFSStrict();
|
||||||
|
|
|
@ -409,7 +409,7 @@ namespace MWWorld
|
||||||
World::World (OEngine::Render::OgreRenderer& renderer, OEngine::Physic::PhysicEngine* physEng,
|
World::World (OEngine::Render::OgreRenderer& renderer, OEngine::Physic::PhysicEngine* physEng,
|
||||||
const Files::Collections& fileCollections,
|
const Files::Collections& fileCollections,
|
||||||
const std::string& master, const boost::filesystem::path& resDir,
|
const std::string& master, const boost::filesystem::path& resDir,
|
||||||
bool newGame, Environment& environment)
|
bool newGame, Environment& environment, const std::string& encoding)
|
||||||
: mSkyManager (0), mScene (renderer,physEng), mPlayer (0), mCurrentCell (0), mGlobalVariables (0),
|
: mSkyManager (0), mScene (renderer,physEng), mPlayer (0), mCurrentCell (0), mGlobalVariables (0),
|
||||||
mSky (false), mCellChanged (false), mEnvironment (environment)
|
mSky (false), mCellChanged (false), mEnvironment (environment)
|
||||||
{
|
{
|
||||||
|
@ -420,6 +420,7 @@ namespace MWWorld
|
||||||
std::cout << "Loading ESM " << masterPath.string() << "\n";
|
std::cout << "Loading ESM " << masterPath.string() << "\n";
|
||||||
|
|
||||||
// This parses the ESM file and loads a sample cell
|
// This parses the ESM file and loads a sample cell
|
||||||
|
mEsm.setEncoding(encoding);
|
||||||
mEsm.open (masterPath.string());
|
mEsm.open (masterPath.string());
|
||||||
mStore.load (mEsm);
|
mStore.load (mEsm);
|
||||||
|
|
||||||
|
|
|
@ -115,7 +115,7 @@ namespace MWWorld
|
||||||
World (OEngine::Render::OgreRenderer& renderer, OEngine::Physic::PhysicEngine* physEng,
|
World (OEngine::Render::OgreRenderer& renderer, OEngine::Physic::PhysicEngine* physEng,
|
||||||
const Files::Collections& fileCollections,
|
const Files::Collections& fileCollections,
|
||||||
const std::string& master, const boost::filesystem::path& resDir, bool newGame,
|
const std::string& master, const boost::filesystem::path& resDir, bool newGame,
|
||||||
Environment& environment);
|
Environment& environment, const std::string& encoding);
|
||||||
|
|
||||||
~World();
|
~World();
|
||||||
|
|
||||||
|
|
|
@ -326,7 +326,7 @@ std::string ESMReader::getString(int size)
|
||||||
mEsm->read(ptr, size);
|
mEsm->read(ptr, size);
|
||||||
|
|
||||||
// Convert to UTF8 and return
|
// Convert to UTF8 and return
|
||||||
return ToUTF8::getUtf8(ToUTF8::WINDOWS_1252);
|
return ToUTF8::getUtf8(mEncoding);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ESMReader::fail(const std::string &msg)
|
void ESMReader::fail(const std::string &msg)
|
||||||
|
@ -344,4 +344,21 @@ void ESMReader::fail(const std::string &msg)
|
||||||
throw std::runtime_error(ss.str());
|
throw std::runtime_error(ss.str());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ESMReader::setEncoding(const std::string& encoding)
|
||||||
|
{
|
||||||
|
if (encoding == "win1250")
|
||||||
|
{
|
||||||
|
mEncoding = ToUTF8::WINDOWS_1250;
|
||||||
|
}
|
||||||
|
else if (encoding == "win1251")
|
||||||
|
{
|
||||||
|
mEncoding = ToUTF8::WINDOWS_1251;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// Default Latin encoding
|
||||||
|
mEncoding = ToUTF8::WINDOWS_1252;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -350,6 +350,9 @@ public:
|
||||||
/// Used for error handling
|
/// Used for error handling
|
||||||
void fail(const std::string &msg);
|
void fail(const std::string &msg);
|
||||||
|
|
||||||
|
/// Sets font encoding for ESM strings
|
||||||
|
void setEncoding(const std::string& encoding);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
Mangle::Stream::StreamPtr mEsm;
|
Mangle::Stream::StreamPtr mEsm;
|
||||||
|
|
||||||
|
@ -360,6 +363,7 @@ private:
|
||||||
|
|
||||||
SaveData mSaveData;
|
SaveData mSaveData;
|
||||||
MasterList mMasters;
|
MasterList mMasters;
|
||||||
|
ToUTF8::FromType mEncoding;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -88,7 +88,23 @@ int main()
|
||||||
// Write namespace
|
// Write namespace
|
||||||
cout << "namespace ToUTF8\n{\n\n";
|
cout << "namespace ToUTF8\n{\n\n";
|
||||||
|
|
||||||
|
// Central European and Eastern European languages that use Latin script, such as
|
||||||
|
// Polish, Czech, Slovak, Hungarian, Slovene, Bosnian, Croatian, Serbian (Latin script), Romanian and Albanian.
|
||||||
|
cout << "\n/// Central European and Eastern European languages that use Latin script,"
|
||||||
|
"\n/// such as Polish, Czech, Slovak, Hungarian, Slovene, Bosnian, Croatian,"
|
||||||
|
"\n/// Serbian (Latin script), Romanian and Albanian."
|
||||||
|
"\n";
|
||||||
|
write_table("WINDOWS-1250", "windows_1250");
|
||||||
|
|
||||||
|
// Cyrillic alphabet such as Russian, Bulgarian, Serbian Cyrillic and other languages
|
||||||
|
cout << "\n/// Cyrillic alphabet such as Russian, Bulgarian, Serbian Cyrillic"
|
||||||
|
"\n/// and other languages"
|
||||||
|
"\n";
|
||||||
|
write_table("WINDOWS-1251", "windows_1251");
|
||||||
|
|
||||||
// English
|
// English
|
||||||
|
cout << "\n/// Latin alphabet used by English and some other Western languages"
|
||||||
|
"\n";
|
||||||
write_table("WINDOWS-1252", "windows_1252");
|
write_table("WINDOWS-1252", "windows_1252");
|
||||||
|
|
||||||
// Close namespace
|
// Close namespace
|
||||||
|
|
|
@ -4,6 +4,533 @@
|
||||||
namespace ToUTF8
|
namespace ToUTF8
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
|
/// Central European and Eastern European languages that use Latin script,
|
||||||
|
/// such as Polish, Czech, Slovak, Hungarian, Slovene, Bosnian, Croatian,
|
||||||
|
/// Serbian (Latin script), Romanian and Albanian.
|
||||||
|
static char windows_1250[] =
|
||||||
|
{
|
||||||
|
0x1, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x1, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x2, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x3, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x4, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x5, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x6, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x7, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x8, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x9, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0xa, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0xb, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0xc, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0xd, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0xe, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0xf, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x10, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x11, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x12, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x13, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x14, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x15, 0x0, 0x0, 0x0, 0x0,
|
||||||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0, 0x0,
|
||||||
|
0x1, 0x20, 0x0, 0x0, 0x0, 0x0, // not part of this charset
|
||||||
|
0x3, 0xe2, 0x80, 0x9a, 0x0, 0x0,
|
||||||
|
0x1, 0x20, 0x0, 0x0, 0x0, 0x0, // not part of this charset
|
||||||
|
0x3, 0xe2, 0x80, 0x9e, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0xa6, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0xa0, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0xa1, 0x0, 0x0,
|
||||||
|
0x1, 0x20, 0x0, 0x0, 0x0, 0x0, // not part of this charset
|
||||||
|
0x3, 0xe2, 0x80, 0xb0, 0x0, 0x0,
|
||||||
|
0x2, 0xc5, 0xa0, 0x0, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0xb9, 0x0, 0x0,
|
||||||
|
0x2, 0xc5, 0x9a, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc5, 0xa4, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc5, 0xbd, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc5, 0xb9, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x20, 0x0, 0x0, 0x0, 0x0, // not part of this charset
|
||||||
|
0x3, 0xe2, 0x80, 0x98, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0x99, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0x9c, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0x9d, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0xa2, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0x93, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0x94, 0x0, 0x0,
|
||||||
|
0x1, 0x20, 0x0, 0x0, 0x0, 0x0, // not part of this charset
|
||||||
|
0x3, 0xe2, 0x84, 0xa2, 0x0, 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7, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc4, 0x8d, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc3, 0xa9, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc4, 0x99, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc3, 0xab, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc4, 0x9b, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc3, 0xad, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc3, 0xae, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc4, 0x8f, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc4, 0x91, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc5, 0x84, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc5, 0x88, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc3, 0xb3, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc3, 0xb4, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc5, 0x91, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc3, 0xb6, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc3, 0xb7, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc5, 0x99, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc5, 0xaf, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc3, 0xba, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc5, 0xb1, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc3, 0xbc, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc3, 0xbd, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xc5, 0xa3, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xcb, 0x99, 0x0, 0x0, 0x0
|
||||||
|
};
|
||||||
|
|
||||||
|
/// Cyrillic alphabet such as Russian, Bulgarian, Serbian Cyrillic
|
||||||
|
/// and other languages
|
||||||
|
static char windows_1251[] =
|
||||||
|
{
|
||||||
|
0x1, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x1, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x2, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x3, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x4, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x5, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x6, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x7, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x8, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x9, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0xa, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0xb, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0xc, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0xd, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0xe, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0xf, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x10, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x11, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x12, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x13, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x14, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x15, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x16, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x17, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x18, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
0x1, 0x19, 0x0, 0x0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x3, 0xe2, 0x80, 0x9e, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0xa6, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0xa0, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0xa1, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x82, 0xac, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0xb0, 0x0, 0x0,
|
||||||
|
0x2, 0xd0, 0x89, 0x0, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0xb9, 0x0, 0x0,
|
||||||
|
0x2, 0xd0, 0x8a, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd0, 0x8c, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd0, 0x8b, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd0, 0x8f, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x92, 0x0, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0x98, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0x99, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0x9c, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0x9d, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0xa2, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0x93, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0x94, 0x0, 0x0,
|
||||||
|
0x1, 0x20, 0x0, 0x0, 0x0, 0x0, // not part of this charset
|
||||||
|
0x3, 0xe2, 0x84, 0xa2, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x99, 0x0, 0x0, 0x0,
|
||||||
|
0x3, 0xe2, 0x80, 0xba, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x9a, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x9c, 0x0, 0x0, 0x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, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd0, 0xbc, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd0, 0xbd, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd0, 0xbe, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd0, 0xbf, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x80, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x81, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x82, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x83, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x84, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x85, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x86, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x87, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x88, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x89, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x8a, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x8b, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x8c, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x8d, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x8e, 0x0, 0x0, 0x0,
|
||||||
|
0x2, 0xd1, 0x8f, 0x0, 0x0, 0x0
|
||||||
|
};
|
||||||
|
|
||||||
|
/// Latin alphabet used by English and some other Western languages
|
||||||
static char windows_1252[] =
|
static char windows_1252[] =
|
||||||
{
|
{
|
||||||
0x1, 0x0, 0x0, 0x0, 0x0, 0x0,
|
0x1, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||||
|
|
|
@ -130,10 +130,28 @@ std::string ToUTF8::getUtf8(ToUTF8::FromType from)
|
||||||
{
|
{
|
||||||
// Pick translation array
|
// Pick translation array
|
||||||
const char *arr;
|
const char *arr;
|
||||||
if(from == ToUTF8::WINDOWS_1252)
|
switch (from)
|
||||||
arr = ToUTF8::windows_1252;
|
{
|
||||||
else
|
case ToUTF8::WINDOWS_1252:
|
||||||
assert(0);
|
{
|
||||||
|
arr = ToUTF8::windows_1252;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case ToUTF8::WINDOWS_1250:
|
||||||
|
{
|
||||||
|
arr = ToUTF8::windows_1250;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case ToUTF8::WINDOWS_1251:
|
||||||
|
{
|
||||||
|
arr = ToUTF8::windows_1251;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
default:
|
||||||
|
{
|
||||||
|
assert(0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Double check that the input string stops at some point (it might
|
// Double check that the input string stops at some point (it might
|
||||||
// contain zero terminators before this, inside its own data, which
|
// contain zero terminators before this, inside its own data, which
|
||||||
|
|
|
@ -8,8 +8,10 @@ namespace ToUTF8
|
||||||
// These are all the currently supported code pages
|
// These are all the currently supported code pages
|
||||||
enum FromType
|
enum FromType
|
||||||
{
|
{
|
||||||
WINDOWS_1252 // Used by English version of Morrowind (and
|
WINDOWS_1250, // Central ane Eastern European languages
|
||||||
// probably others)
|
WINDOWS_1251, // Cyrillic languages
|
||||||
|
WINDOWS_1252 // Used by English version of Morrowind (and
|
||||||
|
// probably others)
|
||||||
};
|
};
|
||||||
|
|
||||||
// Return a writable buffer of at least 'size' bytes. The buffer
|
// Return a writable buffer of at least 'size' bytes. The buffer
|
||||||
|
|
|
@ -2,8 +2,9 @@
|
||||||
|
|
||||||
<MyGUI type="Font">
|
<MyGUI type="Font">
|
||||||
|
|
||||||
<Font name="MyGUI_CoreFont.18" source="Comic.TTF" size="18" resolution="72" antialias_colour="false" space_width="4" tab_count="4" spacer="5">
|
<Font name="MyGUI_CoreFont.18" source="Comic.TTF" size="18" resolution="72" antialias_colour="false" space_width="4" tab_count="4" spacer="5" distance="10">
|
||||||
<Code range="33 126"/>
|
<Code range="33 126"/>
|
||||||
|
<Code range="192 382"/><!-- Central and Eastern European languages glyphs -->
|
||||||
<Code range="1025 1105"/>
|
<Code range="1025 1105"/>
|
||||||
<Code range="8470 8470" help="№"/>
|
<Code range="8470 8470" help="№"/>
|
||||||
<Code hide="128"/>
|
<Code hide="128"/>
|
||||||
|
@ -11,15 +12,16 @@
|
||||||
<Code hide="1104"/>
|
<Code hide="1104"/>
|
||||||
</Font>
|
</Font>
|
||||||
|
|
||||||
|
<Font name="MonoFont" default_height="17" source="VeraMono.ttf" size="18" resolution="50" antialias_colour="false" space_width="4" tab_width="8" cursor_width="2" distance="10" offset_height="0">
|
||||||
<Font name="MonoFont" default_height="17" source="VeraMono.ttf" size="18" resolution="50" antialias_colour="false" space_width="4" tab_width="8" cursor_width="2" distance="5" offset_height="0">
|
|
||||||
<Code range="33 126"/>
|
<Code range="33 126"/>
|
||||||
|
<Code range="192 382"/><!-- Central and Eastern European glyphs -->
|
||||||
<Code range="1025 1105"/>
|
<Code range="1025 1105"/>
|
||||||
</Font>
|
</Font>
|
||||||
|
|
||||||
<!-- Useful for youtube videos :) -->
|
<!-- Useful for youtube videos :) -->
|
||||||
<Font name="youtube" default_height="34" source="VeraMono.ttf" size="36" resolution="50" antialias_colour="false" space_width="8" tab_width="16" cursor_width="4" distance="10" offset_height="0">
|
<Font name="youtube" default_height="34" source="VeraMono.ttf" size="36" resolution="50" antialias_colour="false" space_width="8" tab_width="16" cursor_width="4" distance="15" offset_height="0">
|
||||||
<Code range="33 126"/>
|
<Code range="33 126"/>
|
||||||
|
<Code range="192 382"/><!-- Central and Eastern European languages glyphs -->
|
||||||
<Code range="1025 1105"/>
|
<Code range="1025 1105"/>
|
||||||
</Font>
|
</Font>
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue