如何本地化的.NET库中的文件 [英] How to localize the documentation of a .NET library

查看:134
本文介绍了如何本地化的.NET库中的文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个开放源代码项目(这里),其的documentation 是目前在法国。该文件是从code XML注释生成,使用沙堡。现在,我想的文档翻译成英文两种语言提供文件,但我真的不知道从哪里开始...

I have an open-source project (here) whose documentation is currently in French. The documentation is generated from XML comments in code, using Sandcastle. Now I would like to translate the documentation to English and provide documentation in both languages, but I don't really know where to start...

  • 请我需要提取从code中的XML注释,并把它们放在一个单独的文件?如果是的话,是否有任何工具的过程自动化?
  • 在我使用的沙堡帮助文件生成器生成的文件;我需要创建一个单独的项目,以建立英文文档,还是可以从同一个项目做了什么?
  • 是否有任何工具,在翻译过程中帮助吗?例如并排显示原始和翻译文档的一面?

我也有兴趣在如何制作多语言文件,因为我无法找到任何有用的关于谷歌的链接...

I'm also interested in links on how to produce multilingual documentation, as I couldn't find anything useful on Google...

推荐答案

一个策略,这将需要与沙堡XSLT文件的一些协调,将是使用的xml:lang的属性在你的XML文档。 Visual Studio 2010中允许多个标签保持(虽然你可能得到关于重复标签的投诉)。

One strategy, which would require some coordination with the Sandcastle XSLT files, would be to use the xml:lang attribute on your XML documentation. Visual Studio 2010 allows multiple tags to remain (although you may get complaints about duplicate tags).

/// <summary>
/// Gets or sets the fill size of the load operation.
/// </summary>
/// <summary xml:lang="fr">
/// Obtient ou définit la taille de remplissage de l'opération de chargement.
/// </summary>
public int FillSize
{
    get;
    set;
}

结果输出:

<member name="P:Namespace.MyAttribute.FillSize">
    <summary>
    Gets or sets the fill size of the load operation.
    </summary>
    <summary xml:lang="fr">
    Obtient ou définit la taille de remplissage de l'opération de chargement.
    </summary>
</member>

这篇关于如何本地化的.NET库中的文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