Maven Doxia

Specify the language identification

Details

  • Number of attachments :
    0

Description

Actually, the sink generates:

<html xmlns="http://www.w3.org/1999/xhtml">

We need to add the language identification i.e.

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

Activity

Hide
Dennis Lundberg added a comment -

The language identification needs to be dynamic to work properly, and I'm not sure it will even work with that.

Example 1
A Maven generated site with multiple languages
Doxia needs to be told which language the pages are in. For each of the non-default languages there should be no problem, because the docs are in a directory named after the language id.

Example 2
A Maven generated site in a single language - not English. We have company internal documentation in Swedish only.
How does Doxia know which language it is in? It is not mentioned in the document sources.

Show
Dennis Lundberg added a comment - The language identification needs to be dynamic to work properly, and I'm not sure it will even work with that. Example 1 A Maven generated site with multiple languages Doxia needs to be told which language the pages are in. For each of the non-default languages there should be no problem, because the docs are in a directory named after the language id. Example 2 A Maven generated site in a single language - not English. We have company internal documentation in Swedish only. How does Doxia know which language it is in? It is not mentioned in the document sources.
Hide
Vincent Siveton added a comment -

The Doxia API (forget the Maven integration) misses this feature in xdoc, docbook and xhtml

Yes it should be dynamic, I imagine this integration with Maven:

  • the Maven site plugin allows i18n by directories and with site.xml/site_LANG.xml using the locales parameter. The default language id could be the default locale language for the default site, and the locale language from the language dir. So, you could defined <locales>se</locales> and all your documents in the default site will be tagged as Swedish.
  • known limitation: in a given site (default or i18n dir) you should have the same language in all documents inside.
Show
Vincent Siveton added a comment - The Doxia API (forget the Maven integration) misses this feature in xdoc, docbook and xhtml Yes it should be dynamic, I imagine this integration with Maven:
  • the Maven site plugin allows i18n by directories and with site.xml/site_LANG.xml using the locales parameter. The default language id could be the default locale language for the default site, and the locale language from the language dir. So, you could defined <locales>se</locales> and all your documents in the default site will be tagged as Swedish.
  • known limitation: in a given site (default or i18n dir) you should have the same language in all documents inside.
Hide
Vincent Siveton added a comment -

Fixed in r739565

Show
Vincent Siveton added a comment - Fixed in r739565

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: