射手播放器 新语言版本制作指南

出自射手网Wiki

射手播放器 新语言版本制作指南

跳转到: 导航, 搜索

This Page Is Currently Under Construction And Will Be Available Shortly, Please Visit Reserve Copy Page

Application

Here is a how-to guide for making and translating new language version of SPlayer.

1. You can check out english language files from svn://svn.splayer.org/svplayer/src/apps/lang/res_eng

2. You can traslate .rc and .html file inside that tree, make new button picture etc, but do not commit, just email to tomasen@gmail.com the translated files, then I will create a new project tree for this language resource.

3. After new language resource project create, you will receive svn account to update/commit


NOTE:

1. DONT translate any line start with IDS_RS_xxxxx in .rc file. those are for setting label in registry, so translate those will messed up setting if ppl switch langauge.

2. Save rc file as Unicode(UTF-16) with BOM. Save html file as UTF-8.

MSI Installation Package

  • Current SPlayer MSI supports English, Simplified Chinese, Traditional Chinese and Russian.
  • To add a new language:
    • Check if the languiage is supported in Wix 3.
      • these languages are supported: cs-cz, de-de, en-us, es-es, fr-fr, hu-hu, it-it, ja-jp, nl-nl, pl-pl, ru-ru, uk-ua.
      • if not, you need to create your own translation of the UI strings. Check the svn://svn.splayer.org:3690/svplayer/Setup/svplayer.msi/WiX/zh-cn.wxl for reference.

<pre>

 <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'ReleaseRU|x86' ">
   <DefineConstants>locale=1049;codepage=1251</DefineConstants>
   <Cultures>ru-RU</Cultures>
   <WixVariables>
   </WixVariables>
   <OutputPath>bin\$(Configuration)\</OutputPath>
   <IntermediateOutputPath>obj\$(Platform)\$(Configuration)\</IntermediateOutputPath>
 </PropertyGroup>

</pre>

    • Chnage the WiX\build.bat to build the MSI fro the new language. Still take Russian for example:

<pre> msbuild svplayer.wixproj /property:Configuration=ReleaseRU /l:FileLogger,Microsoft.Build.Engine;logfile=svplayer.ru.log;verbosity=detailed /t:Clean,Build </pre>

    • Create the transform: update the build.bat file under transform folder:

<pre> ... msitran -g ..\wix\bin\Release\en-US\SvPlayer.msi ..\wix\bin\ReleaseRU\ru-RU\SvPlayer.msi ru.mst ... scripts\wisubstg.vbs ..\..\..\..\SPlayer.msi ru.mst 1049

scripts\WiLangId.vbs ..\..\..\..\SPlayer.msi Package 1033,2052,1028,1049

</pre>

赞助商链接:
个人工具