[haiku-doc] Re: Another try at user guide translations

  • From: Vincent Duvert <vincent.duvert@xxxxxxx>
  • To: haiku-doc@xxxxxxxxxxxxx
  • Date: Sat, 29 Aug 2009 10:04:13 +0200


Le 27 août 09 à 17:52, Humdinger a écrit :

I have updated the CSS file used on translate.haikuzone.net to the newest version from Haiku's SVN ; the documentation pages will also need updating.

It may be useful to use a non-fixed-width CSS for the entry page listing all languages and their status. I guess, these can become quite wide...
Also, fixed width columns would be better, with two lines per cell:

English                   French

ActivityMonitor <br />    View . Translate <br />
Block Edit . Full Edit    (77 % - 278 fuzzy)

Yes, the translate tool pages need some love ;-) I will probably work on this soon. Since they use a separate CSS file (shared/styles.css), it will be easy to do whatever changes we need.

I've got a question : How is the top navigation bar generated in the files ? Is it automatic ?

Nope. It's all done by hand.

Wow :-)


The translate tool needs something like this in the pages it imports : <!-- LANG_MENU(../path/to/the/en/page.html,../path/to/the/{LANG}/ page.html,../path/to/images/flags) -->
<div class="topnav">
<!-- NAVIGATION(../path/to/level/ up.html,path_to_previous_page.html,path_to_next_page.html) -->
</div>
so if a special version of the Haiku documentation with this in place of the normal topnav could be generated automatically, it would save me some work ;-)

Now, that we don't have any language-dependent words like "previous" and "next" in there, is that really necessary?

The translators would still have to translate the page names... And I see two problems : - Since the paragraph that contains the navigation bar is considered as one translatable block, the translators would have to deal with something like this:
<a href="contents.html" class="uplink">Contents</a>
                &#160;&#160;::&#160;&#160;
                <a href="preferences.html">Preferences</a>&#160;&#160;&raquo;
which is not very easy to translate.
- We could end up having, for instance, different translation for the "Contents" link title...
Also, the path used for navigation is always relative, e.g. "../ applications.html", so different languages shouldn't be a problem. Having it generated automatically would also always limit us to (I guess) alphabetical order of pages.
For now, the only thing autogenerated is the (possibly translated) page name. You're free to put any link you want in the NAVIGATION() placeholder, even if the page it links to is not related to the current. There is currently some limitations though : every page pointed by those links must be registered in the translation system, and two pages should not have the same filename.

I also have other suggestions about the updated documentation theme, but I'll put them in a separate email :)

Fire away. :)

Here we go. These are mostly nitpicks, but well ;-)

- The "Haiku user guide" logo image has a color profile attached, so it is not displayed with the same background color as the rest of the header in some browsers. The color profile can be removed with this method for instance: http://www.kaktus.cc/weblog/ png_and_color_profiles/. By the way, the header background is #efefef, whereas the image seems to use #eeeeee.

- An image is used to extend the header to the page border. That could probably be done in pure CSS... I will have a look.

- Some pages have XML errors that prevent them to be imported in the translate tool: these are mostly unclosed tags and direct use of special characters (<, >, &). It also complained about some HTML character entities, like "&larr;" or "&eacute;", probably because the real character can be used without issues. This patch (against r32801) should fix them all : http://dl.free.fr/ovxe3P09I

- Since every page will have a language switch menu, what about replacing userguide/languages.html with contents.html ? For the links in contents.html, we could use something like this : '<a href="{LANG_CODE}/bootloader.html">Boot Loader</a>'.

That's all for now ;-)

Vincent


Other related posts: