in
Forums
Blogs
Files
Devexpress.Com
ClientCenter
DevExpress Channel

Gary's Blog

You say Potato I say Potahto: Localization in the eXpress Application Framework

On a recent film making trip to LA, we were out for dinner one night when the waiter asked me what kind of salad I would like, I replied that I would like tomato. Ray, good humoredly, corrected me and said it was tomayto not tomato. Of course he is right, not because he is an expert in the Americanization of the English language, but because he pays my salary and that trump card is enough to hold sway in most arguments. However, it did reminded me of Churchill’s old adage that the U.K. and the U.S. are two countries separated by a common language.

However much that may or may not be true, it is a fact that in our industry, language can be a separator separating countries (and therefore people) into the haves and the have nots depending on whether a particular piece of software has been localized for their country or not. To solve this problem an industry has grown up around internationalization and localization, with books on the subject and tools to help the developer with the process; there are also a number of industry standards to aid collaboration.

When it comes to the localization of software, and that is the only kind of localization we are dealing with in this post, there is a fairly straight forward workflow to follow:-

Workflow

So does XAF support this localization workflow? Well the answer is yes but not entirely. It is clear that applications created with XAF are internationalized, that is to say, the up front work of designing and creating an application to be localizable, has been done for you. It is also clear that the step of extracting localizable content into a central data store has been facilitated through the use of the Model and because the Model Editor can be used as a stand alone product, a developer could use that mechanism in order to allow a translation agent to work with the localizable content. So, to quite a considerable degree, this workflow is supported within XAF.

However, XAF is not perfect (what software product is?) and it is clear that the area in which it lacks, is in its ability to export the localizable content, in a standards compliant medium, for onward transmission to a translation agent; nor does XAF have a mechanism by which to import the translated content back into the Model. Now we do plan to fully support this workflow at some point in the future, it’s just that the opportunity to include it has not presented itself yet.

Although I believe this to be a minor deficit in the productivity gains that XAF brings to the developer, I feel the time has come to rectify this deficit; so, in the coming days I am going to design, build, test and publish a tool that will allow the export and import of localizable content. This will allow XAF to fully support this localization workflow. I will be blogging my progress in future posts, so those of you who have an interest in this topic can follow along at home.

In the meantime, you can read more about XAF’s support for localization in our documentation.

Digg This
Published Jul 22 2008, 03:11 PM by Gary Short (Developer Express)
Filed under:
Technorati tags: XAF

Comments

 

Mohamed Zayani said:

Hi,

Does XAF or in general DXperience supports right to left orientation of data and UI elements?

And if not, are there any plan(s) for the same in the (near) future.

regards,

July 22, 2008 11:30 AM
 

Julian M Bucknall said:

Mohamed

No, DXperience does not support right-to-left languages and hence neither does XAF. Such support is on our todo list, albeit with a low priority.

Cheers, Julian

July 22, 2008 11:47 AM
 

Binish Peter said:

great you thinking on this direction

We follow exact same steps.

since knowing this doesn't exist in XAF www.devexpress.com/issue=Q99924

I had to do this by creating a controller which iterates thru Application.Model and extracts all IsLocalizable.

:)

July 22, 2008 3:47 PM
 

Raoul Wedel said:

Hi,

For me right to left would be high priority. I have to turn down customers on a regular basis because of it.....

I don't think DevExpress realises that any app their customers have built with their components can't be used in large parts of the world.

Where are you calling from? Nope, sorry, can't help you....

Raoul.

July 23, 2008 6:33 AM
 

Gary Short said:

Raoul,

