From: Sergey A Yanovitsky Date: 2002-02-13T01:38:41+09:00 Subject: Re: Help with i18n and RDoc, please.... Hello Alexander, Tuesday, February 12, 2002, 2:52:53 PM, you wrote: AB> On Tue, Feb 12, 2002 at 06:23:40PM +0900, Sergey A Yanovitsky wrote: >> Hello Dave, >> >> Tuesday, February 12, 2002, 2:37:46 AM, you wrote: >> >> >> >> DT> I'd like to add proper internationalization and multiple language >> DT> support to RDoc. My vision is that you'll be able to have a source >> DT> program with comments written in (say) Japanese and English, and have >> DT> the user be able to select the language that they generate >> DT> documentation in. However, as usual, there seems to be more to the >> DT> problem than meets the eye. I've had long chat sessions with Jaf, >> DT> vruz, and Dorao, but I'm still not sure I get it (in fact I know I >> DT> don't get it, particularly when it comes to locales with multiple >> DT> encodings). >> My nick is Jah, Dave :) >> DT> So, in an attempt to get it at least part-way right, I've >> DT> put up a wiki page: >> >> DT> http://www.rubygarden.org/ruby?RDocI18n >> It's the part of wiki page: >> so we might specify a language using >> >> es_MX:iso-8859-1 (Spanish in Mexion) >> en_US:iso-8859-1 (English in the US) >> en:iso-8859-1 (English) >> ja:ISO-2022-JP (Japanese) >> ja-JP:EUC-JP (Japanese using EUC) >> >> My suggestion is to replace ':' with '.', because UN*X LANG >> environment variables looks like >> LANG=ru_RU.KOI8-R, >> not like >> LANG=ru_RU:KOI8-R >> >> With this change made we don't need to do additional variable >> converting. AB> This is a valid point. For proper definition of langauge specification it AB> is better to use LI18NUX draft: AB> http://www.li18nux.org/docs/text/LocNameGuide-20020121.txt >> DT> I would really appreciate it if folks who understand the issues could >> DT> read through this and tell me what works and what doesn't. Remember, >> DT> I'm trying to make this as simple and as transparent as possible in >> DT> the default case. >> I was talking to Eugene Skripnik 'bout i18n and charsets issue. He told >> me that we should look at gettext library. If i understood him >> correctly, this lib is used in vim for the same purposes. He also told >> me that with this lib vim can correctly determine current LANG even on windows :) AB> This is unrelated to what Rdoc wants to support. Gettext is for AB> multilingualized software, which wants to talk with user on different AB> languages. Here we want to support comments in different languages, not a AB> possiblity to specify commentary twice or more times in different language AB> (for which gettext is usefull) in order to be able to produce different AB> documentations for the same source. On wiki Dave wrote that templates will contain static strings for standard languages. That means if you use --lang=ru, ALL pages must be in russian, not just your comments in them. So RDoc WILL talk in different languages :). However i don't suggest to use gettext with RDoc, just to look how it makes proper LANG determination and do something similar in ruby. -- Best regards, Sergey [team Enticla] mailto:Sergey.Yanovitsky@itgrp.net ICQ: 100292077