TEXTDOMAIN(3) Library Functions Manual TEXTDOMAIN(3) NNAAMMEE textdomain - set domain for future gettext() calls SSYYNNOOPPSSIISS ##iinncclluuddee <> cchhaarr ** tteexxttddoommaaiinn ((ccoonnsstt cchhaarr ** _d_o_m_a_i_n_n_a_m_e));; DDEESSCCRRIIPPTTIIOONN The tteexxttddoommaaiinn function sets or retrieves the current message domain. A message domain is a set of translatable _m_s_g_i_d messages. Usually, every software package has its own message domain. The domain name is used to determine the message catalog where a translation is looked up; it must be a non-empty string. The current message domain is used by the ggeetttteexxtt, nnggeetttteexxtt functions, and by the ddggeetttteexxtt, ddccggeetttteexxtt, ddnnggeetttteexxtt and ddccnnggeetttteexxtt functions when called with a NULL domainname argument. If _d_o_m_a_i_n_n_a_m_e is not NULL, the current message domain is set to _d_o_m_a_i_n_- _n_a_m_e. The string the function stores internally is a copy of the _d_o_m_a_i_n_n_a_m_e argument. If _d_o_m_a_i_n_n_a_m_e is NULL, the function returns the current message domain. RREETTUURRNN VVAALLUUEE If successful, the tteexxttddoommaaiinn function returns the current message domain, after possibly changing it. The resulting string is valid until the next tteexxttddoommaaiinn call and must not be modified or freed. If a memory allocation failure occurs, it sets eerrrrnnoo to EENNOOMMEEMM and returns NULL. EERRRROORRSS The following error can occur, among others: EENNOOMMEEMM Not enough memory available. BBUUGGSS The return type ought to be ccoonnsstt cchhaarr **, but is cchhaarr ** to avoid warn- ings in C code predating ANSI C. SSEEEE AALLSSOO ggeetttteexxtt(3), nnggeetttteexxtt(3), bbiinnddtteexxttddoommaaiinn(3), bbiinndd__tteexxttddoommaaiinn__ccooddeesseett(3) GNU gettext 0.20.1 May 2001 TEXTDOMAIN(3)