We feel your pain on this matter (see Julian's post above) but R2L is outwith the scope of this tool

July 23, 2008 6:42 AM
 

Mario Howard said:

Hi,

I suppose that this is your high speed reaction to the 5 page document I sent to Oliver Sturm (for comments) lamenting about the current situation. We have written some tools for localization and intend to make them available for everyone in a few days.

What I really would like DX to do is to closely cooperate with the major translation tools providers. WYSIWYG translation is very important and it can already be done for all DX components except the framework. I hope you will be heading in this direction. Having to translate the framework independently (XML file) is not really good enough.

I just love your very quick reactions to our concerns. DX is great.

Mario

July 23, 2008 9:54 AM
 

Gary's Blog said:

Yesterday, as I was pondering the internals of the XAF model for my ongoing localization project , I

August 1, 2008 6:28 AM
 

Sigurd Decroos said:

Hey,

I have my 'own' idea about localization support for XAF. I already posted a complete thread about this on the clientcenter. What about localization of the data? E.g. a table with articles and a table with the descriptions of those articles in different languages. I would be great if this could be done with a simple attribute for the 'description' property. Now that would make XAF really handy for many European developers (like me) and in countries like Belgium 3 to 4 languages are used daily...

August 1, 2008 10:15 PM
 

Gary Short said:

@Sigurd,

Your solution is interesting but has the same fundamental issue as the current model used in XAF. Currently in XAF all the content you wish to localise is contained within the model, this makes it hard to get that content to a translator, for the translator to work on and for the translator to return the localised content. Your solution, of having content in the database, suffers the same issue. How do you plan to transfer the data to the translator?

August 4, 2008 5:02 AM
 

Sigurd Decroos said:

Actually, this is simple. You would know all properties with the 'localizable' attribute, so you could know all these records aswell. A simple query for each table can return an nice XML-based text with everything that has to be translated for export. Importing the data would be simple too, if you have saved the tablename and tableid for each record.

It is strange that I've seen no ORM which supports multilanguages in the database (e.g. for article descriptions, countries, project descriptions, ...). I'm searching for a good ORM. But DevForce or MM.Net or XPO don't provide this. How come? Is this too difficult? I'm sure EVERY enterprise application needs multilanguage support, and not only the GUI (resource files and such).

August 4, 2008 7:13 AM
 

Gary Short (Developer Express) said:

@Sigurd,

The reason XPO (and I'm guessing the other ORM tools too) does not support localisation is separation of concerns, localisation is not an object/relational mapping issue.

August 4, 2008 7:20 AM
 

Sigurd Decroos said:

Gary,

I don't agree 100% on this one. Where is the localisation defined? In tables right? Mostly it is 1-M relation with 1 or more localizable fields in the base table. If you have a better design or practice, I'm all ears.

Keep the following situation in mind please:

I have 300000 articles with a Dutch description. I have an english customer who wants to see his invoices in English, so English descriptions are needed on the XtraReport while I see them in Dutch on my screen. I also have a French speaking employee who works in a French version of the program. This means GUI and data, but the report stays in English in this customers' case. Can you give me a model where XPO is NOT involved in this? I think not. Like I said, localisation is important in every level of the separation. I don't want to write 100 queries or functions for each table supporting multilanguage descriptions because I need to see the article code and the localized description in my views.

Strictly, this is not 100% XPO's problem, but it is definitely a XAF problem which holds me back for the moment :(

Greetings,

Sigurd

August 4, 2008 7:46 AM
 

Gary Short (Developer Express) said:

@Sigurd, if you handle your localisation in your database then XPO will be involved yes, but only because your localised content is in the database, localisation should not be a function of an ORM tool. An ORM tool maps objects and relational tables it is not concerned with localisation.

August 4, 2008 9:35 AM
 

Sigurd Decroos said:

Gary,

How can I do this in XAF then? It is based upon XPO. I can map al tables without a problem, but this doesn't solve the problem that it has to show lists in the language of the user and some reports in a seperate language and with a description coming from another table. I can't imagine you would put all the localisation in a seperate file, what about searching for something in XAF then?

Greetings,

Sigurd

August 4, 2008 9:59 AM
 

Gary Short (Developer Express) said:

@Sigurd, well if it were me, and I don't know your exact use case here, but what I'd do is have a database, localised per locale, and then change the XAF connection string, based on the locale of the client, to show the product information in the  language of the client. There is no specific localisation support required in XPO to achieve this.

August 4, 2008 12:20 PM
 

Sigurd Decroos said:

Gary,

I'm not sure if I really understand you on this one. 1 database per locale? I have a customer who needs to work in 17 languages (no joke!). This would mean 17 databases? What about concurrency of all those databases? Articles was just an example, but I have 100 tables in total that need localisation (several million records in total per database)...

Greetings,

Sigurd

August 4, 2008 3:01 PM
 

Gary Short (Developer Express) said:

@sigurd, well, like I said, I didn't know your exact use case, previously you had said that you were using your database as a localisation solution, but it is clear now that what you have goes far beyond a localisation solution.

August 4, 2008 3:24 PM

Leave a Comment

(required)  
(optional)
(required)  
Verification code: Required
   
Add
Copyright © 1998-2008 Developer Express Inc.
ALL RIGHTS RESERVED