Questions tagged [locale]

In computing, locale is a set of parameters that defines the user's language, country and any special variant preferences that the user wants to see in their user interface. Usually a locale identifier consists of at least a language identifier and a region identifier.

Examples of variable output controlled by a locale is whether a date is displayed as 25/12/2012 or 12/25/2012 or some other format, and whether a decimal number is displayed as 123,456.78 or 123.456,78

5203 questions
3
votes
1 answer

Translating external api results in Drupal

We're building a multi-language Drupal stack and one of the concerns we have is that our payment processor is going to have to send back some information to us. We've been able to narrow this down so that the strings they're sending back look…
Chuck Vose
  • 4,560
  • 24
  • 31
3
votes
1 answer

How to display on the same JSP a resource bundle key several time but in different locales?

Dear Struts 2 and JSP experts, I can't figure out how to display on the same page a resource bundle key several time but with different locales. Resource Bundles: global_fr.properties #Global messages global.label = Texte en Français …
bgillis
  • 261
  • 6
  • 18
3
votes
2 answers

Libgdx I18NBundle, cant show scandinavian letters

So I've created a I18NBundle for all my strings to support different languages, my problem is that when i draw the strings in my game, the letters æ ø and å wont show, so that something that should be: "Spil på tid" shows up like: "Spil p tid",…
Jolly
  • 399
  • 2
  • 12
3
votes
1 answer

Impose the environment's locale in a Perl block

I have some Perl code which is executed in a context where all command line arguments, inputs and outputs are encoded in the encoding given by the LC_CTYPE environment variable (or more generally the LC_CTYPE setting determined from the…
Gilles 'SO- stop being evil'
  • 104,111
  • 38
  • 209
  • 254
3
votes
0 answers

Why is the PHP localeconv() returning an empty array on Windows 7?

So, localeconv() seems to be ignoring the locale in my php script, and returns a basically empty array. I've found numerous questions, etc. the answers to which all boiled down to the locale not being set correctly for Windows. I believe this…
3
votes
2 answers

How to translate pygtk; glade; gtk.Builder() application?

This is my first trial in translating pygtk glade; I have created Rockdome.mo file on the following dir:./locale/ar/LC_MESSAGES/Rockdome.mo def apply_locale(self , lang): domain = "Rockdome" local_path = basefolder+"/locale" …
esnadr
  • 427
  • 3
  • 18
3
votes
2 answers

How to override the behavior of Input type="file" Browse button?

I need to change the locale/language of the browse button in input type="file" We have a special function to change the locale of any text to the browser language such as en-US es-MX etc. Say changeLang("Test"); // This will display test in Spanish…
user292099
3
votes
2 answers

Rails where is en.yml

Where can Ifind the default em.yml file. I know for translated files on GitHub but I would like to have EN version. Thx.
xpepermint
  • 35,055
  • 30
  • 109
  • 163
3
votes
1 answer

ActiveAdmin number_to_currency helper

I building a administration interface via ActiveAdmin. I have some resources like Products, at the Products i have an Article, Title, Description and Price columns. Everything working well, but i have a little problem, at the Price column i use…
dPanda13
  • 265
  • 1
  • 3
  • 9
3
votes
1 answer

Python: Access Posix' locale database without setlocale()

The setup is a Django based website on an Ubuntu server system with lots of useful information in /usr/share/i18n/locales. The question: Can I access this pool of wisdom without using Python's locale.setlocale() afore? The reason: The docs say, that…
Boldewyn
  • 81,211
  • 44
  • 156
  • 212
3
votes
3 answers

Extract correct text from a wifstream regardless of encoding

Here is the program: http://codepad.org/eyxunHotThe encoding of the file is UTF-8. I have a text file named "config.ini" with the following word in it: ➑ball If I use notepad to save the file with "UTF-8" encoding, then run the program, according to…
scwizard
  • 31
  • 5
3
votes
1 answer

How to display correct Swedish currency on IOS?

I wrote the code below to display given price with a Swedish currency: +(NSString *) getPriceStringWithCurrencySymbolFor:(NSNumber *)price{ NSDictionary *components = [NSDictionary dictionaryWithObject:@"sv_SE" forKey:NSLocaleCurrencyCode]; …
Burak
  • 5,706
  • 20
  • 70
  • 110
3
votes
2 answers

Undefined reference to boost::locale:conv::between

I am trying to follow the answer to my previous question and use boost::locale::conv::between to get a UTF-8 string from vector containing UTF-16 data. My code is pretty much as in the answer (with some differences in how I get the char…
Aleks G
  • 56,435
  • 29
  • 168
  • 265
3
votes
3 answers

A language switcher in Symfony 2.4

I have an object Language, and I can add, delete and update languages from the admin page. What I want to do, is to add a language switcher, I put this html/twig code: {% for language in languages %}
  • SmootQ
    • 2,096
    • 7
    • 33
    • 58
  • 3
    votes
    3 answers

    Is there narrow characters version of iswctype() function?

    Is there any kind of narrow character function like there is iswctype() for wide characters? UPDATE I did not realize there was std::regex_traits::isctype(), otherwise I would have made the question explain the situation better: I am actually…
    wilx
    • 17,697
    • 6
    • 59
    • 114