by Catalin Rotaru <cata@netscape.com>
Last Modified: 23/May/2000 v1.03
Introduction
This document represents the list of modules, componenets and interfaces offered by the charset subsystem. It is intented to be a starting point for someone trying to understand and use these i18n services we provide. It is also very helpful for someone trying to extend or modify that functionality. The next step for a complete understading of the interfaces, is reading the source files: they are well documented in JavaDoc style.Of course, all this is XPCOM so you know the drill: please read those docs first.
The big picture
Module | Component | Interface | Data Files |
uconv | nsCharsetConverterManager [Service] |
|
|
nsCharsetMenu [RDF data source] | |||
strres | nsStringBundleService [Service] |
|
|
nsStringBundle
nsExtensibleStringBundle |
|
||
chardet | nsDocumentCharsetInfo |
The interfaces
nsICharsetConverterManager - deprecatedThis interface has been replace by nsICharsetConverterManager2. Please use that one! However, the deprecation process is not done yet. So you may still have to include it for certain macros...
nsICharsetConverterManager2
This is the main interface for working with Character Sets. All the
main methods are scriptable, but it also provides a few C++ specific, easier
to use shortcuts. It has methods for:
- Obtaining the cannical name of a charset.
- Obtaining Unicode encoders/decoders.
- Obtaining data about charsets, like: human-readable name, language group and other various properties.
nsIStringBundleService,
nsIStringBundle
Fully documented on their own page: String
Resources.
nsIDocumentCharsetInfo
The object implementing this interface is storing all the document
charset information: flags, settings and state machine variables. The iterface
is used to access (get/set) that information from the various places where
it is used (load code, charset menu, etc). The object is attached to nsIDocShell.
The Data Files
charsetTitlesHuman readable names for Character Sets.
Localizable. Extensible String Bundle. Strings should be accessed through nsICharsetConverterManager2 interface's methods.
charsetData
Various charset-related data.
Non-localizable. Extensible String Bundle. Strings should be accessed
through nsICharsetConverterManager2 interface's methods
Plans and ideas for future improvements
XXX This list is far from complete. I should finish it and sync it up with the other i18n documents.Need help? Have questions? Ideas? Want to help? Write on the mozilla.i18n newsgroup or contact me: cata@netscape.com.