Module:String2/doc

The module  contains 4 available calls that convert strings to upper, lower, sentence or title case.

The sentence case function finds the first letter and capitalises it, so it works properly with text containing wiki-markup. Compare  ->  with   -> Action game. Piped wiki-links are handled as well:  ->.

The title case function capitalises the first letter of each word in the text, apart from a number of short words recommended by The U.S. Government Printing Office Style Manual.

It would be useful to add further functions commonly used on strings.

Usage

 * - Shifts all characters to uppercase
 * - Shifts all characters to lowercase
 * - Capitalizes the first character
 * Although similar to magic words'  function, this call works even with piped wiki-links because it searches beyond leading brackets and other non-alphanumeric characters.
 * - Capitalizes the first character and shifts the rest to lowercase
 * - Capitalizes all words, except for,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  , and.

Parameters
The module takes one unnamed parameter comprising (or invoking as a string) the text to be converted.