translate.storage.pocommon

Package translate :: Package storage :: Module pocommon |
[hide private]
[frames] | no frames]

# Module pocommon

source code

Classes | [hide private]
| pounit
| pofile

Functions | [hide private]
unicode |
extract_msgid_comment(text) The one definitive way to extract a msgid comment out of an unescaped unicode string that might contain it. | source code
quote_plus(text) Quote the query fragment of a URL; replacing ' ' with '+' | source code
unquote_plus(text) unquote('%7e/abc+def') -> '~/abc def' | source code
encodingToUse(encoding) Tests whether the given encoding is known in the python runtime, or returns utf-8. | source code

Variables | [hide private]
| msgid_comment_re = `re.compile("_: (.*?)\n")`

Imports: re, urllib, base, poheader, state

Function Details | [hide private]

### encodingToUse(encoding) | source code
Tests whether the given encoding is known in the python runtime, or returns utf-8. This function is used to ensure that a valid encoding is always used.