Click or drag to resize
Localiser Class
A class that can localise Windows Forms elements with strings taken from a strings resource file.
Inheritance Hierarchy
SystemObject
  VirtualRadar.LocalisationLocaliser

Namespace: VirtualRadar.Localisation
Assembly: VirtualRadar.Localisation (in VirtualRadar.Localisation.dll) Version: 1.0.0.0 (1.0.0.0)
Syntax
public class Localiser

The Localiser type exposes the following members.

Constructors
  NameDescription
Public methodLocaliser(Type)
Creates a new object.
Public methodLocaliser(LocalisedStringsMap)
Creates a new object.
Top
Methods
  NameDescription
Public methodAddResourceStrings
Adds strings from a resource file to the localiser.
Public methodColumnHeader
Localises a column header.
Public methodControl
Localises an arbitrary control.
Public methodEquals
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodForm
Localises a form's title and then recursively localises all of the controls on the form.
Public methodGetHashCode
Serves as a hash function for a particular type.
(Inherited from Object.)
Public methodGetLocalisedText
Returns the localised version of the text passed across.
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodListViewColumns
Localises the columns in a list view.
Public methodLookup
Returns the localised version of the string identifier passed across.
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodToolStrip
Localises a toolstrip.
Public methodToolStripItem
Localises a toolstrip item.
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Top
Remarks

This class can be used by the plugins to translate strings for their UI.

All methods look for elements whose text contains tags delimited by double-colons. Those tags are replaced with strings whose name matches the text within the double-colon. So for example, a Label whose Text property is "::UserName::" would be subsituted with the content of the UserName string. Only chunks within double-colons are substituted.

See Also