import "github.com/gosexy/gettext"
Package gettext provides bindings for GNU Gettext.
var (
// LcAll is for all of the locale.
LcAll = uint(C.LC_ALL)
// LcCollate is for regular expression matching (it determines the meaning of
// range expressions and equivalence classes) and string collation.
LcCollate = uint(C.LC_COLLATE)
// LcCtype is for regular expression matching, character classification,
// conversion, case-sensitive comparison, and wide character functions.
LcCtype = uint(C.LC_CTYPE)
// LcMessages is for localizable natural-language messages.
LcMessages = uint(C.LC_MESSAGES)
// LcMonetary is for monetary formatting.
LcMonetary = uint(C.LC_MONETARY)
// LcNumeric is for number formatting (such as the decimal point and the
// thousands separator).
LcNumeric = uint(C.LC_NUMERIC)
// LcTime is for time and date formatting.
LcTime = uint(C.LC_TIME)
)var (
LC_ALL = LcAll
LC_COLLATE = LcCollate
LC_CTYPE = LcCtype
LC_MESSAGES = LcMessages
LC_MONETARY = LcMonetary
LC_NUMERIC = LcNumeric
LC_TIME = LcTime
)Deprecated but kept for backwards compatibility.
BindTextdomain sets the directory containing message catalogs.
BindTextdomainCodeset sets the output codeset for message catalogs on the given domainname.
DCGettext is like Gettext(), but looks up the message in the specified domain and category.
func DCNGettext(domainname string, msgid string, msgidPlural string, n uint64, category uint) string
DCNGettext is like NGettext(), but looks up the message in the specified domain and category.
DGettext is like Gettext(), but looks up the message in the specified domain.
DNGettext is like NGettext(), but looks up the message in the specified domain.
Gettext attempts to translate a text string into the user's system language, by looking up the translation in a message catalog.
NGettext attempts to translate a text string into the user's system language, by looking up the appropriate plural form of the translation in a message catalog.
SetLocale sets the program's current locale.
Sprintf is like fmt.Sprintf() but without %!(EXTRA) errors.
Textdomain sets or retrieves the current message domain.
| Path | Synopsis |
|---|---|
| _examples | |
| go-xgettext |
Package gettext imports 4 packages (graph) and is imported by 48 packages. Updated 2017-12-14. Refresh now. Tools for package owners.