I cannot work out how to add internationalization to the PrimeFaces Editor (Version 3.2).
I need to translate tooltips, texts in comboboxes and change icons of the toolbar.
In an old users guide http://www.scribd.com/doc/49595285/46/Editor I found an attribute called “language” but this seems to be kind of disabled or removed for the actual version.
My project setup is JSF 2 with PrimeFaces 3.2 and GlassFish 3.1.2
I’d be very glad if you could show me how I can solve this problem.
Thanks and Kind regards,
Pedro
Analysis
If we look at the PrimeFaces 3.2 documentation, there is no such attribute as language for Editor component and there is nothing mentioned in localization chapter.
PrimeFaces do not provide a way to localize Editor as they do provide for Calendar. And obviously they do provide it for calendar, because it is out of box feature for jQuery datePicker, which caledar is based on.
Outcome
Look for editor.js in PrimeFaces 3.2 sources. There is a section, where all editor buttons are initialized:
There is provided format for separate button setup:
name,title,command,popupName. Thetitlepart is the one you can make use of.What you can do, you can build primefaces sources with your own titles provided, or override them in other way I cannot think of.
Help
If you are using maven, you can install customized primefaces in local or centralized repository of your own and use it instead of original dependency.
Lesson
You shouldn’t look for old documentation, when you are using newer version. Look for the documentation of the version you are using.