[MPlayer-cvslog] r35961 - in trunk: Changelog input/input.c libvo/x11_common.c osdep/getch2.c osdep

Reimar Döffinger Reimar.Doeffinger at gmx.de
Fri Mar 15 02:57:16 CET 2013


On 15 Mar 2013, at 02:08, Ingo Brückl <ib at wupperonline.de> wrote:
>> Author: reimar
>> Date: Thu Mar 14 20:59:35 2013
>> New Revision: 35961
> 
>> Log:
>> Add support for binding any key in UTF-8 range.
> 
>> +    // Required so that XLookupString returns UTF-8
>> +    if (!setlocale(LC_CTYPE, "C.UTF-8") && !setlocale(LC_CTYPE, "en_US.utf8"))
>> +        mp_msg(MSGT_VO, MSGL_WARN, "Could not find a UTF-8 locale, some keys will no be handled.\n");
> 
> Just curious: Why doesn't a setlocale() call interfere here

As far as I can tell both locales behave in the way be expect/they do not significantly change behaviour compared to not setting the locale.

> and are these the
> two only UTF-8 locales allowed (what if someone only has de_DE.UTF-8, for
> example)?

Well, there are several hundred country/region codes, trying them all is hardly reasonable.
The C one is what we really want but is rare/new, the en_US one is the most commonly available alternative.


More information about the MPlayer-cvslog mailing list